Hello everybody,
I've been looking for some time for a good vector editor to make pictures to include in LaTeX documents. I eventually settled to TpX: http://tpx.sf.net which has the following interesting features - can include LaTeX code in a document - can save to a combined TeX/PS/PDF format which is very easy to include in a LaTeX document On the other hand, it is "primitive" (to say the least) compared to inkscape, works only on win32, is prone to crash and AFAIK it's development is stalled. I'd like to use inkscape as a replacement.
The first feature is (partially) present in inkscape with the "render latex formula" effect, the latter may require some explanation. When you save a document in TpX you get three files: a PDF and a PS with the drawing (but no text) and a TeX file which includes the PDF or the PS (via \includegraphics) and overlays the text using TeX "picture" environment. To include the picture you simple \input the the TeX file and it's done. This way the text is actually rendered by TeX, using whatever fonts and packages it has available.
My C sucks, but if something like this can be implemented as a python effect I'd like to try. I'm thinking about something among these lines: - a tool to insert "latex text" in the document (this could eventually be rendered like the current latex plugin does, but the user should be able to change its contents freely) - an export plugin for "combined latex" which * outputs everything but the "latex text" as a PS and a PDF (using the current PS/PDF exporters I think) * foreach "latex text" box it computes its position and size and outputs a TeX file with the picture environment.
Is something like this actually viable (and implementable without getting mad) ? Sorry for the long post, I hope I've made myself sufficiently clear.
Davide davide125@...92...
On Fri, 2007-05-04 at 14:19 +0200, Davide Cavalca wrote:
Hello everybody,
I've been looking for some time for a good vector editor to make pictures to include in LaTeX documents. I eventually settled to TpX: http://tpx.sf.net which has the following interesting features
- can include LaTeX code in a document
- can save to a combined TeX/PS/PDF format which is very easy to include
in a LaTeX document On the other hand, it is "primitive" (to say the least) compared to inkscape, works only on win32, is prone to crash and AFAIK it's development is stalled. I'd like to use inkscape as a replacement.
Have you considered using the psfrag LaTeX package? It doesn't do quite what you want but might be good enough.
See the section on latex in http://tavmjong.free.fr/INKSCAPE/MANUAL/html/File-Export.html#File-Export-Ot...
Tav
Davide Cavalca wrote:
Hello everybody,
I've been looking for some time for a good vector editor to make pictures to include in LaTeX documents. I eventually settled to TpX: http://tpx.sf.net which has the following interesting features
- can include LaTeX code in a document
- can save to a combined TeX/PS/PDF format which is very easy to include
in a LaTeX document On the other hand, it is "primitive" (to say the least) compared to inkscape, works only on win32, is prone to crash and AFAIK it's development is stalled. I'd like to use inkscape as a replacement.
The first feature is (partially) present in inkscape with the "render latex formula" effect, the latter may require some explanation. When you save a document in TpX you get three files: a PDF and a PS with the drawing (but no text) and a TeX file which includes the PDF or the PS (via \includegraphics) and overlays the text using TeX "picture" environment. To include the picture you simple \input the the TeX file and it's done. This way the text is actually rendered by TeX, using whatever fonts and packages it has available.
My C sucks, but if something like this can be implemented as a python effect I'd like to try. I'm thinking about something among these lines:
- a tool to insert "latex text" in the document (this could eventually
be rendered like the current latex plugin does, but the user should be able to change its contents freely)
- an export plugin for "combined latex" which
- outputs everything but the "latex text" as a PS and a PDF (using the current PS/PDF exporters I think)
- foreach "latex text" box it computes its position and size and
outputs a TeX file with the picture environment.
Is something like this actually viable (and implementable without getting mad) ? Sorry for the long post, I hope I've made myself sufficiently clear.
This sounds like the output you can get using Gnuplot epslatex terminal. If you do plotting and haven't tried this - you should.
The existing latex export options from Inkscape include PSTricks. This should be a adequate solution, however it has a shortfall - as far as I have been able to establish, it ignores text during export.
It would be nice to get this fixed (I think it worked in previous versions) and then to provide for making 'text to path' optional (currently it is fixed on).
If Inkscape text remained as text in PSTricks, it is conceivable that the text from your Inkscape drawing would be parsed by latex.
I have looked at the code which provides PSTricks export to address the problems and to add the 'text to path' option. However, my limited C++ and Inkscape codebase experience has so far prevented any progress.
If you have time and interest I would encourage you to have a look; this is a feature which is of interest and used by people - recently there was a suggestion to extend PSTricks export to support transparency for example.
best regards, richard
participants (3)
-
Davide Cavalca
-
Richard Henwood
-
Tavmjong Bah