Am Montag, den 31.10.2016, 10:09 +0000 schrieb Guenter Milde:
> Dear LyX developers,
> 
> trying the example from http://www.lyx.org/trac/ticket/10456
> with LyX 2.3.0dev (2016-10-28)
>   Git commit hash 42d900c2
> CMake Build
> 
> I was met by a crash.

The problem boils down to the fact that the paragraphs are not
validated when only paragraphs are previewed. Thus,
runparams.use_polyglossia is wrong in this case, leading eventually to
the attempt to pop an empty stack.

Another, less critical consequence is that polyglossia markup is shown
in the preview where babel markup should show up.

The attached patch fixes it.

I'll commit to master since it seems obvious to me. Shoud also go to
stable.

Jürgen
diff --git a/src/Buffer.cpp b/src/Buffer.cpp
--- a/src/Buffer.cpp
+++ b/src/Buffer.cpp
@@ -3753,7 +3753,7 @@ unique_ptr<TexRow> Buffer::getSourceCode(odocstream & os, string const & format,
 			// in order to know if we should output polyglossia
 			// macros (instead of babel macros)
 			LaTeXFeatures features(*this, params(), runparams);
-			params().validate(features);
+			validate(features);
 			runparams.use_polyglossia = features.usePolyglossia();
 			// latex or literate
 			otexstream ots(os);

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to