Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

next_page tabular tui did not know about COLUMNS AND LINES #693

Merged
merged 2 commits into from
Aug 8, 2023

Conversation

calbrecht
Copy link
Contributor

It seems like fzf does not pass those env variables when invoking reload(...) shells. That leads to messing up the tabular layout when in terminal and triggering a reload because then the default values 80 and 25 are assigned, which is different (in my case) from the actual available columns and lines.

Pass TTY_COLS and TTY_LINES to the env in reload(...) invocations of ytfzf and fallback to those values when defining from COLUMNS and LINES.

Introduce private functions _init_video_info_text and _post_video_info_text to be consistent in all invocations of reload(...) shells.

_init_video_info_text is passed TTY_COLS as first param to account for difference between interface_text and interface_ext.

now pass them into environment as TTY_COLS and TTY_LINES and let the
definition of COLUMNS and LINES fallback on those.
Introduce _init_video_info_text that sets the vars for tabular
formatting before video_in_text and _post_video_info_text that uses
column (if available) to format lines.
@Euro20179 Euro20179 merged commit 1fa3176 into pystardust:development Aug 8, 2023
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants