Version: (using KDE KDE 3.4.1) Installed from: Gentoo Packages If you send incorrect formulas with Kopete while KopeTeX is activated, these formulas are not displayed. Instead a huge white space is shown. Example: Try sending $$\fra 1 2$$ (instead of \fract). Proposed behavior: If the formula has an error, just show the formula as text. I see two ways to fix that. 1) in kopete_latexconvert.sh add after the line latex -interaction=batchmode out.tex > /dev/null something along the lines of returncode = $? if [ $returncode -ne 0 ]; then cd - rm -rf $tmpdir exit $returncode fi and check this in kopete. If kopete_latexconvert.sh exits with 0 display the formula, otherwise the text. 2) this is easier for me, because I do not have to modify the C++ sources: add a switch to kopete_latexconvert.sh which renders the text as verbatim text (as opposed to a LaTeX formula). If the latex call from above fails, kopete_latexconvert.sh calls itself recursively, this time rendering the formula as verbatim text. I will attach a patch for fix 2).
Created attachment 11657 [details] Renders LaTeX formulas as verbatim text if they contain errors
Created attachment 11658 [details] Renders LaTeX formulas as verbatim text if they contain errors This patch is a little bit more elegant than the previous
Comment on the patch: best put $tmpdir/out.tex, $homedir, $tmpdir and $0 in double quotes, lest they contain spaces or other nasties. I think either solution is OK.
Created attachment 11660 [details] Renders LaTeX formulas as verbatim text if they contain errors with quotation marks Thanks Richard. The attached patch adds quotation marks to my code. I have not touched the old code. I suppose that it needs quite a lot of quotation marks as well, but my attempts to fix it, broke the script, so I let this to the experts.
I think it is better to don't render nothing at all. (and show the text as normal) And i think this is already the case in SVN. (and maybe even backported, i don't remember)
I have not commited your patch because the svn versions (trunk and 3.4 branch) doesn't display the picture when the picture is not generated (because wrong latex) Thanks anyway.
Git commit 95a7be8b7cf37ddb462bb008ca415aa8091f87aa by Jekyll Wu. Committed on 18/01/2013 at 21:11. Pushed by jekyllwu into branch 'master'. DrKonqi now makes use of the new "drkonqi" keyword on bugs.kde.org That makes it easier to identify and search for reports created by DrKonqi. That should be helpful for developers to collect statistics and examples. REVIEW: 280145 FIXED-IN: 4.11.0 M +1 -0 drkonqi/bugzillalib.cpp M +7 -0 drkonqi/bugzillalib.h M +1 -0 drkonqi/reportinterface.cpp http://commits.kde.org/kde-runtime/95a7be8b7cf37ddb462bb008ca415aa8091f87aa
(In reply to comment #7) > Git commit 95a7be8b7cf37ddb462bb008ca415aa8091f87aa by Jekyll Wu. > Committed on 18/01/2013 at 21:11. > Pushed by jekyllwu into branch 'master'. Sorry, wrong number used in the commit HOOK. Please just ignore comment #7.