Tmux: A bit more styling.

This commit is contained in:
Dmitry Voronin 2024-11-22 06:27:57 +03:00
parent 211936e7b0
commit a2d1a3af88
Signed by: voronind
SSH key fingerprint: SHA256:3kBb4iV2ahufEBNq+vFbUe4QYfHt98DHQjN7QaptY9k
4 changed files with 37 additions and 30 deletions

View file

@ -1,17 +1,9 @@
{
config,
...
}: let
fg = config.module.style.color.fg.dark;
selection = config.module.style.color.selection;
in {
{ ... }: {
text = ''
setw -g mode-keys vi
bind -n M-v copy-mode
bind -n M-p choose-buffer;
bind -T copy-mode-vi v send -X begin-selection
bind -T copy-mode-vi y send-keys -X copy-pipe-and-cancel "pbcopy"
set -g mode-style "fg=#${fg} bg=#${selection} bold"
'';
}

View file

@ -1,10 +1,4 @@
{
config,
...
}: let
accent = config.module.style.color.accent;
bg = config.module.style.color.bg.regular;
{ ... }: let
stepHorizontal = 1;
stepVertical = 1;
in {
@ -33,8 +27,5 @@ in {
bind -n M-c kill-pane
bind -n M-C kill-pane -a
set -g pane-border-style "fg=#${bg}"
set -g pane-active-border-style "fg=#${accent}"
'';
}

View file

@ -1,26 +1,16 @@
{
config,
...
}: let
accent = config.module.style.color.accent;
fg = config.module.style.color.fg.light;
in {
{ ... }: {
text = ''
bind-key -n M-f set-option -g status;
set -g status-left-length 50
set -g status-position bottom
set -g status-justify left
set -g status-style "fg=#${fg}"
set -g status-left "#[bold] #H-#S #[default]"
set -g status-right ""
set-window-option -g window-status-separator ""
setw -g window-status-current-style "fg=#${accent} bold"
setw -g window-status-current-format " #W "
setw -g window-status-style ""
setw -g window-status-format " #W "
set-window-option -g visual-bell off

View file

@ -0,0 +1,34 @@
{
config,
...
}: let
accent = config.module.style.color.accent;
bg = config.module.style.color.bg.regular;
fg = config.module.style.color.fg.light;
selectionBg = config.module.style.color.selection;
selectionFg = config.module.style.color.fg.dark;
in {
# ISSUE: No way to specify `choose` mode style.
# SEE: https://github.com/tmux/tmux/issues/4264
text = ''
set -g mode-style "fg=#${selectionFg} bg=#${selectionBg} bold"
setw -g window-status-current-style "fg=#${accent} bold"
setw -g window-status-style ""
set -g pane-border-style "fg=#${bg}"
set -g pane-active-border-style "fg=#${accent}"
set -g status-style "fg=#${fg}"
set -g menu-style "fg=#${fg}"
set -g menu-selected-style "fg=#${fg} bg=#${bg} bold"
set -g menu-border-style "fg=#${bg}"
set -g popup-style "fg=#${fg}"
set -g popup-border-style "fg=#${bg}"
set -g display-panes-colour "#${bg}"
set -g display-panes-active-colour "#${accent}"
'';
}