File:  [LON-CAPA] / loncom / html / adm / help / tex / Authoring_Daxe_FAQ.tex
Revision 1.1: download - view: text, annotated - select for diffs
Wed Mar 27 16:39:44 2024 UTC (3 months, 1 week ago) by raeburn
Branches: MAIN
CVS tags: version_2_12_X, version_2_11_4_msu, HEAD
- Contents of tutorial/getting_started.xhtml divided into 11 .tex files
- Two links added to "Help" dropdown in Daxe Editor:
   one to Daxe FAQ,
   one to LON-CAPA Math Syntax (describes lm tag).
- Existing "Getting Started" link points to composite of 9 .hlp files
  to facilitate multilingual support.

\label{Authoring_Daxe_FAQ}

\textbf{Daxe Editor -- Frequently Asked Questions}

\begin{description}

  \item[\textmd{\normalsize\textit{Is Daxe compatible with the other LON-CAPA editors?}}]

It should be. But a conversion is needed before a document can be loaded into Daxe, 
and a conversion is done afterwards to match the syntax of the other editors.  
So it is possible that the initial conversion fails, and it is possible that the syntax 
or spacing is altered in some ways. Still, this should not change the output.

  \item[\textmd{\normalsize\textit{Which browsers are supported?}}]

Recent versions of all browsers, on all platforms.  
This constraint is related to the technology used to create Daxe, which is Dart. No plugin is needed.

  \item[\textmd{\normalsize\textit{What is an element?}}]

``element'' is a technical term related to the XML syntax used by Daxe.  
It refers to a part of the document, starting with a start tag and ending with an end tag.  
A hierarchical structure can be created by putting elements inside other elements.  
The tags are usually hidden in LON-CAPA Daxe (a whole element being often represented as a box),
but you will see them if you look at the XML source with the File menu.

  \item[\textmd{\normalsize\textit{What is an attribute?}}]

An attribute is a property of an element. It has a name and a value.  
For instance, the \texttt{img} element (which represents an image) has a
\texttt{src} attribute which gives the path to the image file.

  \item[\textmd{\normalsize\textit{How do I select an element?}}]

The easiest way is to double-click on the title when there is one, 
but you can also click before the element, hold and drag until after its end.

  \item[\textmd{\normalsize\textit{How do I move an element?}}]

Select it, cut it with \texttt{ctrl-X}, and paste it where you want with
\texttt{ctrl-V}.

  \item[\textmd{\normalsize\textit{How do I remove an element?}}]

The easiest way is to do a right-click on the title and choose ``Remove''.  
But the \texttt{backspace} or \texttt{del} keys can be used too.

  \item[\textmd{\normalsize\textit{Why is Daxe sometimes not selecting parts of elements?}}]

Daxe is only doing operations that keep the document syntax correct.
So, it will not for instance select a start tag without the end tag, 
because doing operations on a single tag could break the whole document.  
But if you start a selection before a start tag, and continue 
until after the end tag, the whole element will be selected.

  \item[\textmd{\normalsize\textit{How can I insert a movie or sound?}}]

Use the HTML5's \texttt{video} or \texttt{audio} element (in the HTML-Media menu),
with the path to your previously uploaded video/audio file in the \texttt{src} attribute,
and for a video the dimensions in pixels in the \texttt{width} and \texttt{height} attributes.

Remember that not all browsers support all formats, so it is actually better to provide 
several files with the \texttt{source} element instead of using the \texttt{src} attribute.

  \item[\textmd{\normalsize\textit{My Perl script does not seem to be running ...}}]

Make sure you are using the right \texttt{type} attribute.
If a script has no \texttt{type} attribute, it is assumed to be Javascript.

  \item[\textmd{\normalsize\textit{My math is not looking great in the preview ...}}]

The preview uses the default math display engine for your domain (which may not be MathJax),
unless you have set your own user preference which overrides the default.

  \item[\textmd{\normalsize\textit{What is the validation (in the File menu) checking?}}]

It checks that the elements used in the document really exist in the language, 
and that each element inside a parent is allowed under. It also checks for the 
order of the elements when there is a constraint about that, 
but it is rare with LON-CAPA. It also checks for the syntax of each attribute.

The fact that a document validates does not mean that it will run well in LON-CAPA.  
For instance, there might be an error in a Perl script which will only be caught 
when it is executed. But it helps to create documents that will run well everywhere.

  \item[\textmd{\normalsize\textit{How do I change options for the preview?}}]

It is not possible within the Daxe page, but you can use the ``Problem Testing'' display
of the problem (e.g., by expanding the LON-CAPA menu block (if collapsed) and then 
pushing the ``Save and View'' button to try different preview options.

  \item[\textmd{\normalsize\textit{Can I copy/paste source code between Daxe and the LON-CAPA text editor?}}]

No ! The two editors are using a different syntax. 
Daxe is using the XML syntax, while the text editor is using a LON-CAPA-specific syntax.  
For instance, XML special characters are encoded inside m elements and attribute values with Daxe, 
but that syntax would not work in LON-CAPA without a conversion.

So if you need to reuse source code from Daxe with the text editor, save the document, exit Daxe, 
and open the problem with the text editor before copying code.

  \item[\textmd{\normalsize\textit{How can I get the response field on the same line as the question?}}]

Paragraph tags are hidden in the editor, and a paragraph is just indicated with a gray 
\P mark on the lower right. If a response appears on a different line in the preview, 
it might be because it is in a different paragraph, or outside of a paragraph.  
To move the response in the paragraph with the question, one can select it, cut it, 
and paste it after the text in the previous paragraph. The \P mark will appear on the 
lower right of the response. Note that this is only possible with some responses, 
since other responses display as blocks and cannot be put inside a paragraph.

\end{description}

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>