summaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authoralbert-github <albert.tests@gmail.com>2021-04-20 12:28:19 (GMT)
committeralbert-github <albert.tests@gmail.com>2021-04-20 12:28:19 (GMT)
commitb95b4766c7107e9b3ff0969534fe54c131412249 (patch)
treebe30783533a9dc0955ab7697cd65921824a52de6 /doc
parent98c67549bc3cd855873e0ef5eeab7c6410699d78 (diff)
downloadDoxygen-b95b4766c7107e9b3ff0969534fe54c131412249.zip
Doxygen-b95b4766c7107e9b3ff0969534fe54c131412249.tar.gz
Doxygen-b95b4766c7107e9b3ff0969534fe54c131412249.tar.bz2
Problems with some commands in MathJax
Especially with commands like `\f$\mbox{\LaTeX}\f$`MathJax has some problem as it is not, yet, able to use the commands `\raise` and `lower` inside the `\mbox` as used in this LaTeX command. Also switching in and out of math-mode doesn't work as the resulting code either doesn't work in MathJax or in LaTeX, hence the new command s `\f(` and `\f)`.
Diffstat (limited to 'doc')
-rw-r--r--doc/Doxyfile4
-rw-r--r--doc/commands.doc19
-rw-r--r--doc/formulas.doc29
3 files changed, 42 insertions, 10 deletions
diff --git a/doc/Doxyfile b/doc/Doxyfile
index caf6229..15d210e 100644
--- a/doc/Doxyfile
+++ b/doc/Doxyfile
@@ -51,8 +51,8 @@ USE_PDFLATEX = YES
STRIP_CODE_COMMENTS = NO
HTML_STYLESHEET = doxygen_manual.css
HTML_EXTRA_FILES = doxygen_logo.svg
-ALIASES = LaTeX="\f$\mbox{\LaTeX}\f$"
-ALIASES += TeX="\f$\mbox{\TeX}\f$"
+ALIASES = LaTeX="\f(\LaTeX\f)"
+ALIASES += TeX="\f(\TeX\f)"
ALIASES += forceNewPage="\latexonly \newpage \endlatexonly"
LATEX_BATCHMODE = YES
LATEX_EXTRA_STYLESHEET = manual.sty
diff --git a/doc/commands.doc b/doc/commands.doc
index eff2f42..ffab530 100644
--- a/doc/commands.doc
+++ b/doc/commands.doc
@@ -104,6 +104,8 @@ documentation:
\refitem cmdexample \\example
\refitem cmdexception \\exception
\refitem cmdextends \\extends
+\refitem cmdfrndopen \\f(
+\refitem cmdfrndclose \\f)
\refitem cmdfdollar \\f\$
\refitem cmdfbropen \\f[
\refitem cmdfbrclose \\f]
@@ -3191,6 +3193,23 @@ class Receiver
\sa section \ref formulas "formulas" for an example.
<hr>
+\section cmdfrndopen \\f(
+
+ \addindex \\f(
+
+ Marks the start of an in-text formula, but contrary to \ref cmdfdollar "\\f$" it will
+ not explicitly open the math-mode in \LaTeX.
+ \sa section \ref cmdfrndclose "\\f)" and section \ref formulas "formulas".
+
+<hr>
+\section cmdfrndclose \\f)
+
+ \addindex \\f)
+
+ Marks the end of an in-text formula started with \ref cmdfrndopen "\\f(".
+ \sa section \ref cmdfrndopen "\\f(" and section \ref formulas "formulas".
+
+<hr>
\section cmdfbropen \\f[
\addindex \\f[
diff --git a/doc/formulas.doc b/doc/formulas.doc
index e9a8076..1a87977 100644
--- a/doc/formulas.doc
+++ b/doc/formulas.doc
@@ -34,10 +34,10 @@ require the above tools. If you enable \ref cfg_use_mathjax "USE_MATHJAX" in
the configuration then the latex formulas will be copied to the HTML "as is" and a
client side javascript will parse them and turn them into (interactive) images.
-There are three ways to include formulas in the documentation.
+There are four ways to include formulas in the documentation.
<ol>
<li>Using in-text formulas that appear in the running text.
- These formulas should be put between a pair of \\f\$
+ These formulas should be put between a pair of \ref cmdfdollar "\\f\$"
commands, so
\verbatim
The distance between \f$(x_1,y_1)\f$ and \f$(x_2,y_2)\f$ is
@@ -47,8 +47,19 @@ There are three ways to include formulas in the documentation.
The distance between \f$(x_1,y_1)\f$ and \f$(x_2,y_2)\f$ is
\f$\sqrt{(x_2-x_1)^2+(y_2-y_1)^2}\f$.
<br>
+<li>Using in-text formulas that appear in the running text, contrary to
+ \ref cmdfdollar "\\f$" it will not explicitly open the math mode in \LaTeX.
+ These formulas should be put between \ref cmdfrndclose "\\f(" and
+ \ref cmdfrndopen "\\f)" commands, so
+\verbatim
+ The LaTeX and Tex logos are: \f(\LaTeX \f) and \f(\TeX \f).
+\endverbatim results in:
+
+ The LaTeX and Tex logos are: \f(\LaTeX \f) and \f(\TeX \f).
+<br>
<li>Unnumbered displayed formulas that are centered on a separate line.
- These formulas should be put between \\f[ and \\f] commands.
+ These formulas should be put between \ref cmdfbropen "\\f[" and
+ \ref cmdfbrclose "\\f]" commands.
An example:
\verbatim
\f[
@@ -74,9 +85,9 @@ There are three ways to include formulas in the documentation.
\right|
\f]
<li>Formulas or other latex elements that are not in a math
- environment can be specified using \\f{environment}, where
+ environment can be specified using \ref cmdfcurlyopen "\\f{environment}", where
\c environment is the name of the \LaTeX environment,
- the corresponding end command is \\f}. Here is an example for an
+ the corresponding end command is \ref cmdfcurlyclose "\\f}". Here is an example for an
equation array
\verbatim
\f{eqnarray*}{
@@ -94,9 +105,11 @@ There are three ways to include formulas in the documentation.
&=& 9.82066032\,\mbox{m/s}^2
\f}
</ol>
-For the first two commands one should make sure formulas contain
-valid commands in \LaTeX's math-mode. For the third command
-the section should contain valid command for the specific environment.
+For the first and third commands one should make sure formulas contain
+valid commands in \LaTeX's math-mode.
+The second command should valid text-mode commands that also work in math-mode when using
+\ref cfg_use_mathjax "USE_MATHJAX".
+For the fourth command the section should contain valid command for the specific environment.
\warning Currently, doxygen is not very fault tolerant in recovering
from typos in formulas. It may be necessary to remove the