Re: 2.2.3 Tarballs

2017-05-09 Thread Stephan Witt
Am 09.05.2017 um 18:25 schrieb Richard Heck :
> 
> On 05/09/2017 08:31 AM, Stephan Witt wrote:
>> Am 08.05.2017 um 09:19 schrieb Stephan Witt :
>>> Am 07.05.2017 um 19:07 schrieb Richard Heck :
 The tarballs for LyX 2.2.3 are available at
 
  ftp://ftp.lyx.org/pub/lyx/devel/lyx-2.2/2.2.3/
 
 Please let me know if you have any problems building. Please also
 prepare binaries, if not! We'll aim to release end of the week.
>>> It compiles on recent Mac OS X and on my ancient system. The i386 version 
>>> has a problem with the change to the newer hunspell library (change from
>>> 1.3.2 to 1.3.3) That’s why I couldn’t run the binary from the package.
>>> I have to see how to solve this. I’ll report back later.
>> I’m ready to build LyX for 64-bit-Cocoa on Mac 10.7 or newer and for
>> 32-bit-Carbon on Mac 10.5 or newer.
> 
> OK, please do. It seems all is well.

I’ve put them into my dropbox:

https://www.dropbox.com/s/beoksixflg0mti6/LyX-2.2.3%2Bqt5-x86_64-cocoa.dmg?dl=0
https://www.dropbox.com/s/w0ubyam1c4n9qjm/LyX-2.2.3%2Bqt5-x86_64-cocoa.dmg.sig?dl=0

and

https://www.dropbox.com/s/oyai2dckkckjoon/LyX-2.2.3%2Bqt4-i386-carbon.dmg?dl=0
https://www.dropbox.com/s/jkx4wuw40oiu3so/LyX-2.2.3%2Bqt4-i386-carbon.dmg.sig?dl=0

Best regards,
Stephan

Re: Migration of preferences

2017-05-09 Thread Stephan Witt
Am 10.05.2017 um 02:27 schrieb Uwe Stöhr :
> 
> El 08.05.2017 a las 16:42, Scott Kostyshak escribió:
> 
>> On Mon, May 08, 2017 at 06:39:38PM +1200, Andrew Parsloe wrote:
> 
>>> alpha1-1 installed on windows 7. I can't remember if preferences are
>>> supposed to migrate on a major release.
> 
> They won't be migrated. The idea is to be able to run major versions side by 
> side. This way you can check our LyX 2.3.x as long as you want and can go 
> back to LyX 2.2.x if you encounter problems.

On Mac the preferences are in a separate directory for every major release too. 
2014 I added the feature to create a copy of previous major releases 
automatically if they’re present as first step of the configure process. Not 
all developers were friends of this change - so I made it limited to platform 
darwin (Mac OS X). If you’re interested in doing likewise on Windows too it 
shouldn’t be impossible. That way the old major release and the new one exists 
in parallel - exactly the same as without the additional copy step.

Stephan

Re: libreoffice conversion issues

2017-05-09 Thread Tommaso Cucinotta

On 09/05/2017 22:56, Uwe Stöhr wrote:

Have you tried the latest LibreOffice? Some of the recent releases had 
conversion problems. Until I upgraded to 5.3.2 LibreOffice works fine for me. 
Of course the wrong option syntax should be fixed.


That was among the queued tries after my Ubuntu upgrade. Now I have LibreOffice 
5.3.1.2 and the problem seems to have gone.

This is the full output I get on screen, in addition to the "--" vs "-" syntax 
issue:

$ ./src/lyx ~/newfile1.lyx
Warning: -headless is deprecated.  Use --headless instead.
Warning: -nologo is deprecated.  Use --nologo instead.
Warning: eps is deprecated.  Use -eps instead.
convert /tmp/lyx_tmpdir.TCUECaQ20934/gconverto20934.odg -> 
/tmp/lyx_tmpdir.TCUECaQ20934/gconverto20934.eps using filter : draw_eps_Export
Input files: -
Processing: -
Rendering with existing %%BoundingBox: 0 0 539 785
Calculating Bounding Box...ready. %%BoundingBox: 96 589 236 697
Creating output file - ... ready.

Perhaps some of these lines might also be hidden...

T.



Re: libreoffice conversion issues

2017-05-09 Thread Tommaso Cucinotta

On 09/05/2017 22:56, Uwe Stöhr wrote:

Of course the wrong option syntax should be fixed.


[47cd1e23/lyxgit].

T.


Re: Migration of preferences

2017-05-09 Thread Uwe Stöhr

El 08.05.2017 a las 16:42, Scott Kostyshak escribió:


On Mon, May 08, 2017 at 06:39:38PM +1200, Andrew Parsloe wrote:



alpha1-1 installed on windows 7. I can't remember if preferences are
supposed to migrate on a major release.


They won't be migrated. The idea is to be able to run major versions 
side by side. This way you can check our LyX 2.3.x as long as you want 
and can go back to LyX 2.2.x if you encounter problems.


regards Uwe


Re: 2.2.3 Tarballs

2017-05-09 Thread Uwe Stöhr

El 07.05.2017 a las 19:07, Richard Heck escribió:


Please let me know if you have any problems building.


Everything works fine but I get under Help->About that it was built on 
May 17.



Please also prepare binaries, if not!


Here they are:
http://ftp.lyx.de/LyXWinInstaller/LyX2.2.3/

Please give me a day to test them.

regards Uwe


Re: [patch] support for document class option leqno

2017-05-09 Thread Uwe Stöhr

El 09.05.2017 a las 22:47, Uwe Stöhr escribió:

Unfortunately I have not much spare time. I'll have a look right now and 
try to send a patch.


I needed all I had for a CMake issue and LyX 2.2.3.
Maybe I will have some time on Thursday. If you have time, please step 
in and add support for reqno.


thanks, sorry and regards
Uwe


Re: #10658: LyX cannot be compiled any longer with CMake to show a console

2017-05-09 Thread Uwe Stöhr

El 10.05.2017 a las 00:31, Kornel Benko escribió:


LYX_CONSOLE:BOOL=ON

But I explicitly set it to OFF, see the build5-2015.bat file in git master.


You mean in 'install' case. If mode == 'devel', you set it to "ON".


Yes.
However, I found now the real problem. whatever i execute in my batch 
file is never executed because the path to CMake was never specified and 
by default the patch to the cmake.exe is no longer set to the Windows 
environment variable PATH.

I fixed this now but then I got the next problem I cannot solve:

in my build script I have now

set LYX_BUILD=D:\LyXGit\Master\compile-2015
cmake %LYX_SOURCE% -G"Visual Studio 14 2015" -DCMAKE_PREFIX_PATH="test" 
-DLYX_USE_QT=QT5 ...


with this I get now in the CMakeCache.txt

//Used Qt version
CMAKE_PREFIX_PATH:PATH=D:/LyXGit/Master/compile-2015/test

instead of

//Used Qt version
CMAKE_PREFIX_PATH:PATH=test

So the bug is that CMAKE_PREFIX_PATH always starts with LYX_BUILD. But I 
need an empty value.


If you could fix this, I could replace "test" with the correct path to 
Qt and finally got a running batch file.


many thanks and regards
Uwe


Re: #10658: LyX cannot be compiled any longer with CMake to show a console

2017-05-09 Thread Kornel Benko
Am Dienstag, 9. Mai 2017 um 23:19:30, schrieb Uwe Stöhr 
> El 09.05.2017 a las 23:04, Kornel Benko escribió:
> 
> > Please Uwe, do me the favour and check CMakeCache.txt.
> > I DO believe you, that it is not working. I want to know the value (if any) 
> > in CMakeCache.txt.
> 
> I will.
> Now I turned on the consile on the CMake gui and get a console.
> 
> but when i now use my build script to build an installer version:
> 
> -DLYX_CONSOLE=OFF
> 
> I still get a build with the console.
> in CMakeCache.txt I see
> 
> //Show console on Windows, enforce with =FORCE

The comment is clearly wrong. This is an option (which means cached BOOL 
variable).

> LYX_CONSOLE:BOOL=ON
> 
> But I explicitly set it to OFF, see the build5-2015.bat file in git master.

You mean in 'install' case. If mode == 'devel', you set it to "ON".

> Moreover FORCE is no BOOL value so
> LYX_CONSOLE:BOOL=FORCE
> cannot work.

Exactly.

> thank for having a look and regards
> Uwe

Kornel

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


Re: #10658: LyX cannot be compiled any longer with CMake to show a console

2017-05-09 Thread Uwe Stöhr

El 09.05.2017 a las 23:04, Kornel Benko escribió:


Please Uwe, do me the favour and check CMakeCache.txt.
I DO believe you, that it is not working. I want to know the value (if any) in 
CMakeCache.txt.


I will.
Now I turned on the consile on the CMake gui and get a console.

but when i now use my build script to build an installer version:

-DLYX_CONSOLE=OFF

I still get a build with the console.
in CMakeCache.txt I see

//Show console on Windows, enforce with =FORCE
LYX_CONSOLE:BOOL=ON

But I explicitly set it to OFF, see the build5-2015.bat file in git master.

Moreover FORCE is no BOOL value so
LYX_CONSOLE:BOOL=FORCE
cannot work.

thank for having a look and regards
Uwe


Re: #10658: LyX cannot be compiled any longer with CMake to show a console

2017-05-09 Thread Kornel Benko
Am Dienstag, 9. Mai 2017 um 22:39:34, schrieb Uwe Stöhr 
> El 09.05.2017 a las 22:34, Kornel Benko escribió:
> 
> >>   Therefore I used a build script build5-2015.bat that is in LyX's master
> >>   git. There we have
> >>   -DLYX_CONSOLE=FORCE
> > 
> > Yes, but you also set -DLYX_INSTALL=0, which prevents the handling of 
> > LYX_CONSOLE=FORCE (See CMakeLists.txt:183)
> 
> I set -DLYX_INSTALL=0 because I don't want an install build but a debug 
> build. In the past (the last years) I could do this and got nevertheless 
> a console.
> 
> Nevertheless one cannot set LYX_CONSOLE to FORCE in the CMake gui but 
> the CMake gui tells me that I should do so to get a console on Windows.
> 
> >>   I therefore used now
> >>   -DLYX_CONSOLE=ON
> >>   but I still don't get a console.
> > 
> > Have you checked the value of LYX_CONSOLE in CMakeCache.txt?
> 
> I even deleted the CMake cache and set up everything from scratch with a 
> complete rebuild of LyX.

Please Uwe, do me the favour and check CMakeCache.txt.
I DO believe you, that it is not working. I want to know the value (if any) in 
CMakeCache.txt.

> Do I have to use
> -DLYX_CONSOLE=0
> instead of
> -DLYX_CONSOLE=ON
> 
> regards Uwe

Kornel

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


Re: libreoffice conversion issues

2017-05-09 Thread Uwe Stöhr

El 06.05.2017 a las 01:34, Tommaso Cucinotta escribió:

For 1), we have also the unoconv converter in configure.py, which seems 
to work instead, shall we define unoconv as the first default ?


Please not for Windows.

Have you tried the latest LibreOffice? Some of the recent releases had 
conversion problems. Until I upgraded to 5.3.2 LibreOffice works fine 
for me. Of course the wrong option syntax should be fixed.


thanks and regards
Uwe


Re: default dir when save for first time is not cwd

2017-05-09 Thread Andrew Parsloe


On 9/05/2017 11:04 p.m., Scott Kostyshak wrote:


If the Working Directory slot is not filled on Windows (or if it contains
just a period)  File > Open opens to LyX 2.3/bin which seems dangerous to
me.


I agree it should not open to 2.3/bin.


I imagine it should be the My Documents folder.


Is this what it was on 2.2.x?

Scott

This is too late to be relevant but just for the record, on my system 
when the Working Directory is not explicitly specified (or is .) both 
2.1.5 and 2.2.2 exhibit the same behaviour as 2.3: they open to 2.x/bin 
(windows 7). I hadn't noticed before because I always explicitly specify 
the Working Directory.


Andrew


---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus



Re: [patch] support for document class option leqno

2017-05-09 Thread Uwe Stöhr

El 05.05.2017 a las 18:38, Jean-Marc Lasgouttes escribió:


Here is the example again.


Thanks.

With this file, the numbers are on the left side in the PDF output, 
although I did not use leqno.


That is what i meant. Yes, it is possible that document classes or 
packages set the default numbering to the left by internally calling leqno.


Again, I am not opposed to reqno support. If others agree reqno can be 
supported and as Günter said her sees no problem. So fine with me for reqno.


Unfortunately I have not much spare time. I'll have a look right now and 
try to send a patch.


regards Uwe


Re: #10658: LyX cannot be compiled any longer with CMake to show a console

2017-05-09 Thread Uwe Stöhr

El 09.05.2017 a las 22:34, Kornel Benko escribió:


  Therefore I used a build script build5-2015.bat that is in LyX's master
  git. There we have
  -DLYX_CONSOLE=FORCE


Yes, but you also set -DLYX_INSTALL=0, which prevents the handling of 
LYX_CONSOLE=FORCE (See CMakeLists.txt:183)


I set -DLYX_INSTALL=0 because I don't want an install build but a debug 
build. In the past (the last years) I could do this and got nevertheless 
a console.


Nevertheless one cannot set LYX_CONSOLE to FORCE in the CMake gui but 
the CMake gui tells me that I should do so to get a console on Windows.



  I therefore used now
  -DLYX_CONSOLE=ON
  but I still don't get a console.


Have you checked the value of LYX_CONSOLE in CMakeCache.txt?


I even deleted the CMake cache and set up everything from scratch with a 
complete rebuild of LyX.


Do I have to use
-DLYX_CONSOLE=0
instead of
-DLYX_CONSOLE=ON

regards Uwe


Re: #10658: LyX cannot be compiled any longer with CMake to show a console

2017-05-09 Thread Kornel Benko
Am Dienstag, 9. Mai 2017 um 19:59:37, schrieb LyX Ticket Tracker 
> #10658: LyX cannot be compiled any longer with CMake to show a console
> ---+
>  Reporter:  uwestoehr  |  Owner:  kornel
>  Type:  defect | Status:  new
>  Priority:  normal |  Milestone:  2.3.0
> Component:  build  |Version:  2.3.0dev
>  Severity:  normal |   Keywords:  regression
> ---+
>  For a fresh build open the CMake gui.
>  it offers to set the variable
>  LYX_CONSOLE
>  The tooltip says "Show console on Windows, enforce with =FORCE"
> 
>  But one cannot set FORCE via the CMake gui.
> 
>  Therefore I used a build script build5-2015.bat that is in LyX's master
>  git. There we have
>  -DLYX_CONSOLE=FORCE

Yes, but you also set -DLYX_INSTALL=0, which prevents the handling of 
LYX_CONSOLE=FORCE (See CMakeLists.txt:183)

>  This works for LyX 2.2.x branch but not for master. I can compile but the
>  lyx.exe I get has no console.
> 
>  I therefore used now
>  -DLYX_CONSOLE=ON
>  but I still don't get a console.

Have you checked the value of LYX_CONSOLE in CMakeCache.txt?

>  As lat try I set
>  LYX_CONSOLE
>  in the CMake gui ut still don't get a console.
> 
>  A console is useful for debug builds so it would be nice to have a way to
>  get one.

Kornel

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


2.3.0alpha1-1: file save

2017-05-09 Thread john kennan
Start a new file
type something
save
type some more
save

I get "the file ... changed on disk." with two buttons: "Reload" and
"Ignore"

hitting Ignore leaves the file unsaved
hitting Reload works -- I get a warning:

Any changes will be lost. Are you sure you want to load the version on disk
of the document .../Papers/LyX/test1.lyx?

with buttons for Revert and Cancel
Hitting Revert saves the file, as desired, and the changes are not lost.

John


Re: 2.3.0alpha1-1

2017-05-09 Thread Richard Heck
On 05/09/2017 08:22 AM, Stephan Witt wrote:
> Am 09.05.2017 um 14:14 schrieb john kennan :
>>
>>
>> On Tue, May 9, 2017 at 1:11 AM, Stephan Witt  wrote:
>>
>>> Am 09.05.2017 um 02:59 schrieb john kennan :
>>>
>>>
>>>
>>> On Mon, May 8, 2017 at 1:04 PM, Stephan Witt  wrote:
>>> Am 08.05.2017 um 19:48 schrieb Richard Heck :
 On 05/08/2017 11:22 AM, john kennan wrote:
> Scott:
>
> log file, as requested.
>
> John
>
>
> jkmac:referee jk$ /Applications/LyX.app/Contents/MacOS/lyx -dbg info
> "/Users/jk/Box Sync/jk/jkdonorblurb.lyx"
> Setting debug level to info
> Debugging `info' (General information)
> support/filetools.cpp (1002): Running: python -tt -V 2>&1
> support/filetools.cpp (1002): Running: python -tt
> "/Applications/LyX.app/Contents/Resources/scripts/prefs2prefs.py" -p
> "/Users/jk/Library/Application Support/LyX-2.3/preferences"
> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/convert_lyxrc.Ul2103"
> Encoding.cpp (798): Read unicode symbol 160 '~' ' '0 1 ~' '' 0 1 0 0 1
> ...
> Encoding.cpp (798): Read unicode symbol 120831 '' ' '0 0 \mathtt{9}'
> '' 0 1 0 0 1
> Encoding.cpp (864): Reading encoding utf8
> ...
> Language.cpp (210): Reading language welsh
> support/filetools.cpp (1002): Running: python -tt
> "/Applications/LyX.app/Contents/Resources/scripts/prefs2prefs.py" -l
> "/Users/jk/Library/Application Support/LyX-2.3/bind/user.bind"
> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/convert_bind.yA2103"
> Buffer.cpp (477): Buffer::Buffer()
> BufferList.cpp (122): Assigning to buffer 0
> Buffer.cpp (1324): Running 'python -tt
> "/Applications/LyX.app/Contents/Resources/lyx2lyx/lyx2lyx" -t 541 -o
> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/lyx_tmpdir.YQwVSnRg2103/Buffer_convertLyXFormatWT2103.lyx"
> "/Users/jk/Box Sync/jk/jkdonorblurb.lyx"'
> support/filetools.cpp (1002): Running: python -tt
> "/Applications/LyX.app/Contents/Resources/lyx2lyx/lyx2lyx" -t 541 -o
> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/lyx_tmpdir.YQwVSnRg2103/Buffer_convertLyXFormatWT2103.lyx"
> "/Users/jk/Box Sync/jk/jkdonorblurb.lyx"
> Traceback (most recent call last):
>  File "/Applications/LyX.app/Contents/Resources/lyx2lyx/lyx2lyx",
> line 22, in 
>import argparse
> ImportError: No module named argparse
> Error: Conversion script failed
 That's the error there. For some reason the called version of python
 does not see that module. Note that the two versions of python are very
 different: 2.7.5 and 3.6.1. I would guess that the argparse module may
 not be installed for 2.7.5.
>>> On Mac OS X 10.11.6 the vanilla python is 2.7.10 - I cannot believe it’s
>>> 2.7.5 on 10.12.4 (Sierra?)
>>>
>>> $ /usr/bin/python
>>> Python 2.7.10 (default, Oct 23 2015, 19:19:21)
>>> [GCC 4.2.1 Compatible Apple LLVM 7.0.0 (clang-700.0.59.5)] on darwin
>>> Type "help", "copyright", "credits" or "license" for more information.
>> import argparse;
>> quit()
>>> $
>>>
>>> Stephan
>>>
>>> Apparently argparse was installed
>>>
>>> jkmac-3:MacOS jk$ python
>>> Python 2.7.5 |Anaconda 1.8.0 (x86_64)| (default, Oct 24 2013, 07:02:20)
>>> [GCC 4.0.1 (Apple Inc. build 5493)] on darwin
>>> Type "help", "copyright", "credits" or "license" for more information.
>> import argparse
>> import quack
>>> Traceback (most recent call last):
>>>   File "", line 1, in 
>>> ImportError: No module named quack
>> quit()
>>> Presumably lyx2lyx wasn't looking in the right place.
>> What is this for a python installation? Does it work with /usr/bin/python?
>>
>> jkmac-3:MacOS jk$ /usr/bin/python
>> Python 2.7.10 (default, Feb  6 2017, 23:53:20) 
>> [GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.34)] on darwin
>> Type "help", "copyright", "credits" or "license" for more information.
> import argparse
> quit()
>> jkmac-3:MacOS jk$ python
>> Python 2.7.5 |Anaconda 1.8.0 (x86_64)| (default, Oct 24 2013, 07:02:20) 
>> [GCC 4.0.1 (Apple Inc. build 5493)] on darwin
>> Type "help", "copyright", "credits" or "license" for more information.
> import argparse
> quit()
>> jkmac-3:MacOS jk$ 
> Sorry, I was not explicit. Are you able to test the LyX reconfigure
> menu item with /usr/bin/python as your system python interpreter?
>
> Meanwhile I searched for the phenomena „Anaconda on Mac“ and there
> are other reports of problems from users of Anaconda python with
> their regular tasks. Perhaps you should temporarily disable it to
> test LyX - I don’t know what to do in case you want to work with
> Anaconda python and LyX in parallel.

It feels (and it just is a feeling) as if there's some kind of conflict
that happens when we call
the system python. Maybe because of something in the path? Could that
lead python itself to
look for packages in the 

Re: 2.2.3 Tarballs

2017-05-09 Thread Richard Heck
On 05/09/2017 08:31 AM, Stephan Witt wrote:
> Am 08.05.2017 um 09:19 schrieb Stephan Witt :
>> Am 07.05.2017 um 19:07 schrieb Richard Heck :
>>> The tarballs for LyX 2.2.3 are available at
>>>
>>>   ftp://ftp.lyx.org/pub/lyx/devel/lyx-2.2/2.2.3/
>>>
>>> Please let me know if you have any problems building. Please also
>>> prepare binaries, if not! We'll aim to release end of the week.
>> It compiles on recent Mac OS X and on my ancient system. The i386 version 
>> has a problem with the change to the newer hunspell library (change from
>> 1.3.2 to 1.3.3) That’s why I couldn’t run the binary from the package.
>> I have to see how to solve this. I’ll report back later.
> I’m ready to build LyX for 64-bit-Cocoa on Mac 10.7 or newer and for
> 32-bit-Carbon on Mac 10.5 or newer.

OK, please do. It seems all is well.

Richard



Re: [LyX/master] python3: fix the preview framework to work with both python 2 and 3

2017-05-09 Thread José Abílio Matos
On Tuesday, 9 May 2017 16.06.54 WEST Jean-Marc Lasgouttes wrote:
> I just got the following. Is it related?

Yes. I committed the obvious fix.

Thank you. :-)
-- 
José Abílio


Re: default dir when save for first time is not cwd

2017-05-09 Thread Scott Kostyshak
On Tue, May 09, 2017 at 04:44:11PM +0200, Stephan Witt wrote:
> Am 09.05.2017 um 15:39 schrieb Scott Kostyshak :
> > 
> > On Tue, May 09, 2017 at 02:38:10PM +0200, Stephan Witt wrote:
> > 
> >> Thank you too. Code-wise I think it’s ok now. No regression anymore.
> >> But UI-wise the translation is not ok. I have both versions here. First
> >> the german and after it the english one - frankly said, I don’t know how
> >> to fix it. I’m attaching a screen shot instead :)
> > 
> > Fixed at f8ffc2c5 :)
> 
> I fixed the fix at e51ccbf, thanks anyway. Now I know it better. :)

Oops, thanks.

Scott


signature.asc
Description: PGP signature


Re: default dir when save for first time is not cwd

2017-05-09 Thread Stephan Witt
Am 09.05.2017 um 15:39 schrieb Scott Kostyshak :
> 
> On Tue, May 09, 2017 at 02:38:10PM +0200, Stephan Witt wrote:
> 
>> Thank you too. Code-wise I think it’s ok now. No regression anymore.
>> But UI-wise the translation is not ok. I have both versions here. First
>> the german and after it the english one - frankly said, I don’t know how
>> to fix it. I’m attaching a screen shot instead :)
> 
> Fixed at f8ffc2c5 :)

I fixed the fix at e51ccbf, thanks anyway. Now I know it better. :)

Stephan

Re: [LyX/master] Add support to cross out characters

2017-05-09 Thread Jean-Marc Lasgouttes

Le 07/05/2017 à 14:41, Guillaume MM a écrit :

 LFUN_SECTION_SELECT,// vfr, 20090503
 LFUN_FONT_UNDERLINE,
 LFUN_FONT_STRIKEOUT,
+LFUN_FONT_CROSSOUT, // uwestoehr 20170402
 LFUN_FONT_UNDERUNDERLINE,
 // 335
 LFUN_FONT_UNDERWAVE,


After this addition the comments "// 335" etc. are no longer in sync
with the enum value, I fear.


You are right, I fixed it.

JMarc



Re: [coverity again] missing move constructors

2017-05-09 Thread Jean-Marc Lasgouttes

Le 21/04/2017 à 00:11, Guillaume MM a écrit :

Le 08/04/2017 à 23:05, Jean-Marc Lasgouttes a écrit :



FileName:
This would be automatically copyable and movable if not for the use of
the pointer to implementation.


What is the problem with the pointer?


For motivations see for instance
.


The spimpl template declared there looks good to me. There is no problem 
with distributing Boost licenced stuff with LyX, we do it already.


Concerning the patches, thery are in general way above my head, and I 
trust your judgment. My remarks are
* it is not nice to have to use unique_ptr allover the 
place, I do not really care about implementation details. Is it possible 
to have the vector carry InsetLabel objects instead?

* the MouseHover.* files seems to be missing fro your third patch.


Speaking of review, I found that setMouseHover was never used, making
the variable useless. What do you think?


I'm afraid I don't understand what you mean here.

JMarc



Re: default dir when save for first time is not cwd

2017-05-09 Thread Scott Kostyshak
On Tue, May 09, 2017 at 02:38:10PM +0200, Stephan Witt wrote:

> Thank you too. Code-wise I think it’s ok now. No regression anymore.
> But UI-wise the translation is not ok. I have both versions here. First
> the german and after it the english one - frankly said, I don’t know how
> to fix it. I’m attaching a screen shot instead :)

Fixed at f8ffc2c5 :)

Scott


signature.asc
Description: PGP signature


Re: 2.3.0alpha1-1

2017-05-09 Thread Stephan Witt
Am 09.05.2017 um 14:57 schrieb john kennan :
> 
> On Tue, May 9, 2017 at 7:22 AM, Stephan Witt  wrote:
> Am 09.05.2017 um 14:14 schrieb john kennan :
> >
> >
> >
> > On Tue, May 9, 2017 at 1:11 AM, Stephan Witt  wrote:
> >
> > > Am 09.05.2017 um 02:59 schrieb john kennan :
> > >
> > >
> > >
> > > On Mon, May 8, 2017 at 1:04 PM, Stephan Witt  wrote:
> > > Am 08.05.2017 um 19:48 schrieb Richard Heck :
> > > >
> > > > On 05/08/2017 11:22 AM, john kennan wrote:
> > > >> Scott:
> > > >>
> > > >> log file, as requested.
> > > >>
> > > >> John
> > > >>
...
> Sorry, I was not explicit. Are you able to test the LyX reconfigure
> menu item with /usr/bin/python as your system python interpreter?
> 
> I'm not sure what this means, but in any case I don't think I can do it at 
> this point. I'm using two machines, one with 2.3alpha and the other with 
> 2.2.2 And the alpha machine now has Python 2.7.13, and lyx2lyx works there. 
> The other machine still has Anaconda python, so I can't test the (Anaconda, 
> 2.3alpha combination)
> 
> But the machine with Anaconda and LxY 2.2.2 has no trouble running lyx2lyx on 
> old formats (501, for example). I've been through many LyX versions with no 
> change in the python setup, and this conversion problem is new with 2.3alpha.
>  
> 
> Meanwhile I searched for the phenomena „Anaconda on Mac“ and there
> are other reports of problems from users of Anaconda python with
> their regular tasks. Perhaps you should temporarily disable it to
> test LyX - I don’t know what to do in case you want to work with
> Anaconda python and LyX in parallel.
> 
> It's an old version of Anaconda, not currently in use. It may well be that 
> updating Anaconda would fix the problem.  

Just in case you’re curious… there are some possibilities to test.

You can open the disk image and start LyX from there. The first start
fires configure.py and your LyX-2.2 user directory will be copied to
LyX-2.3 - but perhaps that is too risky. I’m not sure what happens if
the copy-operation is failing. So, make a backup of your
„$HOME/Library/Application Support/LyX-2.2“ directory first.

To disable Anaconda you should comment out the PATH change in your
.bash_profile or .bashrc or .login (I don’t know exactly). You probably
need to disconnect and reconnect to make this change effective.

Perhaps it’s better to create a test account and start LyX-2.2.2 first.
Do some configuration and save it. Next you can test LyX-2.3alpha.

Stephan

Re: 2.3.0alpha1-1

2017-05-09 Thread john kennan
On Tue, May 9, 2017 at 7:22 AM, Stephan Witt  wrote:

> Am 09.05.2017 um 14:14 schrieb john kennan :
> >
> >
> >
> > On Tue, May 9, 2017 at 1:11 AM, Stephan Witt  wrote:
> >
> > > Am 09.05.2017 um 02:59 schrieb john kennan :
> > >
> > >
> > >
> > > On Mon, May 8, 2017 at 1:04 PM, Stephan Witt  wrote:
> > > Am 08.05.2017 um 19:48 schrieb Richard Heck :
> > > >
> > > > On 05/08/2017 11:22 AM, john kennan wrote:
> > > >> Scott:
> > > >>
> > > >> log file, as requested.
> > > >>
> > > >> John
> > > >>
> > > >>
> > > >> jkmac:referee jk$ /Applications/LyX.app/Contents/MacOS/lyx -dbg
> info
> > > >> "/Users/jk/Box Sync/jk/jkdonorblurb.lyx"
> > > >> Setting debug level to info
> > > >> Debugging `info' (General information)
> > > >> support/filetools.cpp (1002): Running: python -tt -V 2>&1
> > > >> support/filetools.cpp (1002): Running: python -tt
> > > >> "/Applications/LyX.app/Contents/Resources/scripts/prefs2prefs.py"
> -p
> > > >> "/Users/jk/Library/Application Support/LyX-2.3/preferences"
> > > >> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/convert_lyxrc.
> Ul2103"
> > > >> Encoding.cpp (798): Read unicode symbol 160 '~' ' '0 1 ~' '' 0 1 0
> 0 1
> > > >> ...
> > > >> Encoding.cpp (798): Read unicode symbol 120831 '' ' '0 0 \mathtt{9}'
> > > >> '' 0 1 0 0 1
> > > >> Encoding.cpp (864): Reading encoding utf8
> > > >> ...
> > > >> Language.cpp (210): Reading language welsh
> > > >> support/filetools.cpp (1002): Running: python -tt
> > > >> "/Applications/LyX.app/Contents/Resources/scripts/prefs2prefs.py"
> -l
> > > >> "/Users/jk/Library/Application Support/LyX-2.3/bind/user.bind"
> > > >> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/convert_bind.
> yA2103"
> > > >> Buffer.cpp (477): Buffer::Buffer()
> > > >> BufferList.cpp (122): Assigning to buffer 0
> > > >> Buffer.cpp (1324): Running 'python -tt
> > > >> "/Applications/LyX.app/Contents/Resources/lyx2lyx/lyx2lyx" -t 541
> -o
> > > >> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/lyx_tmpdir.
> YQwVSnRg2103/Buffer_convertLyXFormatWT2103.lyx"
> > > >> "/Users/jk/Box Sync/jk/jkdonorblurb.lyx"'
> > > >> support/filetools.cpp (1002): Running: python -tt
> > > >> "/Applications/LyX.app/Contents/Resources/lyx2lyx/lyx2lyx" -t 541
> -o
> > > >> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/lyx_tmpdir.
> YQwVSnRg2103/Buffer_convertLyXFormatWT2103.lyx"
> > > >> "/Users/jk/Box Sync/jk/jkdonorblurb.lyx"
> > > >> Traceback (most recent call last):
> > > >>  File "/Applications/LyX.app/Contents/Resources/lyx2lyx/lyx2lyx",
> > > >> line 22, in 
> > > >>import argparse
> > > >> ImportError: No module named argparse
> > > >> Error: Conversion script failed
> > > >
> > > > That's the error there. For some reason the called version of python
> > > > does not see that module. Note that the two versions of python are
> very
> > > > different: 2.7.5 and 3.6.1. I would guess that the argparse module
> may
> > > > not be installed for 2.7.5.
> > >
> > > On Mac OS X 10.11.6 the vanilla python is 2.7.10 - I cannot believe
> it’s
> > > 2.7.5 on 10.12.4 (Sierra?)
> > >
> > > $ /usr/bin/python
> > > Python 2.7.10 (default, Oct 23 2015, 19:19:21)
> > > [GCC 4.2.1 Compatible Apple LLVM 7.0.0 (clang-700.0.59.5)] on darwin
> > > Type "help", "copyright", "credits" or "license" for more information.
> > > >>> import argparse;
> > > >>> quit()
> > > $
> > >
> > > Stephan
> > >
> > > Apparently argparse was installed
> > >
> > > jkmac-3:MacOS jk$ python
> > > Python 2.7.5 |Anaconda 1.8.0 (x86_64)| (default, Oct 24 2013, 07:02:20)
> > > [GCC 4.0.1 (Apple Inc. build 5493)] on darwin
> > > Type "help", "copyright", "credits" or "license" for more information.
> > > >>> import argparse
> > > >>> import quack
> > > Traceback (most recent call last):
> > >   File "", line 1, in 
> > > ImportError: No module named quack
> > > >>> quit()
> > >
> > > Presumably lyx2lyx wasn't looking in the right place.
> >
> > What is this for a python installation? Does it work with
> /usr/bin/python?
> >
> > jkmac-3:MacOS jk$ /usr/bin/python
> > Python 2.7.10 (default, Feb  6 2017, 23:53:20)
> > [GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.34)] on darwin
> > Type "help", "copyright", "credits" or "license" for more information.
> > >>> import argparse
> > >>> quit()
> > jkmac-3:MacOS jk$ python
> > Python 2.7.5 |Anaconda 1.8.0 (x86_64)| (default, Oct 24 2013, 07:02:20)
> > [GCC 4.0.1 (Apple Inc. build 5493)] on darwin
> > Type "help", "copyright", "credits" or "license" for more information.
> > >>> import argparse
> > >>> quit()
> > jkmac-3:MacOS jk$
>
> Sorry, I was not explicit. Are you able to test the LyX reconfigure
> menu item with /usr/bin/python as your system python interpreter?
>

I'm not sure what this means, but in any case I don't think I can do it at
this point. I'm using two machines, one with 2.3alpha and the other with
2.2.2 And the alpha machine now has Python 

Re: 2.2.3 Tarballs

2017-05-09 Thread Stephan Witt
Am 08.05.2017 um 09:19 schrieb Stephan Witt :
> 
> Am 07.05.2017 um 19:07 schrieb Richard Heck :
>> 
>> The tarballs for LyX 2.2.3 are available at
>> 
>>   ftp://ftp.lyx.org/pub/lyx/devel/lyx-2.2/2.2.3/
>> 
>> Please let me know if you have any problems building. Please also
>> prepare binaries, if not! We'll aim to release end of the week.
> 
> It compiles on recent Mac OS X and on my ancient system. The i386 version 
> has a problem with the change to the newer hunspell library (change from
> 1.3.2 to 1.3.3) That’s why I couldn’t run the binary from the package.
> I have to see how to solve this. I’ll report back later.

I’m ready to build LyX for 64-bit-Cocoa on Mac 10.7 or newer and for
32-bit-Carbon on Mac 10.5 or newer.

Stephan

Re: 2.3.0alpha1-1

2017-05-09 Thread Stephan Witt
Am 09.05.2017 um 14:14 schrieb john kennan :
> 
> 
> 
> On Tue, May 9, 2017 at 1:11 AM, Stephan Witt  wrote:
> 
> > Am 09.05.2017 um 02:59 schrieb john kennan :
> >
> >
> >
> > On Mon, May 8, 2017 at 1:04 PM, Stephan Witt  wrote:
> > Am 08.05.2017 um 19:48 schrieb Richard Heck :
> > >
> > > On 05/08/2017 11:22 AM, john kennan wrote:
> > >> Scott:
> > >>
> > >> log file, as requested.
> > >>
> > >> John
> > >>
> > >>
> > >> jkmac:referee jk$ /Applications/LyX.app/Contents/MacOS/lyx -dbg info
> > >> "/Users/jk/Box Sync/jk/jkdonorblurb.lyx"
> > >> Setting debug level to info
> > >> Debugging `info' (General information)
> > >> support/filetools.cpp (1002): Running: python -tt -V 2>&1
> > >> support/filetools.cpp (1002): Running: python -tt
> > >> "/Applications/LyX.app/Contents/Resources/scripts/prefs2prefs.py" -p
> > >> "/Users/jk/Library/Application Support/LyX-2.3/preferences"
> > >> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/convert_lyxrc.Ul2103"
> > >> Encoding.cpp (798): Read unicode symbol 160 '~' ' '0 1 ~' '' 0 1 0 0 1
> > >> ...
> > >> Encoding.cpp (798): Read unicode symbol 120831 '' ' '0 0 \mathtt{9}'
> > >> '' 0 1 0 0 1
> > >> Encoding.cpp (864): Reading encoding utf8
> > >> ...
> > >> Language.cpp (210): Reading language welsh
> > >> support/filetools.cpp (1002): Running: python -tt
> > >> "/Applications/LyX.app/Contents/Resources/scripts/prefs2prefs.py" -l
> > >> "/Users/jk/Library/Application Support/LyX-2.3/bind/user.bind"
> > >> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/convert_bind.yA2103"
> > >> Buffer.cpp (477): Buffer::Buffer()
> > >> BufferList.cpp (122): Assigning to buffer 0
> > >> Buffer.cpp (1324): Running 'python -tt
> > >> "/Applications/LyX.app/Contents/Resources/lyx2lyx/lyx2lyx" -t 541 -o
> > >> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/lyx_tmpdir.YQwVSnRg2103/Buffer_convertLyXFormatWT2103.lyx"
> > >> "/Users/jk/Box Sync/jk/jkdonorblurb.lyx"'
> > >> support/filetools.cpp (1002): Running: python -tt
> > >> "/Applications/LyX.app/Contents/Resources/lyx2lyx/lyx2lyx" -t 541 -o
> > >> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/lyx_tmpdir.YQwVSnRg2103/Buffer_convertLyXFormatWT2103.lyx"
> > >> "/Users/jk/Box Sync/jk/jkdonorblurb.lyx"
> > >> Traceback (most recent call last):
> > >>  File "/Applications/LyX.app/Contents/Resources/lyx2lyx/lyx2lyx",
> > >> line 22, in 
> > >>import argparse
> > >> ImportError: No module named argparse
> > >> Error: Conversion script failed
> > >
> > > That's the error there. For some reason the called version of python
> > > does not see that module. Note that the two versions of python are very
> > > different: 2.7.5 and 3.6.1. I would guess that the argparse module may
> > > not be installed for 2.7.5.
> >
> > On Mac OS X 10.11.6 the vanilla python is 2.7.10 - I cannot believe it’s
> > 2.7.5 on 10.12.4 (Sierra?)
> >
> > $ /usr/bin/python
> > Python 2.7.10 (default, Oct 23 2015, 19:19:21)
> > [GCC 4.2.1 Compatible Apple LLVM 7.0.0 (clang-700.0.59.5)] on darwin
> > Type "help", "copyright", "credits" or "license" for more information.
> > >>> import argparse;
> > >>> quit()
> > $
> >
> > Stephan
> >
> > Apparently argparse was installed
> >
> > jkmac-3:MacOS jk$ python
> > Python 2.7.5 |Anaconda 1.8.0 (x86_64)| (default, Oct 24 2013, 07:02:20)
> > [GCC 4.0.1 (Apple Inc. build 5493)] on darwin
> > Type "help", "copyright", "credits" or "license" for more information.
> > >>> import argparse
> > >>> import quack
> > Traceback (most recent call last):
> >   File "", line 1, in 
> > ImportError: No module named quack
> > >>> quit()
> >
> > Presumably lyx2lyx wasn't looking in the right place.
> 
> What is this for a python installation? Does it work with /usr/bin/python?
> 
> jkmac-3:MacOS jk$ /usr/bin/python
> Python 2.7.10 (default, Feb  6 2017, 23:53:20) 
> [GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.34)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.
> >>> import argparse
> >>> quit()
> jkmac-3:MacOS jk$ python
> Python 2.7.5 |Anaconda 1.8.0 (x86_64)| (default, Oct 24 2013, 07:02:20) 
> [GCC 4.0.1 (Apple Inc. build 5493)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.
> >>> import argparse
> >>> quit()
> jkmac-3:MacOS jk$ 

Sorry, I was not explicit. Are you able to test the LyX reconfigure
menu item with /usr/bin/python as your system python interpreter?

Meanwhile I searched for the phenomena „Anaconda on Mac“ and there
are other reports of problems from users of Anaconda python with
their regular tasks. Perhaps you should temporarily disable it to
test LyX - I don’t know what to do in case you want to work with
Anaconda python and LyX in parallel.

Stephan

Re: 2.3.0alpha1-1

2017-05-09 Thread john kennan
On Tue, May 9, 2017 at 1:11 AM, Stephan Witt  wrote:

>
> > Am 09.05.2017 um 02:59 schrieb john kennan :
> >
> >
> >
> > On Mon, May 8, 2017 at 1:04 PM, Stephan Witt  wrote:
> > Am 08.05.2017 um 19:48 schrieb Richard Heck :
> > >
> > > On 05/08/2017 11:22 AM, john kennan wrote:
> > >> Scott:
> > >>
> > >> log file, as requested.
> > >>
> > >> John
> > >>
> > >>
> > >> jkmac:referee jk$ /Applications/LyX.app/Contents/MacOS/lyx -dbg info
> > >> "/Users/jk/Box Sync/jk/jkdonorblurb.lyx"
> > >> Setting debug level to info
> > >> Debugging `info' (General information)
> > >> support/filetools.cpp (1002): Running: python -tt -V 2>&1
> > >> support/filetools.cpp (1002): Running: python -tt
> > >> "/Applications/LyX.app/Contents/Resources/scripts/prefs2prefs.py" -p
> > >> "/Users/jk/Library/Application Support/LyX-2.3/preferences"
> > >> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/convert_lyxrc.
> Ul2103"
> > >> Encoding.cpp (798): Read unicode symbol 160 '~' ' '0 1 ~' '' 0 1 0 0 1
> > >> ...
> > >> Encoding.cpp (798): Read unicode symbol 120831 '' ' '0 0 \mathtt{9}'
> > >> '' 0 1 0 0 1
> > >> Encoding.cpp (864): Reading encoding utf8
> > >> ...
> > >> Language.cpp (210): Reading language welsh
> > >> support/filetools.cpp (1002): Running: python -tt
> > >> "/Applications/LyX.app/Contents/Resources/scripts/prefs2prefs.py" -l
> > >> "/Users/jk/Library/Application Support/LyX-2.3/bind/user.bind"
> > >> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/convert_bind.
> yA2103"
> > >> Buffer.cpp (477): Buffer::Buffer()
> > >> BufferList.cpp (122): Assigning to buffer 0
> > >> Buffer.cpp (1324): Running 'python -tt
> > >> "/Applications/LyX.app/Contents/Resources/lyx2lyx/lyx2lyx" -t 541 -o
> > >> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/lyx_tmpdir.
> YQwVSnRg2103/Buffer_convertLyXFormatWT2103.lyx"
> > >> "/Users/jk/Box Sync/jk/jkdonorblurb.lyx"'
> > >> support/filetools.cpp (1002): Running: python -tt
> > >> "/Applications/LyX.app/Contents/Resources/lyx2lyx/lyx2lyx" -t 541 -o
> > >> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/lyx_tmpdir.
> YQwVSnRg2103/Buffer_convertLyXFormatWT2103.lyx"
> > >> "/Users/jk/Box Sync/jk/jkdonorblurb.lyx"
> > >> Traceback (most recent call last):
> > >>  File "/Applications/LyX.app/Contents/Resources/lyx2lyx/lyx2lyx",
> > >> line 22, in 
> > >>import argparse
> > >> ImportError: No module named argparse
> > >> Error: Conversion script failed
> > >
> > > That's the error there. For some reason the called version of python
> > > does not see that module. Note that the two versions of python are very
> > > different: 2.7.5 and 3.6.1. I would guess that the argparse module may
> > > not be installed for 2.7.5.
> >
> > On Mac OS X 10.11.6 the vanilla python is 2.7.10 - I cannot believe it’s
> > 2.7.5 on 10.12.4 (Sierra?)
> >
> > $ /usr/bin/python
> > Python 2.7.10 (default, Oct 23 2015, 19:19:21)
> > [GCC 4.2.1 Compatible Apple LLVM 7.0.0 (clang-700.0.59.5)] on darwin
> > Type "help", "copyright", "credits" or "license" for more information.
> > >>> import argparse;
> > >>> quit()
> > $
> >
> > Stephan
> >
> > Apparently argparse was installed
> >
> > jkmac-3:MacOS jk$ python
> > Python 2.7.5 |Anaconda 1.8.0 (x86_64)| (default, Oct 24 2013, 07:02:20)
> > [GCC 4.0.1 (Apple Inc. build 5493)] on darwin
> > Type "help", "copyright", "credits" or "license" for more information.
> > >>> import argparse
> > >>> import quack
> > Traceback (most recent call last):
> >   File "", line 1, in 
> > ImportError: No module named quack
> > >>> quit()
> >
> > Presumably lyx2lyx wasn't looking in the right place.
>
> What is this for a python installation? Does it work with /usr/bin/python?
>

jkmac-3:MacOS jk$ /usr/bin/python
Python 2.7.10 (default, Feb  6 2017, 23:53:20)
[GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.34)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import argparse
>>> quit()
jkmac-3:MacOS jk$ python
Python 2.7.5 |Anaconda 1.8.0 (x86_64)| (default, Oct 24 2013, 07:02:20)
[GCC 4.0.1 (Apple Inc. build 5493)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import argparse
>>> quit()
jkmac-3:MacOS jk$


>
> Stephan


Re: default dir when save for first time is not cwd

2017-05-09 Thread Scott Kostyshak
On Tue, May 09, 2017 at 01:36:16PM +0200, Stephan Witt wrote:
> Am 09.05.2017 um 13:04 schrieb Scott Kostyshak :
> > 
> > On Mon, May 08, 2017 at 10:42:42PM +0200, Stephan Witt wrote:
> > 
> >> The culprit in my case on Mac was the missing entry for document_dir (aka 
> >> Working Directory).
> >> If I fill it with the name of my real document directory (e.g. 
> >> /Users/stephan/Documents) then
> >> it works for me too. The 2.2.3 LyX doesn’t need that entry in preferences 
> >> and uses the platform
> >> specific default value from Qt in this case.
> > 
> > Stephan, do you think the easiest thing to do is just revert 892593fb?
> > I'm fine with that.
> 
> This probably would solve the problem too. And I’m not that confident
> it is only Windows or Mac platform having this problem. If a Linux desktop
> manager software programmer decides it would be correct to start programs
> from menu or desktop icons at some arbitrary directory like / or /var/private
> or so we have the same problem on Linux.

Good point. I agree.

> Your goal was to start LyX from terminal with current directory as document 
> dir.

Yes.

> Wouldn’t it be better to provide a command line option to choose the initial
> document dir explicitly?

I don't know. Reverting 892593fb doesn't affect me since I have '.' in
my personal preferences file. I made that change because I thought the
default would be more reasonable for everyone, but I was wrong. And if
someone does like the behavior of '.', I think the GUI of the paths tab
makes it clear how to achieve that behavior.

Reverted at 638020ab.

Thanks for the discussion. Let me know if you think anything further
needs to be done.

Scott


signature.asc
Description: PGP signature


Re: default dir when save for first time is not cwd

2017-05-09 Thread Stephan Witt
Am 09.05.2017 um 13:04 schrieb Scott Kostyshak :
> 
> On Mon, May 08, 2017 at 10:42:42PM +0200, Stephan Witt wrote:
> 
>> The culprit in my case on Mac was the missing entry for document_dir (aka 
>> Working Directory).
>> If I fill it with the name of my real document directory (e.g. 
>> /Users/stephan/Documents) then
>> it works for me too. The 2.2.3 LyX doesn’t need that entry in preferences 
>> and uses the platform
>> specific default value from Qt in this case.
> 
> Stephan, do you think the easiest thing to do is just revert 892593fb?
> I'm fine with that.

This probably would solve the problem too. And I’m not that confident
it is only Windows or Mac platform having this problem. If a Linux desktop
manager software programmer decides it would be correct to start programs
from menu or desktop icons at some arbitrary directory like / or /var/private
or so we have the same problem on Linux.

Your goal was to start LyX from terminal with current directory as document dir.
Wouldn’t it be better to provide a command line option to choose the initial
document dir explicitly?

Stephan

Re: Fwd: 2.3.0alpha1-1

2017-05-09 Thread Scott Kostyshak
On Tue, May 09, 2017 at 10:10:12AM +0100, José Abílio Matos wrote:

> In order to test the python3 support I created the fedora packages that force 
> the usage of python 3.
> Attached follows the patch that I have used to force the python 3. This is a 
> brute force approach but the main idea is that there are two places where we 
> need to make the changes to support a custom python version:

Thanks for looking into this, José. I will test also with your patch
when I have time. If you update your patch, please post the newer
version.

Scott


signature.asc
Description: PGP signature


Re: Migration of preferences

2017-05-09 Thread Jürgen Spitzmüller
2017-05-09 13:03 GMT+02:00 Scott Kostyshak:

> Nice work! I have no idea how to improve our read of different
> encodings. I'm guessing this issue is not so rare for users who manually
> edit the preferences files with various text editors that for some
> reason do not preserve encodings. If you happen to have your old
> preferences file, or can recreate the situation, you might want to post
> a bug report with a small preferences file.
>

We (José and Enrico) fixed a similar problem with encodings in layouts in
lyx2lyx, so I suppose prefs2prefs can be fixed as well.

Jürgen


>
> Scott
>


Re: focus-handling

2017-05-09 Thread Scott Kostyshak
On Mon, May 08, 2017 at 08:26:58PM +0200, mn wrote:
> On 08.05.17 01:44, Scott Kostyshak wrote:
> > On Mon, Apr 24, 2017 at 05:19:45PM -0700, Pavel Sanda wrote:
> >> mn wrote:
> >>> The blinking cursor should always indicate where keyboard action would
> >>> have consequences.
> >>> This seems to be a general issue since similar behavior also impedes
> >>> working with other panels, like find and spell checking.
> >>>
> >>> Is this now working as designed, i.e. intended?
> >>
> >> Surely not intended. P
> > 
> > Mike, did you file a bug report for this so it doesn't get lost?
> > 
> 
> I filed two related reports about UI issues but cannot pinpoint which is
> which right now. Lyx.org has not been reachable for me today.
> They should be:
> https://www.lyx.org/trac/ticket/10639
> https://www.lyx.org/trac/ticket/10640

Thanks, I posted something to try for #10640.

Scott


signature.asc
Description: PGP signature


Re: default dir when save for first time is not cwd

2017-05-09 Thread Scott Kostyshak
On Mon, May 08, 2017 at 10:42:42PM +0200, Stephan Witt wrote:

> The culprit in my case on Mac was the missing entry for document_dir (aka 
> Working Directory).
> If I fill it with the name of my real document directory (e.g. 
> /Users/stephan/Documents) then
> it works for me too. The 2.2.3 LyX doesn’t need that entry in preferences and 
> uses the platform
> specific default value from Qt in this case.

Stephan, do you think the easiest thing to do is just revert 892593fb?
I'm fine with that.

Scott


signature.asc
Description: PGP signature


Re: [LyX/master] GuiDocument: fix bug #10653

2017-05-09 Thread Scott Kostyshak
On Tue, May 09, 2017 at 01:00:46AM +0200, Uwe Stöhr wrote:

> --- a/src/frontends/qt4/GuiDocument.h
> +++ b/src/frontends/qt4/GuiDocument.h
> @@ -110,7 +110,7 @@ private Q_SLOTS:
>   void setSkip(int);
>   void enableSkip(bool);
>   void allowMathIndent();
> - void setMathIndent(int);
> + void EnableMathIndent(int);
>   void browseLayout();
>   void browseMaster();
>   void classChanged();

I'm not sure, but just taking a look at the surroundings suggests that
capitalizing the first letter breaks with our current style.

Scott


signature.asc
Description: PGP signature


Re: [LyX/master] gnuplot.lyx: add missing makefile entries

2017-05-09 Thread Scott Kostyshak
On Mon, May 08, 2017 at 11:29:30PM +0200, Uwe Stöhr wrote:
> commit 2f44afcb75153d104586b78573978126d9742ea7
> Author: Uwe Stöhr 
> Date:   Mon May 8 23:29:25 2017 +0200
> 
> gnuplot.lyx: add missing makefile entries
> 
> - also adapt style to match existing examples (e.g. the filename)
> ---
>  lib/Makefile.am  |2 +
>  lib/examples/example_gnuplot.gp  |4 -
>  lib/examples/example_gnuplot.lyx |  213 
> --
>  lib/examples/gnuplot-example.gp  |4 +
>  lib/examples/gnuplot.lyx |  208 +
>  5 files changed, 214 insertions(+), 217 deletions(-)
> 
> diff --git a/lib/Makefile.am b/lib/Makefile.am
> index e4354ff..b655357 100644
> --- a/lib/Makefile.am
> +++ b/lib/Makefile.am
> @@ -327,6 +327,8 @@ dist_examples_DATA = \
>   examples/example_lyxified.lyx \
>   examples/example_raw.lyx \
>   examples/FeynmanDiagrams.lyx \
> + examples/gnuplot.lyx \
> + examples/gnuplot-example.gp \
>   examples/H-P-statements.lyx \
>   examples/iecc05.fen \
>   examples/iecc07.fen \

+1

I made a similar change at faea3bdb.

Scott


signature.asc
Description: PGP signature


Re: default dir when save for first time is not cwd

2017-05-09 Thread Scott Kostyshak
On Tue, May 09, 2017 at 10:36:02AM +1200, Andrew Parsloe wrote:
> 
> 
> On 9/05/2017 8:42 a.m., Stephan Witt wrote:
> > Am 08.05.2017 um 22:26 schrieb Andrew Parsloe :
> > > 
> > > On 9/05/2017 2:41 a.m., Scott Kostyshak wrote:
> > > > On Mon, May 08, 2017 at 12:14:02PM +1200, Andrew Parsloe wrote:
> > > > 
> > > > > On windows 7, alpha1-1, the Open dialogue displays the CWD.
> > > > 
> > > > For alpha1-1, if you open LyX from the GUI (the Start menu?), and you
> > > > create a new document, type something, and go to save or save as, where
> > > > is the location in the dialog? i.e. what is the CWD in this case?
> > > > 
> > > > Is that experience any different from 2.2.x?
> > > > 
> > > > Thanks for testing,
> > > > 
> > > > Scott
> > > > 
> > > As far as I can tell from brief testing with LyX 2.1.3, 2.2.2, and 
> > > alpha1-1, nothing has changed. Saving a new document in a just-opened LyX 
> > > offers the directory set in Tools > Preferences > Paths > Working 
> > > Directory, say D:/Documents.
> > 
> > The culprit in my case on Mac was the missing entry for document_dir (aka 
> > Working Directory).
> > If I fill it with the name of my real document directory (e.g. 
> > /Users/stephan/Documents) then
> > it works for me too. The 2.2.3 LyX doesn’t need that entry in preferences 
> > and uses the platform
> > specific default value from Qt in this case.
> > 
> > Stephan
> > 
> If the Working Directory slot is not filled on Windows (or if it contains
> just a period)  File > Open opens to LyX 2.3/bin which seems dangerous to
> me.

I agree it should not open to 2.3/bin.

> I imagine it should be the My Documents folder.

Is this what it was on 2.2.x?

Scott


signature.asc
Description: PGP signature


Re: Migration of preferences

2017-05-09 Thread Scott Kostyshak
On Tue, May 09, 2017 at 08:22:08PM +1200, Andrew Parsloe wrote:

> The problem was with a customized copy of cua.bind in my LyX2.3/bind folder.
> prefs2prefs.py was stumbling on it. After much blundering about I found the
> problem was an encoding one. The customized cua.bind dates from many years
> ago and (according to my text editor) the encoding is ANSI rather utf8.
> prefs2prefs.py choked at
> 
> line 52 in read: lines = source.read().splitlines() or ['']
> 
> Python27/lib/codecs.py, line 314, in decode
>   (result, consumed) = self._buffer_decode(data, self.errors, final)
> LookupError: unknown error handler name 'surrogateescape'
> 
> I have updated the customized cua.bind, now encoded in utf8, and the problem
> has vanished.

Nice work! I have no idea how to improve our read of different
encodings. I'm guessing this issue is not so rare for users who manually
edit the preferences files with various text editors that for some
reason do not preserve encodings. If you happen to have your old
preferences file, or can recreate the situation, you might want to post
a bug report with a small preferences file.

Scott


signature.asc
Description: PGP signature


Re: [LyX/master] python3: fix the preview framework to work with both python 2 and 3

2017-05-09 Thread José Abílio Matos
On Tuesday, 9 May 2017 11.21.45 WEST José Matos wrote:
> commit 11f2a59ce90b406537ff3379276d5e0bb1bf6c37
> Author: José Matos 
> Date:   Tue May 9 11:20:34 2017 +0100
> 
> python3: fix the preview framework to work with both python 2 and 3
> ---
>  lib/scripts/legacy_lyxpreview2ppm.py |   16 
>  lib/scripts/lyxpreview2bitmap.py |   28 +++-
>  lib/scripts/lyxpreview_tools.py  |   12 ++--
>  3 files changed, 29 insertions(+), 27 deletions(-)
> 
> diff --git a/lib/scripts/legacy_lyxpreview2ppm.py
> b/lib/scripts/legacy_lyxpreview2ppm.py index 3049b44..6a91402 100644
> --- a/lib/scripts/legacy_lyxpreview2ppm.py
> +++ b/lib/scripts/legacy_lyxpreview2ppm.py
> @@ -79,7 +79,7 @@
>  # If possible, the script will use pdftocairo instead of gs,
>  # as it's much faster and gives better results.
> 
> -import glob, os, pipes, re, string, sys
> +import glob, os, pipes, re, sys
> 
>  from lyxpreview_tools import check_latex_log, copyfileobj, error,
> filter_pages,\ find_exe, find_exe_or_terminate, join_metrics_and_rename,
> latex_commands, \ @@ -118,8 +118,8 @@ def
> legacy_extract_metrics_info(log_file):
>  error("Unexpected data in %s\n%s" % (log_file, line))
> 
>  if snippet:
> -ascent  = string.atof(match.group(2))
> -descent = string.atof(match.group(3))
> +ascent  = float(match.group(2))
> +descent = float(match.group(3))

This is an example of what we get when running lyx with python3. Now the latex 
preview works also for python 3.

FWIW most of the changes were from functions that were deprecated since python 
2.0. The final version of Python 2.0 was released on October 16, 2000. So it 
was not as if we had not enough time to change this.

The functions are
string.atoi -> int
string.atof -> float
string.join -> " ".join

In fairness it was Bo Peng who converted this code, from perl, and he warned 
in the commit thread that he did not know python so well but he wanted to 
ensure that all our scripts run with python.

Regards,
-- 
José Abílio


Re: Fwd: 2.3.0alpha1-1

2017-05-09 Thread José Abílio Matos
On Tuesday, 9 May 2017 08.11.22 WEST Pavel Sanda wrote:
> Jose, as mentioned in other thread, could you summarize the current python
> situation in master and put it into RELEASE_NOTES?
> As packager I would like to see: what versions of python are currently
> supported and which version is preffered for running lyx.
> 
> Pavel

The reason why I did not answer immediately in the other thread, it is in my 
todo list is because honestly I do not know the full extent of our python 3 
support.

What I know is the following:
- python 2 works;
- python 3 is the unknown, every time that we find a place where it 
does 
not work we have been converting it to a version that works for both versions.

As I said in the other message in some places we still call python, the only 
place where /usr/bin/python is python 3 is on arch linux.

This means in particular that if we pass, in the autotools building process, 
the environment variable PYTHON=/usr/bin/python3 that will be ignored.

That means that we always use the system version regardless of the fact that 
$PYTHON is defined or not.

In order to test the python3 support I created the fedora packages that force 
the usage of python 3.
Attached follows the patch that I have used to force the python 3. This is a 
brute force approach but the main idea is that there are two places where we 
need to make the changes to support a custom python version:

1) src/support/os.cpp

2) lib/configure.py

The easiest is 2) since we are running we can make the call to python use the 
same version used to run the script itself.

It is enough to use sys.executable in all the places where we use python. 
sys.executable gives the full path to the python executable used to run the 
script. Another prettier option world to only use the executable name and 
discard the directory since this should be in path.

Another option that we discussed some time ago was to create another variable 
in the preferences called $$python that would be converted into the python 
version used through lyx.

For 1) we need to decide how do we choose if we find several versions of 
python because at the moment we go with the system python. We just test for 
the existence of a python executable on PATH, if there is not any we search 
for python with any suffix and the last tested wins.

BTW I understand that the second part of the code is a last resort. In any 
case the test is not correct because if a python binary is found but then we 
find some program called python_monty (totally unrelated to a python 
interpreter) that would reset the command name. A better strategy would be to 
return after the first successful python found.

So before mention anything regarding the python 3 support we need to test it 
in real day usage. FWIW I am confident that we should be able to run 2.3 with 
python 3 exclusively and that is what I am running to find the potential 
problems.

Any comment?

Regards,
-- 
José Abílio

lyx-2.3.0-force-python3.patch.gz
Description: application/gzip


Re: Migration of preferences

2017-05-09 Thread Andrew Parsloe

On 9/05/2017 2:42 a.m., Scott Kostyshak wrote:

On Mon, May 08, 2017 at 06:39:38PM +1200, Andrew Parsloe wrote:

alpha1-1 installed on windows 7. I can't remember if preferences are
supposed to migrate on a major release. They didn't. I renamed my LyX2.2
folder LyX2.3 and then had to manually increment the format numbers of the
files in bind and ui.


Thanks for testing, Andrew. I forget whether we migrate preferences on
Windows.

For any Windows-related emails, you might want to CC Uwe since he
doesn't have time to read every message on the mailing list but he's
interested in the Windows-related ones. (I add him to CC this time).

If you do not manually increment the format numbers of the bind and ui
files, what error do you get?

Scott



The problem was with a customized copy of cua.bind in my LyX2.3/bind 
folder. prefs2prefs.py was stumbling on it. After much blundering about 
I found the problem was an encoding one. The customized cua.bind dates 
from many years ago and (according to my text editor) the encoding is 
ANSI rather utf8. prefs2prefs.py choked at


line 52 in read: lines = source.read().splitlines() or ['']

Python27/lib/codecs.py, line 314, in decode
(result, consumed) = self._buffer_decode(data, self.errors, final)
LookupError: unknown error handler name 'surrogateescape'

I have updated the customized cua.bind, now encoded in utf8, and the 
problem has vanished.


Andrew

---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus



Re: Fwd: 2.3.0alpha1-1

2017-05-09 Thread Pavel Sanda
José Abílio Matos wrote:
> On Monday, 8 May 2017 18.48.30 WEST Richard Heck wrote:
> > That's the error there. For some reason the called version of python
> > does not see that module. Note that the two versions of python are very
> > different: 2.7.5 and 3.6.1. I would guess that the argparse module may
> > not be installed for 2.7.5.
> > 
> > Richard
> 
> argparse is in the standard library for both versions. So if the python 
> version is well/correctly installed it should be there.
> 
> After all argparse was introduced in python 2.7. :-)
> 
> Now I am also a bit confused because that means that we been requiring python 
> 2.7 for some time and no one complained. :-D

Jose, as mentioned in other thread, could you summarize the current python
situation in master and put it into RELEASE_NOTES?
As packager I would like to see: what versions of python are currently
supported and which version is preffered for running lyx.

Pavel


Re: [LyX/2.2.x] Prepare for 2.2.3.

2017-05-09 Thread Pavel Sanda
Richard Heck wrote:
> On 05/08/2017 02:59 PM, José Abílio Matos wrote:
> > On Monday, 8 May 2017 14.03.35 WEST Richard Heck wrote:
> >> Do you think I can fix these typos without changing the package name?
> >>
> >> Richard
> > Since these are simple typos with no consequence I think that you can 
> > either way.
> >
> > Wearing (pun intended) my Fedora hat I am used to upstream that sometimes 
> > re-spun their tar balls.
> >
> > So whatever you do you have a +1 from me. And yes, I know that I am not 
> > helping here. :-)
> 
> I'm going to go ahead and rebuild and relabel. As long as it's clear
> from what the binaries are built, it won't really make a difference.

Personally I wouldn't touch the tarballs and fix those typos just in email
& web annoucements; it's not big deal.

Pavel


Re: 2.3.0alpha1-1

2017-05-09 Thread Stephan Witt

> Am 09.05.2017 um 02:59 schrieb john kennan :
> 
> 
> 
> On Mon, May 8, 2017 at 1:04 PM, Stephan Witt  wrote:
> Am 08.05.2017 um 19:48 schrieb Richard Heck :
> >
> > On 05/08/2017 11:22 AM, john kennan wrote:
> >> Scott:
> >>
> >> log file, as requested.
> >>
> >> John
> >>
> >>
> >> jkmac:referee jk$ /Applications/LyX.app/Contents/MacOS/lyx -dbg info
> >> "/Users/jk/Box Sync/jk/jkdonorblurb.lyx"
> >> Setting debug level to info
> >> Debugging `info' (General information)
> >> support/filetools.cpp (1002): Running: python -tt -V 2>&1
> >> support/filetools.cpp (1002): Running: python -tt
> >> "/Applications/LyX.app/Contents/Resources/scripts/prefs2prefs.py" -p
> >> "/Users/jk/Library/Application Support/LyX-2.3/preferences"
> >> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/convert_lyxrc.Ul2103"
> >> Encoding.cpp (798): Read unicode symbol 160 '~' ' '0 1 ~' '' 0 1 0 0 1
> >> ...
> >> Encoding.cpp (798): Read unicode symbol 120831 '' ' '0 0 \mathtt{9}'
> >> '' 0 1 0 0 1
> >> Encoding.cpp (864): Reading encoding utf8
> >> ...
> >> Language.cpp (210): Reading language welsh
> >> support/filetools.cpp (1002): Running: python -tt
> >> "/Applications/LyX.app/Contents/Resources/scripts/prefs2prefs.py" -l
> >> "/Users/jk/Library/Application Support/LyX-2.3/bind/user.bind"
> >> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/convert_bind.yA2103"
> >> Buffer.cpp (477): Buffer::Buffer()
> >> BufferList.cpp (122): Assigning to buffer 0
> >> Buffer.cpp (1324): Running 'python -tt
> >> "/Applications/LyX.app/Contents/Resources/lyx2lyx/lyx2lyx" -t 541 -o
> >> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/lyx_tmpdir.YQwVSnRg2103/Buffer_convertLyXFormatWT2103.lyx"
> >> "/Users/jk/Box Sync/jk/jkdonorblurb.lyx"'
> >> support/filetools.cpp (1002): Running: python -tt
> >> "/Applications/LyX.app/Contents/Resources/lyx2lyx/lyx2lyx" -t 541 -o
> >> "/var/folders/s6/r89g40d97y98b56w71p_49ncgn/T/lyx_tmpdir.YQwVSnRg2103/Buffer_convertLyXFormatWT2103.lyx"
> >> "/Users/jk/Box Sync/jk/jkdonorblurb.lyx"
> >> Traceback (most recent call last):
> >>  File "/Applications/LyX.app/Contents/Resources/lyx2lyx/lyx2lyx",
> >> line 22, in 
> >>import argparse
> >> ImportError: No module named argparse
> >> Error: Conversion script failed
> >
> > That's the error there. For some reason the called version of python
> > does not see that module. Note that the two versions of python are very
> > different: 2.7.5 and 3.6.1. I would guess that the argparse module may
> > not be installed for 2.7.5.
> 
> On Mac OS X 10.11.6 the vanilla python is 2.7.10 - I cannot believe it’s
> 2.7.5 on 10.12.4 (Sierra?)
> 
> $ /usr/bin/python
> Python 2.7.10 (default, Oct 23 2015, 19:19:21)
> [GCC 4.2.1 Compatible Apple LLVM 7.0.0 (clang-700.0.59.5)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.
> >>> import argparse;
> >>> quit()
> $
> 
> Stephan
> 
> Apparently argparse was installed
> 
> jkmac-3:MacOS jk$ python
> Python 2.7.5 |Anaconda 1.8.0 (x86_64)| (default, Oct 24 2013, 07:02:20) 
> [GCC 4.0.1 (Apple Inc. build 5493)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.
> >>> import argparse
> >>> import quack
> Traceback (most recent call last):
>   File "", line 1, in 
> ImportError: No module named quack
> >>> quit()
>  
> Presumably lyx2lyx wasn't looking in the right place.

What is this for a python installation? Does it work with /usr/bin/python?

Stephan