From: Uwe Stöhr Date: Sun, 18 Nov 2012 15:02:43 +0000 (+0100) Subject: thesis template: add check for babel (as discussed in bug #8423) X-Git-Tag: 2.0.6~238 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=2f99aabf6d5d5285bf02e2920c908566264a47d4;p=features.git thesis template: add check for babel (as discussed in bug #8423) --- diff --git a/lib/templates/thesis/Appendix.lyx b/lib/templates/thesis/Appendix.lyx index 6016557c33..7e535e097e 100644 --- a/lib/templates/thesis/Appendix.lyx +++ b/lib/templates/thesis/Appendix.lyx @@ -5,7 +5,10 @@ \textclass scrbook \begin_preamble % increases link area for cross-references and autoname them +% if you change the document language to e.g. French +% you must change "extrasenglish" to "extrasfrench" \AtBeginDocument{\renewcommand{\ref}[1]{\mbox{\autoref{#1}}}} +\@ifundefined{extrasenglish}{\usepackage[english]{babel}}{} \addto\extrasenglish{% \renewcommand*{\equationautorefname}[1]{} \renewcommand{\sectionautorefname}{sec.\negthinspace} diff --git a/lib/templates/thesis/chapter-1.lyx b/lib/templates/thesis/chapter-1.lyx index 52248f95b4..5421e22c5a 100644 --- a/lib/templates/thesis/chapter-1.lyx +++ b/lib/templates/thesis/chapter-1.lyx @@ -5,7 +5,10 @@ \textclass scrbook \begin_preamble % increases link area for cross-references and autoname them +% if you change the document language to e.g. French +% you must change "extrasenglish" to "extrasfrench" \AtBeginDocument{\renewcommand{\ref}[1]{\mbox{\autoref{#1}}}} +\@ifundefined{extrasenglish}{\usepackage[english]{babel}}{} \addto\extrasenglish{% \renewcommand*{\equationautorefname}[1]{} \renewcommand{\sectionautorefname}{sec.\negthinspace} diff --git a/lib/templates/thesis/chapter-2.lyx b/lib/templates/thesis/chapter-2.lyx index b52f714609..c810a153b7 100644 --- a/lib/templates/thesis/chapter-2.lyx +++ b/lib/templates/thesis/chapter-2.lyx @@ -5,7 +5,10 @@ \textclass scrbook \begin_preamble % increases link area for cross-references and autoname them +% if you change the document language to e.g. French +% you must change "extrasenglish" to "extrasfrench" \AtBeginDocument{\renewcommand{\ref}[1]{\mbox{\autoref{#1}}}} +\@ifundefined{extrasenglish}{\usepackage[english]{babel}}{} \addto\extrasenglish{% \renewcommand*{\equationautorefname}[1]{} \renewcommand{\sectionautorefname}{sec.\negthinspace} diff --git a/lib/templates/thesis/thesis.lyx b/lib/templates/thesis/thesis.lyx index 580f94e8a1..82f26ac799 100644 --- a/lib/templates/thesis/thesis.lyx +++ b/lib/templates/thesis/thesis.lyx @@ -5,7 +5,10 @@ \textclass scrbook \begin_preamble % increases link area for cross-references and autoname them +% if you change the document language to e.g. French +% you must change "extrasenglish" to "extrasfrench" \AtBeginDocument{\renewcommand{\ref}[1]{\mbox{\autoref{#1}}}} +\@ifundefined{extrasenglish}{\usepackage[english]{babel}}{} \addto\extrasenglish{% \renewcommand*{\equationautorefname}[1]{} \renewcommand{\sectionautorefname}{sec.\negthinspace} diff --git a/status.20x b/status.20x index b8289181dd..745904da20 100644 --- a/status.20x +++ b/status.20x @@ -71,6 +71,9 @@ What's new * DOCUMENTATION AND LOCALIZATION +- Make the thesis template compilable again. (The reason for this bug + was that LyX no longer loads the babel package if the document + language is English and no other languages are used in the file.) * LYXHTML