mirror of
https://github.com/rivo/tview.git
synced 2026-04-26 21:35:54 +03:00
[GH-ISSUE #512] Horizonal scroll for List #371
Labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/tview#371
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @abitrolly on GitHub (Oct 9, 2020).
Original GitHub issue: https://github.com/rivo/tview/issues/512
I want to add horizonal scrolling to the list element, because for wide tables not everything could fit the screen.
There is no setting for this on the List element https://pkg.go.dev/github.com/rivo/tview#List
What is the proper way to do this? An example in wiki would be nice to have.
@tslocum commented on GitHub (Oct 13, 2020):
Hey @abitrolly, I've submitted the necessary changes to implement this for review.
Horizontal scrolling is also available in cview, a fork of tview.
@rivo commented on GitHub (Feb 15, 2021):
@abitrolly It was previously not possible to shift list items horizontally. This is now implemented with the latest version. There are now
SetOffset()andGetOffset()functions but I'm not sure if you need them because I also extended the function of the left and right arrow keys. Before hitting the right arrow key selects the next item (as it was before), it will shift the list to the left if it doesn't fit its box.If this doesn't work as expected, please open a new issue so I don't miss it.