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

TBD: Status-left/right priority + Recommended Nerd Font #10

Open
IdoEsports opened this issue Jul 15, 2023 · 17 comments
Open

TBD: Status-left/right priority + Recommended Nerd Font #10

IdoEsports opened this issue Jul 15, 2023 · 17 comments
Labels
documentation Improvements or additions to documentation help wanted Extra attention is needed

Comments

@IdoEsports
Copy link

Hey, what is the recommended nerd font here? I've tried and applied a few like FiraCode and CaskaydiaCove but wasn't able to replicate the icons that were shown in the screenshots.

Good work guys and would love a reply.
Screenshot 2023-07-16 at 2 08 40 AM

@mrs4ndman
Copy link
Member

The font used in the screenshots is JetBrains Mono, from the nerdfonts.com website.

What icons are you trying to replicate?

@IdoEsports
Copy link
Author

The font used in the screenshots is JetBrains Mono, from the nerdfonts.com website.

What icons are you trying to replicate?

I figured it out, I simply had to replace the separators with the icons I wanted.

But while I have you here, what is the best way to deal with clunky status bar when the window is shrunk.

So basically, is there a way to configure the responsiveness behavior of the status bar so that the window tabs are prioritized over everything else.

Fullscreen
Screenshot 2023-07-16 at 11 41 57 PM

smaller window split(notice how the windows don't show up but the rest of the information does. Is there a way to flip this behavior?)
Screenshot 2023-07-16 at 11 42 23 PM

@mrs4ndman
Copy link
Member

I can make it so that, from a certain number of windows onwards, the elements on the rigth disappear / are hidden. I might take the time to implement it as a user feature. Thanks for the suggestion, just give me a bit of time

@IdoEsports
Copy link
Author

I can make it so that, from a certain number of windows onwards, the elements on the rigth disappear / are hidden. I might take the time to implement it as a user feature. Thanks for the suggestion, just give me a bit of time

Yea that's perfect. i'm looking forward to it.

@mrs4ndman
Copy link
Member

mrs4ndman commented Jul 16, 2023

I have been doing some testing, and it is impossible to make it dynamic without the user needing to refresh the settings with Prefix + I (reloading the tmux.conf file)

I don't know if this will satisfy your needs:

set -g @rose_pine_prioritize_windows 'on'
# A setting to toggle the 2 following conditions
set -g @rose_pine_width_to_hide '80'
# If tmux's terminal size is less that '80' (or the number you choose), cut the status bar to only the directory.
set -g @rose_pine_window_count '5'
# If there are more than 5 (or the number you choose) windows open on the session, cut the status bar to only the directory

It is very complicated to make it dynamically update on the component space, as the tmux API and exposed functions don't provide a way to do so.
Can look into letting you / the user choose what components appear in the "cut" / shorter state
Edit: These features are not currently implemented, I am testing them right now

@IdoEsports
Copy link
Author

the options you listed above could be pretty nice to have but let me give you a new perspective on this.

if we were to assume the right side elements are the preferred ones, right now we have ideal case. When the terminal size shrinks, the only thing that shows up are those elements.

I don't know what is happening with the window tabs when the terminal shrinks, whether they are being disabled or hidden. But if you were to reverse this behavior and allow window tabs to be shown instead, I believe that would be saner defaults.

I'm not sure if changing old code could be viable but that's my take on it.

@mrs4ndman
Copy link
Member

mrs4ndman commented Jul 17, 2023

I have searched through every StackOverflow and GitHub issue related with the tmux status-bar styling, and haven't found the setting to turn it around. I really want it, but I haven't found it after researching for hours. My best effort are the 2 options I showed you before + New settings to toggle the user + directory settings.

Do let me know if you find it, I am currently preparing the code and the readme.md for the new options

EDIT: Implemented in this commit

@mrs4ndman
Copy link
Member

Is it OK if I edit the name of the issue to add the note about the status-left / right priority? I am going to pin it in the issues section

@IdoEsports
Copy link
Author

yea sure, that works perfectly. Good work btw, looking forward to the feature implementation.

@mrs4ndman mrs4ndman changed the title Recommended Nerd Font TBD: Status-left/right priority+ Recommended Nerd Font Jul 18, 2023
@mrs4ndman mrs4ndman pinned this issue Jul 18, 2023
@mrs4ndman
Copy link
Member

mrs4ndman commented Jul 18, 2023

yea sure, that works perfectly. Good work btw, looking forward to the feature implementation.

For the priority one I will open when I have time a good PR / detailed issue to upstream.

My best effort are the 2 options I showed you before + New settings to toggle the user + directory settings.
I am currently preparing the code and the readme.md for the new options

EDIT: Implemented in this commit

This one is already done, update the plugin and add the new configuration (instructions in the readme) to use it

@mrs4ndman mrs4ndman changed the title TBD: Status-left/right priority+ Recommended Nerd Font TBD: Status-left/right priority + Recommended Nerd Font Jul 18, 2023
@IdoEsports
Copy link
Author

Wow you work fast, that's for sure. I just tried the new features out and a few things.

Problem #1: Atleast for me, my most common usecase of the status bar is to keep track of the windows. when prioritize_windows is 'on' i think the status bar should consist of nothing but the windows.

Suggestion: when prioritize_windows is enabled, remove everything except the windows from the status bar including the directory name, current window(this already feels a little redundant since the current window is already highlighted), and maybe even session name.
All this information looks nice in fullscreen statusline so leave that be.

Problem #2(Not really a problem but a bug): This is regarding the new implemented 'window_status_separator'. For some reason, the separators between the 0 and 1 window is still the same blue arrow but the rest of the separators have changed to what i set. Look at the screenshot.

Screenshot 2023-07-19 at 12 27 20 AM

@mrs4ndman
Copy link
Member

mrs4ndman commented Jul 18, 2023

Wow you work fast, that's for sure. I just tried the new features out and a few things.

The codebase is small, and now in summer I have more free time to code :D
On the first one: I can add a "hyper-focused" only windows setting

On the second one: I just tested changing to >, and I didn't get the bug that you mentioned.
Have you reset tmux completely? Most of tmux's status-bar options require a reset to change them.
Can test it more in-depth, but it might be a one-off. For now, I am adding a commit that makes the separator feature the one that switches between the user-set and the default one (instead of a hard-coded one).

Thanks for the feedback :)

@IdoEsports
Copy link
Author

yea that hyper-focused only setting would be awesome.

On the second one: I just tested changing to >, and I didn't get the bug that you mentioned.
Have you reset tmux completely? Most of tmux's status-bar options require a reset to change them.

Yea you're right, it works properly in a new session but just sourcing it seems to be the cause of the bug. Any suggestions to reset tmux without having to kill the session?

Thanks for the feedback :)

Thanks to you lol

@mrs4ndman
Copy link
Member

Yea you're right, it works properly in a new session but just sourcing it seems to be the cause of the bug. Any suggestions to reset tmux without having to kill the session?

I will look into this tomorrow, but it is really weird. Will also try to get the hyper-focused feature for this week ;)

@IdoEsports
Copy link
Author

that works. Thanks again.

@mrs4ndman
Copy link
Member

Hyper-focus feature implemented on this commit: d588e25
The readme has the option syntax and explanation ;)

@IdoEsports
Copy link
Author

very nice. It works perfectly as i imagined. The only thing now would be instead of making 'only-windows' a separate option i would prefer it to be the default behavior of 'prioritize_windows' option when either one of the conditions are met(too many windows or too little screen).

An alternative would be to make 'prioritize_windows' poly-valued instead of a simple on or off, include 'only-windows' as another value for prioritize_windows.

Also thank you again, good work.

@mrs4ndman mrs4ndman added documentation Improvements or additions to documentation help wanted Extra attention is needed labels Jul 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants