From 0f0c03772e184087888f070cd49501619f9f1743 Mon Sep 17 00:00:00 2001 From: jkriege2 Date: Mon, 6 Jun 2022 14:16:50 +0200 Subject: [PATCH] NEW: JKQTMathText supports new instructions: \cancel, \xcancel, \bcancel, \sout --- doc/dox/todo.dox | 2 +- doc/dox/whatsnew.dox | 1 + doc/images/mathparser/MTDbcancel.png | Bin 0 -> 4325 bytes doc/images/mathparser/MTDcancel.png | Bin 0 -> 4085 bytes doc/images/mathparser/MTDstrike.png | Bin 0 -> 2051 bytes doc/images/mathparser/MTDxcancel.png | Bin 0 -> 5269 bytes examples/jkqtmathtext_test/testform.cpp | 9 +++--- lib/jkqtmathtext/jkqtmathtext.cpp | 40 ++++++++++++++++++++++++ lib/jkqtmathtext/jkqtmathtext.h | 11 ++++++- 9 files changed, 57 insertions(+), 6 deletions(-) create mode 100644 doc/images/mathparser/MTDbcancel.png create mode 100644 doc/images/mathparser/MTDcancel.png create mode 100644 doc/images/mathparser/MTDstrike.png create mode 100644 doc/images/mathparser/MTDxcancel.png diff --git a/doc/dox/todo.dox b/doc/dox/todo.dox index d1e3dda052..37e49c4bb9 100644 --- a/doc/dox/todo.dox +++ b/doc/dox/todo.dox @@ -38,7 +38,7 @@ This page lists several todos and wishes for future version of JKQTPlotter
  • JKQTMathText: diff --git a/doc/dox/whatsnew.dox b/doc/dox/whatsnew.dox index 39f205b548..4bdcf604c2 100644 --- a/doc/dox/whatsnew.dox +++ b/doc/dox/whatsnew.dox @@ -26,6 +26,7 @@ Changes, compared to \ref page_whatsnew_V4_0_0 "v4.0.0" include:
  • NEW: new "seaborn" style for plots
  • NEW/BREAKING CHANGE: changed JKQTPColorDerivationMode into a struct, which extends its capabilities above the previously available few enum-items
  • NEW: added debug-feature to show boxes around text in the plot
  • +
  • NEW: JKQTMathText supports new instructions: \cancel, \xcancel, \bcancel, \sout
  • \subsection page_whatsnew_TRUNK_DOWNLOAD trunk: Download diff --git a/doc/images/mathparser/MTDbcancel.png b/doc/images/mathparser/MTD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/images/mathparser/MTDcancel.png b/doc/images/mathparser/MTDcancel.png new file mode 100644 index 0000000000000000000000000000000000000000..04bb022cd05c22ff0d0cb2c07deb947fed991f18 GIT binary patch literal 4085 zcmbW4XE@t@XwhbrF@zv$h>2c8h%Q?6 z-g_syVe*{&{qTN%uIIx!XYF&Hz0X>Euj{{lD^mM~3e_E!J0v6|RH|@A9TF1Kdw>nS zMF!kk_JdM^2dTS`iabe4AKL~nxMnM-DMvz58b@(yejOO!M!^l-Nl5Ot{CkmhxD;3c zFF_tk`X0J2HXdH)Zq_6!Zr0XFcRLpk(^t2EDb!A?igJ41raS4k^#uhcfZT0svGVKq$XwCS>p_}3UhI4 ztuDJb_r3II&^^Lz5xv@>Pv2o+z}`pb+*8}tj8oC^mbs){ZC)hn2>gzcL?(-BR_6^p zP6+)((AMT++sCY%^Tx51+$4P~o!VsogQ?Wx`Sej3H2V4zET_WlAor)Di6sAnNvj*P zJpSK1prj#=vHb6U$0UMi$3Z`u^EcJ9F{_b$>_%r@`yb2?DHmVU<UCyO&I;{^zH9MX$fUDtZlA(_VA_;X@w42@w^ntgQS9JJn$Sqk%H(?mW%3 zlV%Db*wxVx6{|%3>8$VJa+g9KcOdcdbS^Nk+@`nAYfsv3x$~*}YOz@(F+ofEd?Wu8 zkw|dSLuaw5qNna_UB<}}z0dX+Djmmu5HGfb8ZX`K?Cek|R9h6o;Yznk-TNaAoTxR& zyY;LW=~7heQXcKm%#U9ek5{{Zeflqt$IJ>AX-42t-x=II&o2-AtDPqPj2gMb0KprZ z7*;u*&xcSm^6A|QV032?GOaglcn3IP^_O^M=DSnb_JL_{vhwls=U4qQe-$IQ6~r-% zv8#YbnFy@ctdH$tYotHn#CfVpz}FLET!T8^90B`om(Di$#(`y|MMMr7PG<>!x`hG> zJCccK2<@1hP9NlKy}hxCg{9?9Y7RCKXfRWbd}&iBQ}!RVBtCJM*~DZ14T!T$PEIcUnHPtI(|8XKiYPIz4g5>oYy3-0#tZ&s@v`OoX&EulTHXkyS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5=ONJXsWihcCFh=bdfqhk~x8DY-h%CA33?^Nt*q%DRBD@rOytR6;^l|J5guOq{17>u0Geu@{=7~oHA#m7f zt|T`nGinfx8$58Tl?6H}9$l#n&5e6`EL{oz_dO+)6>@kw2kpyf5bv({rhSzd+mje; s+kIW?65q&hr%mABUbn`%tc*y_2}!s4!%y@Ex^fa#r5B1N@^6Cw18;WkVgLXD literal 0 HcmV?d00001 diff --git a/doc/images/mathparser/MTDstrike.png b/doc/images/mathparser/MTDstrike.png new file mode 100644 index 0000000000000000000000000000000000000000..37ee86445a4e04ac8a4c82a01afaccc6d4b18ad1 GIT binary patch literal 2051 zcmV+e2>kbnP)Px#1ZP1_K>z@;j|==^1poj532;bRa{vGi!vFvd!vV){sAK>D01|XXSaefwW^{L9 za%BKVa%E+1b7*gLUR4MM000MiNkl3-G5Xa9GP^U>lL6riDG!$E=;010K ziZtmdQ5qs1APvn%qDxCjq&xsfyZ~A$RT@gPVx`r7DBQI@V|&K)_c`a1dlMGsCl@*P z_&*=^oWtE6mX6~Hyd@k*;Vt1f3U3L=QFu!@j>22QaTMMXj-&9Fa2&;Lw8Z)0Fbt1R zF8MKWdGgp!t`FqWaprIfEs?Hgy`a<##QHDoX4Th+jB}j3$zpDNKj3TU8(ZT1WQ9_I zS2kCCQw60iyrbiqRht;0iZ9>6!*ia9q&(EjI=DPJnJdY!GhE6T@*UM!utGNT_@35f zOU$l~`IK~8BFwM%C74RHu9gVP>u%W9STUPftlSb4HJZz2FYRX4yWFHUy_Q%jt2XQFXbuhjL#$>gDR3H(n=Gvh+;Au zZ2;mYziA=cl0a>V>+9=ZBD?qR4a3$>`a7_*6>RU_-{nVM7c(Pl9kXd6GyVGmaJXuN>G7dwex`g<_4)P@%8K1mw{(bwufQ& zY5bE3Guuy|@dFzSawb5N!}j)e+WK@iJY*4GQ<`KURH9L%8HiSBU$b%2sE>-20o!Rx z3xd38YK~t6tF^HtY;k~fp2~(XWGhCAASW15i$wHhRFZKs%V9}@S;e$QU>i*}9#Irz zh~xr`m%q}7g1#l@A5QcU(H}7NTaXOeFA;tH(Dx~SmKsTEA0E)ow6Xb==FcqK<6y?3 zQJ`c49I;qHf*`L>ICHQ*3(Z~iaI}c=vIXn>IxDByJ>3D zFT%Jit%2w*{*QdrO`6sA?SrL!}zm=X>nptjMp+|<=E^`!}$82))( z0|0xllnt%`qm(XSV0j;u%#e!R-J92NV91QaD@#Za5O*BxIym$^=(|*_QmW8@rYEK}n`t zfTGUN7~YOta8zXl34*+6YRWI9A58K+TQk?QQ#o3OOAwZub`PpS*wWdVkz&>vu+3!C zuVT)mtdJ>4tlts@3yG~*$^=&d*{b|<8m%PU$MF9mYSYXJ^)Yxmuxka7AczmwW)`^$ zHrLzBL^yrtUp&P#qe^xP*k+K2XXiB=I85D23ojd}=;mvQK)VMf4 zIMp+!`%!Cg#*Y`rQYxFB?M0*gBYu?Q-ND1Swx?vtKC5sdjSX+CuJd^H{1I7(Kaxc) z3K<+N;_QRx@942RD7E3y!9{#ziO6{j@8R*QY>5OxUKEckb6J`iAX%2k)v@UuEjaT0 zSZyd^N`Yk(G_UJCHhMbM=HhrSIn8I$-T_-Wc{%fBTTHu)4@(?Mu1q}rVkQGFlX0Z& zLXbSh0#ZgqSOP8appgqRVQiLG~MvUf7Il6JOzFX=;qLM0o?N)tIArjIPCFjc{?sDha+ZWO=$j*&FhP zu|y&pgs^i>=$=ICA?CWND#;H@ngPXRzopSVSrulITsLlt>a~PGyrF57f9Is`RLLZ& zZ;;qUeI;aKUzn@ko;PEH38TC%n8lfC7I1&>4* zNq`BK-P=!f_Pd5{{$rmT(+N{vBO@z<&35OE{at z{I}NsM_+hLIF4fYSkK5GomT(;~er6qS3D*JRXVw}1y}BA1*PlPLz;b#0P`(gk9002ovPDHLkV1hlR)o1_! literal 0 HcmV?d00001 diff --git a/doc/images/mathparser/MTDxcancel.png b/doc/images/mathparser/MTDxcancel.png new file mode 100644 index 0000000000000000000000000000000000000000..6cb7483b2eaef05906af2aa523a2f30f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XdmUb4+-A?(@X!&1QBe1BwW4c04Xh%~Sz@w~%bP zE4J95cyABis1!*?(j8Izh^-Pyqdr{ciC8(?qR)6*khT*=1Ax4qOE3LK%UR^|bXWHdex zU=TtH#os;G8cmPzx5NA8{v@B7o7-+ZBVi=T#d{fbwi=&w#l--}QMqWpDgvS#d*|&6 zV2f*1YW&0W>O+R$Wti0kpQM+Da#+S2waALS!r^qxn}~82X?H(U(}kTGNqT{%I`66o z{9+wBB_-&t>Z?`;+1VHScHiBGk9xbp)i8s7QBfMvF==;MSbpy<);tw`?sfK+l+?n( zx6*6x3dyH*7rmk`VXGj;IAP_Lq%7) I9BC2qU#r2%0RR91 literal 0 HcmV?d00001 diff --git a/examples/jkqtmathtext_test/testform.cpp b/examples/jkqtmathtext_test/testform.cpp index 2388dbdb1e..d98cfa327c 100644 --- a/examples/jkqtmathtext_test/testform.cpp +++ b/examples/jkqtmathtext_test/testform.cpp @@ -29,7 +29,8 @@ TestForm::TestForm(QWidget *parent) : ui->cmbTestset->addItem("text 0", "text"); ui->cmbTestset->addItem("text 1", "text \\mathbf{bold}"); ui->cmbTestset->addItem("text 2", "text \\mathbf{bold}\\textcolor{red}{RED}"); - ui->cmbTestset->addItem("decoration", "$\\vec{x}\\vec{X}\\vec{\\psi} -- \\dot{x}\\dot{X}\\dot{\\psi} -- \\ddot{x}\\ddot{X}\\ddot{\\psi} -- \\overline{x}\\overline{X}\\overline{\\psi} -- \\underline{x}\\underline{X}\\underline{\\psi} -- \\hat{x}\\hat{X}\\hat{\\psi} -- \\tilde{x}\\tilde{X}\\tilde{\\psi} -- \\uul{x}\\uul{X}\\uul{\\psi} -- \\ool{x}\\ool{X}\\ool{\\psi} -- \\bar{x}\\bar{X}\\bar{\\psi} -- \\arrow{x}\\arrow{X}\\arrow{\\psi}$"); + ui->cmbTestset->addItem("decoration: math", "$\\vec{x}\\vec{X}\\vec{\\psi} -- \\dot{x}\\dot{X}\\dot{\\psi} -- \\ddot{x}\\ddot{X}\\ddot{\\psi} -- \\overline{x}\\overline{X}\\overline{\\psi} -- \\underline{x}\\underline{X}\\underline{\\psi} -- \\hat{x}\\hat{X}\\hat{\\psi} -- \\tilde{x}\\tilde{X}\\tilde{\\psi} -- \\uul{x}\\uul{X}\\uul{\\psi} -- \\ool{x}\\ool{X}\\ool{\\psi} -- \\bar{x}\\bar{X}\\bar{\\psi} -- \\arrow{x}\\arrow{X}\\arrow{\\psi} -- \\cancel{x}\\cancel{X}\\cancel{\\psi} -- \\bcancel{x}\\bcancel{X}\\bcancel{\\psi} -- \\xcancel{x}\\xcancel{X}\\xcancel{\\psi} -- \\sout{x}\\sout{X}\\sout{\\psi}$"); + ui->cmbTestset->addItem("decoration: text", "Text \\ul{underlined Text Equator} -- \\ol{overlined Text Equator} -- \\sout{striked out Text Equator} -- \\cancel{canceled out Text Equator} -- \\bcancel{b-canceled out Text Equator} -- \\xcancel{x-canceled out Text Equator}"); ui->cmbTestset->addItem("mathtest", "This is normal text: $this is math:\\langle r^2(\\tau)\\rangle=\\left\\langle (\\vec{r}(t)-\\vec{r}(t+\\tau) )^2\\right\\rangle\\ \\ \\ g(\\tau)=\\frac{1}{N}\\cdot\\left(1+\\frac{2}{3}\\frac{\\langle r^2(\\tau)\\rangle}{w_{xy}^2}\\right)^{-1} \\lfloor\\rfloor\\lceil\\rceil\\langle\\rangle\\left\\{\\va\\left|\\|\\va\\|_2\\geq2\\right.\\right\\} \\vr\\vR\\frac{\\sqrt{\\sqrt{\\sqrt{\\sum_{i=0}^\\infty \\hat{i}^2}+y^\\alpha}+1}}{\\dot{v}\\equiv\\ddot{r}}\\argmin_{\\vec{k}}\\sum_{\\sqrt{i}=0}^{N}\\int_{x_0}^{x_1}\\left(\\left(\\left(x\\right)\\right)\\right)\\underbrace{\\left[\\left\\{\\frac{\\partial f}{\\partial x}\\right\\}\\cdot\\frac{1}{2}\\right]}{\\text{underbraced text \\hbar}}\\cdots\\frac{\\sqrt{\\sum_{i=0}^2 \\hat{i}^2}+y^\\alpha}{\\dot{v}\\equiv\\ddot{r}}, \\hat{t}\\hat{T} \\overbrace{\\left|\\sqrt{x\\cdot Y}\\right|}{\\propto\\bbN\\circ\\bbZ} \\left<\\arrow{x(\\tau)}\\cdot\\vec{R}(t+\\bar{\\tau})\\right> \\alpha\\beta\\gamma\\delta\\epsilon\\Gamma\\Delta\\Theta\\Omega \\left\\_\\left~\\cbrt{\\hbar\\omega}\\right~\\right\\_$"); ui->cmbTestset->addItem("upper/lower parantheses test:", "$\\text{bblabla} \\frac{1}{2}\\cdot\\left(\\frac{1}{\\mathrm{e}^x+\\mathrm{e}^{-x}}\\right)\\cdot\\left(\\frac{1}{\\frac{1+2}{5+x}}\\right)\\cdot\\left(\\frac{1}{\\exp\\left[-\\frac{y^2}{\\sqrt{x}}\\right]\\cdot\\exp\\left[-\\frac{1}{\\frac{1}{2}}\\right]}\\right) $"); ui->cmbTestset->addItem("ACF test", "$g_{rg}^{ab}(\\tau)=\\frac{1}{N}\\cdot\\left(1+\\frac{2}{3}\\frac{\\langle r^2(\\tau)\\rangle}{w_{xy}^2}\\right)^{-1}\\cdot\\left(1+\\frac{2}{3}\\frac{\\langle r^2(\\tau)\\rangle}{w_{xy}^2}\\right)^{-\\frac{1}{2}}$"); @@ -376,9 +377,9 @@ void TestForm::updateMath() //QString symbolTest="\\lfloor\\rfloor\\lceil\\rceil\\langle\\rangle\\sum\\int \\iint \\oint \\prod \\leftrightarrow \\leftarrow\\Leftarrow\\rightarrow\\Rightarrow\\pm\\mp\\leq\\geq\\ll\\gg\\hbar\\euro\\bbC\\bbH\\bbN\\bbP\\bbQ\\bbZ\\bbR\\Angstrom\\Alef\\Bet\\Gimel\\Dalet\\nexists\\ni\\notni\\circ\\tilde\\oiint\\oiiint\\emptyset\\odot\\ominus\\subsetnot\\DC\\bot\\cdots\\perthousand\\leftharpoonup\\rightharpoonup \\upharpoonleft \\downharpoonleft \\leftrightharpoon \\rightleftharpoon \\coprod \\leftharpoondown \\rightharpoondown \\nwarrow \\nearrow \\mapsto \\cent \\pound \\yen \\div \\multimap \\maporiginal \\mapimage \\bigcap \\bigcup \\benzene \\times \\cdot \\propto \\equiv \\Im \\Re \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ \\ "; //QString mathTest="$\\left\\|\\stackrel{1}{2}\\right\\|\\cdot\\left|\\begin{Bmatrix}1123&2^2&\\frac{3}{4}\\\\4&5_5&6\\\\72_8&8_{\\text{längerer Index}}&9&10&11\\end{Bmatrix}\\right|\\cdots f(x)$"; //QString mathTest="0"; - //QString text="x_0 \\sqrt{a^2+b^2}\\underbrace{underbrace}{x_0} (\\bf{Test})\\_\\it{Text} ... ! Äquator\\alpha\\beta $f(x)=\\sin(x{\\cdot}y)$ \\ul{Text\\ol{\\gamma}} \\script{Script}, \\tt{Typewriter}, \\sf{sans serif}"; - //QString text="$\\sum_{i=0_{j=-1_{k=-45}}}^{n^{m^{123456789}}}\\left(\\left(\\left(\\int_0^\\inf\\left[r+i^{\\left\\{2^2\\right\\}}\\right]{\\dd}r\\right)\\right)\\right)$ \\bf{Test}\\_\\it{Text} ... ! \\sc{&Äquator \\&}\\alpha\\beta $f(x)=\\sin(x\\cdot\\cos(a+{\\ii}b))$ \\ul{Text\\gamma} \\script{Script-Text}\\tt{ and Typewriter} \\sf{also sans serif}"; - //QString text="$\\sum_{i=0_{j=-1_{k=-45}}}^2\\left(\\left(\\left(\\int_0^\\inf\\left[r+i^{\\left\\{2^2\\right\\}}\\right]{\\dd}r\\right)\\right)\\right)$ \\bf{Test}\\_\\it{Text} ... ! \\sc{&Äquator \\&}\\alpha\\beta $f(x)=\\sin(x\\cdot\\cos(a+{\\ii}b))$ \\ul{Text\\gamma} \\script{Script-Text}\\tt{ and Typewriter} \\sf{also sans serif}"; + //QString text="x_0 \\sqrt{a^2+b^2}\\underbrace{underbrace}{x_0} (\\bf{Test})\\_\\it{Text} ... ! Equator\\alpha\\beta $f(x)=\\sin(x{\\cdot}y)$ \\ul{Text\\ol{\\gamma}} \\script{Script}, \\tt{Typewriter}, \\sf{sans serif}"; + //QString text="$\\sum_{i=0_{j=-1_{k=-45}}}^{n^{m^{123456789}}}\\left(\\left(\\left(\\int_0^\\inf\\left[r+i^{\\left\\{2^2\\right\\}}\\right]{\\dd}r\\right)\\right)\\right)$ \\bf{Test}\\_\\it{Text} ... ! \\sc{&Equator \\&}\\alpha\\beta $f(x)=\\sin(x\\cdot\\cos(a+{\\ii}b))$ \\ul{Text\\gamma} \\script{Script-Text}\\tt{ and Typewriter} \\sf{also sans serif}"; + //QString text="$\\sum_{i=0_{j=-1_{k=-45}}}^2\\left(\\left(\\left(\\int_0^\\inf\\left[r+i^{\\left\\{2^2\\right\\}}\\right]{\\dd}r\\right)\\right)\\right)$ \\bf{Test}\\_\\it{Text} ... ! \\sc{&Equator \\&}\\alpha\\beta $f(x)=\\sin(x\\cdot\\cos(a+{\\ii}b))$ \\ul{Text\\gamma} \\script{Script-Text}\\tt{ and Typewriter} \\sf{also sans serif}"; //QString text="x_0My Text$\\sqrt{a^2+b^2 } \\underbrace{underbrace}{x_0}$"; diff --git a/lib/jkqtmathtext/jkqtmathtext.cpp b/lib/jkqtmathtext/jkqtmathtext.cpp index e72df19f30..eb4a129d12 100644 --- a/lib/jkqtmathtext/jkqtmathtext.cpp +++ b/lib/jkqtmathtext/jkqtmathtext.cpp @@ -1171,6 +1171,7 @@ double JKQTMathText::MTdecoratedNode::draw(QPainter& painter, double x, double y //double d=overallHeight-baselineHeight; double dheightfactor=parent->getDecorationHeightFactor(); double dpos=y-a*(1.0+dheightfactor); + double spos=y-a/2.0; double dposb=y+qMax((overallHeight-baselineHeight)*(1.0+dheightfactor), fm.xHeight()*dheightfactor); double deltax=0;//(wc-ll)/2.0; double dheight=dheightfactor*a; @@ -1266,7 +1267,30 @@ double JKQTMathText::MTdecoratedNode::draw(QPainter& painter, double x, double y painter.setBrush(bold); painter.setPen(pold); painter.setBrush(bold); + } else if (decoration==MTDstrike) { + painter.setPen(p); + QLineF l(x+deltax, spos, xnew+deltax-0.2*wc, spos); + if (l.length()>0) painter.drawLine(l); + painter.setPen(pold); + } else if (decoration==MTDcancel) { + painter.setPen(p); + QLineF l(x+deltax, dposb, xnew+deltax-0.2*wc, dpos); + if (l.length()>0) painter.drawLine(l); + painter.setPen(pold); + } else if (decoration==MTDbcancel) { + painter.setPen(p); + QLineF l(x+deltax, dpos, xnew+deltax-0.2*wc, dposb); + if (l.length()>0) painter.drawLine(l); + painter.setPen(pold); + } else if (decoration==MTDxcancel) { + painter.setPen(p); + QLineF l(x+deltax, dpos, xnew+deltax-0.2*wc, dposb); + if (l.length()>0) painter.drawLine(l); + QLineF l1(x+deltax, dposb, xnew+deltax-0.2*wc, dpos); + if (l1.length()>0) painter.drawLine(l1); + painter.setPen(pold); } + // return xnew+0.3*wc; } @@ -4343,6 +4367,14 @@ JKQTMathText::MTnode* JKQTMathText::parseLatexString(bool get, const QString& qu nl->addNode(new MTdecoratedNode(this, MTDtilde, parseLatexString(true))); } else if (name=="ddot") { nl->addNode(new MTdecoratedNode(this, MTDddot, parseLatexString(true))); + } else if (name=="cancel") { + nl->addNode(new MTdecoratedNode(this, MTDcancel, parseLatexString(true))); + } else if (name=="xcancel") { + nl->addNode(new MTdecoratedNode(this, MTDxcancel, parseLatexString(true))); + } else if (name=="bcancel") { + nl->addNode(new MTdecoratedNode(this, MTDbcancel, parseLatexString(true))); + } else if (name=="strike" || name=="st" || name=="sout") { + nl->addNode(new MTdecoratedNode(this, MTDstrike, parseLatexString(true))); } else { if (name=="textcolor" || name=="mathcolor" || name=="color" || name=="colorbox") { bool foundError=true; @@ -4803,6 +4835,14 @@ QString JKQTMathText::decorationToString(JKQTMathText::MTdecoration mode) return "underline"; case MTDdoubleunderline: return "double underline"; + case MTDcancel: + return "cancel"; + case MTDbcancel: + return "bcancel"; + case MTDxcancel: + return "xcancel"; + case MTDstrike: + return "strike"; } return "unknown"; } diff --git a/lib/jkqtmathtext/jkqtmathtext.h b/lib/jkqtmathtext/jkqtmathtext.h index 221f89aa8a..74d4f14b16 100644 --- a/lib/jkqtmathtext/jkqtmathtext.h +++ b/lib/jkqtmathtext/jkqtmathtext.h @@ -193,6 +193,10 @@ private: - \c \\script{...} \c \\textscript{...} \c \\mathscript{...} : draw the contained text in a script font face \image html jkqtmathtext_fonts.png - \c \\sc{...} : draw the text in small caps \image html jkqtmathtext_sc.png - \c \\ul{...} \c \\underline{...} \c \\underlined{...} : draw the text with underlining \image html jkqtmathtext_ul.png + - \c \\sout{...} : strike out the text \image html mathparser/MTDstrike.png + - \c \\cancel{...} : slanted strike out the text \image html mathparser/MTDcancel.png + - \c \\bcancel{...} : back-strike out the text \image html mathparser/MTDbcancel.png + - \c \\xcancel{...} : x-strike out the text \image html mathparser/MTDxcancel.png - \c \\ol{...} \c \\overline{...} \c \\overlined{...} : draw the text with overlining \image html jkqtmathtext_ol.png - \c \\tt{...} \c \\texttt{...} \c \\mathtt{...} : draw text in typewriter font \image html jkqtmathtext_fonts.png - \c \\textcolor{color}{...} \c \\color{color} \c \\mathcolor{color}{...} : draw colored text \image html jkqtmathtext_colored.png @@ -1092,8 +1096,13 @@ class JKQTMATHTEXT_LIB_EXPORT JKQTMathText : public QObject { MTDdoubleoverline, /*!< \brief double overline over block \image html mathparser/MTDdoubleoverline.png */ MTDunderline, /*!< \brief underline under block \image html mathparser/MTDunderline.png */ MTDdoubleunderline, /*!< \brief double underline under block \image html mathparser/MTDdoubleunderline.png */ - MTDtilde /*!< \brief tilde over block \image html mathparser/MTDtilde.png */ + MTDtilde, /*!< \brief tilde over block \image html mathparser/MTDtilde.png */ + MTDcancel, /*!< \brief cancel text with sloped line \image html mathparser/MTDcancel.png */ + MTDbcancel, /*!< \brief cancel text with backward sloped line \image html mathparser/MTDbcancel.png */ + MTDxcancel, /*!< \brief cancel text with X \image html mathparser/MTDxcancel.png */ + MTDstrike /*!< \brief strikethrough text \image html mathparser/MTDstrike.png */ }; + /** \brief convert a MTdecoration into a string */ static QString decorationToString(MTdecoration mode); /** \brief subclass representing a decorated text m (e.g. \c \\vec \c \\hat ...) node