jean-luc malet wrote:
thanks for the reply,
for some reason I would like to continue using the cygwin one...
this .bat was working some time ago, until I update cygwin....

1) when I launch cygwin's gvim from a dos cmd shell it run as expected
2) when I launch "c:\Cygwin\bin\run gvim" in the same dos cmd shell it
spawn a process gvim (ps -a show it) attached to con but nothing is
displayed on screen

-> this isn't a pb of DISPLAY else 1) wouldn't have worked and
cygwin's gvim wouldn't have displayed
----
        That may not, exactly, be the case.

        I was under the impression that starting something using the
'run' command is starting outside of your normal "Cygwin" session (and not
attached to a Shell window).  Depending on how you set your DISPLAY variable,
this could easily mean that the 'gvim' you start via "run" doesn't have
DISPLAY set properly.

I.e. if you set DISPLAY in your cygwin environment via the startup commands in BASH, OR if you start "X", which spawns an Xterm, that
already has DISPLAY, "preset" for you, (by "X", before it spawns Xterm), then
by using "run", you are starting 'gvim' outside of the "environment" where
you normally have DISPLAY set to a valid value.

        The only way DISPLAY would be set correctly for gvim when run
using 'run', is if you be sure that it's set by the 'run' command, OR if you have it set in your Windows System or User Environment variables
when you log on (settable in Computer Properties(shortcut=WIN-BREAK on 
keyboard),
then Advanced->Environment Variables.  There you can set display for your
userid, or system wide under the User variables.

        So do you know that DISPLAY is set correctly for gvim when invoked
by "run"?
        A test you could do is « run bash.exe -c "printenv>/tmp/my_envvars.txt" 
»
That will dump out all the env vars you think you are setting to a file that you
can look at after running it -- then you can make sure DISPLAY is set the way
you want it.

        BTW, regarding Vim versions:
        I use the X-version of Gvim when i'm logged into my linux machines, but 
I
use the Win version locally on my desktop (or the 'cygwin-vim' version when I'm
working in a command window and just want to do quick edits).  So I jump between
all three version somewhat interchangeably.  The Win version has a nicety that
you can set the horizontal scaling of a font separately from the vertical 
scaling,
and use 'half' sizes like "Lucida_Console:h10.5" -- which is different than
Lucida_Console:10, or 11.  But the X-version of Gvim has better Foreign 
character
display capabilities which can confused the Windows version.  So depends on 
what I'm
editing I suppose, as well.

        Hope the DISPLAY stuff helps.

-linda

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://x.cygwin.com/docs/
FAQ:                   http://x.cygwin.com/docs/faq/

Reply via email to