From 5fbcd20084b35145b02b51de6e8d35d2e72c4d14 Mon Sep 17 00:00:00 2001 From: lanxu Date: Thu, 26 Apr 2018 21:53:31 +0300 Subject: [PATCH] Fixed awesome configuration so that there is only one screen with important widgets --- .Xresources | 29 +++++++++-------- .config/awesome/rc.lua | 65 +++++++++++++++++++++---------------- .config/awesome/widgets.lua | 2 +- .zshrc | 2 +- 4 files changed, 54 insertions(+), 44 deletions(-) diff --git a/.Xresources b/.Xresources index aeab502..b264a49 100644 --- a/.Xresources +++ b/.Xresources @@ -11,12 +11,12 @@ Xft.rgba: rgb ! rxvt-unicode URxvt.perl-ext-common: default,matcher,clipboard -URxvt*font: xft:Noto Emoji,xft:Fura Code Nerd Font:size=10:style=Regular -URxvt*boldFont: xft:Noto Emoji,xft:Fura Code Nerd Font:size=10:style=Bold +!URxvt*font: xft:xft:Fura Code Nerd Font:size=10:style=Regular +!URxvt*boldFont: xft:xft:Fura Code Nerd Font:size=10:style=Bold !URxvt.font: xft:Fira Code:size=10:style=Regular !URxvt.boldFont: xft:Fira Code:size=10:style=Bold -!URxvt.font: xft:DejaVu Sans Mono:size=10:style=Regular -!URxvt.boldFont: xft:DejaVu Sans Mono:size=10:style=Bold +URxvt.font: xft:DejaVu Sans Mono:size=10:style=Regular +URxvt.boldFont: xft:DejaVu Sans Mono:size=10:style=Bold URxvt.url-launcher: firefox URxvt.matcher.button: 1 URxvt*scrollBar: false @@ -26,15 +26,16 @@ URxvt.letterSpace: 0 URxvt.keysym.M-c: perl:clipboard:copy URxvt.keysym.M-v: perl:clipboard:paste URxvt.keysym.M-C-v: perl:clipboard:paste_escaped -URxvt.iso14755: false -URxvt.iso14755_52: false -URxvt*termName: rxvt-unicode-256color +URxvt.iso14755: false +URxvt.iso14755_52: false +URxvt*termName: rxvt-unicode-256color ! xterm -XTerm.vt100.faceName: xft:Fura Code Nerd Font:style=Regular -!XTerm*faceName: xft:DejaVu Sans Mono:size=10:style=Regular -!XTerm*faceName: xft:Fira Code:size=10:style=Regular -XTerm.vt100.faceSize: 10 -XTerm.scaleHeight: 1.0 -XTerm*renderFont: true -XTerm.termName: xterm-256color +!XTerm.vt100.faceName: xft:Fura Code Nerd Font:style=Regular +XTerm*faceName: xft:DejaVu Sans Mono:size=10:style=Regular +!XTerm*faceName: xft:Bitstream Vera Sans Mono:size=10:style=Regular +!XTerm*faceName: xft:Fira Code:size=10:style=Regular +!xterm*faceName: xft:Bitstream Vera Sans Mono:size=10:style=Regular +xterm.vt100.faceSize: 10 +xterm*renderFont: true +xterm.termName: xterm diff --git a/.config/awesome/rc.lua b/.config/awesome/rc.lua index 2605b9b..617ae26 100644 --- a/.config/awesome/rc.lua +++ b/.config/awesome/rc.lua @@ -199,7 +199,7 @@ screen.connect_signal("property::geometry", set_wallpaper) -- Tags -- Define a tag table which hold all screen tags. primary_screen = 1 -secondary_screen = awful.screen.count +secondary_screen = screen:count() tags = { names = { @@ -245,6 +245,39 @@ awful.screen.connect_for_each_screen(function(s) -- Create the wibox s.mywibox = awful.wibar({ position = "top", screen = s }) + local right_widgets = { + layout = wibox.layout.fixed.horizontal, + --mykeyboardlayout, + wibox.widget.systray(), + spacer, + myserverstatus, + spacer, + volume, + spacer, + mydpmsstatus, + spacer, + mycpu, + spacer, + mymem, + spacer, + myweather, + spacer, + mycputemp, + spacer, + mygputemp, + spacer, + mytextclock, + spacer, + s.mylayoutbox, + } + -- Only show everything on the first screen + if s.index > 1 then + right_widgets = { + layout = wibox.layout.fixed.horizontal, + s.mylayoutbox, + } + end + -- Add widgets to the wibox s.mywibox:setup { layout = wibox.layout.align.horizontal, @@ -255,31 +288,7 @@ awful.screen.connect_for_each_screen(function(s) s.mypromptbox, }, s.mytasklist, -- Middle widget - { -- Right widgets - layout = wibox.layout.fixed.horizontal, - --mykeyboardlayout, - wibox.widget.systray(), - spacer, - myserverstatus, - spacer, - volume, - spacer, - mydpmsstatus, - spacer, - mycpu, - spacer, - mymem, - spacer, - myweather, - spacer, - mycputemp, - spacer, - mygputemp, - spacer, - mytextclock, - spacer, - s.mylayoutbox, - }, + right_widgets, } end) -- }}} @@ -583,10 +592,10 @@ awful.rules.rules = { properties = { screen = primary_screen, tag = "GFX" } }, { rule = { class = "Blender" }, properties = { screen = primary_screen, tag = "GFX" } }, - { rule = { class = "Steam" }, - properties = { screen = secondary_screen, tag = "Other" } }, { rule = { class = "Steam", name = "Friends" }, properties = { screen = secondary_screen, tag = "Other", width = 200 } }, + { rule = { class = "Steam" }, + properties = { screen = secondary_screen, tag = "Other" } }, } -- }}} diff --git a/.config/awesome/widgets.lua b/.config/awesome/widgets.lua index b655b20..88c77f4 100644 --- a/.config/awesome/widgets.lua +++ b/.config/awesome/widgets.lua @@ -85,7 +85,7 @@ myweather = lain.widget.weather({ settings = function() widget.markup = create_markup("Tampere", weather_now.main.temp, "℃", valuecolor) end -}); +}) -- DPMS mydpmsstatus = wibox.widget.textbox() diff --git a/.zshrc b/.zshrc index dfea7ac..c728302 100644 --- a/.zshrc +++ b/.zshrc @@ -60,6 +60,6 @@ source $HOME/.config/base16-shell/scripts/base16-default-dark.sh # Emscripten #source /home/lanxu/Koodit/github/emsdk/emsdk_env.sh -TERM=xterm-256color +# TERM=xterm-256color #bindkey "${terminfo[khome]}" beginning-of-line #bindkey "${terminfo[kend]}" end-of-line