>>>>> "mv" == mv  <[EMAIL PROTECTED]> writes:

mv> Actually I wonder if anyone *really* understands this as well as I
mv> right now. I have an idea similar to the one above: to understand
mv> it, you should know that it now works as follows:

mv> For all 'LaTeX command' type paragraphs, what is output is

mv> 1) \command{<paragraph content>}

mv> if there is no shorttitle inset in it (which the above method
mv> tests for), and

mv> 2) \command[<par content containing shorttitle inset>}

mv> where the shorttitle inset outputs

mv>     <inset content i.e. short title text>]{

mv> As you can see, this works only by careful co-ordination. Now, if
mv> you make the mistake of inserting a shorttitleinset into an
mv> ordinary paragraph, say, you will end up with a lonely ]{ embedded
mv> in the LaTeX output, giving a mysterious-looking error.

Here is another less dirty idea:

- have InsetShortTitle::latex do nothing

- add a InsetShortTitle::realLaTeX which does what ::latex should do

- when outputing a paragraph, search for a shorttitle in it. If it
  exists, output
    \command[InsetShortTitle::realLaTeX]{par contents}
  otherwise
    \command{par contents}

- now add a new member to LyXLayout telling whether short titles are
  allowed or not and honor it as you see fit.

Note that this solution allow for inserting short titles anywhere in
the paragraph.

I feel that this kind of solution could be good enough to go in 1.3.0,
although it does not catter for the general 'turn the label of a
paragraph into an inset' problem.

JMarc

Reply via email to