Jan Parthey wrote:
> Hi,
>
> I see inconsistent results when typing "dit" to delete content of an XML
> element. Result depends on whether the closing XML tag is indented or not.
>
> Observed: Opening and closing tag end up ...
> - on different lines when closing tag had no indent (see Case_A below)
> - on same line when closing tag had some indent before deleting (see Case_B
> below)
>
> Expected: Same result, regardless of indent.
>
> How to reproduce - details
> ==========================
>
> Case_A: closing tag w/o any indent
>
> 1. contents:
> |<li>
> |foo
> |</li>
> ^ Note: pipe symbols mark window edge and are not part of contents
> 2. type "dit"
> 3. result: tags end up on different lines
> |<li>
> |</li>
>
> Case_B: closing tag with some indent
>
> 1. contents:
> |<li>
> |foo
> | </li>
> 2. type "dit"
> 3. result: tags end up on same line
> |<li></li>
>
> Additional Notes:
> =================
> - inconsistency goes away when using "vitd" instead of "dit"
> - compare "dit" with "di{" - latter behaves more nicely, IMHO
> - issue can be worked around with a custom mapping:
> :onoremap it :normal! vit<CR>
> - unfortunately, this workaround doesn't fix "surround" plugin (ID 1697) which
> breaks for removing tags at end of buffer that have no indent
> (problem: line preceding opening tag ends up after XML element contents)
I'll put it on the todo list.
--
panic("Foooooooood fight!");
-- In the kernel source aha1542.c, after detecting a bad segment list
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--
--
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.