Sorry for late reply!
Thank you very much for your advice. With your help I might have fixed the
first issue in release 1.2.3, Please update your release. I redefine the
text
element "txtApostrophe" which now avoid to mistakely highlight words like
"it's
and man's". Now I pair a ' after a Start-of-line or no-alpha characters and
before a End-of-line or no-alpha characters. I have tested in English and it
works well. As about other language, Could someone help to have a test?
For asymetric quotes, It seems good in Englist and Chinese, doesn't it? I
need
help from other language's expert.
At last, Txtbrowser use regular expression to recognize the title, But I
didn't
succeed when testng regular expression with multi lines. Can you give some
clue? for example, how to express the following (as a title.)
This is a title
===============
Besides, TxtBrowser have many update after its initial release, for example
easy install, fix of issue about encoding, bug fix, etc. Hope it's useful
for
peoples who use plain text in daily work.
Thanks
ypguo
Tony Mechelynck-2 wrote:
>
> On 03/02/10 15:00, vimer_at_cn wrote:
>>
>> Hi:
>>
>> It seemed that you are very careful, As I have mentioned before,
>> TxtBrowser
>> is
>> not enough smart. I remembered I had mentioned a example:
>>
>> References from my response before:
>> |
>> |Thank you very for your advice. This is the 1st time I increase my
>> weight
>> by
>> |1.1 kilogram.
>>
>> The plugin would recognize it as a title, but it isn't. I have no clues
>> about
>> how to differentiate bewteen those except that vim know it's meaning. The
>> only
>> way to avoid to make a mistake is to cancel the highlight the word in the
>> apostrophes. But when you obtain the precise, you will lose some
>> highlight
>> when
>> it should be. Vim is an open world, I hope I provide a possiblity for
>> everyone
>> to custimize his own syntax highlight, I hope people custimize what the
>> syntax
>> is defined and share what they define. I'm not good at regular expression
>> indeed. Of course I will do some study and think about the
>> possibility.:-)
>> Any
>> clue is welcome.
>>
>> Thank you very much. Please let me know if you have any question or
>> suggestion.
>
> Why not pair a ' or " preceded by a quote, tab, start-of-line or
> punctuation with the same quote followed by a space, tab, end-of-line or
> punctuation? Or maybe pair /\%(^\|\A\)\zs'\ze\a/ with
> /\a\zs'\ze\%(\A\|$\)/ This would exclude most English examples
> (including it's and man's), but it isn't perfect for all languages: in
> Dutch, «'t is» (short for «het is» i.e. it's, «'s avonds» (in the
> evening), or «'s Hertogenbosch» (name of a city) would not be caught.
> (There are several such citynames in Belgium and the Netherlands,
> including 's Gravenhage, the older or «more pompous» name of Den Haag
> i.e. The Hague). In "seaman's French" words like canot', bout' etc. are
> often written with an added apostrophe at the end to indicate that the
> final consonant is pronounced, /à la bretonne/. In Esperanto poetry, the
> final -o of substantives may be elided (and replaced by an apostrophe)
> for reasons of prosody. And so on.
>
> For asymetric quotes (such as « » or " ") it might be simpler, except
> that an upper-6 quote may be paired (depending on language) with either
> an upper-9 or lower-9, and that " and « are opening quotes in French and
> closing quotes in German (vice-versa for » and „). Also I've been told
> that an upper-9 single quote is the "preferred glyph" for the apostrophe
> (in charsets which possess it) even when replacing an elided character.
>
> For titles, maybe only consider a start-of-line number if it is at the
> start of a paragraph? (start of document, or after a blank line, or
> indented differently than the rest of the text)?
>
>
> Best regards,
> Tony.
> --
> "Every time I think I know where it's at, they move it."
>
> --
> 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
>
>
--
View this message in context: http://old.nabble.com/show-the-document%27s-structure-and-syntax-highlight-of-plain-text-tp27095084p27996349.html
Sent from the Vim - General mailing list archive at Nabble.com.
--
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
To unsubscribe from this group, send email to vim_use+unsubscribegooglegroups.com or reply to this email with the words "REMOVE ME" as the subject.
No comments:
Post a Comment