On 08/11/2010 04:35 PM, Jean-Marc Lasgouttes wrote:
We can also add code to LyX 1.6 that reads these borked files: if
MyStyle does not exist and the inset is of type Custom, try
Custom:MyStyle.
Of course, we do not know that the inset is of type custom... So, we
would have to try in turn CharStyle:MyStyle, Element:MyStyle and
Custom:MyStyle.
Not very nice. And people have to have the latest 1.6 version.
Yes, I thought of that too.
You think I should try the other idea---recording this in the LyX file?
By the way, I sometimes feel hamstrung by the thought that files
produced with LyX 2.0 ought to work just as well in LyX 1.2.x. There is
a sense in which we cannot guarantee this when layout changes are
involved, since we do not in any way revert layout information. E.g.,
suppose we update article.layout to provide some new features.Or suppose
we change the LaTeX associated with some particular environment in some
layout. Now we create a file in 2.0 using the new layout and export it
to 1.6.x. Is this supposed to require a dummy format change, etc? That
seems insane to me. People can override this stuff. We certainly didn't
try to provide for reversion of the stuff in logicalmkup.module.
I'm inclined to think that the policy should be: Old files imported into
2.0 ought to be able to be exported back to where they came from. But
with new 2.0 files, we make a reasonable attempt and, if there are cases
where the file can't be reverted, then, well, so it goes. Don't use old
versions. This would allow us to do something with imported files, such
as I suggested, and then to apologize for new 2.0 files. Of course, in
practice, anyone who has a problem has an easy fix: Open the layout and
remove "Custom:" etc.
rh