Browse Source

color config

systemd-xsession
parent
commit
827c3ee306
5 changed files with 18 additions and 36 deletions
  1. +1
    -0
      .gitignore
  2. +1
    -0
      defaults/main.yaml
  3. +12
    -0
      filter_plugins/colors.py
  4. +2
    -24
      templates/i3/i3.config.j2
  5. +2
    -12
      templates/rofi/rofi.theme.j2

+ 1
- 0
.gitignore View File

@@ -0,0 +1 @@
__pycache__

+ 1
- 0
defaults/main.yaml View File

@@ -1,4 +1,5 @@
---
home_base_color_hue: 219
home_xft_dpi: 96
home_copy_pulseaudio_cookie: false
home_desktop: false


+ 12
- 0
filter_plugins/colors.py View File

@@ -0,0 +1,12 @@
#!/usr/bin/python

import colorsys

class FilterModule(object):
def filters(self):
return {'hsv2rgb': self.hsv2rgb}

def hsv2rgb(self, hue, saturation, value):
rgb = colorsys.hsv_to_rgb(hue/360., saturation/100., value/100.)
rgb = tuple(map(lambda x: round(x*255), rgb))
return '#%02x%02x%02x' % rgb

+ 2
- 24
templates/i3/i3.config.j2 View File

@@ -351,18 +351,7 @@ bar {
separator #666666

# <colorclass> <border> <background> <text>
{% if home_profile == "desktop" %}
# lila: Farbton 274
focused_workspace #774C99 #552877 #ffffff
{% endif %}
{% if home_profile == "vdesk" %}
# grün: Farbton 110
focused_workspace #4D994C #357728 #ffffff
{% endif %}
{% if home_profile == "presentation" %}
# gelb: Farbton 60
focused_workspace #99994C #777728 #ffffff
{% endif %}
focused_workspace {{home_base_color_hue|hsv2rgb(50,60)}} {{home_base_color_hue|hsv2rgb(66,47)}} #ffffff
active_workspace #333333 #696969 #ffffff
inactive_workspace #333333 #222222 #888888
urgent_workspace #2f343a #900000 #ffffff
@@ -375,18 +364,7 @@ bar {
### Design

# class border backgr. text indicator child_border
{% if home_profile == "desktop" %}
# lila: Farbton 274
client.focused #784C99 #552877 #ffffff #9E2EF4 #552877
{% endif %}
{% if home_profile == "vdesk" %}
# grün: Farbton 110
client.focused #59994C #357728 #ffffff #4FF42E #357728
{% endif %}
{% if home_profile == "presentation" %}
# gelb: Farbton 60
client.focused #99994C #777728 #ffffff #F4F42E #777728
{% endif %}
client.focused {{home_base_color_hue|hsv2rgb(50,60)}} {{home_base_color_hue|hsv2rgb(66,47)}} #ffffff {{home_base_color_hue|hsv2rgb(81,91)}} {{home_base_color_hue|hsv2rgb(66,47)}}
client.focused_inactive #333333 #6A6A6A #ffffff #505050 #6A6A6A
client.unfocused #333333 #222222 #888888 #2E2E2E #222222
client.urgent #2f343a #900000 #ffffff #900000 #900000


+ 2
- 12
templates/rofi/rofi.theme.j2 View File

@@ -24,18 +24,8 @@
active-background: #6A6A6A;

selected-urgent-background: #2f343a;
{% if home_profile == "desktop" %}
selected-normal-background: #552877;
selected-active-background: #784C99;
{% endif %}
{% if home_profile == "vdesk" %}
selected-normal-background: #357728;
selected-active-background: #59994C;
{% endif %}
{% if home_profile == "presentation" %}
selected-normal-background: #99994C;
selected-active-background: #777728;
{% endif %}
selected-normal-background: {{home_base_color_hue|hsv2rgb(66,47)}};
selected-active-background: {{home_base_color_hue|hsv2rgb(50,60)}};

spacing: 2;