[GH-ISSUE #9] [Enhancement] Left and Right to jump pages in the message list #8

Closed
opened 2026-03-03 01:18:51 +03:00 by kerem · 15 comments
Owner

Originally created by @Kabouik on GitHub (Jan 13, 2020).
Original GitHub issue: https://github.com/d99kris/nmail/issues/9

Originally assigned to: @d99kris on GitHub.

Pretty much like PageUp and PageDown, but Left and Right are easily accessible when already using Up and Down to move among messages, and not all devices have direct PageUp and PageDown keys.

I found myself 6 months in the past in my Inbox at some point, and have just arrows on my device. Jumping pages would have been a life-changer (I actually just ended up closing and reopening nmail to reset the view).

Originally created by @Kabouik on GitHub (Jan 13, 2020). Original GitHub issue: https://github.com/d99kris/nmail/issues/9 Originally assigned to: @d99kris on GitHub. Pretty much like PageUp and PageDown, but Left and Right are easily accessible when already using Up and Down to move among messages, and not all devices have direct PageUp and PageDown keys. I found myself 6 months in the past in my Inbox at some point, and have just arrows on my device. Jumping pages would have been a life-changer (I actually just ended up closing and reopening nmail to reset the view).
kerem closed this issue 2026-03-03 01:18:52 +03:00
Author
Owner

@d99kris commented on GitHub (Jan 13, 2020):

The default nmail keymapping follows closely that of pine / alpine, but yeah there wouldn't be any harm in allowing re-mapping the arrow keys to different function. Due to how the keymapping is done today it's not super straight-forward, so I just need to think of how to best implement this.

<!-- gh-comment-id:573695080 --> @d99kris commented on GitHub (Jan 13, 2020): The default nmail keymapping follows closely that of `pine` / `alpine`, but yeah there wouldn't be any harm in allowing re-mapping the arrow keys to different function. Due to how the keymapping is done today it's not super straight-forward, so I just need to think of how to best implement this.
Author
Owner

@Kabouik commented on GitHub (Jan 13, 2020):

I think the left/right arrow keys are not currently being used, hence why I thought about them for jumping pages. Space seems to jump page too, but I couldn't find a way to jump backwards, plus I use modifier+space for global keybindings anyway so having alternatives would be nice. Not something really crucial though.

<!-- gh-comment-id:573707374 --> @Kabouik commented on GitHub (Jan 13, 2020): I think the left/right arrow keys are not currently being used, hence why I thought about them for jumping pages. Space seems to jump page too, but I couldn't find a way to jump backwards, plus I use modifier+space for global keybindings anyway so having alternatives would be nice. Not something really crucial though.
Author
Owner

@d99kris commented on GitHub (Jan 14, 2020):

Oh yeah you are right, left/right arrows are not currently being used. In pine / alpine they do have a different meaning (basically same as < and >) but not in nmail. Ok I'll consider this.

<!-- gh-comment-id:574112873 --> @d99kris commented on GitHub (Jan 14, 2020): Oh yeah you are right, left/right arrows are not currently being used. In `pine` / `alpine` they do have a different meaning (basically same as `<` and `>`) but not in `nmail`. Ok I'll consider this.
Author
Owner

@d99kris commented on GitHub (Feb 10, 2020):

This feature request will take a bit of time as it requires some redesign in how nmail handles key mappings.

<!-- gh-comment-id:584102057 --> @d99kris commented on GitHub (Feb 10, 2020): This feature request will take a bit of time as it requires some redesign in how `nmail` handles key mappings.
Author
Owner

@Kabouik commented on GitHub (May 30, 2020):

Just an additional note because I see that I initially asked for fixed additional keys for jumping pages. It would actually be best to make it user configurable, but I suspect that is what you had in mind anyway. I now switched to using Left and Right to navigate between views, so I would for example use ^Left and ^Right for jumping pages; and of course others users may want something else, so custom key mapping for this would be great.

<!-- gh-comment-id:636341961 --> @Kabouik commented on GitHub (May 30, 2020): Just an additional note because I see that I initially asked for fixed additional keys for jumping pages. It would actually be best to make it user configurable, but I suspect that is what you had in mind anyway. I now switched to using `Left` and `Right` to navigate between views, so I would for example use `^Left` and `^Right` for jumping pages; and of course others users may want something else, so custom key mapping for this would be great.
Author
Owner

@d99kris commented on GitHub (May 30, 2020):

It would actually be best to make it user configurable, but I suspect that is what you had in mind anyway.

Right, correct. 👍

<!-- gh-comment-id:636343973 --> @d99kris commented on GitHub (May 30, 2020): > It would actually be best to make it user configurable, but I suspect that is what you had in mind anyway. Right, correct. :+1:
Author
Owner

@d99kris commented on GitHub (Aug 2, 2020):

Just FYI - In commit 7543d02 I've changed default nmail key handling so that Left and Right can be used to navigate between views (in addition to what's configured). This follows pine / alpine user interface, and makes navigation faster (same keys can be used on every view, even in folder/address/file-selection lists).

I've not yet made PageUp, PageDown or other basic navigation configurable. Will try to get to that eventually.

<!-- gh-comment-id:667668887 --> @d99kris commented on GitHub (Aug 2, 2020): Just FYI - In commit 7543d02 I've changed default `nmail` key handling so that `Left` and `Right` can be used to navigate between views (in addition to what's configured). This follows `pine` / `alpine` user interface, and makes navigation faster (same keys can be used on every view, even in folder/address/file-selection lists). I've not yet made `PageUp`, `PageDown` or other basic navigation configurable. Will try to get to that eventually.
Author
Owner

@Kabouik commented on GitHub (Aug 4, 2020):

Excellent, we can use Left and Right from the folder view too now, it's indeed much more consistent. And I like how you made it so the keys move views when no characters have been typed in the folder/email search field, and move cursor when something is being typed.

<!-- gh-comment-id:668492893 --> @Kabouik commented on GitHub (Aug 4, 2020): Excellent, we can use `Left` and `Right` from the folder view too now, it's indeed much more consistent. And I like how you made it so the keys move views when no characters have been typed in the folder/email search field, and move cursor when something is being typed.
Author
Owner

@Kabouik commented on GitHub (Aug 4, 2020):

Just a note, it might make sense to allow navigating through folders in the file selection dialog with Left and Right as well, if deemed relevant. Perhaps better to reference that That was mentioned in #47.

<!-- gh-comment-id:668577993 --> @Kabouik commented on GitHub (Aug 4, 2020): Just a note, it might make sense to allow navigating through folders in the file selection dialog with `Left` and `Right` as well, if deemed relevant. ~~Perhaps better to reference that~~ That was mentioned in #47.
Author
Owner

@d99kris commented on GitHub (Aug 4, 2020):

Ah, thanks for reminding me about that. Yes, that is an excellent idea (and should be simple to implement).

<!-- gh-comment-id:668599937 --> @d99kris commented on GitHub (Aug 4, 2020): Ah, thanks for reminding me about that. Yes, that is an excellent idea (and should be simple to implement).
Author
Owner

@d99kris commented on GitHub (Aug 4, 2020):

The right-arrow navigation was already working in the file selection view. I've added support for navigating to parent directory using left arrow in 62c26bc.

<!-- gh-comment-id:668607506 --> @d99kris commented on GitHub (Aug 4, 2020): The right-arrow navigation was already working in the file selection view. I've added support for navigating to parent directory using left arrow in 62c26bc.
Author
Owner

@d99kris commented on GitHub (Jan 12, 2021):

Hi, just for my clarification. The remaining part of this request is to make PageUp and PageDown key bindings configurable, so that a user can use for example Ctrl+Left and Ctrl+Right instead. Is my understanding correct? Thanks.

<!-- gh-comment-id:758636621 --> @d99kris commented on GitHub (Jan 12, 2021): Hi, just for my clarification. The remaining part of this request is to make `PageUp` and `PageDown` key bindings configurable, so that a user can use for example `Ctrl+Left` and `Ctrl+Right` instead. Is my understanding correct? Thanks.
Author
Owner

@Kabouik commented on GitHub (Jan 12, 2021):

Absolutely.

<!-- gh-comment-id:758645518 --> @Kabouik commented on GitHub (Jan 12, 2021): Absolutely.
Author
Owner

@d99kris commented on GitHub (Jan 17, 2021):

A fix has been implemented in above commit, please let me know if you encounter any issues. Please help report as new issue(s) if there are remaining problems.

<!-- gh-comment-id:761823948 --> @d99kris commented on GitHub (Jan 17, 2021): A fix has been implemented in above commit, please let me know if you encounter any issues. Please help report as new issue(s) if there are remaining problems.
Author
Owner

@Kabouik commented on GitHub (Jan 17, 2021):

Great, thank you. It works for me with KEY_CTRLU and KEY_CTRLD, I finally chose those as they match keybindings of my TUI IRC client (tiny) . I assume Ctrl+Left and Ctrl+Down could work too but I have to find the Octal key sequences for them (KEY_CTRLRIGHT/KEY_CTRLRIGHT don't work).

<!-- gh-comment-id:761899322 --> @Kabouik commented on GitHub (Jan 17, 2021): Great, thank you. It works for me with `KEY_CTRLU` and `KEY_CTRLD`, I finally chose those as they match keybindings of my TUI IRC client ([`tiny`](https://github.com/osa1/tiny)) . I assume `Ctrl+Left` and `Ctrl+Down` could work too but I have to find the Octal key sequences for them (`KEY_CTRLRIGHT`/`KEY_CTRLRIGHT` don't work).
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/nmail#8
No description provided.