Re: [PATCH] LFUN_BUFFER_FORALL

2012-07-19 Thread Jean-Marc Lasgouttes

Le 19/07/2012 04:46, Scott Kostyshak a écrit :

From: Jean-Marc Lasgouttes [lasgout...@lyx.org] Sent: Wednesday, July
18, 2012 4:14 AM

JMarc,

Thank you for your guidance. Attached is an updated patch and below I
respond to your comments.


Great! Just one thing beofre committing:


BTW, what happens if several windows are open? It looks like you
are not going to see whether the buffers on other windows are


If there are more windows open, buffer-forall iterates over the
buffers in the current window, treating a buffer as hidden as
designated in the current window.


It would be nice to rephrase the status message to reflect the situation 
like maybe

Applied the following command to all visible buffers in this window: 
(or something else, I am not the native english speaker here)

Note however that on the Mac tabs are not used by default and that each 
files is in its own window (there is an option for that). buffer-forall 
is just useless in this case, isn't it?


JMarc


Re: LyX, XeTeX, bidi and Hebrew

2012-07-19 Thread Guenter Milde
On 2012-07-18, Ronen Abravanel wrote:
 On Wed, Jul 18, 2012 at 11:09 AM, Guenter Milde mi...@users.sf.net wrote:
 On 2012-07-16, Ronen Abravanel wrote:

...

 * What do you get if the example is written as

 שלום (שלום)

   in LyX?

 Just Hello (Hello) in hebrew
 In LyX it's
 שלום (שלום)


 * How would you write the same in OpenOffice or some other word
 processor?

 If I *write* the same thing in a different word processor (OO, ms word or
 other bidi-supported WP) I get the brace proper. If I paste the tex-code
 into a word processor, it's inverted as in the PDF.

This is why I wonder whether XeTeX gets it right (i.e. compatible with other
applications) and pdfLaTeX does it wrong.

Then, instead of fixing XeTeX input, we would need a fix for the export
to traditional TeX and a way to convert existing LyX documents.

Günter



Re: Re: [LyX master] Read list of translated languages from a file

2012-07-19 Thread Kornel Benko
Am Donnerstag, 19. Juli 2012 um 00:26:33, schrieb Jean-Marc Lasgouttes 
lasgout...@lyx.org
 Le 19/07/12 00:21, Jean-Marc Lasgouttes a écrit :
  commit ed1515ef69d0381e9b0657cf1966f9d86e0cb25f
  Author: Jean-Marc Lasgouttes lasgout...@lyx.org
  Date:   Thu Jul 19 00:02:56 2012 +0200
 
   Read list of translated languages from a file
 
   The previous scheme of loading all possible translations and checking 
  whether the work
   is a bit too much brute force and causes problems on Mac OS X 
  (documents loaded
   with the wrong language).
 
   In the new scheme, autotools install a file lib/installed_translations 
  that contains a list of installed languages (the .gmo files that got 
  installed). This file is read
   in Languages::readInstalledTranslations and allows to set the 
  translated() property
   of each language.
 
 Kornel, this requires an adaptation of cmake (see above). On my machine 
 the contents of installed _translations is just
   ar ca cs da de el en es eu fi fr gl he hu ia id it ja nb nl nn pl pt 
 ro ru sk sr sv tr uk zh_CN zh_TW


Counting languages I wonder why I have 36 languages and here are only 32 
languages listed?

Do we have to account for the number of translated strings?

Kornel


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


Re: Re: [LyX master] Read list of translated languages from a file

2012-07-19 Thread Kornel Benko
Am Donnerstag, 19. Juli 2012 um 00:26:33, schrieb Jean-Marc Lasgouttes 
lasgout...@lyx.org
 Le 19/07/12 00:21, Jean-Marc Lasgouttes a écrit :
  commit ed1515ef69d0381e9b0657cf1966f9d86e0cb25f
  Author: Jean-Marc Lasgouttes lasgout...@lyx.org
  Date:   Thu Jul 19 00:02:56 2012 +0200
 
   Read list of translated languages from a file
 
   The previous scheme of loading all possible translations and checking 
  whether the work
   is a bit too much brute force and causes problems on Mac OS X 
  (documents loaded
   with the wrong language).
 
   In the new scheme, autotools install a file lib/installed_translations 
  that contains a list of installed languages (the .gmo files that got 
  installed). This file is read
   in Languages::readInstalledTranslations and allows to set the 
  translated() property
   of each language.


How should automake reflect changes in the po-files? As I understood,
installed_translations is created only during configure.

1.) Shouldn't this step go to make?
2.) Should cmake mimic this behaviour?

Kornel

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


Re: LyX, XeTeX, bidi and Hebrew

2012-07-19 Thread Ronen Abravanel
On Thu, Jul 19, 2012 at 11:17 AM, Guenter Milde mi...@users.sf.net wrote:

 On 2012-07-18, Ronen Abravanel wrote:
  On Wed, Jul 18, 2012 at 11:09 AM, Guenter Milde mi...@users.sf.net
 wrote:
  On 2012-07-16, Ronen Abravanel wrote:

 ...

  * What do you get if the example is written as

  שלום (שלום)

in LyX?

  Just Hello (Hello) in hebrew
  In LyX it's
  שלום (שלום)


  * How would you write the same in OpenOffice or some other word
  processor?

  If I *write* the same thing in a different word processor (OO, ms word or
  other bidi-supported WP) I get the brace proper. If I paste the tex-code
  into a word processor, it's inverted as in the PDF.

 This is why I wonder whether XeTeX gets it right (i.e. compatible with
 other
 applications) and pdfLaTeX does it wrong.

 Then, instead of fixing XeTeX input, we would need a fix for the export
 to traditional TeX and a way to convert existing LyX documents.

 Günter


XeTexX get in in the modern (unicode) sense of right.
LyX, by default, input it wrong, but LyX output is good for pdfLaTeX.

LyX fixes it's output in the plain-text output, and my patch apply the same
correction for Hebrew-XeTeX output...

Ronen


Re: [LyX master] Read list of translated languages from a file

2012-07-19 Thread Pavel Sanda
Jean-Marc Lasgouttes wrote:
  In the new scheme, autotools install a file 
 lib/installed_translations that contains a list of installed languages 
 (the .gmo files that got installed). This file is read

How exactly is this list assembled? Just presence of .gmo in compiled tree
is enough? This could break on linux installs where only subset of compiled
translation is installed.

Pavel


Re: [LyX master] Make the toolbar code less noisy when the session file is not found

2012-07-19 Thread Pavel Sanda
Jean-Marc Lasgouttes wrote:
 commit 02ce050fb825e7707c050f04d5e69f7d1a2a5c8a
 Author: Jean-Marc Lasgouttes lasgout...@lyx.org
 Date:   Mon Jul 16 23:11:26 2012 +0200

  Make the toolbar code less noisy when the session file is not found

 To branch? I am constantly annoyed by this while developing.

+1
P


Re: [LyX master] Make the toolbar code less noisy when the session file is not found

2012-07-19 Thread Richard Heck

On 07/19/2012 03:18 PM, Pavel Sanda wrote:

Jean-Marc Lasgouttes wrote:

commit 02ce050fb825e7707c050f04d5e69f7d1a2a5c8a
Author: Jean-Marc Lasgouttes lasgout...@lyx.org
Date:   Mon Jul 16 23:11:26 2012 +0200

  Make the toolbar code less noisy when the session file is not found

To branch? I am constantly annoyed by this while developing.

+1

Fine by me.

rh



Re: [LyX master] Read list of translated languages from a file

2012-07-19 Thread Jean-Marc Lasgouttes

Le 19/07/12 12:09, Kornel Benko a écrit :

Counting languages I wonder why I have 36 languages and here are only 32
languages listed?

Do we have to account for the number of translated strings?


Yes, we only take those which are green or orange on the status web page 
(described in the file LINGUAS).


JMarc



Re: [LyX master] Read list of translated languages from a file

2012-07-19 Thread Jean-Marc Lasgouttes

Le 19/07/12 14:41, Kornel Benko a écrit :

In the new scheme, autotools install a file
lib/installed_translations that contains a list of installed languages
(the .gmo files that got installed). This file is read

How should automake reflect changes in the po-files? As I understood,
installed_translations is created only during configure.

1.) Shouldn't this step go to make?


The Makefile variable CATALOGS, which tells which languages to 
installed, is fixed at configure time, and it is not really meant to be

changed at make time. The recommended way to handle this problem is to
set the LINGUAS environment vatiable for, say, fr de before running 
configure.



2.) Should cmake mimic this behaviour?


Yes, I think it is good to have the same behaviour for both systems.

JMarc



Re: [LyX master] Read list of translated languages from a file

2012-07-19 Thread Jean-Marc Lasgouttes

Le 19/07/12 21:17, Pavel Sanda a écrit :

Jean-Marc Lasgouttes wrote:

  In the new scheme, autotools install a file
lib/installed_translations that contains a list of installed languages
(the .gmo files that got installed). This file is read


How exactly is this list assembled? Just presence of .gmo in compiled tree
is enough? This could break on linux installs where only subset of compiled
translation is installed.


I use te variable CATALOGS which is built in po.m4 juste before 
generating the po/Makefile. The variable cannot be subst'd using 
@CATALOGS@ in Makefile.am, therefore it is easier to generate the file 
at configure time (after all we already generate other files like 
lyxrc.dist).


JMarc



Re: [LyX master] Make the toolbar code less noisy when the session file is not found

2012-07-19 Thread Jean-Marc Lasgouttes

Le 19/07/12 21:22, Richard Heck a écrit :

On 07/19/2012 03:18 PM, Pavel Sanda wrote:

Jean-Marc Lasgouttes wrote:

commit 02ce050fb825e7707c050f04d5e69f7d1a2a5c8a
Author: Jean-Marc Lasgouttes lasgout...@lyx.org
Date:   Mon Jul 16 23:11:26 2012 +0200

  Make the toolbar code less noisy when the session file is not
found

To branch? I am constantly annoyed by this while developing.

+1

Fine by me.


Done.

JMarc



Re: [LyX master] Read list of translated languages from a file

2012-07-19 Thread Pavel Sanda
Jean-Marc Lasgouttes wrote:
 How exactly is this list assembled? Just presence of .gmo in compiled tree
 is enough? This could break on linux installs where only subset of 
 compiled
 translation is installed.

 I use te variable CATALOGS which is built in po.m4 juste before generating 
 the po/Makefile. The variable cannot be subst'd using @CATALOGS@ in 
 Makefile.am, therefore it is easier to generate the file at configure time 
 (after all we already generate other files like lyxrc.dist).

I think this will break at my distro. What is the damage in case LyX is 
installed
with only few .gmo files while installed_translations contains much more of 
them?

Pavel


Re: [PATCH] LFUN_BUFFER_FORALL

2012-07-19 Thread Jean-Marc Lasgouttes

Le 19/07/2012 04:46, Scott Kostyshak a écrit :

From: Jean-Marc Lasgouttes [lasgout...@lyx.org] Sent: Wednesday, July
18, 2012 4:14 AM

JMarc,

Thank you for your guidance. Attached is an updated patch and below I
respond to your comments.


Great! Just one thing beofre committing:


BTW, what happens if several windows are open? It looks like you
are not going to see whether the buffers on other windows are


If there are more windows open, buffer-forall iterates over the
buffers in the current window, treating a buffer as hidden as
designated in the current window.


It would be nice to rephrase the status message to reflect the situation 
like maybe

"Applied the following command to all visible buffers in this window: "
(or something else, I am not the native english speaker here)

Note however that on the Mac tabs are not used by default and that each 
files is in its own window (there is an option for that). buffer-forall 
is just useless in this case, isn't it?


JMarc


Re: LyX, XeTeX, bidi and Hebrew

2012-07-19 Thread Guenter Milde
On 2012-07-18, Ronen Abravanel wrote:
> On Wed, Jul 18, 2012 at 11:09 AM, Guenter Milde  wrote:
>> On 2012-07-16, Ronen Abravanel wrote:

...

>> * What do you get if the example is written as

>> שלום (שלום)

>>   in LyX?

> Just "Hello (Hello)" in hebrew
> In LyX it's
> שלום (שלום)


>> * How would you write the same in OpenOffice or some other "word
>> processor"?

> If I *write* the same thing in a different word processor (OO, ms word or
> other bidi-supported WP) I get the brace proper. If I paste the tex-code
> into a word processor, it's inverted as in the PDF.

This is why I wonder whether XeTeX gets it right (i.e. compatible with other
applications) and pdfLaTeX does it wrong.

Then, instead of "fixing" XeTeX input, we would need a fix for the export
to traditional TeX and a way to convert existing LyX documents.

Günter



Re: Re: [LyX master] Read list of translated languages from a file

2012-07-19 Thread Kornel Benko
Am Donnerstag, 19. Juli 2012 um 00:26:33, schrieb Jean-Marc Lasgouttes 

> Le 19/07/12 00:21, Jean-Marc Lasgouttes a écrit :
> > commit ed1515ef69d0381e9b0657cf1966f9d86e0cb25f
> > Author: Jean-Marc Lasgouttes 
> > Date:   Thu Jul 19 00:02:56 2012 +0200
> >
> >  Read list of translated languages from a file
> >
> >  The previous scheme of loading all possible translations and checking 
> > whether the work
> >  is a bit too much "brute force" and causes problems on Mac OS X 
> > (documents loaded
> >  with the wrong language).
> >
> >  In the new scheme, autotools install a file lib/installed_translations 
> > that contains a list of installed languages (the .gmo files that got 
> > installed). This file is read
> >  in Languages::readInstalledTranslations and allows to set the 
> > translated() property
> >  of each language.
> 
> Kornel, this requires an adaptation of cmake (see above). On my machine 
> the contents of installed _translations is just
>   ar ca cs da de el en es eu fi fr gl he hu ia id it ja nb nl nn pl pt 
> ro ru sk sr sv tr uk zh_CN zh_TW
>

Counting languages I wonder why I have 36 languages and here are only 32 
languages listed?

Do we have to account for the number of translated strings?

Kornel


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


Re: Re: [LyX master] Read list of translated languages from a file

2012-07-19 Thread Kornel Benko
Am Donnerstag, 19. Juli 2012 um 00:26:33, schrieb Jean-Marc Lasgouttes 

> Le 19/07/12 00:21, Jean-Marc Lasgouttes a écrit :
> > commit ed1515ef69d0381e9b0657cf1966f9d86e0cb25f
> > Author: Jean-Marc Lasgouttes 
> > Date:   Thu Jul 19 00:02:56 2012 +0200
> >
> >  Read list of translated languages from a file
> >
> >  The previous scheme of loading all possible translations and checking 
> > whether the work
> >  is a bit too much "brute force" and causes problems on Mac OS X 
> > (documents loaded
> >  with the wrong language).
> >
> >  In the new scheme, autotools install a file lib/installed_translations 
> > that contains a list of installed languages (the .gmo files that got 
> > installed). This file is read
> >  in Languages::readInstalledTranslations and allows to set the 
> > translated() property
> >  of each language.


How should automake reflect changes in the po-files? As I understood,
installed_translations is created only during configure.

1.) Shouldn't this step go to "make"?
2.) Should cmake mimic this behaviour?

Kornel

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


Re: LyX, XeTeX, bidi and Hebrew

2012-07-19 Thread Ronen Abravanel
On Thu, Jul 19, 2012 at 11:17 AM, Guenter Milde  wrote:

> On 2012-07-18, Ronen Abravanel wrote:
> > On Wed, Jul 18, 2012 at 11:09 AM, Guenter Milde 
> wrote:
> >> On 2012-07-16, Ronen Abravanel wrote:
>
> ...
>
> >> * What do you get if the example is written as
>
> >> שלום (שלום)
>
> >>   in LyX?
>
> > Just "Hello (Hello)" in hebrew
> > In LyX it's
> > שלום (שלום)
>
>
> >> * How would you write the same in OpenOffice or some other "word
> >> processor"?
>
> > If I *write* the same thing in a different word processor (OO, ms word or
> > other bidi-supported WP) I get the brace proper. If I paste the tex-code
> > into a word processor, it's inverted as in the PDF.
>
> This is why I wonder whether XeTeX gets it right (i.e. compatible with
> other
> applications) and pdfLaTeX does it wrong.
>
> Then, instead of "fixing" XeTeX input, we would need a fix for the export
> to traditional TeX and a way to convert existing LyX documents.
>
> Günter
>
>
XeTexX get in in the modern (unicode) sense of right.
LyX, by default, input it "wrong", but LyX output is good for pdfLaTeX.

LyX fixes it's output in the plain-text output, and my patch apply the same
correction for Hebrew-XeTeX output...

Ronen


Re: [LyX master] Read list of translated languages from a file

2012-07-19 Thread Pavel Sanda
Jean-Marc Lasgouttes wrote:
>>  In the new scheme, autotools install a file 
>> lib/installed_translations that contains a list of installed languages 
>> (the .gmo files that got installed). This file is read

How exactly is this list assembled? Just presence of .gmo in compiled tree
is enough? This could break on linux installs where only subset of compiled
translation is installed.

Pavel


Re: [LyX master] Make the toolbar code less noisy when the session file is not found

2012-07-19 Thread Pavel Sanda
Jean-Marc Lasgouttes wrote:
>> commit 02ce050fb825e7707c050f04d5e69f7d1a2a5c8a
>> Author: Jean-Marc Lasgouttes 
>> Date:   Mon Jul 16 23:11:26 2012 +0200
>>
>>  Make the toolbar code less noisy when the session file is not found
>
> To branch? I am constantly annoyed by this while developing.

+1
P


Re: [LyX master] Make the toolbar code less noisy when the session file is not found

2012-07-19 Thread Richard Heck

On 07/19/2012 03:18 PM, Pavel Sanda wrote:

Jean-Marc Lasgouttes wrote:

commit 02ce050fb825e7707c050f04d5e69f7d1a2a5c8a
Author: Jean-Marc Lasgouttes 
Date:   Mon Jul 16 23:11:26 2012 +0200

  Make the toolbar code less noisy when the session file is not found

To branch? I am constantly annoyed by this while developing.

+1

Fine by me.

rh



Re: [LyX master] Read list of translated languages from a file

2012-07-19 Thread Jean-Marc Lasgouttes

Le 19/07/12 12:09, Kornel Benko a écrit :

Counting languages I wonder why I have 36 languages and here are only 32
languages listed?

Do we have to account for the number of translated strings?


Yes, we only take those which are green or orange on the status web page 
(described in the file LINGUAS).


JMarc



Re: [LyX master] Read list of translated languages from a file

2012-07-19 Thread Jean-Marc Lasgouttes

Le 19/07/12 14:41, Kornel Benko a écrit :

 > >  In the new scheme, autotools install a file
lib/installed_translations that contains a list of installed languages
(the .gmo files that got installed). This file is read

How should automake reflect changes in the po-files? As I understood,
installed_translations is created only during configure.

1.) Shouldn't this step go to "make"?


The Makefile variable CATALOGS, which tells which languages to 
installed, is fixed at configure time, and it is not really meant to be

changed at make time. The recommended way to handle this problem is to
set the LINGUAS environment vatiable for, say, "fr de" before running 
configure.



2.) Should cmake mimic this behaviour?


Yes, I think it is good to have the same behaviour for both systems.

JMarc



Re: [LyX master] Read list of translated languages from a file

2012-07-19 Thread Jean-Marc Lasgouttes

Le 19/07/12 21:17, Pavel Sanda a écrit :

Jean-Marc Lasgouttes wrote:

  In the new scheme, autotools install a file
lib/installed_translations that contains a list of installed languages
(the .gmo files that got installed). This file is read


How exactly is this list assembled? Just presence of .gmo in compiled tree
is enough? This could break on linux installs where only subset of compiled
translation is installed.


I use te variable CATALOGS which is built in po.m4 juste before 
generating the po/Makefile. The variable cannot be subst'd using 
@CATALOGS@ in Makefile.am, therefore it is easier to generate the file 
at configure time (after all we already generate other files like 
lyxrc.dist).


JMarc



Re: [LyX master] Make the toolbar code less noisy when the session file is not found

2012-07-19 Thread Jean-Marc Lasgouttes

Le 19/07/12 21:22, Richard Heck a écrit :

On 07/19/2012 03:18 PM, Pavel Sanda wrote:

Jean-Marc Lasgouttes wrote:

commit 02ce050fb825e7707c050f04d5e69f7d1a2a5c8a
Author: Jean-Marc Lasgouttes 
Date:   Mon Jul 16 23:11:26 2012 +0200

  Make the toolbar code less noisy when the session file is not
found

To branch? I am constantly annoyed by this while developing.

+1

Fine by me.


Done.

JMarc



Re: [LyX master] Read list of translated languages from a file

2012-07-19 Thread Pavel Sanda
Jean-Marc Lasgouttes wrote:
>> How exactly is this list assembled? Just presence of .gmo in compiled tree
>> is enough? This could break on linux installs where only subset of 
>> compiled
>> translation is installed.
>
> I use te variable CATALOGS which is built in po.m4 juste before generating 
> the po/Makefile. The variable cannot be subst'd using @CATALOGS@ in 
> Makefile.am, therefore it is easier to generate the file at configure time 
> (after all we already generate other files like lyxrc.dist).

I think this will break at my distro. What is the damage in case LyX is 
installed
with only few .gmo files while installed_translations contains much more of 
them?

Pavel