newsbeuter icon indicating copy to clipboard operation
newsbeuter copied to clipboard

feature: scroll offset?

Open sharethewisdom opened this issue 9 years ago • 3 comments

Vim's setting scrolloff specifies the minimal number of screen lines to keep above and below the cursor

It would be nice to have such a setting for Newsbeuter in either item-, search- or feedlist views.

sharethewisdom avatar Jun 15 '15 12:06 sharethewisdom

I like this idea, too.

simonnagl avatar Jun 21 '15 09:06 simonnagl

Yes, it's my personal opinion that the added value and potential complexity in the code would meet the design purpose. I'm not a good programmer myself, so I hope someone will respond that has the experience to patch this properly and start running some tests. After a quick look it appears that the visible_items vector should probably be updated with some logic based on a scroll_offset config setting. I know, it's probably more complicated. Maybe some inspiration can be obtained from Cmus's scroll offset implementation (also here)? I hope it helps.

sharethewisdom avatar Jun 21 '15 12:06 sharethewisdom

mutt has a setting called menu_scroll. From the docs: When set, menus will be scrolled up or down one line when you attempt to move across a screen boundary. If unset, the screen is cleared and the next or previous page of the menu is displayed (useful for slow links to avoid many redraws).

The default for mutt is unset, which is a nice setting for going through large amounts of mail. Basically the same applies to newsfeeds. This would be worthwhile addition/alternative to vims scrolloff. Ideally we would have both options to choose from in newsbeuter.

sassmann avatar Apr 21 '17 09:04 sassmann