Commit 6f7c0387 authored by phob1an's avatar phob1an 🎧
Browse files

sync

parent fb9fdaea
......@@ -139,7 +139,25 @@ tmp_img = Image.open(wallpaper.rstrip())
tmp_img = tmp_img.resize((512, 512))
tmp_img_path = os.path.expanduser('~/.cullax.png')
tmp_img.save(tmp_img_path)
colors = colorgram.extract(tmp_img_path, 2)
colors = colorgram.extract(tmp_img_path, 3)
#background_hue = colors[0].hsl[0]
#higlight_hsl = colors[0].hsl
#diff = 0
#for i in colors:
#print(i.hsl, i)
##tmp_hue = i.hsl[0]
#if abs(background_hue - i.hsl[0]) > diff:
#contrast_color = i.hsl
#diff = abs(background_hue - i.hsl[0])
#print(contrast_color)
#sys.exit(0)
h,s,l = [ c/255.0 for c in colors[1].hsl ]
hb,sb,lb = [ c/255.0 for c in colors[0].hsl ]
......@@ -148,7 +166,7 @@ hb,sb,lb = [ c/255.0 for c in colors[0].hsl ]
os.remove(tmp_img_path)
print(h,s,l)
#print(h,s,l)
#sys.exit(0)
# Remove hue for b/w images
......@@ -156,12 +174,12 @@ if s < 0.011:
s = 0.0
h = 0.0
l_midlight = (1.0 - l) / 4.0 + l
#l_midlight = (1.0 - l) / 4.0 + l
panel_background = color_triplet(hb, 0.15, sb/6)
button_foreground = color_triplet(h, 0.85, s/3.0)
foreground = color_triplet(h, 0.99, 0.9)
highlight_color = color_triplet(h, 0.84, 1)
button_background = color_triplet(h, 0.55, 0.65)
highlight_color = color_triplet(h, 0.88, 1)
midlight = color_triplet(h, 0.55, 0.58)
print(panel_background)
......@@ -170,7 +188,7 @@ plasma_colors = plasma_colors.replace('aaa', panel_background)
plasma_colors = plasma_colors.replace('bbb', foreground)
plasma_colors = plasma_colors.replace('ddd', highlight_color)
plasma_colors = plasma_colors.replace('eee', button_foreground)
plasma_colors = plasma_colors.replace('fff', button_background)
plasma_colors = plasma_colors.replace('fff', midlight)
try:
with open(os.path.expanduser(
......@@ -179,7 +197,6 @@ try:
except:
sys.exit("Unable to open Culla Plasma colors. Is it installed?")
print("here")
# Call kwriteconfig5 to change Plasma theme
try:
subprocess.run(['kwriteconfig5', '--file=plasmarc',
......@@ -187,7 +204,6 @@ try:
# Do this too quickly and Plasma won't reload
time.sleep(0.6)
print("there")
subprocess.run(['kwriteconfig5', '--file=plasmarc',
'--group=Theme', '--key=name', 'CullaX'])
......
[Colors:Window]
ForegroundNormal=254,252,250
BackgroundNormal=34,41,42
ForegroundNormal=254,250,252
BackgroundNormal=40,36,37
ForegroundNegative=212,84,0
[Colors:Selection]
BackgroundNormal=254,217,173
BackgroundNormal=254,193,221
[Colors:Complimentary]
BackgroundNormal=255,0,0
ForegroundNormal=0,255,0
[Colors:Button]
ForegroundNormal=219,216,214
BackgroundNormal=214,146,65
DecorationFocus=254,217,173
ForegroundNormal=222,211,216
BackgroundNormal=206,73,133
DecorationFocus=254,193,221
DecorationHover=0,255,0
[Colors:View]
ForegroundNormal=254,252,250
ForegroundNormal=254,250,252
BackgroundNormal=128,128,128
DecorationHover=254,217,173
\ No newline at end of file
DecorationHover=254,193,221
\ No newline at end of file
......@@ -59,9 +59,9 @@
inkscape:window-height="480"
id="namedview76"
showgrid="false"
inkscape:zoom="9.8044205"
inkscape:cx="60.073279"
inkscape:cy="13.352682"
inkscape:zoom="13.865544"
inkscape:cx="35.924055"
inkscape:cy="50.571974"
inkscape:current-layer="svg986"
inkscape:pagecheckerboard="true" />
<metadata
......@@ -77,14 +77,14 @@
</rdf:RDF>
</metadata>
<rect
style="fill:#212121;fill-rule:evenodd;fill-opacity:1;opacity:0.5"
style="fill:#3c3c3c;fill-rule:evenodd;fill-opacity:1;opacity:0.4"
height="16"
width="32"
y="14.000025"
x="13"
id="base-center" />
<rect
style="fill:#212121;fill-rule:evenodd;stroke-width:0.89442718;fill-opacity:1;opacity:0.5"
style="fill:#3c3c3c;fill-rule:evenodd;stroke-width:0.89442718;fill-opacity:1;opacity:0.4"
height="4"
width="32"
y="-34.000023"
......@@ -92,7 +92,7 @@
transform="scale(1,-1)"
id="base-bottom" />
<rect
style="fill:#212121;fill-rule:evenodd;stroke-width:0.89442718;fill-opacity:1;opacity:0.5"
style="fill:#3c3c3c;fill-rule:evenodd;stroke-width:0.89442718;fill-opacity:1;opacity:0.4"
height="4"
width="16"
y="-49"
......@@ -100,7 +100,7 @@
transform="matrix(0,-1,-1,0,0,0)"
id="base-right" />
<rect
style="fill:#212121;fill-rule:evenodd;stroke-width:0.89442718;fill-opacity:1;opacity:0.5"
style="fill:#3c3c3c;fill-rule:evenodd;stroke-width:0.89442718;fill-opacity:1;opacity:0.4"
height="4"
width="16"
y="9"
......@@ -108,14 +108,14 @@
transform="rotate(-90)"
id="base-left" />
<rect
style="fill:#212121;fill-rule:evenodd;stroke-width:0.80000001;fill-opacity:1;opacity:0.5"
style="fill:#3c3c3c;fill-rule:evenodd;stroke-width:0.80000001;fill-opacity:1;opacity:0.4"
height="4"
width="4"
y="30.000027"
x="45"
id="base-bottomright" />
<rect
style="fill:#212121;fill-rule:evenodd;stroke-width:0.80000001;fill-opacity:1;opacity:0.5"
style="fill:#3c3c3c;fill-rule:evenodd;stroke-width:0.80000001;fill-opacity:1;opacity:0.4"
height="4"
width="4"
y="30.000027"
......@@ -123,14 +123,14 @@
transform="scale(-1,1)"
id="base-bottomleft" />
<rect
style="fill:#212121;fill-rule:evenodd;stroke-width:0.73029679;fill-opacity:1;opacity:0.5"
style="fill:#3c3c3c;fill-rule:evenodd;stroke-width:0.73029679;fill-opacity:1;opacity:0.4"
height="4"
width="4"
y="10.000025"
x="45"
id="base-topright" />
<rect
style="fill:#212121;fill-rule:evenodd;stroke-width:0.73029679;fill-opacity:1;opacity:0.5"
style="fill:#3c3c3c;fill-rule:evenodd;stroke-width:0.73029679;fill-opacity:1;opacity:0.4"
height="4"
width="4"
y="10.000025"
......@@ -138,37 +138,37 @@
transform="scale(-1,1)"
id="base-topleft" />
<rect
style="fill:#bed4d9;fill-rule:evenodd"
height="4"
style="fill:#bed4d9;fill-rule:evenodd;stroke-width:1.22474492"
height="6"
width="1"
y="1.273357"
y="-0.72664297"
x="7.6630297"
id="base-hint-top-margin" />
<rect
style="fill:#bed4d9;fill-rule:evenodd"
height="4"
style="fill:#bed4d9;fill-rule:evenodd;stroke-width:1.22474492"
height="6"
width="1"
y="39.15942"
y="37.15942"
x="43.855759"
id="base-hint-bottom-margin" />
<rect
style="fill:#bed4d9;fill-rule:evenodd"
height="4"
style="fill:#bed4d9;fill-rule:evenodd;stroke-width:1.22474492"
height="6"
width="1"
y="-6.3648477"
y="-8.3648472"
x="36.140026"
transform="rotate(90)"
id="base-hint-left-margin" />
<rect
style="fill:#bed4d9;fill-rule:evenodd"
height="4"
style="fill:#bed4d9;fill-rule:evenodd;stroke-width:1.22474492"
height="6"
width="1"
y="-58.375759"
y="-60.375759"
x="14.721237"
transform="rotate(90)"
id="base-hint-right-margin" />
<rect
style="fill:#212121;fill-rule:evenodd;fill-opacity:1;opacity:0.6"
style="fill:#3c3c3c;fill-rule:evenodd;fill-opacity:1;opacity:0.3"
height="16"
width="32"
y="49.599998"
......@@ -177,7 +177,7 @@
<g
id="focus-top"
transform="translate(-24.901847,16.550334)"
style="opacity:0.6">
style="opacity:1">
<rect
style="fill:none;fill-opacity:1;fill-rule:evenodd;stroke-width:0.86602539"
height="3"
......@@ -195,24 +195,24 @@
class="ColorScheme-ViewHover" />
</g>
<rect
style="fill:#bed4d9;fill-rule:evenodd;stroke-width:1.41421354"
height="4"
style="fill:#bed4d9;fill-rule:evenodd;stroke-width:1.2247448"
height="3"
width="1"
y="32.952641"
y="33.952641"
x="68.612968"
id="focus-hint-top-margin" />
<rect
style="fill:#bed4d9;fill-rule:evenodd;stroke-width:1.41421354"
height="4"
style="fill:#bed4d9;fill-rule:evenodd;stroke-width:1.2247448"
height="3"
width="1"
y="73.759537"
y="74.759537"
x="102.77831"
id="focus-hint-bottom-margin" />
<rect
style="fill:#bed4d9;fill-rule:evenodd;stroke-width:1.41421354"
height="4"
style="fill:#bed4d9;fill-rule:evenodd;stroke-width:1.2247448"
height="3"
width="1"
y="-111.34263"
y="-110.34263"
x="45.6222"
transform="rotate(90)"
id="focus-hint-right-margin" />
......@@ -223,11 +223,11 @@
y="-14.000025"
width="32"
height="4"
style="fill:#212121;fill-rule:evenodd;stroke-width:0.89442718;fill-opacity:1;opacity:0.5" />
style="fill:#3c3c3c;fill-rule:evenodd;stroke-width:0.89442718;fill-opacity:1;opacity:0.4" />
<g
id="focus-bottom"
transform="matrix(1,0,0,-1,-24.900848,98.631813)"
style="opacity:0.6">
style="opacity:1">
<rect
id="rect863"
x="92.900848"
......@@ -247,7 +247,7 @@
<g
id="focus-right"
transform="matrix(0,0.5,-1,0,133.03632,3.1495285)"
style="opacity:0.6">
style="opacity:1">
<rect
id="rect869"
x="92.900848"
......@@ -267,7 +267,7 @@
<g
transform="matrix(0,0.5,1,0,34.968186,3.1495743)"
id="focus-left"
style="opacity:0.6">
style="opacity:1">
<rect
style="fill:none;fill-opacity:1;fill-rule:evenodd;stroke-width:0.86602539"
height="3"
......@@ -287,7 +287,7 @@
<g
id="focus-bottomleft"
transform="translate(2.3441319,-1.6943741)"
style="opacity:0.6">
style="opacity:1">
<rect
y="67.294373"
x="61.655865"
......@@ -305,17 +305,17 @@
y="67.294373" />
</g>
<rect
style="fill:#bed4d9;fill-rule:evenodd;stroke-width:1.41421354"
height="4"
style="fill:#bed4d9;fill-rule:evenodd;stroke-width:1.2247448"
height="3"
width="1"
y="-60.055508"
y="-59.055508"
x="61.795139"
transform="rotate(90)"
id="focus-hint-left-margin" />
<g
transform="matrix(1,0,0,-1,2.3431329,116.87652)"
id="focus-topleft"
style="opacity:0.6">
style="opacity:1">
<rect
style="opacity:0.5;fill:none;fill-opacity:1;stroke-width:0.74061066;stroke-miterlimit:4;stroke-dasharray:none"
id="rect889"
......@@ -335,7 +335,7 @@
<g
transform="matrix(-1,0,0,1,165.66037,-1.6944199)"
id="focus-bottomright"
style="opacity:0.6">
style="opacity:1">
<rect
style="opacity:0.5;fill:none;fill-opacity:1;stroke-width:0.74061066;stroke-miterlimit:4;stroke-dasharray:none"
id="rect896"
......@@ -355,7 +355,7 @@
<g
id="focus-topright"
transform="rotate(-180,82.827435,58.438261)"
style="opacity:0.6">
style="opacity:1">
<rect
y="67.294373"
x="61.655865"
......
This diff is collapsed.
This diff is collapsed.
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment