[Solved] How to make keyboard shortcut for Navigate By Page up & down?

How can I make a keyboard shortcut to, or enable on the keyboard with some other option setting, the functions of these two buttons on the Find toolbar (circled in red)?

image description

I’ve looked in the Keyboard Shortcut grouping for Navigate and the closest matches I’ve found to what these buttons do are “To Begin of Previous Page” and “To Begin of Next Page”… which move the page focus up & down by insert point, not by page view. There’s a big difference between what we need and this common workaround, also suggested here: 208765/librewriter-exact-page-navigation-in-edit-mode/

Since we’re comparing hundreds of top-of-page titles, just like these Navigation buttons we need to keep the top of the focused page at the top, while the “To Begin … Page” functions scroll the updated insert point to the middle of the screen, assuming that’s where we want to be editing (which we generally don’t).

i.e. we need to proofread or visually scan a document by scanning through & viewing whole pages at a time. The buttons above do this perfectly so we just want to link a shortcut to those button functions instead of previewing some other way.

It would be a shame for our disabled crew if they were told they could only do this by changing the document reading mode or with a hand-eye coordinated motion, rather than mapping the easily accessible PgUp and PgDn keys.

EDIT: Consensus is that it’s impossible to do this, i.e. that keyboard shortcut functions for these buttons are missing outright, so submitted as minor bug report / feature request: tdf#140448

EDIT 2: The developer link above, repeated in my answer below, eventually identified the correct shortcuts to use (Previous Element and Next Element).

(links reformatted by ajlittoz for better readability)

In the menu click Tools > Customise, select the Keyboard tab.

In the bottom left pane (category) click Navigate, In the bottom middle pane (Function) select To beginning of next page. In the top pane (Shortcut keys) select Page down, click the Modify button. Cheers, Al

Whoops, I didn’t pay sufficient attention

There is another question where OP complains that his mouse setting does exactly what you are asking, but only in Windows I think, and might be a bug.

In Control Panel > Mouse > Wheel there is a radio button that says One screen at a time; if that is checked you will go to the top of the next page each time you turn one notch of the wheel.

thanks again for the attention @EarnestAl - nothing like this in Linux (either on its own “Control Panel” or LibreOffice settings)… that would not be so good for “twitchy” people either. I generally go over all the accessibility settings and was hoping we could find a way of approximating them, but it seems that if the “Navigate By” button functions haven’t been exposed in the Keyboard Shortcuts API then we’ve got no way to do exactly the same thing, i.e this thread will have to be reposted as a feature request.

Have submitted bug report / feature request. Also editing this into OP, so thread followers can be notified: https://bugs.documentfoundation.org/show_bug.cgi?id=140448

@rphair Original poster for Question 299005 Found the keyboard shortcut should be mapped to Next Element and Previous Element to get same effect as navigation arrows. Cheers, Al

@EarnestAl - that question is a later-arriving duplicate of this one, and the other OP would have found the answer by following the link to the bug report which was edited into this OP a few weeks ago. See comment immediately before yours for that already posted solution as identified by the LO devs. If you want to post that solution in this thread I’ll mark it as “Solved” here - I haven’t done so already because the LO devs admitted that the UI is confusing and then said they’ll do nothing about it.

Yup it is confusing. It isn’t my answer so I won’t try and make it so. Thanks for posting bug. Cheers, Al

and thank you for your attention @EarnestAl - I’ve posted the answer & editing the title as [Solved] since I don’t know how to do mark it any more officially than that. :slight_smile:

@rphair: question reopened because you didn’t accept any answer. To do that, click on the gray checkmark at top left of relevant answer.

If you consider yours should be checked, tell so because your karma won’t let you. Other users will be able to do so after 7 days have elapsed since last update.

Also, remove “[solved]” from question title. The way to flag a question as solved is to accept an answer. Then the site engine will mark the question in the database and “decorate” its title in the home page.

The shortcut functions to use, Previous Element and Next Element, were identified in my official bug report by the LibreOffice developers as the correct ones to use in this case.

They correspond exactly to the highlighted buttons, and the page up & down behaviour is exactly what I was looking for when the “Page” element is selected from the menu next to the buttons and mapped to the PgUp and PgDn keys.

The link to the developer thread, again, since people are missing it from my edit to the OP and the comments below it: tdf#140448

(link to bug report reformatted by ajlittoz)

I couldn’t find a way to do exactly what you want (if I understood correctly), but I made a demo document containing a few macros which may help you. Only for the demo the document also contains a custom toolbar for calling these macros.

If you decided to use the macros, you would need to move the contained module to the local Standard library for Basic scripts and to assign the needed macros to shortcuts.

Two of the macros you won’t need. As far as I can see they do exactly what is achieved by Alt+PageUp and Alt+PageDown. (I only noticed this when the macros were already written.)

But as you obviously found the action performed by the described shortcuts will not preserve the previous selection.

To help with this, simply always use the pageNavigationStart in a first step. Having finished the onePageUp and onePageDown steps, a call to pageNavigationStop will then reinstate the selection that was made in advance of the whole process. No need to search for.

Of course you can use very similar simple macros to memorizeCurrentSelction and reselectMemorizedSelection independent of the page navigation.

What are Alt+PageUp and Alt+PageDown for in Writer? My shortcuts list are empty for these two. Thanks in advance.

(My UI is English, but my Win is German. The version I made this with was LibreOfficeDev It’s install was not based on my prior user profile, and I don’t remember shortcut settings since.)

Thanks for all your work to put this together… since we’re working on high security documents we can’t add macros but if there’s no response from the developers about adding proper keyboard shortcuts for those toolbar buttons, it’s nice to know we have some other options available :slight_smile: