[Inkscape 0.48.3.1 r9886] : latex generation problem

Bug #1091484 reported by didier garcin
20
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Inkscape
New
Wishlist
Unassigned

Bug Description

Latex is angry because Inkscape, in particular in batch mode (ex: inkscape -f<filename>.svg <filename>.pdf --export-latex ) generates the following line in the generated latex file:

\smash{#}

instead of :

\smash{\#}

Remembering that # is a special character in latex that must be backskashed.

Same remark for { and }. They should be backskashed too. Others special characters ?

I will very pleased someone corrects soon this bug easily solvable.

Thanks all !

Revision history for this message
didier garcin (dg-recrutement31) wrote :
description: updated
su_v (suv-lp)
tags: added: cli export
removed: backslash batch character export-latex special
Revision history for this message
su_v (suv-lp) wrote :

AFAIU a duplicate of
Bug #719320 “EPS/LaTeX export: certain text characters (e.g. underscore) produce invalid LaTeX code”
<https://bugs.launchpad.net/inkscape/+bug/719320>

«If you want to export to latex, the text has to be valid latex code. Escaping would destroy complex latex code like for example formulas.»

tags: added: exporting pdf
removed: export
Revision history for this message
didier garcin (dg-recrutement31) wrote :

I see. While text embedded in svg files should be considerer as raw text because most of the time it is, Inkscape developers have chosen to considerer it as latex formatted.

The SVG standard should extended to consider mime-types, instead.

So, I guess this bug may not be solved one day not to break backward compatibility of this function.

Arg...

Revision history for this message
Johan Engelen (johanengelen) wrote :

It is straightforward to add an option to escape all special LaTeX characters, so if anyone wants to do so, go ahead. But in doing so, we may open up a can of worms with LaTeX export option requests...

Just make sure the default option is to *not* escape those characters.

Changed in inkscape:
importance: Undecided → Wishlist
tags: added: easy-fix
removed: cli
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.