Re: Patch 7.2.023
I wrote: Patch 7.2.023 Problem:'cursorcolumn' is in the wrong place in a closed fold when the display is shifted left. (Gary Johnson) Solution: Subtract w_skipcol or w_leftcol when needed. Files:src/screen.c This patch is not in CVS yet, because the SourceForge CVS appears to be down :-(. Hopefully it comes back to life before I leave. -- hundred-and-one symptoms of being an internet addict: 125. You begin to wonder how often it REALLY is necessary to get up and shower or bathe. /// 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: Patch 7.2.023
I wrote: Patch 7.2.023 Problem:'cursorcolumn' is in the wrong place in a closed fold when the display is shifted left. (Gary Johnson) Solution: Subtract w_skipcol or w_leftcol when needed. Files: src/screen.c This patch is not in CVS yet, because the SourceForge CVS appears to be down :-(. Hopefully it comes back to life before I leave. It just came back, 7.2.023 is checked in now. -- A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing on usenet and in e-mail? /// 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 -~--~~~~--~~--~--~---
New feature: cursor at the beginning of tab character in normal mode
Hello! A few days ago I wrote the following to [EMAIL PROTECTED]: I'd like to switch to vim but there is an annoying issue with it that I couldn't solve. When the cursor is at a tab character most editors display the cursor at the beginning of the interval the tab character occupies as follows (_ is the cursor): _ if (a c) ... Vim does the same in insert or replace mode. But in normal mode the cursor is displayed at the end of the tab character: _if (a c) ... Is there a way to make vim show the cursor at the beginning of a tab character in normal mode as it does in insert mode? I tried searching in Google but found nothing unfortunatelly :( Then I got a reply that said it's impossible without vim code modification so I decided to find out how to fix that. I seem to find the solution (the patch is at the end of this email) but it is so simple that I can't understand why it hasn't been done yet (since I know several people that are irritated by this feature of vim). I guess this mailing list is the best place to ask whether I miss anything. Here are my questions: 1. Are there any obvious problems/bugs with the patch itself? In other words, does it breaks anything very basic so that it definitely breaks some basic functionality or some plugins? 2. If there are no problems with it, do you have any wishes to apply it to the trunk? (And what the reasons for not doing so?) If so, I would add an option called, say, cursorattabstart that will trigger the new behaviour and resend the patch here for anyone of you to commit. -- Vladimir The patch follows (should be applied to just unpacked vim-7.2.tar.bz2): diff -Naur vim72.orig/src/charset.c vim72/src/charset.c --- vim72.orig/src/charset.c2008-07-24 18:59:44.0 +0400 +++ vim72/src/charset.c 2008-10-02 21:44:18.0 +0400 @@ -1333,7 +1333,7 @@ if (start != NULL) *start = vcol + head; if (end != NULL) - *end = vcol + incr - 1; + *end = vcol; if (cursor != NULL) { if (*ptr == TAB @@ -1345,7 +1345,7 @@ (*p_sel == 'e' || ltoreq(*pos, VIsual))) #endif ) - *cursor = vcol + incr - 1; /* cursor at end */ + *cursor = vcol; /* cursor at end */ else *cursor = vcol + head; /* cursor at start */ } --~--~-~--~~~---~--~~ You received this message from the vim_dev maillist. For more information, visit http://www.vim.org/maillist.php -~--~~~~--~~--~--~---
Re: vim keyboard mode via X server.
how would you type the letters hjkl into text? (almost any program needs to be able to use text, if only as the name of a file for its data). From what I understand, international modes are togled on and off with a keypress. It would work the same way, like vim insert and normal mode. - Ian --~--~-~--~~~---~--~~ You received this message from the vim_dev maillist. For more information, visit http://www.vim.org/maillist.php -~--~~~~--~~--~--~---
Patch 7.2.024
Patch 7.2.024 Problem:It's possible to set 'history' to a negative value and that causes an out-of-memory error. Solution: Check that 'history' has a positive value. (Doug Kearns) Files: src/option.c *** ../vim-7.2.023/src/option.c Thu Jul 24 18:45:15 2008 --- src/option.cFri Sep 26 22:20:20 2008 *** *** 7974,7979 --- 7974,7984 else /* curwin-w_p_scr curwin-w_height */ curwin-w_p_scr = curwin-w_height; } + if (p_hi 0) + { + errmsg = e_positive; + p_hi = 0; + } if (p_report 0) { errmsg = e_positive; *** ../vim-7.2.023/src/version.cWed Oct 1 21:09:02 2008 --- src/version.c Thu Oct 2 22:47:22 2008 *** *** 678,679 --- 678,681 { /* Add new patch number below this line */ + /**/ + 24, /**/ -- hundred-and-one symptoms of being an internet addict: 127. You bring your laptop and cellular phone to church. /// 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: New feature: cursor at the beginning of tab character in normal mode
Vladimir A. Pavlov wrote: A few days ago I wrote the following to [EMAIL PROTECTED]: I'd like to switch to vim but there is an annoying issue with it that I couldn't solve. When the cursor is at a tab character most editors display the cursor at the beginning of the interval the tab character occupies as follows (_ is the cursor): _ if (a c) ... Vim does the same in insert or replace mode. But in normal mode the cursor is displayed at the end of the tab character: _if (a c) ... Is there a way to make vim show the cursor at the beginning of a tab character in normal mode as it does in insert mode? I tried searching in Google but found nothing unfortunatelly :( Then I got a reply that said it's impossible without vim code modification so I decided to find out how to fix that. I seem to find the solution (the patch is at the end of this email) but it is so simple that I can't understand why it hasn't been done yet (since I know several people that are irritated by this feature of vim). I guess this mailing list is the best place to ask whether I miss anything. Here are my questions: 1. Are there any obvious problems/bugs with the patch itself? In other words, does it breaks anything very basic so that it definitely breaks some basic functionality or some plugins? The way it works is intentional. It's how Vi has always worked. I have no intention to change it. Now we could start a long discussion about yet another option... Keep in mind that switching this option on would have the risk of breaking some plugins and making users wonder why Vim doesn't behave as expected. 2. If there are no problems with it, do you have any wishes to apply it to the trunk? (And what the reasons for not doing so?) I haven't tried it, but I would suspect there are a few more places to change. If so, I would add an option called, say, cursorattabstart that will trigger the new behaviour and resend the patch here for anyone of you to commit. -- You cannot have a baby in one month by getting nine women pregnant. /// 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 -~--~~~~--~~--~--~---
Patch 7.2.025
Patch 7.2.025 Problem:When a CursorHold event invokes system() it is retriggered over and over again. Solution: Don't reset did_cursorhold when getting K_IGNORE. Files: src/normal.c *** ../vim-7.2.024/src/normal.c Sat Sep 6 16:44:06 2008 --- src/normal.cSat Sep 27 13:03:34 2008 *** *** 1132,1138 out_flush(); #endif #ifdef FEAT_AUTOCMD ! did_cursorhold = FALSE; #endif State = NORMAL; --- 1132,1139 out_flush(); #endif #ifdef FEAT_AUTOCMD ! if (ca.cmdchar != K_IGNORE) ! did_cursorhold = FALSE; #endif State = NORMAL; *** ../vim-7.2.024/src/version.cThu Oct 2 22:48:01 2008 --- src/version.c Thu Oct 2 22:54:41 2008 *** *** 678,679 --- 678,681 { /* Add new patch number below this line */ + /**/ + 25, /**/ -- hundred-and-one symptoms of being an internet addict: 128. You can access the Net -- via your portable and cellular phone. /// 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: New feature: cursor at the beginning of tab character in normal mode
On 02-Oct-08 20:03, Vladimir A. Pavlov wrote: Hello! A few days ago I wrote the following to [EMAIL PROTECTED]: I'd like to switch to vim but there is an annoying issue with it that I couldn't solve. When the cursor is at a tab character most editors display the cursor at the beginning of the interval the tab character occupies as follows (_ is the cursor): _ if (a c) ... Vim does the same in insert or replace mode. But in normal mode the cursor is displayed at the end of the tab character: _if (a c) ... Is there a way to make vim show the cursor at the beginning of a tab character in normal mode as it does in insert mode? I tried searching in Google but found nothing unfortunatelly :( Then I got a reply that said it's impossible without vim code modification so I decided to find out how to fix that. I seem to find the solution (the patch is at the end of this email) but it is so simple that I can't understand why it hasn't been done yet (since I know several people that are irritated by this feature of vim). I guess this mailing list is the best place to ask whether I miss anything. Here are my questions: 1. Are there any obvious problems/bugs with the patch itself? In other words, does it breaks anything very basic so that it definitely breaks some basic functionality or some plugins? 2. If there are no problems with it, do you have any wishes to apply it to the trunk? (And what the reasons for not doing so?) If so, I would add an option called, say, cursorattabstart that will trigger the new behaviour and resend the patch here for anyone of you to commit. -- Vladimir When 'list' is set, the cursor stays at the beginning of a Tab interval, too. So you could achieve the same effect with these settings: ':set list listchars=tab:\ \ ' Of course, you would lose the functionality of ':set invlist'; but you can probably define an alternative command / mapping that now will toggle the 'listchars' option. -- regards, ingo --~--~-~--~~~---~--~~ You received this message from the vim_dev maillist. For more information, visit http://www.vim.org/maillist.php -~--~~~~--~~--~--~---
RE: New feature: cursor at the beginning of tab character in normal mode
Not to take sides, but just to add my comments... 1) In normal mode, if you have the 'list' option on, the cursor is displayed at the beginning of the tab character, not the end. So now it's not just mode that determines it. If you sit your cursor on a tab character and repeatedly toggle the 'list' option (which I actually have a keymapping for), the cursor will actually jump back and forth on screen from the beginning of the tab to the end. That seems unexpected to me. 2) As a general question: If there's a quirk carried forward from original Vi, and the general consensus among Vim users is that the quirk is only there for strict Vi compatibility and it would make more sense to change it, would it not make sense to have it controlled by the 'compatible' option? Setting 'nocompatible' already breaks some Vi compliance. So, yet-another-option would not necessarily need to be introduced. Cheers, Craig --~--~-~--~~~---~--~~ You received this message from the vim_dev maillist. For more information, visit http://www.vim.org/maillist.php -~--~~~~--~~--~--~---