Re: doc nitpicking
On Oct 12, 9:31 pm, Bram Moolenaar [EMAIL PROTECTED] wrote: The docs are correct, :silent !true doesn't mess up the display for me. Check your shell init scripts for something that produces output. ... Apparently your termcap settings are causing this. Try this: :set t_ti= t_ks= But then something else might break... It might have something to do with the colorscheme you are using, esp. if you are using a non-default background color. I am curious, because it was always like this for me : 'silent! cmd' clears the screen (debian + xterm) and forces a redraw. I tried all you mentioned ( default colors, xterm with white bg, no output from loginscripts checked, setting the t_ opts ) ,but it does not change it. -ap --~--~-~--~~~---~--~~ You received this message from the vim_dev maillist. For more information, visit http://www.vim.org/maillist.php -~--~~~~--~~--~--~---
Re: doc nitpicking
The screen is not redrawn then, thus you have to use CTRL-L or :redraw! if the command did display something. I do not think this paragraph can be interpreted ambiguously. The first part - The screen is not redrawn then - I see it as information not operational, it does not contradict the second part. The second part is operational. It instructs the user when to use Ctrl-L and when not to use Ctrl-L: You have to use Ctrl-L(or :redraw!) *IF* the command did display something. Do you interpret the above phrase differently than me ? The problem with this instruction, it is incorrect. Yakov --~--~-~--~~~---~--~~ You received this message from the vim_dev maillist. For more information, visit http://www.vim.org/maillist.php -~--~~~~--~~--~--~---
Re: doc nitpicking
vim -u NONE :help helpget some text on screen, and statuslines :silent :true The screen is garbled. Not for me. I think the point made earlier was that the docs actually, in the most strict logical sense, don't say anything about what you need to do if a command doesn't output anything. I.e. they say you need Ctrl-L if the command does output something, but are silent (no pun intended) on whether or not you need a Ctrl-L if the command doesn't output anything. However, in English 'if' often really means 'if and only if', so the logic nitpicking isn't really valid--a phrase such as 'particularly if' or 'and even sometimes if it doesn't' could perhaps make the documentation clearer--if the behaviour you mention actually is reproducible elsewhere and not just a bug in a particular version, system or GUI! Which version/system/GUI are you using? Ben. Send instant messages to your online friends http://au.messenger.yahoo.com --~--~-~--~~~---~--~~ You received this message from the vim_dev maillist. For more information, visit http://www.vim.org/maillist.php -~--~~~~--~~--~--~---
Re: doc nitpicking
On 10/11/07, Yakov Lerner [EMAIL PROTECTED] wrote: On 10/11/07, ap [EMAIL PROTECTED] wrote: On Oct 10, 10:22 pm, Yakov Lerner [EMAIL PROTECTED] wrote: :help :! says: :silent !{cmd} The screen is not redrawn then, thus you have to use CTRL-L or :redraw! if the command did display something. The last part (if the command did display something) is not true. In console vim, screen is always grabled after ':silent !CMD even if CMD did not print anything. (try ':silent !true' after ':help help'). The correct wording would be: :silent !{cmd} The screen is not redrawn then, thus you have to use CTRL-L or :redraw! even if the command did not display anything. Yakov logic nitpicking: I forgot to include the testcase that demonstrates the discrepancy between the doc and the reality. Here it is: vim -u NONE :help helpget some text on screen, and statuslines :silent :true The screen is garbled. Now you need Ctrl-L. Oops. This sould have veen :silent !true The screen is garbled. Now you need Ctrl-L. console vim, Linux, v 7.1.2. This is noting new. I had always have this behavour since 6.3 times. In GUI vim, the sceen seems to be not garbled in such scenario. --~--~-~--~~~---~--~~ You received this message from the vim_dev maillist. For more information, visit http://www.vim.org/maillist.php -~--~~~~--~~--~--~---
Re: doc nitpicking
Yakov Lerner wrote: :help :! says: :silent !{cmd} The screen is not redrawn then, thus you have to use CTRL-L or :redraw! if the command did display something. The last part (if the command did display something) is not true. In console vim, screen is always grabled after ':silent !CMD even if CMD did not print anything. (try ':silent !true' after ':help help'). The correct wording would be: :silent !{cmd} The screen is not redrawn then, thus you have to use CTRL-L or :redraw! even if the command did not display anything. The docs are correct, :silent !true doesn't mess up the display for me. Check your shell init scripts for something that produces output. -- hundred-and-one symptoms of being an internet addict: 14. You start introducing yourself as Jim at I-I-Net dot net dot au /// Bram Moolenaar -- [EMAIL PROTECTED] -- http://www.Moolenaar.net \\\ ///sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ \\\download, build and distribute -- http://www.A-A-P.org/// \\\help me help AIDS victims -- http://ICCF-Holland.org/// --~--~-~--~~~---~--~~ You received this message from the vim_dev maillist. For more information, visit http://www.vim.org/maillist.php -~--~~~~--~~--~--~---
Re: doc nitpicking
On 10/11/07, Bram Moolenaar [EMAIL PROTECTED] wrote: Yakov Lerner wrote: :help :! says: :silent !{cmd} The screen is not redrawn then, thus you have to use CTRL-L or :redraw! if the command did display something. The last part (if the command did display something) is not true. In console vim, screen is always grabled after ':silent !CMD even if CMD did not print anything. (try ':silent !true' after ':help help'). The correct wording would be: :silent !{cmd} The screen is not redrawn then, thus you have to use CTRL-L or :redraw! even if the command did not display anything. The docs are correct, :silent !true doesn't mess up the display for me. Check your shell init scripts for something that produces output. To make sure that shell init script are not even invoked, I set :set shell=/bin/true Still, screen is cleared after :silent !/bin/true. In gdb, I caught the place and the string that clears the screen. The string is \033[?1049h\033[?1h\033= (length=15). It is printed after fork+execve(/bin/true), at this place: mch_write ( s=0x820b040 \033[?1049h\033[?1h\033=..., len=15) at os_unix.c:307 307 write(1, (char *)s, len); (gdb) n [Yakov] the vim screen is cleared at after the write() above 308 if (p_wd) /* Unix is too fast, slow down a bit more */ (gdb) where #0 mch_write ( s=0x820b040 \033[?1049h\033[?1h\033=..., len=15) at os_unix.c:308 #1 0x081a2b74 in ui_write ( s=0x820b040 \033[?1049h\033[?1h\033=..., len=15) at ui.c:51 #2 0x0819ed96 in out_flush () at term.c:2545 #3 0x0819fa6a in starttermcap () at term.c:3233 #4 0x08090393 in do_shell (cmd=0x82155d8 /bin/true, flags=0) at ex_cmds.c:1471 #5 0x0808fac8 in do_bang (addr_count=0, eap=0xbf96b110, forceit=0, do_in=1, do_out=1) at ex_cmds.c:1021 #6 0x080a99de in ex_bang (eap=0xbf96b110) at ex_docmd.c:8305 #7 0x080a0e58 in do_one_cmd (cmdlinep=0xbf96b278, sourcing=0, cstack=0xbf96b2d4, fgetline=0x80b4454 getexline, cookie=0x0) at ex_docmd.c:2622 #8 0x0809e718 in do_cmdline (cmdline=0x0, getline=0x80b4454 getexline, cookie=0x0, flags=0) at ex_docmd.c:1100 #9 0x0811b3f5 in nv_colon (cap=0xbf96b658) at normal.c:5168 #10 0x08114a32 in normal_cmd (oap=0xbf96b6f8, toplevel=1) at normal.c:1141 #11 0x080dc833 in main_loop (cmdwin=0, noexmode=0) at main.c:1180 #12 0x080dc383 in main (argc=3, argv=0xbf96b8f4) at main.c:939 After that, there is only one mch_write(), \033[1;25H (len=7), and screen remains empty, and vim waits for input. Yakov --~--~-~--~~~---~--~~ You received this message from the vim_dev maillist. For more information, visit http://www.vim.org/maillist.php -~--~~~~--~~--~--~---