I'm using webkit-gtk-1.8.3.
I'm having trouble highlighting the current text match. I can highlight all of the marked text matches using this block of code within a keypress function:
hits = webkit_web_view_mark_text_matches (web_views[current_tab], gtk_entry_get_text (GTK_ENTRY (search_entry)), FALSE, 0);
webkit_web_view_set_highlight_text_matches (web_views[current_tab], TRUE);
webkit_web_view_search_text (web_views[current_tab], gtk_entry_get_text (GTK_ENTRY (search_entry)), FALSE, TRUE, TRUE);
Each time this block of code is executed the webview scrolls so the current match is on the page, but if more than one match is on this page nothing happens and nothing distinguishes the current match from the others. I've seen in other webkit-gtk browsers where the current match is highlighted a green color to make it stand out from the other matches highlighted in yellow. I've dug through the source code of some of these projects, but I can't for the life of me figure out how they did it. I must be missing something because it seems they are using these same functions.
Any help would be greatly appreciated. Thanks.