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

What's the correct way to handle SIGWINCH #99

Open
amosbird opened this issue Dec 10, 2020 · 10 comments
Open

What's the correct way to handle SIGWINCH #99

amosbird opened this issue Dec 10, 2020 · 10 comments

Comments

@amosbird
Copy link
Contributor

When terminal gets resized, clickhouse-client (an replxx application) fails to render the display correctly unless it resets the current replxx-state. I wonder if there is any example I can refer to.

@AmokHuginnsson
Copy link
Owner

Does afb020a improve your experience?

@amosbird
Copy link
Contributor Author

Does afb020a improve your experience?

Unfortunately nope. Nothing changed.

@AmokHuginnsson
Copy link
Owner

Do you call install_window_change_handler() in the client in the beginning?

@amosbird
Copy link
Contributor Author

amosbird commented Dec 11, 2020

install_window_change_handler() That works!

There is one tiny issue left. After resizing, syntax highlighting gets lost. I have to input some actions such as moving cursors around to get it back.

edit

Just found another issue. When doing terminal shrink, replxx rerenders current line but somehow in a new line, with one line duplicated. Here is the screencast describing the issue http://oracle.wentropy.com/b5decbe52268770c

@AmokHuginnsson
Copy link
Owner

AmokHuginnsson commented Dec 11, 2020

Current master should fix color issue.
But I haven't read your edit before I started working on syntax highlighting.

@amosbird
Copy link
Contributor Author

amosbird commented Dec 11, 2020

Current master should fix color issue.

Awesome

But I haven't read your edit before I started working on syntax highlighting.

That just means you're super productive :)

@AmokHuginnsson
Copy link
Owner

I can reproduce duplicated line issue only in tmux, raw terminals do not show this problem.

@amosbird
Copy link
Contributor Author

I can reproduce duplicated line issue only in tmux, raw terminals do not show this problem.

Hmm, what does that imply? I thought tmux should obey the terminal standard.

@AmokHuginnsson
Copy link
Owner

Hmm, what does that imply? I thought tmux should obey the terminal standard.

I do not know yet.

@AmokHuginnsson
Copy link
Owner

AmokHuginnsson commented Dec 12, 2020

Ok, most terminals express this behavior (also GNU screen), the only unaffected terminals I found are xterm and rxvt derivatives (running without any terminal multiplexer).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants