On 2024-03-17, San wrote: > @chrisbra > Also i found another bug( or maybe its on purpose) > When you only have /t( tab or indentation) without any text on a new line. And > you navigate back to previous line and press delete button, the next line does > not get deleted but the /t( tab or indentation) does.
When you create a new line for which Vim automatically provides indentation, and you don't add any text on that line, and you then move to a different line, Vim removes the indentation. This is by design, to avoid adding superfluous white space to a buffer. The delete button should delete one character. Why would you expect it to delete a line, and a different line at that? > Which in some cases is kind of annoying so most IDE's delete the next line > when > delete is pressed if the next line contains only /t's. That seems weird. A text file is simply a sequence of characters. Different editors have different ways of representing that to the user. In Unix, by convention, a text file is a sequence of lines, where each line is a sequence of characters terminated by a newline. Vim represents each line as a line-object (my term) without a newline. The end-of-line sequence terminating each line is implicit and does not appear in the Vim buffer, which is simply a sequence of line-objects. I'm not sure that was very clear. My point is that Vim's representation of a text file in a buffer may differ from what you're used to. It isn't a bug; it's by design. You may have to think differently about what it means to edit a Vim buffer for some of Vim's behavior to make sense to you. Regards, Gary -- -- 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]. To view this discussion on the web visit https://groups.google.com/d/msgid/vim_dev/20240318172831.GE2578%40phoenix.
