On Thu, Oct 04, 2007 at 10:10:25PM +0200, Helge Hafting wrote:
>  I tried making a custom inset, and found that
>  if I don't specify "Font . . . EndFont", then LyX crashes
>  as soon as I try "Insert->Custom Insets->my inset"
> 
>  I didn't want to specify a font, I though LyX could use whatever font
>  that was in effect at the moment. Some cases don't need to
>  set a font, they are merely meant to add some latex command
>  or environment to the output.

I cannot reproduce this in Linux... a fix may be to initialize
font in TextClass.cpp to defaultfont rather than INHERIT_ALL.
Would make sense.
 
>  Second bug:
>  I had this:
>  #\DeclareLyXModule[multicol.sty]{Adds support for text in multiple 
>  columns}{Multicol}
> 
>  So I expected multicol.sty to load automatically, but no. I had to add
>  that to "Preamble...EndPreamble" as well. What is the purpose
>  of having [multicol.sty] in declarelyxmodule if the package isn't
>  loaded as a result? Bug, or did I misunderstand something crucial?
 
Only that the DeclareLyXModule line is for the configurator
(to avoid offering the module on a system not having the
.sty file). 

The Preamble thingy is still needed to trigger inclusion 
of the \usepackage statement if you enter one or more
instances of this inset into the file. (Because you may
want to have this inset type 'on offer' in your doc, like
in a template, without actually using it)
 
>  Now for the question. Is it possible to create an inset that can
>  contain severla paragraphs of various types, similiar to how the
>  minipage or branch inset works?

Could be done. Look at the dispatch routine in InsetFlex,
where entering paragraph breaks is suppressed. Could easily
be made dependent upon a layout_.allowmultipar added to the
inset layout format. Do it yourself if you are in a hurry ;-)

>  I understand that something like an endnote shouldn't be able to
>  have internal paragraphs. But a "4 columns" inset should. The only
>  way I can achieve this at the moment is to use a style instead of an inset,
>  but this solution is a bit odd: Other paragraphs have to nest
>  in order to be inside the multicol region, and "standard" don't
>  nest well. Any nesting mistake breaks up the multicol region
>  which isn't intuitive. That's why I think some kind of boxed inset
>  would be better for this - if it can contain several paragraphs.
>  An inset also shows where the multicol region ends - a style
>  won't do that, endlabels doesn't seem to work.
> 
>  Helge Hafting
 
- Martin
 

Reply via email to