On Fri, Jun 03, 2011 at 09:47:35AM +0200, Jean-Marc Lasgouttes wrote: > Le 03/06/11 02:07, Enrico Forestieri a écrit : > >See attached patch. > > I am not sure I understand the patch, but how come one has to decide > based on isMainText()? What about a Flex inset in a Note? What would > the situation be different?
I am not sure I understand the question, either. As \selectlanguage introduces spurious white space, it should not be used in "inline" content. As \selectlanguage is only used when the language is changed at the very beginning of a LyX paragraph, checking isMainText() ensures that it is used only at the beginning of a LaTeX paragraph, such that the spurious white space added at the end is not harmful. -- Enrico