
|
|
When to use <display> tag |
Functions that must be inside of a <display> when outputting text:
&prettyprint &tex &web &xmlparseFunctions that shouldn't be used but if used need it &dollarformat (use pretty print instead with '$2f') &var_in_tex | |
|
More gory details: When coverting the HTML of a problem to LaTeX, Lon-CAPA assumes that the contents of the entire problem, and the contents of all variables that it expands is HTML,. LaTeX has some charactes that are special, as they tell it to do special things. In order to not have the characters that HTML generates confuse LaTeX we need to protect them. The problem with the &xmlparse(), &prettyprint() etc functions is that when printing, these functions rather than genearte HTML, they generate LaTeX code. So the assumption that everything is in HTML is wrong, and can cause things to break. Thus enters the <display> tag. The <display> tag says, that this variable's value or function's result is safe to pass directly to the LaTeX engine. | |
| [Append to This Answer] |
| Previous: |
|
| Next: |
|
| ||||||||||