mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-12 22:14:35 +00:00
Work around French babel's incompatibility with prettyref
In classic (pdf)latex, where the colon is activated, detokenize the argument of \prettyref. Fix proposed by egreg at https://tex.stackexchange.com/a/527912/19291
This commit is contained in:
parent
6671f9bee1
commit
858b076ab7
@ -498,6 +498,7 @@ Language canadien
|
|||||||
BabelName acadian
|
BabelName acadian
|
||||||
PolyglossiaName french
|
PolyglossiaName french
|
||||||
PolyglossiaOpts "variant=canadian"
|
PolyglossiaOpts "variant=canadian"
|
||||||
|
ActiveChars ;!?:
|
||||||
XindyName french
|
XindyName french
|
||||||
QuoteStyle french
|
QuoteStyle french
|
||||||
Encoding iso8859-15
|
Encoding iso8859-15
|
||||||
@ -705,6 +706,7 @@ Language french
|
|||||||
GuiName "French"
|
GuiName "French"
|
||||||
HasGuiSupport true
|
HasGuiSupport true
|
||||||
BabelName french
|
BabelName french
|
||||||
|
ActiveChars ;!?:
|
||||||
PolyglossiaName french
|
PolyglossiaName french
|
||||||
XindyName french
|
XindyName french
|
||||||
QuoteStyle french
|
QuoteStyle french
|
||||||
|
@ -1284,6 +1284,14 @@ string const LaTeXFeatures::getPackages() const
|
|||||||
// The rest of these packages are somewhat more complicated
|
// The rest of these packages are somewhat more complicated
|
||||||
// than those above.
|
// than those above.
|
||||||
|
|
||||||
|
// Babel languages with activated colon (such as French) break
|
||||||
|
// with prettyref. Work around that.
|
||||||
|
if (!runparams_.isFullUnicode() && useBabel()
|
||||||
|
&& mustProvide("prettyref") && contains(getActiveChars(), ':')) {
|
||||||
|
packages << "% Make prettyref compatible with babel active colon\n"
|
||||||
|
<< "\\def\\prettyref#1{\\expandafter\\@prettyref\\detokenize{#1:}}\n";
|
||||||
|
}
|
||||||
|
|
||||||
if (mustProvide("changebar")) {
|
if (mustProvide("changebar")) {
|
||||||
packages << "\\usepackage";
|
packages << "\\usepackage";
|
||||||
if (runparams_.flavor == Flavor::LaTeX
|
if (runparams_.flavor == Flavor::LaTeX
|
||||||
|
Loading…
Reference in New Issue
Block a user