On 16/11/12 04:02, ping wrote:
I know vim is an "pure text" editor, not word or rendering system.
but currently I have it displaying the bold, italic, underline with an
asciidoc syntax highlight file.
https://github.com/dagwieers/asciidoc-vim

it is surprisingly good in terms of displaying effect and asciidoc
syntax compliance.

only thing is it is VERY slow sometime when you jump back and forth. but
that is another issue.
here I'm talking about the word displaying effect -- I'm still curious
how can this pure text editor display the a underline under each
charactor, but it works.

anyway, if the underline is OK, how about a "cross-through" line?


Short answer: You can't.

Long answer: Gvim knows about 16777216 background colours, 16777216 foreground colours, as many different characters as are possible with Unicode, bold, italic and underline in the foreground colour, and 16777216 additional colours for curly underline.

When running in a terminal, Vim is limited by what the terminal can do. This usually reduces the number of different colours, suppresses curly underline, and, depending on the terminal, may suppress italic and/or ordinary underline, and may make boldface no different from some "brighter" foreground colour. It may also reduce the number of different glyphs effectively displayable.

Neither gvim nor Console Vim can display strike-through, except by modifying the text by adding U+0336 COMBINING LONG STROKE OVERLAY after each character — but this is a text change, not a highlighting effect, so you cannot do it as a syntax highlight. If you could, it would probably already be used in the syntax/html.vim script for the <s> and <strike> (and maybe <del>) elements.

What you might do, at the cost of spell checking, is use for instance
        :hi StrikeOut gui=undercurl guisp=fg
to add a curly underline in the default foreground colour to represent overstrike (but only in gvim, not in Vim in a terminal).


Best regards,
Tony.
--
You are only young once, but you can stay immature indefinitely.

--
You received this message from the "vim_use" 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

Reply via email to