Paul A. Rubin <[EMAIL PROTECTED]> writes:

> 
> Enrico Forestieri wrote:
> 
> >>
> >> I'm wondering if this is something that should go into bugzilla, or 
> >> whether it's one of those "we'll have to live with it" sorts of things?
> > 
> > The latter, I fear. If the same preamble was not used, the snippets
> > could not be generated because something in the preamble is needed.
> > Frankly, implementing a sort of artificial intelligence simply to be
> > able to recognize what is really needed for instant-preview seems
> > to much, IMO.
> > 
> 
> Is it possible to load the full preamble but also add a line that 
> overrides the format decision, so that a DVI is always generated even if 
> the document is targeting pdftex?

This would be fragile and prone to errors.

>  If so, that is one way to circumvent 
> the problem.  If not, then perhaps the conversion script needs to search 
> first for 0lyxpreview.dvi and then, failing to find it, 0lyxpreview.pdf, 
> and convert the latter to PNG if it exists (?).

This would be possible, but then we would be missing the "ascent" and
"descent" values necessary to correctly align the snippets with the
surrounding text. Currently these values are provided by dvipng which
only works with dvi files. Maybe the legacy script using the ghostscript
route could be adapted, as preview.sty should also work with pdflatex.
In this case those values could be extracted from the log file. 

I think that you could enter this in bugzilla.

-- 
Enrico

Reply via email to