> I am working on an Export class that allows exporting a lyx file to
> an arbitrary format (this includes the requested feature of exporting to PDF).

Neat.

The external inset was moving in this direction with "killer" conversion
scripts which could convert basically any graphics format file into any
other.  It's only logical to formalize and generalize this.

Do you implement a shortest-path graph-searching algorithm such that it 
can automatically combine several single convertions into one complex?

I.e. LyX -> GIF, which can be done as LyX -> LaTeX -> PS -> GIF.

Sometimes, you can imagine that the same result can be obtained in
different ways, and then it's interesting to know how you would allow
the user to choose.

Or is this beyond the current plans?

> 1. The \converter command make the old \dvi_to_ps_command etc. commands
> obsolete. Should I remove these commands, or keep them as an alias to the
> \converter command?

Remove them. As far as I know, they were never used.

> 2. What is the purpose of Buffer::Dispatch() ?
> It is only used when running lyx with --export flag (LyX::LyX), but why
> not use LyXFunc::Dispatch() instead ?

We decided to try to move into having more Dispatch-functions, in order
to be able to trim LyXFunc::Dispatch a bit. So consider Buffer::Dispatch
as new infrastructure.

The rule is: Use the most logical Dispatch. In this case, it probably
is Buffer::Dispatch, and in general we should try to avoid LyXFunc::Dispatch,
because it's too big.

This extrapolates further: If it seems natural, you should not be afraid
to add a Dispatch-method in another point in the structure.

Greets,

Asger

Reply via email to