[LyX/master] Add check to preamble code

Juergen Spitzmueller <[email protected]> Sun, 26 Apr 2026 06:54:27 +0000
Newsgroups gmane.editors.lyx.cvs
Message-ID <[email protected]>
commit 503b6bacee5fa9cb822f5ff4097b53f77af39e66
Author: Juergen Spitzmueller <[email protected]>
Date:   Sun Apr 26 08:53:50 2026 +0200

    Add check to preamble code
    
    So this also works without babel and polyglossia
---
 lib/examples/ja/Graphics_and_Insets/Feynman_Diagrams.lyx | 12 +++++++-----
 1 file changed, 7 insertions(+), 5 deletions(-)

diff --git a/lib/examples/ja/Graphics_and_Insets/Feynman_Diagrams.lyx b/lib/examples/ja/Graphics_and_Insets/Feynman_Diagrams.lyx
index 5fbbf02a85..d5468000be 100644
--- a/lib/examples/ja/Graphics_and_Insets/Feynman_Diagrams.lyx
+++ b/lib/examples/ja/Graphics_and_Insets/Feynman_Diagrams.lyx
@@ -20,11 +20,13 @@
  \renewcommand{\ref}[1]{\mbox{\autoref{#1}}}
  \newlength{\abc}
  \settowidth{\abc}{\space}
- \addto\extrasenglish{
- \renewcommand{\equationautorefname}{\hspace{-\abc}}
- \renewcommand{\sectionautorefname}{sec.\negthinspace}
- \renewcommand{\subsectionautorefname}{sec.\negthinspace}
- \renewcommand{\subsubsectionautorefname}{sec.\negthinspace}}
+ \@ifundefined{addto}{}{
+   \addto\extrasenglish{
+   \renewcommand{\equationautorefname}{\hspace{-\abc}}
+   \renewcommand{\sectionautorefname}{sec.\negthinspace}
+   \renewcommand{\subsectionautorefname}{sec.\negthinspace}
+   \renewcommand{\subsubsectionautorefname}{sec.\negthinspace}}
+ }
 }
 
 % wird benutzt, um Tabellenzellen zu vergrosern
-- 
lyx-cvs mailing list
[email protected]
https://lists.lyx.org/mailman/listinfo/lyx-cvs