> On Thu, September 16, 2010 12:10 am, hsitz wrote:
>> I have Vim documents that have codeblock areas that use 'syntax
>> include' regions to have different syntax highlighting from the main
>> document. For example, I have a syntax region named 'pyregion' defined
>> that I use when I input Python code. The pyregion areas of the
>> document are then highlighted using setup in Python's syntax file,
>> while the area outside the region uses the syntax file of the main
>> document.
...[snip]...
>
> I hear a lot about the txtfmt plugin, which seems to be very advanced.
> But I don't know, whether it can help in your scenario, when you want
> to color whole lines. Brett, probably knows better.
The Txtfmt plugin can be used to change the background color (as well as
foreground color and format attributes) of arbitrary regions of text. As
Christian correctly points out, however, the syntax mechanism operates
only on actual *characters*. As far as I know, the only way to do what
you're trying to do involves the addition of trailing whitespace (whose
background color can be set). Of course, you may not wish to have such
whitespace in your source files...
The problem is that Vim's background coloring mechanism is akin to
"highlighting" in a word processor, whereas what you want is analogous
to "Background Color".
Brett Stahlman
>
> regards,
> Christian
>
--
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
No comments:
Post a Comment