fix bug 1807: New on-screen translations do not work

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@9960 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Jean-Marc Lasgouttes 2005-05-20 09:13:42 +00:00
parent 9601a476f0
commit 971d9986b7
38 changed files with 85032 additions and 36262 deletions

View File

@ -1,3 +1,18 @@
2005-05-18 Jean-Marc Lasgouttes <lasgouttes@lyx.org>
* layouts/report.layout: no need to change LabelString here
* layouts/heb-article.layout:
* layouts/heb-letter.layout:
* layouts/dinbrief.layout: avoid 8bit characters
* layouts/scrclass.inc: no need to reset LabelString here
* layouts/amsbook.layout: no need to remove numbering of paragraph
layout.
* layouts/amsdefs.inc: fix case of LabelString
2005-05-10 Jean-Marc Lasgouttes <lasgouttes@lyx.org> 2005-05-10 Jean-Marc Lasgouttes <lasgouttes@lyx.org>
* layouts/llncs.layout: fix some font sizes; change description; * layouts/llncs.layout: fix some font sizes; change description;

View File

@ -97,11 +97,9 @@ Style Section
End End
# Paragraph doesn't have numbered labels
Style Paragraph Style Paragraph
LabelString ""
LabelStringAppendix ""
Font Font
Series Medium
EndFont EndFont
End End

View File

@ -175,7 +175,7 @@ Style Email
CopyStyle Address CopyStyle Address
Margin First_Dynamic Margin First_Dynamic
LatexName email LatexName email
labelString "E-mail address: " LabelString "E-mail address: "
End End
@ -183,7 +183,7 @@ Style URL
CopyStyle Address CopyStyle Address
Margin First_Dynamic Margin First_Dynamic
LatexName urladdr LatexName urladdr
labelString "URL: " LabelString "URL: "
End End

View File

@ -70,7 +70,7 @@ End
Style Closing Style Closing
LeftMargin Unterschr LeftMargin Unterschr
LabelString Gruß: LabelString "Gruss:"
LabelSep x LabelSep x
LabelFont LabelFont
Series Medium Series Medium

View File

@ -14,11 +14,6 @@ Preamble
EndPreamble EndPreamble
Style Abstract
LabelString "øéö÷ú"
End
Style Theorem Style Theorem
Margin First_Dynamic Margin First_Dynamic
LatexType Environment LatexType Environment
@ -34,7 +29,7 @@ Style Theorem
Align Block Align Block
AlignPossible Block, Left AlignPossible Block, Left
LabelType Static LabelType Static
LabelString ".# èôùî" LabelString "Theorem #."
Font Font
Shape Up Shape Up
Size Normal Size Normal
@ -49,7 +44,7 @@ End
Style Lemma Style Lemma
CopyStyle Theorem CopyStyle Theorem
LatexName lemma LatexName lemma
LabelString ".# äîì" LabelString "Lemma #."
Preamble Preamble
\newtheorem{lemma}[theorem]{\R{ìîä}} \newtheorem{lemma}[theorem]{\R{ìîä}}
EndPreamble EndPreamble
@ -59,7 +54,7 @@ End
Style Corollary Style Corollary
CopyStyle Theorem CopyStyle Theorem
LatexName corollary LatexName corollary
LabelString ".# äð÷ñî" LabelString "Corollary #."
Preamble Preamble
\newtheorem{corollary}[theorem]{\R{îñ÷ðä}} \newtheorem{corollary}[theorem]{\R{îñ÷ðä}}
EndPreamble EndPreamble
@ -69,7 +64,7 @@ End
Style Claim Style Claim
CopyStyle Theorem CopyStyle Theorem
LatexName claim LatexName claim
LabelString ".# äðòè" LabelString "Claim #."
Preamble Preamble
\newtheorem{claim}[theorem]{\R{èòðä}} \newtheorem{claim}[theorem]{\R{èòðä}}
EndPreamble EndPreamble
@ -79,7 +74,7 @@ End
Style Definition Style Definition
CopyStyle Theorem CopyStyle Theorem
LatexName definition LatexName definition
LabelString ".# äøãâä" LabelString "Definition #."
Preamble Preamble
\newtheorem{definition}[theorem]{\R{äâãøä}} \newtheorem{definition}[theorem]{\R{äâãøä}}
EndPreamble EndPreamble
@ -89,7 +84,7 @@ End
Style Remarks Style Remarks
CopyStyle Theorem CopyStyle Theorem
LatexName remark LatexName remark
LabelString ".# äøòä" LabelString "Remarks #."
Preamble Preamble
\newtheorem{remark}[theorem]{\R{äòøä}} \newtheorem{remark}[theorem]{\R{äòøä}}
EndPreamble EndPreamble
@ -111,7 +106,7 @@ Style Proof
Align Block Align Block
AlignPossible Block, Left AlignPossible Block, Left
LabelType Static LabelType Static
LabelString ":äçëåä" LabelString "Proof:"
EndLabelType Filled_Box EndLabelType Filled_Box
Font Font
Shape Up Shape Up

View File

@ -15,17 +15,3 @@ Style Send_To_Address
Align Right Align Right
End End
Style Opening
LabelString :äçéúô
End
Style Closing
LabelString :íåéñ
End
Style Signature
LabelString :äîéúç
End

View File

@ -8,12 +8,6 @@
Input stdclass.inc Input stdclass.inc
Input numreport.inc Input numreport.inc
Style Chapter
LabelString "Chapter \arabic{chapter}"
LabelStringAppendix "Appendix \Alph{chapter}"
End
Style Bibliography Style Bibliography
TopSep 4 TopSep 4
LabelString Bibliography LabelString Bibliography

View File

@ -55,7 +55,6 @@ End
Style Chapter Style Chapter
LabelString ""
Font Font
Family Sans Family Sans
Size Largest Size Largest

View File

@ -1,3 +1,7 @@
2005-05-18 Jean-Marc Lasgouttes <lasgouttes@lyx.org>
* Makefile.in.in: add the layout LabelString entries in pot file.
2005-05-02 Angus Leeming <leeming@lyx.org> 2005-05-02 Angus Leeming <leeming@lyx.org>
* po/POTFILES.in: src/SpellBase.C now contains a translatable string. * po/POTFILES.in: src/SpellBase.C now contains a translatable string.

View File

@ -441,6 +441,15 @@ layouts_l10n.pot: $(top_srcdir)/lib/layouts/*.layout $(top_srcdir)/lib/layouts/*
printf("#: %s:%d\nmsgid \"%s\"\nmsgstr \"\"\n\n", \ printf("#: %s:%d\nmsgid \"%s\"\nmsgstr \"\"\n\n", \
fixupfilename(), FNR, line); \ fixupfilename(), FNR, line); \
} \ } \
/LabelString[A-Za-z]*/ { \
line=$$0; \
sub(/[[:space:]]*LabelString[A-Za-z]*[[:space:]]*/, "", line); \
gsub(/"/, "", line); \
gsub(/\\/, "\\\\", line); \
if (line != "") \
printf("#: %s:%d\nmsgid \"%s\"\nmsgstr \"\"\n\n", \
fixupfilename(), FNR, line); \
} \
/GuiName/ { \ /GuiName/ { \
line=$$0; \ line=$$0; \
sub(/[[:space:]]*GuiName[[:space:]]*/, "", line); \ sub(/[[:space:]]*GuiName[[:space:]]*/, "", line); \

5821
po/bg.po

File diff suppressed because it is too large Load Diff

5254
po/ca.po

File diff suppressed because it is too large Load Diff

5253
po/cs.po

File diff suppressed because it is too large Load Diff

5283
po/da.po

File diff suppressed because it is too large Load Diff

4370
po/de.po

File diff suppressed because it is too large Load Diff

5293
po/es.po

File diff suppressed because it is too large Load Diff

5332
po/eu.po

File diff suppressed because it is too large Load Diff

5311
po/fi.po

File diff suppressed because it is too large Load Diff

View File

@ -14856,6 +14856,14 @@ msgstr "Encodage"
msgid "Paragraph layout set" msgid "Paragraph layout set"
msgstr "Style du paragraphe redéfini" msgstr "Style du paragraphe redéfini"
#: lib/layouts/numreport.inc:14
msgid "Chapter \\arabic{chapter}"
msgstr "Chapitre \\arabic{chapter}"
#: lib/layouts/numreport.inc:15
msgid "Appendix \\Alph{chapter}"
msgstr "Appendice \\Alph{chapter}"
#, fuzzy #, fuzzy
#~ msgid "To:|#T" #~ msgid "To:|#T"
#~ msgstr "Haute :|#H" #~ msgstr "Haute :|#H"

5218
po/he.po

File diff suppressed because it is too large Load Diff

5265
po/hu.po

File diff suppressed because it is too large Load Diff

5256
po/it.po

File diff suppressed because it is too large Load Diff

5279
po/nl.po

File diff suppressed because it is too large Load Diff

5405
po/nn.po

File diff suppressed because it is too large Load Diff

5249
po/no.po

File diff suppressed because it is too large Load Diff

5258
po/pl.po

File diff suppressed because it is too large Load Diff

5261
po/pt.po

File diff suppressed because it is too large Load Diff

5341
po/ro.po

File diff suppressed because it is too large Load Diff

5341
po/ru.po

File diff suppressed because it is too large Load Diff

5284
po/sk.po

File diff suppressed because it is too large Load Diff

5342
po/sl.po

File diff suppressed because it is too large Load Diff

5255
po/sv.po

File diff suppressed because it is too large Load Diff

5253
po/tr.po

File diff suppressed because it is too large Load Diff

5253
po/wa.po

File diff suppressed because it is too large Load Diff

View File

@ -1,3 +1,11 @@
2005-05-18 Jean-Marc Lasgouttes <lasgouttes@lyx.org>
* buffer_funcs.C (expandLabel): take a Buffer as argument;
translate the labelstring.
(setCounter): translate labelstring as needed.
* output_docbook.C (makeCommand): fix expandLabel invokation
2005-05-14 Michael Schmitt <michael.schmitt@teststep.org> 2005-05-14 Michael Schmitt <michael.schmitt@teststep.org>
* BufferView.C: fix dialog title * BufferView.C: fix dialog title

View File

@ -382,7 +382,7 @@ void setCounter(Buffer const & buf, ParIterator & it)
&& (layout->latextype != LATEX_ENVIRONMENT && (layout->latextype != LATEX_ENVIRONMENT
|| isFirstInSequence(it.pit(), it.plist()))) { || isFirstInSequence(it.pit(), it.plist()))) {
counters.step(layout->counter); counters.step(layout->counter);
string label = expandLabel(textclass, layout, string label = expandLabel(buf, layout,
par.params().appendix()); par.params().appendix());
par.params().labelString(label); par.params().labelString(label);
} }
@ -442,7 +442,7 @@ void setCounter(Buffer const & buf, ParIterator & it)
int number = counters.value("bibitem"); int number = counters.value("bibitem");
if (par.bibitem()) if (par.bibitem())
par.bibitem()->setCounter(number); par.bibitem()->setCounter(number);
par.params().labelString(layout->labelstring()); par.params().labelString(buf.B_(layout->labelstring()));
// In biblio should't be following counters but... // In biblio should't be following counters but...
} else if (layout->labeltype == LABEL_SENSITIVE) { } else if (layout->labeltype == LABEL_SENSITIVE) {
// Search for the first float or wrap inset in the iterator // Search for the first float or wrap inset in the iterator
@ -498,11 +498,13 @@ void updateCounters(Buffer const & buf)
} }
string expandLabel(LyXTextClass const & textclass, string expandLabel(Buffer const & buf,
LyXLayout_ptr const & layout, bool appendix) LyXLayout_ptr const & layout, bool appendix)
{ {
string fmt = appendix ? LyXTextClass const & tclass = buf.params().getLyXTextClass();
layout->labelstring_appendix() : layout->labelstring();
string fmt = buf.B_(appendix ? layout->labelstring_appendix()
: layout->labelstring());
// handle 'inherited level parts' in 'fmt', // handle 'inherited level parts' in 'fmt',
// i.e. the stuff between '@' in '@Section@.\arabic{subsection}' // i.e. the stuff between '@' in '@Section@.\arabic{subsection}'
@ -511,12 +513,12 @@ string expandLabel(LyXTextClass const & textclass,
size_t const j = fmt.find('@', i + 1); size_t const j = fmt.find('@', i + 1);
if (j != string::npos) { if (j != string::npos) {
string parent(fmt, i + 1, j - i - 1); string parent(fmt, i + 1, j - i - 1);
string label = expandLabel(textclass, textclass[parent], appendix); string label = expandLabel(buf, tclass[parent], appendix);
fmt = string(fmt, 0, i) + label + string(fmt, j + 1, string::npos); fmt = string(fmt, 0, i) + label + string(fmt, j + 1, string::npos);
} }
} }
return textclass.counters().counterLabel(fmt); return tclass.counters().counterLabel(fmt);
} }

View File

@ -20,7 +20,6 @@
class Buffer; class Buffer;
class DocIterator; class DocIterator;
class ErrorList; class ErrorList;
class LyXTextClass;
class TeXErrors; class TeXErrors;
/** /**
@ -46,8 +45,8 @@ void bufferErrors(Buffer const &, ErrorList const &);
int countWords(DocIterator const & from, DocIterator const & to); int countWords(DocIterator const & from, DocIterator const & to);
/// Expand the counters for the labelstring of \c layout /// Expand the counters for the labelstring of \c layout
std::string expandLabel(LyXTextClass const & textclass, std::string expandLabel(Buffer const & buf, LyXLayout_ptr const & layout,
LyXLayout_ptr const & layout, bool appendix); bool appendix);
/// updates all counters /// updates all counters
void updateCounters(Buffer const &); void updateCounters(Buffer const &);

View File

@ -233,7 +233,7 @@ ParagraphList::const_iterator makeCommand(Buffer const & buf,
// Label around sectioning number: // Label around sectioning number:
if (!bstyle->labeltag().empty()) { if (!bstyle->labeltag().empty()) {
sgml::openTag(os, bstyle->labeltag()); sgml::openTag(os, bstyle->labeltag());
os << expandLabel(buf.params().getLyXTextClass(), bstyle, false); os << expandLabel(buf, bstyle, false);
sgml::closeTag(os, bstyle->labeltag()); sgml::closeTag(os, bstyle->labeltag());
} }