[Vimperator] Configurable hints for vimperator 0.6
Daniel Trstenjak
Daniel.Trstenjak at online.de
Sat May 3 03:45:05 PDT 2008
Hi Martin,
On Fri, May 02, 2008 at 08:35:08PM +0200, Martin Stubenschrott wrote:
> Still two things I do not like:
>
> 1.) the isLetter() function. Even though I am Austrian, hardcoding äö
> etc. looks bad. Why is that needed at all?
Hey, you caught me ;). It's just hacked in.
Is there a more language independet way of determining a letter? Or can
we seperate this checking in a language dependent way?
Beside letters there should also be some other characters considered as
word elements. Like the apostrophe or the hyphen.
Perhaps the characters which can be contained in a word should be
configurable. Like: wordchars=a-z,ä,ö,ü,',-
In vim there are the filetypes, which do meaningful stuff for each
programming language. In vimperator there could be natural language
types, which could set the option 'wordchars'.
Just some thoughts.
> 2.) I still can't just write "Rossi" in a "Rossi morning time untouched
> in second Shanghai session" link. My intuitive way to follow such a link
> would be to type "ros", if that doesn't succeed, I'd just write "mor",
> making it "rosmor". Of course "rmt" should also work.
I think the consenus we have is, that the typed characters should be matched
against the words in the order they appear in the link.
Now the question is, which way of matching gets the highest score.
We have three ways of matching.
1) first character of each word
2) beginning characters of each word
3) beginning characters of first word
Perhaps a very simple algorithm would cover sufficiently all three
cases. Start matching the typed characters at the beginning of the first
word, if theres no more match, go to the beginning to the next word ...
I will try this.
> I am not sure, we'll agree on how a 4th hint-matcher would look like,
> but I really don't want to add too many of them. (4-5 might be ok, but I
> certainly won't have 10 hint matchers in vimperator).
I'm absolutely on your side. I'm currently more in experimeting what
works best. I'm really not propsing to add all the stuff I'm coming up.
I'm just gaming. :)
Greetings,
Daniel
More information about the Vimperator
mailing list