On Fr, 19 Sep 2014, Christian Brabandt wrote: > On Fr, 19 Sep 2014, Bram Moolenaar wrote: > > > > > Nazri Ramliy wrote: > > > > > Attached is a patch that adds a failing test that should show the > > > buggy behavior on the following text: > > > > > > -- 8< -- > > > +REMOVE: This text must not be deleted > > > +REMOVE: aaaaaaa...repeat until linebreak kicks in...aaaaaaaaaaa.... > > > +-- >8 -- > > > > > > With linebreak set and doing a character-wise visual selection on both > > > the "REMOVE: " characters (including the single whitespaces) will > > > select more than both of the "REMOVE: " characters. > > > > The test writes the ".ok" file, that's not the right way to do this. > > > > Christian, did you already look into fixing this? > > No, I thought this was just about a missing test. I'll look into it next > week.
This is ... complicated. Here is a visual representation of what happens: ,-----------------, | 1 BAR: xxxx | | 2 BAR: | | xxxxxxxxxxxxx | `----------------ยด (now visually block-select the BAR: (including the following whitespace). You'll notice, that the visual selection extends till the end of the window. The problem is, when linebreak is set, win_lbr_chartabsize() will select the complete whitespace until the end of the screen line, this is, so that the linebreak feature works and the rest of the text is drawn on the next line (and also moving around works as expected). I have no idea how to fix it. I played around in function win_update() where wp->w_old_cursor_lcol is set, but this has obviously problems when moving around with the cursor. Best, Christian -- Wie man sein Kind nicht nennen sollte: Klaas Nost -- -- You received this message from the "vim_dev" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php --- You received this message because you are subscribed to the Google Groups "vim_dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
