On Fri, Jun 18, 2010 at 10:59:05AM -0400, Joost Verburg wrote:

> On 6/17/2010 9:00 PM, Enrico Forestieri wrote:
> >So, this patch does not help in this respect, as the launcher is needed
> >for hiding the initial console that would otherwise open.
> >I think that the solution could be hiding the console from inside
> >LyX itself. Once there was code for doing that, but I don't remember
> >anymore why it was nuked.
> 
> It does help. There is no initial console when LyX is build as a GUI app.

This is the bit I was missing. I think I remember that there were
problems building LyX as a GUI application. So, this is not the case
anymore, seemingly.

> The code to hide the console from LyX itself also had issues and
> caused console windows to pop up during initialization.

Using the code I posted, I simply "almost" see a flashing window that
is immediately closed.

> >Now, instead, you have to edit the
> >preferences and add "cmd /c" here and there, hoping that you get right
> >the way you have to quote the parameters (and in some cases it is very
> >difficult to get it right, believe me).
> 
> I investigated the code a little more and it appears that QProcess
> is used for the actual image/LaTeX conversions.
> ForkedCalls/runCommand are only used for internal Python scripts for
> display images / lyx2lyx etc. (please correct me if I'm wrong). So
> there will be absolutely no difference for the conveters when this
> patch is applied.
> 
> If you want support for batch files / ShellExecute in Systemcall /
> QProcess, the solution would be to send all the commands through
> cmd.exe. I found this piece of code that was used when USE_QPROCESS
> is not defined:
> 
> case os::CMD_EXE:
>       command = "start /min " + command;
>       break;
> 
> This should be added to the USE_QPROCESS code as well I think. It's
> however a totally separate issue unrelated to this patch.

I only use the native version for investigating bugs and some such, so
it is your call deciding what to do, as I already said. I simply could
not resist seeing that nobody in the Windows world seems to care for
the possibility of using scripts.

-- 
Enrico

Reply via email to