Author Topic: Problem with special text and export  (Read 9881 times)

mgwerder

  • Newbie
  • *
  • Posts: 3
    • View Profile
Problem with special text and export
« on: March 09, 2017, 01:22:31 PM »
Hi everybody

I have a Problem driving me currently up the wall. When drawing Images text flagged as "Special" renders perfect on screen as shown in the first attachment. Whenever I export an image (I checked Export to PNG and PDF) Special text is no longer rendered (as shown in the second image attachment).

Additional information:
  • It does not change when closing and reopening WinFig.
  • Winfig is a registered winfig Version 6.2. The "About WinFig" says "Ghostscript binary found in: not found".
  • Ghostscript and Latex are in the System path
  • OS is  a Windows 7 64 Bit
  • Ghostscript is Version 9.2 (32 and 64 Bit binaries available). Path to 32 Bit Version is manually specified (using the browse button and picking the gswi32 executable) in preferences (behaviour does not Change regardless of the used Version or Setting to "automatically determine...").
  • Flush Latex Images does not solve the problem
  • When text is edited the Rendering within WinFig is updated

Any suggestions where to look for the problem?

Regards
Martin

Andreas

  • Administrator
  • Full Member
  • *****
  • Posts: 140
    • View Profile
Re: Problem with special text and export
« Reply #1 on: March 09, 2017, 02:58:56 PM »
The on-screen rendering is only a convenience feature. It does not mean that LaTeX can be rendered like that in all output formats. When you export directly to PNG or PDF, no LaTeX processing is applied, and therefore you won't see LaTeX formatting. I'm contemplating about adding such a feature, but it's not trivial.

Usually you would export to pstrickts, pstex or pdftex and include the resulting files in a LaTeX main document. That's what you usually do when you write a paper and include WinFIG/Xfig draings.  See the FAQ and the forum for info. But remember that the actual look of the LaTeX texts depends on document class, styles etc in the main document. When WinFIG generates the graphics snippets for viewing on screen, it uses an envelope as a replacement for a main document in which it wraps the LaTeX texts. You can edit that envelope in the preferences (TeX view) to match your main document.

However, there is a convenience option in pstex/pdftex exports called "export both parts and create a document..." that can be used to create a one page PDF or PS in one step. WinFIG will create the envelope on the file and send it through LaTeX tool chain.
This forum belongs to www.schmidt-web-berlin.de/winfig

mgwerder

  • Newbie
  • *
  • Posts: 3
    • View Profile
Re: Problem with special text and export
« Reply #2 on: March 09, 2017, 04:26:35 PM »
Hmmm ... that causes a Major headache. The files generated by pdftex scale ugly as the font size is not adapted.

I could use the PDF generated as you sugested but the envelope is currently (on my Installation) just the documentclass. I tried to use the envelope from the preferences tag with COLORTOKEN and TEXTTOKEN but that did not work. any Chance you know a valid envelope for this function?

Regards
Martin

mgwerder

  • Newbie
  • *
  • Posts: 3
    • View Profile
Re: Problem with special text and export
« Reply #3 on: March 12, 2017, 10:07:23 AM »
I think I got somewhere. The following envelope seems to work:
Code: [Select]
\documentclass[11pt]{standalone}
\usepackage{xcolor}
\usepackage[pdftex]{graphicx}
\pagestyle{empty}
\begin{document}
\input{\jobname_temp.pdftex_t}
\end{document}

Make sure that you do not scale when exporting (as this seems to mess up a lot). If there is one day a better  export function to PNG I will welcome it with open arms. In the meantime this does the Job for me.

Thanks for the help.
Martin