John Doe wrote:
I am sorry for my html post. Anyway I can reproduce the resizing bug on
my system by doing:

set lines=999 columns=999

twice in a row.


Strange. Once I do that, gvim starts behaving strangely -- and very slowly. I don't see ex-commands I type (as if they were off-screen); what I see is my first window (with its statusline) and a couple of lines of the second window where the command-line ought to be. gvim starts using a lot of CPU time for several seconds (competing with Firefox which for some reason usually uses most).

Then with the following
        :set lines=99999 columns=99999
        :redir! >vim.log
        :set lines? columns?
        :redir END
followed in bash by
        cat vim.log
I see two blank lines, then
  lines=1000
  columns=10000
which are the compiled-in maxima. The only way to make gvim behave "normally" seems to be clicking the maximize button once (maximizing the application), after what
        :set lines? columns?
replies with "sensible" values of
  lines=37
  columns=166

":qa" and restart gvim: it starts up maximized with the "intro" screen. ":set lines? columns?" replies
  lines=37
        Last set from ~/.vimrc
  columns=166
        Last set from ~/.vimrc
which is normal since my vimrc includes
        if has("gui_running")
                set lines=99999 columns=99999
        endif
and
        if ! &verbose
                au VimEnter * set verbose=1
                au VimLeave * set verbose=0
        endif
Then doing
        :set lines=99999 columns=99999
exhibits the strange behaviour avain: gvim behaves sluggishly, shows neither the bottom status line nor the command line, the command-line area is replaced by text from one of the edit files, and the right end of the status line is squeezed at the left, displaying (with a split window and a custom status line)

[No Name] [utf-8,BOM] 0,0-1[0=0x00] All

instead of dilating it somewhat like

[No Name]                                        [utf-8,BOM] 0,0-1[0=0x00] All

which would be normal, or just [No Name] which would be normal if gvim "really believed" it had ten thousand columns on which to draw.

Now:
        :set lines=37 columns=166
Gvim redraws, albeit slowly (takes maybe half a second to display all the tildes for lines in the empty file) and the display looks normal again, with all status lines displayed where they belong, and "All" "Top" "Bot" or "nn%" flush at the right screen margin.

Trying ":set lines=99999 columns=99999" in kvim 6.2.14 (for comparison) exhibits different behaviour: after several seconds of intense processing, a blank window is displayed with a small scrollbar (three lines or so) at top left, all keys beep, and finally a SIGSEGV crash. (The same line in the vimrc is handled correctly, resulting in 37 lines and 142 columns, with the same font [9pt SUSE Sans Mono] but drawn slightly wider and somewhat prettier with Qt than with the GTK2 used by gvim and Thunderbird.)

I think it's a bug.

Workaround: ":set lines=25 columns=80 lines=99999 columns=99999" (not needed in the vimrc). The display behaves weirdly with resizes and scrolls for a second or so, but the end result is a correct maximized display even if it already was so beforehand.

Best regards,
Tony.
--
hundred-and-one symptoms of being an internet addict:
16. You step out of your room and realize that your parents have moved and you
    don't have a clue when it happened.

Reply via email to