On Fri, Nov 16, 2007 at 08:12:17PM +0000, place wrote:
Johannes wrote:
On Fri, Nov 16, 2007 at 07:10:48PM +0000, place wrote:
Johannes wrote:
Very nice! I was text search a lot. What about incremental searching as you type? I don't mind the title bar...
Hmm... I'd have to modify findtext.cc some... I may get around to it at some point here, though I'm feeling the need to look into what's going on with redirection and gzip, so if anybody else gets there first, it'll be fine with me! :)
I was thinking about something like:
diff -r f18e37a8e3ac src/dialog.cc --- a/src/dialog.cc Fri Nov 16 20:25:11 2007 +0100 +++ b/src/dialog.cc Fri Nov 16 20:27:18 2007 +0100 @@ -141,14 +141,6 @@ static void findtext_search_cb(Widget *, const char *key = tf->i->value(); bool case_sens = tf->cb->value();
- /* - * Somehow fltk even regards the first loss of focus for the - * window as a WHEN_ENTER_KEY_ALWAYS event. - */ - int e = event_key(); - if ((e != ReturnKey) && (e != LeftButton)) - return; - if (key[0] != '\0') a_UIcmd_findtext_search(tf->bw, key, case_sens);
@@ -176,7 +168,7 @@ TextFinder::TextFinder(int ww, int wh, B
begin(); i = new Input(0, 0, ww, ih); - i->when(WHEN_ENTER_KEY_ALWAYS); + i->when(WHEN_CHANGED); i->callback(findtext_search_cb, this);
cb = new CheckButton(0, ih, ww, wh-ih-bh, "Case-sensitive");
on top of your patch of course. Works for me.
I had tried that before replying earlier, and I was happy at first, but then after I hit Enter a few times on the final string, I was disappointed when I found backspace made the search go to the top of the page again. To me it felt like it should've been relative to where I found myself the last time I hit enter. I don't make much use of anything with incremental search, though, so I don't know what the standard behavior is.
Though I think the current behaviour is consistent, I understand your concern. Firefox never goes back when you shorten the search string even if you have not yet hit enter. But I think that's bad if you just mistyped the search string and want to correct it. Johannes
_______________________________________________ Dillo-dev mailing list Dillo-dev@dillo.org http://lists.auriga.wearlab.de/cgi-bin/mailman/listinfo/dillo-dev