From 7ce052b1db5be77799fc1e59308753f81b20fbb7 Mon Sep 17 00:00:00 2001 From: Ian Mancini Date: Mon, 6 Sep 2021 16:41:28 -0300 Subject: [PATCH] Add jpbar, fix fnm, add japanese typography --- appearances/emojibar.toml | 14 +++++++-- appearances/jp.toml | 27 ++++++++++++++++ filesets/base/environment/.envrc | 2 +- filesets/base/polybar/.config/polybar/config | 33 ++++++++++---------- typographies/base.toml | 4 +++ 5 files changed, 61 insertions(+), 19 deletions(-) create mode 100644 appearances/jp.toml diff --git a/appearances/emojibar.toml b/appearances/emojibar.toml index 766a024..0a66062 100644 --- a/appearances/emojibar.toml +++ b/appearances/emojibar.toml @@ -4,7 +4,7 @@ extends = "base" [custom.polybar] modules_left = "i3" modules_center = "" -modules_right = "eth wifi cpu memory volume batteryemoji time date xkeyboard" +modules_right = "cpu memory time date xkeyboard" text_offset = "2" icon_font_scale ="8" antialias = "true" @@ -25,4 +25,14 @@ layout_icon = "⌨️" charging_icon = "🔋⬆️" full_charge_icon = "🔋" discharging_icon = "🔋⬇️" - +ws0_icon = "home" +ws1_icon = "web" +ws2_icon = "vim" +ws3_icon = "chat" +ws4_icon = "music" +ws5_icon = "design" +ws6_icon = "seven" +ws7_icon = "eight" +ws8_icon = "games" +ws9_icon = "random" +ws_icon = "?" # default diff --git a/appearances/jp.toml b/appearances/jp.toml new file mode 100644 index 0000000..6482800 --- /dev/null +++ b/appearances/jp.toml @@ -0,0 +1,27 @@ +name = "Base with japanese themed Polybar" +extends = "base" + +[custom.polybar] +modules_left = "i3" +modules_center = "time date" +modules_right = "cpu memory xkeyboard" +text_offset = "2" +icon_font_scale ="8" +antialias = "true" +bottom = "false" +height = "32" +i3_label = "%icon%" +cpu_icon = "CPU:" +ram_icon = "RAM:" +layout_icon = "KEY:" +ws0_icon = "一" +ws1_icon = "二" +ws2_icon = "三" +ws3_icon = "四" +ws4_icon = "五" +ws5_icon = "六" +ws6_icon = "七" +ws7_icon = "八" +ws8_icon = "九" +ws9_icon = "十" +ws_icon = "〇" # default diff --git a/filesets/base/environment/.envrc b/filesets/base/environment/.envrc index f5e2b58..107c62b 100644 --- a/filesets/base/environment/.envrc +++ b/filesets/base/environment/.envrc @@ -30,7 +30,7 @@ export FZF_CTRL_T_COMMAND="$FZF_DEFAULT_COMMAND" # fnm export PATH=/home/ianmethyst/.fnm:$PATH -eval "`fnm env --multi`" +eval "`fnm env`" # Python diff --git a/filesets/base/polybar/.config/polybar/config b/filesets/base/polybar/.config/polybar/config index 393c47c..0df03c3 100755 --- a/filesets/base/polybar/.config/polybar/config +++ b/filesets/base/polybar/.config/polybar/config @@ -30,16 +30,17 @@ border-top-size = 0 font-0 = {{typography.mono.font}}:style={{typography.mono.weight}}:size={{typography.mono.size}}:{{appearance.polybar.antialias}};{{appearance.polybar.text_offset}} font-1 = {{typography.emoji.font}}:size={{typography.emoji.size}}:scale={{appearance.polybar.icon_font_scale}}:{{appearance.polybar.antialias}};{{appearance.polybar.text_offset}} +font-2 = {{typography.japanese.font}}:size={{typography.japanese.size}}:{{appearance.polybar.antialias}};{{appearance.polybar.text_offset}} modules-left = {{appearance.polybar.modules_left}} modules-center = {{appearance.polybar.modules_center}} modules-right = {{appearance.polybar.modules_right}} -tray-position = -tray-background = ${colors.background-alt} -tray-padding = 2 +tray-position = "right" +tray-background = ${colors.background} +tray-padding = 0 tray-maxsize = 18 -tray-detached = true -tray-offset-x = -4 +tray-detached = false +tray-offset-x = 0 [module/empty] type = custom/script @@ -94,17 +95,17 @@ label-visible = {{appearance.polybar.i3_label}} label-visible-padding= 1 label-visible-foreground = ${colors.purple} -ws-icon-0 = 1;home -ws-icon-1 = 2;web -ws-icon-2 = 3;vim -ws-icon-3 = 4;chat -ws-icon-4 = 5;music -ws-icon-5 = 6;design -ws-icon-6 = 7;seven -ws-icon-7 = 8;eight -ws-icon-8 = 9;games -ws-icon-9 = 10;random -ws-icon-default = ? +ws-icon-0 = 1;{{appearance.polybar.ws0_icon}} +ws-icon-1 = 2;{{appearance.polybar.ws1_icon}} +ws-icon-2 = 3;{{appearance.polybar.ws2_icon}} +ws-icon-3 = 4;{{appearance.polybar.ws3_icon}} +ws-icon-4 = 5;{{appearance.polybar.ws4_icon}} +ws-icon-5 = 6;{{appearance.polybar.ws5_icon}} +ws-icon-6 = 7;{{appearance.polybar.ws6_icon}} +ws-icon-7 = 8;{{appearance.polybar.ws7_icon}} +ws-icon-8 = 9;{{appearance.polybar.ws8_icon}} +ws-icon-9 = 10;{{appearance.polybar.ws9_icon}} +ws-icon-default = {{appearance.polybar.ws_icon}} [module/wifi] type = internal/network diff --git a/typographies/base.toml b/typographies/base.toml index 4da258e..3bda36b 100644 --- a/typographies/base.toml +++ b/typographies/base.toml @@ -26,6 +26,10 @@ italic = "Italic" bold_italic = "Bold Italic" size = 14 +[custom.japanese] +font = "Source Han Sans JP" +size = 14 + [custom.emoji] font = "Noto Color Emoji" size = 14