Commit [3366c49f/lyxgit] intended to strip braces only for minted
but was actually stripping them also for listings. As the braces
are necessary for the listings package, reintroduce them.
This is a master-only issue.
The specific test was introduced in ef6be5f4 because
CJKutf8 was relatively new (cf. lyx.org/trac/ticket/5386).
10 years on, CJKutf8 is an established part of the CJK bundle
and we can skip the special test for CJKutf8 to make the logic
considerabely simpler to read, maintain and debug.
Since April 2018, pdflatex falls back to input-encoding utf8 if
it does not detect an input encoding setting.
https://www.latex-project.org/news/latex2e-news/ltnews28.pdf
This leads to failure with CJK legacy encodings and may not
be what you want if selecting "Language Default (no inputenc)"
as document input-encoding.
The problem here is, that selecting any subset of a \lettrine{}
line always creates an initials header. That makes it impossible
to our search engine to find strings, because the regex does not
contain that info. So we have to discard the leading \lettrine part
completely.
We place now a marker (\endarguments) to determine that removable
part.
Remove special handling of spaces at end of paragraph. Now they are
handled like interword spaces by both DEPM methods.
Fix off-by-one error in loop when testing for end of paragraph.
Style: use Dociterator::lastpos() instead of Paragraph::size().
Part of bug #11412.
If Document>Settings>Language>Encoding is set to any value except "auto" or "default", we
expect the whole document to use this encoding. Wiht encodings from the CJK package, this means
one big "CJK" environment and no encoding switches.
Characters that are not handled by the CJK package need to be "forced" in lib/unicodesymbols.
This is completed for "euc-cn", the others will follow.
The default fonts provide a good match to LatinModern and
closer similarity to the look with 8-bit TeX fonts.
Also replace a box-drawing character in a heading with an em-dash.
Additionally, correct the cursor by an offset equal to the variation of paragraph size : if change tracking is on, deleting a space may mean that it is just marked as deleted.
Part of bug #11412.
In the lines specifying the font, e.g.
\font_typewriter "DejaVuSansMono" "DejaVu Sans Mono"
the system font specs may contain words separated by spaces
A \clearpage command issued right before \end{CJK} is recommended by the
package author to prevent any un-processed CJK chars outside the
\begin{CJK} and \end{CJK} scope. Otherwise, TOC, header, footer,
and may contain CJK chars but get processed outside the CJK environment scope.
Tha new dedicated export test fails without the fix.