[kitty] added gruvbox

This commit is contained in:
Afonso Franco 2024-07-31 14:22:19 +01:00
parent 7a7ef568e9
commit 77de585888
Signed by: afonso
SSH key fingerprint: SHA256:PQTRDHPH3yALEGtHXnXBp3Orfcn21pK20t0tS1kHg54
7 changed files with 153 additions and 166 deletions

View file

@ -1,80 +1,49 @@
# vim:ft=kitty
# gruvbox dark by morhetz, https://github.com/morhetz/gruvbox
# This work is licensed under the terms of the MIT license.
# For a copy, see https://opensource.org/licenses/MIT.
## name: Catppuccin-Frappe
## author: Pocco81 (https://github.com/Pocco81)
## license: MIT
## upstream: https://github.com/catppuccin/kitty/blob/main/frappe.conf
## blurb: Soothing pastel theme for the high-spirited!
background #1d2021
foreground #d4be98
cursor #928374
selection_foreground #928374
selection_background #3c3836
# The basic colors
foreground #C6D0F5
background #303446
selection_foreground #303446
selection_background #F2D5CF
# Cursor colors
cursor #F2D5CF
cursor_text_color #303446
# URL underline color when hovering with mouse
url_color #F2D5CF
# Kitty window border colors
active_border_color #BABBF1
inactive_border_color #737994
bell_border_color #E5C890
# OS Window titlebar colors
wayland_titlebar_color system
macos_titlebar_color system
# Tab bar colors
active_tab_foreground #232634
active_tab_background #CA9EE6
inactive_tab_foreground #C6D0F5
inactive_tab_background #292C3C
tab_bar_background #232634
# Colors for marks (marked text in the terminal)
mark1_foreground #303446
mark1_background #BABBF1
mark2_foreground #303446
mark2_background #CA9EE6
mark3_foreground #303446
mark3_background #85C1DC
# The 16 terminal colors
# black
color0 #51576D
color8 #626880
color0 #282828
color8 #928374
# red
color1 #E78284
color9 #E78284
color1 #cc241d
# light red
color9 #fb4934
# green
color2 #A6D189
color10 #A6D189
color2 #98971a
# light green
color10 #b8bb26
# yellow
color3 #E5C890
color11 #E5C890
color3 #d79921
# light yellow
color11 #fabd2d
# blue
color4 #8CAAEE
color12 #8CAAEE
color4 #458588
# light blue
color12 #83a598
# magenta
color5 #F4B8E4
color13 #F4B8E4
color5 #b16286
# light magenta
color13 #d3869b
# cyan
color6 #81C8BE
color14 #81C8BE
color6 #689d6a
# lighy cyan
color14 #8ec07c
# white
color7 #B5BFE2
color15 #A5ADCE
# light gray
color7 #a89984
# dark gray
color15 #928374

View file

@ -1,25 +1,21 @@
font_family FiraCode Nerd Font Mono Regular
font_size 16.0
# Font handling
font_family JetBrainsMono Nerd Font Mono Light
font_size 16.0
#Remove annoying things
enable_audio_bell no
window_padding_width 6
confirm_os_window_close 0
# Set TERM env
env TERM=xterm-256color
# Macos stuff
macos_option_as_alt yes
background_opacity 0.90
hide_window_decorations no
#Project management
#map ctrl+space launch --type=overlay fish -ic "kitty @ ls | jq -r '.[0].tabs | map(.title) | .[]' | fzf | xargs -I _ kitty @ focus-tab --match title:_"
include current-theme.conf
# Make it borderless
hide_window_decorations yes
# BEGIN_KITTY_THEME
# Catppuccin-Frappe
# Gruvbox Dark
include current-theme.conf
# END_KITTY_THEME

View file

@ -1,42 +1,21 @@
font_family FiraCode Nerd Font Mono Normal
font_size 14.0
# Font handling
font_family JetBrainsMono Nerd Font Mono Light
font_size 16.0
#Remove annoying things
enable_audio_bell no
window_padding_width 6
confirm_os_window_close 0
# Set TERM env
env TERM=xterm-256color
# Macos stuff
macos_option_as_alt yes
# Multiplexer mappings
#map ctrl+u kitten pass_keys.py neighboring_window bottom ctrl+u
#map ctrl+i kitten pass_keys.py neighboring_window top ctrl+i
#map ctrl+y kitten pass_keys.py neighboring_window left ctrl+y
#map ctrl+o kitten pass_keys.py neighboring_window right ctrl+o
#
#map ctrl+shift+w no_op
#map ctrl+x close_window
#map ctrl+shift+x close_tab
#
#map ctrl+shift+enter no_op
#map ctrl+n new_window
#map ctrl+shift+n new_tab
#
#map ctrl+f toggle_layout stack
#
# Remote control
#allow_remote_control yes
#listen-on unix:@"$(date +%s%N)"
#Project management
#map ctrl+space launch --type=overlay fish -ic "kitty @ ls | jq -r '.[0].tabs | map(.title) | .[]' | fzf | xargs -I _ kitty @ focus-tab --match title:_"
include current-theme.conf
# Make it borderless
hide_window_decorations yes
# BEGIN_KITTY_THEME
# Catppuccin-Latte
# Gruvbox Light
include current-theme.conf
# END_KITTY_THEME
# END_KITTY_THEME

View file

@ -1,9 +0,0 @@
def main():
pass
def handle_result(args, result, target_window_id, boss):
boss.active_tab.neighboring_window(args[1])
handle_result.no_ui = True

View file

@ -1,46 +0,0 @@
import re
from kittens.tui.handler import result_handler
from kitty.key_encoding import KeyEvent, parse_shortcut
def is_window_vim(window, vim_id):
fp = window.child.foreground_processes
return any(re.search(vim_id, p['cmdline'][0] if len(p['cmdline']) else '', re.I) for p in fp)
def encode_key_mapping(window, key_mapping):
mods, key = parse_shortcut(key_mapping)
event = KeyEvent(
mods=mods,
key=key,
shift=bool(mods & 1),
alt=bool(mods & 2),
ctrl=bool(mods & 4),
super=bool(mods & 8),
hyper=bool(mods & 16),
meta=bool(mods & 32),
).as_window_system_event()
return window.encoded_key(event)
def main():
pass
@result_handler(no_ui=True)
def handle_result(args, result, target_window_id, boss):
window = boss.window_id_map.get(target_window_id)
direction = args[2]
key_mapping = args[3]
vim_id = args[4] if len(args) > 4 else "n?vim"
if window is None:
return
if is_window_vim(window, vim_id):
for keymap in key_mapping.split(">"):
encoded = encode_key_mapping(window, keymap)
window.write_to_child(encoded)
else:
boss.active_tab.neighboring_window(direction)

View file

@ -0,0 +1,49 @@
# gruvbox dark by morhetz, https://github.com/morhetz/gruvbox
# This work is licensed under the terms of the MIT license.
# For a copy, see https://opensource.org/licenses/MIT.
background #1d2021
foreground #d4be98
cursor #928374
selection_foreground #928374
selection_background #3c3836
color0 #282828
color8 #928374
# red
color1 #cc241d
# light red
color9 #fb4934
# green
color2 #98971a
# light green
color10 #b8bb26
# yellow
color3 #d79921
# light yellow
color11 #fabd2d
# blue
color4 #458588
# light blue
color12 #83a598
# magenta
color5 #b16286
# light magenta
color13 #d3869b
# cyan
color6 #689d6a
# lighy cyan
color14 #8ec07c
# light gray
color7 #a89984
# dark gray
color15 #928374

View file

@ -0,0 +1,49 @@
# gruvbox light by morhetz, https://github.com/morhetz/gruvbox
# This work is licensed under the terms of the MIT license.
# For a copy, see https://opensource.org/licenses/MIT.
background #fbf1c7
foreground #3c3836
cursor #928374
selection_foreground #3c3836
selection_background #928374
color0 #fbf1c7
color8 #282828
# red
color1 #cc241d
# light red
color9 #9d0006
# green
color2 #98971a
# light green
color10 #79740e
# yellow
color3 #d79921
# light yellow
color11 #b57614
# blue
color4 #458588
# light blue
color12 #076678
# magenta
color5 #b16286
# light magenta
color13 #8f3f71
# cyan
color6 #689d6a
# lighy cyan
color14 #427b58
# light gray
color7 #7c6f64
# dark gray
color15 #928374