Re: New layouttranslation strings

2011-07-15 Thread Pavel Sanda
Kornel wrote:
> > >>> the source files for layouttranslation are
> > >>> echo .../lib/layouts/*.{layout,inc,module} >
> > >>> .../po/layouttranslations_files
> > >> 
> > >> So it is a file which lists all the relevant filenames.
> > > 
> > > But how can I create layouttranslations_files? On Windows I don't have an
> > > echo command.
> 
> How about "dir" ?

i bet for a beer that windows shell has no idea about {layout,inc,module} 
constructs.
so forget about it all and just look for files inside /lib/layouts/ which has 
extension layout,inc,module :)

pavel


Re: New layouttranslation strings

2011-07-15 Thread Kornel
Am Freitag, 15. Juli 2011 schrieb Pavel Sanda:
> Uwe Stöhr wrote:
> >>> and there is indeed no file in SVN with the name
> >>> "layouttranslations_files". So what is wrong?
> >> 
> >> You need to create this file. As Kornel said:
> >>> the source files for layouttranslation are
> >>> echo .../lib/layouts/*.{layout,inc,module} >
> >>> .../po/layouttranslations_files
> >> 
> >> So it is a file which lists all the relevant filenames.
> > 
> > But how can I create layouttranslations_files? On Windows I don't have an
> > echo command.

How about "dir" ?

> the official route is "make ../lib/layouttranslations" which wont work
> on windows. iirc Peter/Kornel added this target to cmake.

On cmake this target is "layouttranslations1", therefore:
#make layouttranslations1

> anyway this file shouldn't be routinely rewritten as we do with .po files.
> special care needs to be done so we know what has been reviewed and what
> was not (i try to document those things in layouttranslations.review so if
> anybody commits changes he should make this file up-to-date).
> 
> pavel

Kornel


signature.asc
Description: This is a digitally signed message part.


Re: New layouttranslation strings

2011-07-15 Thread Uwe Stöhr

Am 15.07.2011 21:08, schrieb Pavel Sanda:


Style Prob


indeed, but we were talking about Prop, not Prob :)
so the 'Prop' prolem is still there.


;-)
In German we have the proverb "Who can read is strongly in advantage."

I removed "Prop" now from the layouttranslations.


do we want Property and Solution inside translations?


Yes because several layouts use this term. Many paper submission classes are supporting theorems and 
the like, so we will need this for the future too.


regards Uwe


Re: New layouttranslation strings

2011-07-15 Thread Uwe Stöhr

Am 15.07.2011 18:27, schrieb Kornel:


So it is a file which lists all the relevant filenames.


Exactly. It is written in csh-syntax. It shouldn't be too hard to use an 
equivalent in windows.


It is. I don't know how to do this nor have I ever heard from csh.

regards Uwe


Re: New layouttranslation strings

2011-07-15 Thread Pavel Sanda
Uwe Stöhr wrote:
>>> and there is indeed no file in SVN with the name
>>> "layouttranslations_files". So what is wrong?
>>
>> You need to create this file. As Kornel said:
>>> the source files for layouttranslation are
>>> echo .../lib/layouts/*.{layout,inc,module} > 
>>> .../po/layouttranslations_files
>>
>> So it is a file which lists all the relevant filenames.
>
> But how can I create layouttranslations_files? On Windows I don't have an 
> echo command.

the official route is "make ../lib/layouttranslations" which wont work
on windows. iirc Peter/Kornel added this target to cmake.

anyway this file shouldn't be routinely rewritten as we do with .po files.
special care needs to be done so we know what has been reviewed and what was not
(i try to document those things in layouttranslations.review so if anybody
commits changes he should make this file up-to-date).

pavel


Re: New layouttranslation strings

2011-07-15 Thread Pavel Sanda
Uwe Stöhr wrote:
>>> I'm still confused. In layouttranslation there is neither Prop nor Sol.
>>> Moreover, their definition in theorems-without-preamble.inc is the same,
>>> so why appears only Prop?
>>
>> It is not the same. Prop has LangPreamble and BabelPreamble, Sol does not
>> have them.
>
> No, here are the definitions:
>
> Style Sol
>   CopyStyle   Problem
>   LabelCountersol
>   LatexName   sol
>   LabelString "\thesol"
>   RequiredArgs1
> End
>
> Style Prob

indeed, but we were talking about Prop, not Prob :)
so the 'Prop' prolem is still there.

the current diff to the current layouttranslations attached.

do we want Property and Solution inside translations?
(there is no point if we use it only in some special layout,
on the other they can be useful if they are part of some general module.)

pavel
diff --git a/lib/layouttranslations b/lib/layouttranslations
index 085b4b7..b2860e6 100644
--- a/lib/layouttranslations
+++ b/lib/layouttranslations
@@ -34,10 +34,13 @@ Translation ar
"Note" "ملاحظة"
"Problem" "مشكلة"
"Proof" "برهان"
+   "Prop" "Prop"
+   "Property" "خاصية"
"Proposition" "Proposition"
"Question" "سؤال"
"Remark" "ملاحظة"
"Scheme" "مخطط"
+   "Solution" "حل"
"Summary" "موجز"
"Tableau" "جدول"
"Theorem" "نظرية"
@@ -108,10 +111,13 @@ Translation ca
"Note" "Nota"
"Problem" "Problema"
"Proof" "DemostraciĂł"
+   "Prop" "ProposiciĂł"
+   "Property" "Propietat"
"Proposition" "ProposiciĂł"
"Question" "QĂźestiĂł"
"Remark" "Comentari"
"Scheme" "Scheme"
+   "Solution" "SoluciĂł"
"Summary" "Resum"
"Tableau" "Tableau"
"Theorem" "Teorema"
@@ -145,10 +151,13 @@ Translation cs
"Note" "PoznĂĄmka"
"Problem" "Úloha"
"Proof" "DĹŻkaz"
+   "Prop" "Prop"
+   "Property" "Property"
"Proposition" "TvrzenĂ­"
"Question" "OtĂĄzka"
"Remark" "PoznĂĄmka"
"Scheme" "SchĂŠma"
+   "Solution" "Solution"
"Summary" "Souhrn"
"Tableau" "Tablo"
"Theorem" "Věta"
@@ -182,10 +191,13 @@ Translation da
"Note" "Notat"
"Problem" "Problem"
"Proof" "Bevis"
+   "Prop" "Prop"
+   "Property" "Property"
"Proposition" "Forslag"
"Question" "Spørgsmül"
"Remark" "BemĂŚrkning"
"Scheme" "Schema"
+   "Solution" "Løsning"
"Summary" "ResumĂŠ"
"Tableau" "Tableau"
"Theorem" "SĂŚtning"
@@ -219,10 +231,13 @@ Translation de
"Note" "Notiz"
"Problem" "Problem"
"Proof" "Beweis"
+   "Prop" "Eigenschaft"
+   "Property" "Eigenschaft"
"Proposition" "Satz"
"Question" "Frage"
"Remark" "Bemerkung"
"Scheme" "Schema"
+   "Solution" "LĂśsung"
"Summary" "Zusammenfassung"
"Tableau" "Tableau"
"Theorem" "Theorem"
@@ -260,10 +275,13 @@ Translation el
"Note" "Σημείωση"
"Problem" "Πρόβλημα"
"Proof" "Απόδειξη"
+   "Prop" "Prop"
+   "Property" "Ιδιότητα"
"Proposition" "Πρόταση"
"Question" "Ερώτημα"
"Remark" "Παρατήρηση"
"Scheme" "Σχέδιο"
+   "Solution" "Λύση"
"Summary" "Σύνοψη"
"Tableau" "Ταμπλό"
"Theorem" "Θεώρημα"
@@ -297,10 +315,13 @@ Translation en
"Note" "Note"
"Problem" "Problem"
"Proof" "Proof"
+   "Prop" "Prop"
+   "Property" "Property"
"Proposition" "Proposition"
"Question" "Question"
"Remark" "Remark"
"Scheme" "Scheme"
+   "Solution" "Solution"
"Summary" "Summary"
"Tableau" "Tableau"
"Theorem" "Theorem"
@@ -334,10 +355,13 @@ Translation es
"Note" "Nota"
"Problem" "Problema"
"Proof" "DemostraciĂłn"
+   "Prop" "Prop"
+   "Property" "Propiedad"
"Proposition" "ProposiciĂłn"
"Question" "Pregunta"
"Remark" "ObservaciĂłn"
"Scheme" "Esquema"
+   "Solution" "SoluciĂłn"
"Summary" "Resumen"
"Tableau" "Tableau"
"Theorem" "Teorema"
@@ -371,10 +395,13 @@ Translation eu
"Note" "Ohar"
"Problem" "Buruketa"
"Proof" "Frogapena"
+   "Prop" "Prop"
+   "Property" "Jabegotza"
"Proposition" "Proposizioa"
"Question" "Galdera"
"Remark" "Oharra"
"Scheme" "Eskema"
+   "Solution" "Emaitza"
"Summary" "Laburpena"
"Tableau" "Taula"
"Theorem" "Teorema"
@@ -408,10 +435,13 @@ Translation fi
"Note" "Muistiinpano"
"Problem" "Ongelma"
"Proof" "Todistus"
+   "Prop" "Prop"
+   "Property" "Ominaisuus"
"Proposition" "Väittämä"
"Question" "Kysymys"
"Remark" "Huomau

Re: New layouttranslation strings

2011-07-15 Thread Uwe Stöhr

Am 15.07.2011 16:33, schrieb Julien Rioux:


and there is indeed no file in SVN with the name
"layouttranslations_files". So what is wrong?


You need to create this file. As Kornel said:

the source files for layouttranslation are
echo .../lib/layouts/*.{layout,inc,module} > .../po/layouttranslations_files


So it is a file which lists all the relevant filenames.


But how can I create layouttranslations_files? On Windows I don't have an echo 
command.

thanks and regards
Uwe


Re: New layouttranslation strings

2011-07-15 Thread Uwe Stöhr

Am 15.07.2011 17:01, schrieb Georg Baum:


It is the other way round. You explicitly include strings in that file by
defining LangPreamble and BabelPreamble and using _() in there. Read
Customization.lyx for details.


Thanks for this hint.


I'm still confused. In layouttranslation there is neither Prop nor Sol.
Moreover, their definition in theorems-without-preamble.inc is the same,
so why appears only Prop?


It is not the same. Prop has LangPreamble and BabelPreamble, Sol does not
have them.


No, here are the definitions:

Style Sol
CopyStyle   Problem
LabelCountersol
LatexName   sol
LabelString "\thesol"
RequiredArgs1
End

Style Prob
CopyStyle   Problem
LabelCounterprob
LatexName   prob
LabelString "\theprob."
OptionalArgs0
End

So both inherit the problem style which has a babel preamble. Therefore both Styles should appear in 
layouttranslations, but Sol does not appear.



To answer your question, Prop and Sol are proper
names. They are only used for document classes where English is required
so translating them would not make sense and would only confuse the users.


Then you should remove LangPreamble and BabelPreamble from the layout files
for those styles.


I removed now the dependency of the Problem style. I hope that it is now fixed.

thanks and regards
Uwe


Re: New layouttranslation strings

2011-07-15 Thread Kornel
Am Freitag, 15. Juli 2011 schrieb Julien Rioux:
> On 15/07/2011 10:23 AM, Uwe Stöhr wrote:
> > Am 15.07.2011 07:44, schrieb Kornel:
> >>> I read it now but still don't understand which string appears and how
> >>> I can
> >>> exclude a string.
> >> 
> >> the source files for layouttranslation are
> >> echo .../lib/layouts/*.{layout,inc,module}>
> >> .../po/layouttranslations_files
> > 
[snip]
> > and there is indeed no file in SVN with the name
> > "layouttranslations_files". So what is wrong?
> 
> You need to create this file. As Kornel said:
> > the source files for layouttranslation are
> > 
> > echo .../lib/layouts/*.{layout,inc,module} >
> > .../po/layouttranslations_files
> 
> So it is a file which lists all the relevant filenames.

Exactly. It is written in csh-syntax. It shouldn't be too hard to use an 
equivalent in windows.

> Cheers,
> Julien
> 
> > thanks and regards
> > Uwe

Kornel


signature.asc
Description: This is a digitally signed message part.


Re: New layouttranslation strings

2011-07-15 Thread Georg Baum
Uwe Stöhr wrote:

> I understand this but I don't understand which strings will appear in
> layouttranslation and which not. How can I in/exclude a string from
> appearing in the file?

It is the other way round. You explicitly include strings in that file by 
defining LangPreamble and BabelPreamble and using _() in there. Read 
Customization.lyx for details.

> I'm still confused. In layouttranslation there is neither Prop nor Sol.
> Moreover, their definition in theorems-without-preamble.inc is the same,
> so why appears only Prop?

It is not the same. Prop has LangPreamble and BabelPreamble, Sol does not 
have them.

> To answer your question, Prop and Sol are proper
> names. They are only used for document classes where English is required
> so translating them would not make sense and would only confuse the users.

Then you should remove LangPreamble and BabelPreamble from the layout files 
for those styles.


Georg




Re: New layouttranslation strings

2011-07-15 Thread Julien Rioux

On 15/07/2011 10:23 AM, Uwe Stöhr wrote:

Am 15.07.2011 07:44, schrieb Kornel:


I read it now but still don't understand which string appears and how
I can
exclude a string.


the source files for layouttranslation are
echo .../lib/layouts/*.{layout,inc,module}>
.../po/layouttranslations_files


I understand that layouttranslation consists of all strings in the
layout,inc,module files, but why does "prob" appears" and "sol" not?
Their definition in the inc file is exactly the same. Maybe the script
thinks that a 3 letter word is not a string.


The command to create
.../po/lyx_pot.py -b ... -o .../po/layouttranslations -t
layouttranslations --src_file=.../po/layouttranslations_files
(... stands for root lyx source dir)


This does not work for me. My root folder is

D:\LyXSVN\lyx-devel

so I called

python lyx_pot.py -b D:/LyXSVN/lyx-devel -o
D:/LyXSVN/lyx-devel/lib/layouttranslations -t layouttranslations
--src_file=D:/LyXSVN/lyx-devel/po/layouttranslations_files

and get the error:

Traceback (most recent call last):
File "lyx_pot.py", line 573, in 
input_files = [f.strip() for f in open(value)]
IOError: [Errno 2] No such file or directory:
'D:/LyXSVN/lyx-devel/po/layouttranslations_files'

and there is indeed no file in SVN with the name
"layouttranslations_files". So what is wrong?



You need to create this file. As Kornel said:

the source files for layouttranslation are
echo .../lib/layouts/*.{layout,inc,module} > 
.../po/layouttranslations_files


So it is a file which lists all the relevant filenames.

Cheers,
Julien


thanks and regards
Uwe





Re: New layouttranslation strings

2011-07-15 Thread Uwe Stöhr

Am 15.07.2011 07:44, schrieb Kornel:


I read it now but still don't understand which string appears and how I can
exclude a string.


the source files for layouttranslation are
echo .../lib/layouts/*.{layout,inc,module}>  
.../po/layouttranslations_files


I understand that layouttranslation consists of all strings in the layout,inc,module files, but why 
does "prob" appears" and "sol" not? Their definition in the inc file is exactly the same. Maybe the 
script thinks that a 3 letter word is not a string.



The command to create
.../po/lyx_pot.py -b ... -o .../po/layouttranslations -t 
layouttranslations --src_file=.../po/layouttranslations_files
(... stands for root lyx source dir)


This does not work for me. My root folder is

D:\LyXSVN\lyx-devel

so I called

python lyx_pot.py -b D:/LyXSVN/lyx-devel -o D:/LyXSVN/lyx-devel/lib/layouttranslations -t 
layouttranslations --src_file=D:/LyXSVN/lyx-devel/po/layouttranslations_files


and get the error:

Traceback (most recent call last):
  File "lyx_pot.py", line 573, in 
input_files = [f.strip() for f in open(value)]
IOError: [Errno 2] No such file or directory: 
'D:/LyXSVN/lyx-devel/po/layouttranslations_files'

and there is indeed no file in SVN with the name "layouttranslations_files". So 
what is wrong?

thanks and regards
Uwe


Re: New layouttranslation strings

2011-07-14 Thread Kornel
Am Freitag, 15. Juli 2011 schrieb Uwe Stöhr:
> Am 14.07.2011 03:42, schrieb Pavel Sanda:
> >> I have not touched the file "layouttranslations".
> > 
> > well, not directly. if you change strings they are going to appear in .po
> > files sooner or later. if you change/add some environments which are
> > translatable in .tex output, they'll soon appear in layouttranslation
> > when anyone "remerges" this file.
> 
...
> 
> I read it now but still don't understand which string appears and how I can
> exclude a string.

Well,
the source files for layouttranslation are
echo .../lib/layouts/*.{layout,inc,module} > 
.../po/layouttranslations_files
The command to create
.../po/lyx_pot.py -b ... -o .../po/layouttranslations -t 
layouttranslations --src_file=.../po/layouttranslations_files
(... stands for root lyx source dir)

Therefore any translatable string in .../lib/layouts/*.{layout,inc,module} 
appears in layouttranslations

> regards Uwe

Kornel


Re: New layouttranslation strings

2011-07-14 Thread Uwe Stöhr

Am 14.07.2011 03:42, schrieb Pavel Sanda:


I have not touched the file "layouttranslations".


well, not directly. if you change strings they are going to appear in .po
files sooner or later. if you change/add some environments which are
translatable in .tex output, they'll soon appear in layouttranslation
when anyone "remerges" this file.


I understand this but I don't understand which strings will appear in layouttranslation and which 
not. How can I in/exclude a string from appearing in the file?



to repeat my question: we translate "Prop" and not "Sol". this can
be seen when layouttranslation file is remerged. should they be both translated?
or none of them?


I'm still confused. In layouttranslation there is neither Prop nor Sol. Moreover, their definition 
in theorems-without-preamble.inc is the same, so why appears only Prop?
To answer your question, Prop and Sol are proper names. They are only used for document classes 
where English is required so translating them would not make sense and would only confuse the users.



i guess you missed the discussion about new translation mechanism
of lyx while being in SA. README.localization, PART II should
be read to have at least some user-perspective.


I read it now but still don't understand which string appears and how I can 
exclude a string.

regards Uwe


Re: New layouttranslation strings

2011-07-13 Thread Pavel Sanda
Uwe Stöhr wrote:
> Am 13.07.2011 03:12, schrieb Pavel Sanda:
>
>> it seems you recently add new layout strings to be translated in latex 
>> output,
>> in particular "Prop", "Property", "Solution".
>
> I don't understand. I added new styles for the Springer layouts. Their 
> names should automaticaklly appear in the po-files after a remerge.
>
>> its also strange that we want to translate introduced "Prop" while
>> letting new environment "Sol" untranslated.
>
> What do you mean? "Sol" is a style in svcommons.inc as "Prop". What is the 
> difference?
>
> I have not touched the file "layouttranslations".

well, not directly. if you change strings they are going to appear in .po
files sooner or later. if you change/add some environments which are
translatable in .tex output, they'll soon appear in layouttranslation
when anyone "remerges" this file.

to repeat my question: we translate "Prop" and not "Sol". this can 
be seen when layouttranslation file is remerged. should they be both translated?
or none of them?

i guess you missed the discussion about new translation mechanism
of lyx while being in SA. README.localization, PART II should
be read to have at least some user-perspective.

pavel


Re: New layouttranslation strings

2011-07-13 Thread Uwe Stöhr

Am 13.07.2011 03:12, schrieb Pavel Sanda:


it seems you recently add new layout strings to be translated in latex output,
in particular "Prop", "Property", "Solution".


I don't understand. I added new styles for the Springer layouts. Their names should automaticaklly 
appear in the po-files after a remerge.



its also strange that we want to translate introduced "Prop" while
letting new environment "Sol" untranslated.


What do you mean? "Sol" is a style in svcommons.inc as "Prop". What is the 
difference?

I have not touched the file "layouttranslations".

regards Uwe