GNOME Bugzilla – Bug 661345
PageUp and PageDown down scroll text from within the search window
Last modified: 2020-11-06 20:22:52 UTC
When using the search bar (ctrl+f) to search though code, PageUp and PageDown should scroll the current document. Pressing up or down in the search box moves focus to the current document, so maybe PageUp and PageDown should have the same behavior.
If you want to give it a try, add PAGEUP/PAGEDOWN do the special casing here: http://git.gnome.org/browse/anjuta/tree/plugins/document-manager/search-box.c#n207
Thanks for the code point. It is clear enough how to revert focus to the code window, but what I am not sure how to do is pass through the Page{Up,Down} event. Do I need to re-emit this signal somehow?
AFAIK, we just have to ignore the signal in the entry. But I am not overall sure if we can do it with the signal. Normally you would overwrite the virtual function and just don't call the parent's one. Anyway, I will have a look at it once I am back home in about two weeks.
Created attachment 212075 [details] [review] Patch for PageUp and PageDown to work when search window is active The patch adds two cases for page up and page down in document-manager/search-box.c enabling the Page-up and Page-down functions to work even when there is a search window.
Review of attachment 212075 [details] [review]: Thanks for your patch, I have tried here and it's working. But I think that perhaps it could be a bit better to stay in the search entry widget. Currently when you press page up/page down you just exit from the search entry. The first page up/page down is ignored and you have to press Ctrl+F again to go back to the search entry. So first, isn't it possible to redirect the first page up/page down event to the editor? Then could you stay in the search entry widget after the move in the text editor?
Do you think editing on this part of the code can help? git.gnome.org/browse/anjuta/tree/plugins/sourceview/anjuta-view.c#n613 And can you tell me what is assist_tip ?
(In reply to comment #6) > Do you think editing on this part of the code can help? > git.gnome.org/browse/anjuta/tree/plugins/sourceview/anjuta-view.c#n613 No, it should work whatever is the editor. So you should rather try to reemit the event to the editor widget. > And can you tell me what is assist_tip ? It's a small popup window which appears , by example, when you type a function name to list all possibilities or give you information about the function arguments. It's not related to this.
bugzilla.gnome.org is being replaced by gitlab.gnome.org. We are closing all old bug reports in Bugzilla which have not seen updates for many years. If you can still reproduce this issue in a currently supported version of GNOME (currently that would be 3.38), then please feel free to report it at https://gitlab.gnome.org/GNOME/anjuta/-/issues/ Thank you for reporting this issue and we are sorry it could not be fixed.