On Thu, 2005-09-01 at 12:58, Jean-Marc Lasgouttes wrote: > >>>>> "Martin" == Martin Vermeer <[EMAIL PROTECTED]> writes: > > Martin> As bugzilla is down, attached the summary of my hebrew-related > Martin> changes as a patch. > > The following part is not good: > > @@ -271,10 +272,16 @@ string Counters::labelItem(string const > return string(1, hebrewCounter(value(ctr))); > > if (numbertype == "alph") > - return string(1, loweralphaCounter(value(ctr))); > + if (language == "hebrew") > + return string(1, hebrewCounter(value(ctr))); > + else > + return string(1, loweralphaCounter(value(ctr))); > > if (numbertype == "Alph") > - return string(1, alphaCounter(value(ctr))); > + if (language == "hebrew") > + return string(1, hebrewCounter(value(ctr))); > + else > + return string(1, alphaCounter(value(ctr))); > > > If the hebrew version needs \hebrew{counter} instead of > \alph{counter}, this should be done in he.po. No need to hardcode any > of this logic.
Yes, I agree with this. I have this locally corrected and would have already posted a patch if CVS had been up. > We should not need to pass the language to the counter methods. > Actually only enumLabel needs it for now, but it can be fixed by > something like (untested): > > string Counters::enumLabel(string const & ctr, Buffer const & buf) > { > string format; > > if (ctr == "enumi") > format = buf.B_("\\arabic{enumi}."); > else if (ctr == "enumii") > format = buf.B_("(\\alph{enumii})"); > else if (ctr == "enumiii") > format = buf.B_("\\roman{enumiii}."); > else if (ctr == "enumiv") > format = buf.B_("\\Alph{enumiv}."); > } > > return counterLabel(format); > } Clever! Why not. > This would allow to make the hebrew tricks in he.po, but also to > change for other languages (at least french would like that). I really > think most explicit tests for "hebrew" should go away. Agree 110%. > Note that if strings like "\\arabic{enumi}." seem cryptic, they can be > replaced by something like > "\\arabic{enumi}.[[First level in enumerate environment]]" Hmmm, won't replace a little handholding. Is this explained in the customization guide? > JMarc
signature.asc
Description: This is a digitally signed message part