Open dharmik2319 opened 1 year ago
Why not ? But if I'm right pywal is like Monet ...
Cc: @daudix-UFO
Maybe we can replace monet with it if it will be good enough :)
This would also solve #779, right?
Why not ? But if I'm right pywal is like Monet ...
It is, but it generates 16 color templates, and is already kind of the standard for wallpaper based theming, so the GTK themes would be even better if they are consistent with, for example, the user's terminal theme, or their pywalfox theme, or their vim theme.
This would also solve #779, right?
Nope, monet needs #736
I meant that if #779 is a monet specific problem, then if we replace monet, we would get rid of the problem as well
Problem is not in monet itself, problem is that I needed less bright color and thought that transparency will work, how wrong I were...
We can add pywal alongside monet, but keep it disabled by default, so if someone prefers it over monet he can disable monet and enable pywal
if you seriously intend to support pywal, please don't, at least not https://github.com/dylanaraps/pywal as it has been abandoned for 4 years now and may break without notice or even a hope to get it fixed upstream whatsoever.
instead support https://github.com/eylles/pywal16 which i'm maintaining (painfully) as it has the capability to generate not just 16 color palettes but internal the internal functions lighten
, darken
and saturate
can be ran on templates at export time to create more color shades, in practice it can serve to create the whole "material design" variations of the colors (all the shades of gray between black to white and every light and dark shade of the 6 distinct colors) which i may end up implementing as a regular part of pywal16 in the future.
if you seriously intend to support pywal, please don't, at least not https://github.com/dylanaraps/pywal as it has been abandoned for 4 years now and may break without notice or even a hope to get it fixed upstream whatsoever.
instead support https://github.com/eylles/pywal16 which i'm maintaining (painfully) as it has the capability to generate not just 16 color palettes but internal the internal functions
lighten
,darken
andsaturate
can be ran on templates at export time to create more color shades, in practice it can serve to create the whole "material design" variations of the colors (all the shades of gray between black to white and every light and dark shade of the 6 distinct colors) which i may end up implementing as a regular part of pywal16 in the future.
Yeah, if we add pywal, we'll take a maintained engine :)
Well, on the meantime i'm experimenting on cobbling a template so that pywal can produce gradience presets, any advice on that front?
Well, on the meantime i'm experimenting on cobbling a template so that pywal can produce gradience presets, any advice on that front?
That would be nice, you can use presets in the community repo as base
didn't take long to cobble a working template for pywal16
pywal's templating system requires curly braces to be escaped by doubling them up
this template works for dark colorschemes for light colorschemes some minimal tweaking is required, basically just change the normal foreground and background colors around and darken the background instead of lightening it, will cobble one together later.
pywal.json
{{
"name": "pywal",
"variables": {{
"accent_color": "{color10}",
"accent_bg_color": "{color10}",
"accent_fg_color": "#{color10.lighten(70%)}",
"destructive_color": "{color11}",
"destructive_bg_color": "{color3}",
"destructive_fg_color": "#{color11.lighten(70%)}",
"success_color": "{color13}",
"success_bg_color": "{color13}",
"success_fg_color": "{color15}",
"warning_color": "{color14}",
"warning_bg_color": "{color6}",
"warning_fg_color": "{color15}",
"error_color": "{color11}",
"error_bg_color": "{color3}",
"error_fg_color": "{color15}",
"window_bg_color": "{color0}",
"window_fg_color": "{color15}",
"view_bg_color": "#{color0.lighten(1%)}",
"view_fg_color": "{color15}",
"headerbar_bg_color": "{color0}",
"headerbar_fg_color": "{color15}",
"headerbar_border_color": "#{color0.lighten(3%)}",
"headerbar_backdrop_color": "@window_bg_color",
"headerbar_shade_color": "#{color0.lighten(2%)}",
"card_bg_color": "#{color0.lighten(2%)}",
"card_fg_color": "{color15}",
"card_shade_color": "#{color0.lighten(1%)}",
"dialog_bg_color": "{color0}",
"dialog_fg_color": "{color15}",
"popover_bg_color": "{color0}",
"popover_fg_color": "{color15}",
"shade_color": "{color8}",
"scrollbar_outline_color": "{color10}"
}},
"palette": {{
"blue_": {{
"1": "#99c1f1",
"2": "#62a0ea",
"3": "#3584e4",
"4": "#1c71d8",
"5": "#1a5fb4"
}},
"green_": {{
"1": "#8ff0a4",
"2": "#57e389",
"3": "#33d17a",
"4": "#2ec27e",
"5": "#26a269"
}},
"yellow_": {{
"1": "#f9f06b",
"2": "#f8e45c",
"3": "#f6d32d",
"4": "#f5c211",
"5": "#e5a50a"
}},
"orange_": {{
"1": "#ffbe6f",
"2": "#ffa348",
"3": "#ff7800",
"4": "#e66100",
"5": "#c64600"
}},
"red_": {{
"1": "#f66151",
"2": "#ed333b",
"3": "#e01b24",
"4": "#c01c28",
"5": "#a51d2d"
}},
"purple_": {{
"1": "#dc8add",
"2": "#c061cb",
"3": "#9141ac",
"4": "#813d9c",
"5": "#613583"
}},
"brown_": {{
"1": "#cdab8f",
"2": "#b5835a",
"3": "#986a44",
"4": "#865e3c",
"5": "#63452c"
}},
"light_": {{
"1": "#ffffff",
"2": "#f6f5f4",
"3": "#deddda",
"4": "#c0bfbc",
"5": "#9a9996"
}},
"dark_": {{
"1": "#77767b",
"2": "#5e5c64",
"3": "#3d3846",
"4": "#241f31",
"5": "#000000"
}}
}},
"custom_css": {{
"gtk4": "",
"gtk3": ""
}},
"plugins": {{}}
}}
i don't use the client side decorations as i got my own style of window buttons, after playing some with gradience and adw-gtk3 one of my upcoming projects is reviving a gtk3 theme i hacked together years ago as a gradience preset but that will involve learning how to draw my particular style of window buttons in css because i feel that a svg to css converter will mangle them
Woaw this is nice, i'll look at how I can integrate it :)
speaking of nice and solving headaches, i took a look at the code of https://github.com/GabePoel/KvLibadwaita and pywal's templating system is powerful enough to turn it into a template, my plan for that is using the adwaita-dark.json as a dictionary of colors to replace for the corresponding variables in pywal.json, apply the replacements to KvLibadwaitaDark.kvconfig and KvLibadwaita.svg, build the themes and then manually tune the colors to a perfect match.
tho i'll work on that after lunch, as for pywal's templating system it uses python's string formatting so a possible stopgap would be to copy some functions from https://github.com/eylles/pywal16/blob/master/pywal/export.py
god this was awful and made it very clear why you guys didn't tackle kvlibadvaita sooner, this is rough around the edges and needs some refinement but so far is a good enough "match", not sure what the correct place for the templates could be but i can always add them to pywal16
edit: why did i think github would be capable of handling 7000 lines of code in a commnet... oh well on the meantime i will create a repo to host these specific templates cuz i'm not sure where to put them
edit: templates repo and a script, will add a readme with screenshots of some programs, a couple colorschemes and some detail of what is happening, what are the limitations and what improvements could be added.
Yeah this can be cool
Welp, been without power at home since yesterday at noon so i haven't been able to properly document how i'm gluing everything together not my personal scripts to fully wrap things around.
Still the importan takeaway is that pywal is 2 programs in one, a color palette generator (okay-ish) and an extremely powerful template builder that can produce variations from the 16 colors of any palette it is provided.
so for all intends and purposes, with the templates i cobbled we can either supply wal with a color palette or have it build one and then export the templates, pass the gradience one to gradience, copy the qt and kvantum stuff to the apropiate place and issue the kvantum command.
I'm still working on other stuff so that with 1 "setup" script we can issue all the necessary commands for flatpaks and even build chromium themes, but i'm doing all this with scripts somewhat tied to pywal.
Now i don't want to get everyone's horses high, but this approach may be able to suceed where oomox/themix failed, as we can add some scripts from themix to colorize icons and one of my own that can colorize cursors (mind you my script is more of a proof of concept, but get me a gnome style cursors repo that is easy to build with either inkscape or rendsvg and i will retrofit my script to it), extract the part of pywal16 responsible for the template exporting and theme loading, bundle it with gradience in a way that we can load the pywal format themes, that part of pywal would export the theme.json, the kvantum stuff and the templates to colorize the icons, then we can have gradience load the generated theme.json, colorize gtk3,4, gnome shell and the icon and cursor building duty can be left to plugins.
or we could build a different python program that uses pywal16 as a library (pywal has supported being used as library for years), gradience as another library (can gradience be used as a library?) and finally it can use the plugins (we can bulld it to use them directly from oomox/themix) to build colorized icons and cursors.
Then again this is just a proposal first we have to polish what we have some more, and by that i meam i gotta explain how the stuff i've wrote works, publish my personal scripts that wrap pywal, gradience and many more, make everything cohesive (this is the hardest part but i'm already working on that) and then easy to use so that the script can fetch the other required plugins and scripts, then we may be able to propose something to gnome and talk interfaces and other serious stuff but with a good proof of concept behind.
welp, sorry for the radio silence, been having some breakdowns, regardless.
i'm working on the script to "build" the kvantum templates and json file from a passed color palette, then i have to cobble another to use the colors from the json file to build the kvantum template, that should cover most usecases as said script can then be developed into a gradience plugin, and then would just be a matter of using pywal16 as a library inside gradience to have "built-in" support.
progress has been slow here, currently i hope to release pywal16 3.5.0 and publish to pypi soon™ tho unfortunately i got no timeframe for that.
after one eternity pywal16 3.5.0 is finally on pypi https://pypi.org/project/pywal16/
after one eternity pywal16 3.5.0 is finally on pypi https://pypi.org/project/pywal16/
awesome, maybe it'll replace monet :)
awesome, maybe it'll replace monet :)
i'd rather not, pywal generates colors in a different manner as it is more of a wrapper for many small tasks on top of some color generation backends.
on a different note, the pywal16-libadwaita is a lot more readable now and i even got a clear TODO, i have not digged deep for documentation on gradience plugins but i'll do once the build-kvantum.py script is on a more advanced state.
okay so i have forgotten to update here what i've done, the script https://github.com/eylles/pywal16-libadwaita/blob/master/scripts/build-gradience.py can take the current colors.json and output a gradience theme, also can provide colors that match with pywalfox.
Would it be possible to link this to a dynamic color changer such as KDE Material You Colors? Works as frontend for pywal, I use it together with Koi so I can change the colors of all my apps given a light/dark wallpaper. What I don't know is if Gradience is able to apply themes dynamically or you need to log-out no matter what.
well, at least in gnome i think the log-out is rather a good advice due to all the stuff that goes on the background, on my setup tho (window manager) i need to tell a settings daemon to reload the settings (xsettingsd) and kill the xdg-portal to have it's theme reloaded, other programs and components of the gnome/gtk stack need a similar approach like the gtk network manager applet.
for KDE i'm not sure, it could need those too or not, also there's the "problem" of updating the env var for the colorscheme to use and that i don't have yet figured out how to cobble together a kde colorscheme file but i'll need to since i've recently picked up on using KDEnlive, tho for the colorscheme env var i can see an easy way to define a path like ~/.config/KDE/current-colorscheme.colors and set _KDE_NET_WM_COLOR_SCHEME(STRING) to point towards that file which will be just a symlink to the actual colorscheme.
@nozerorma does that help?
well, at least in gnome i think the log-out is rather a good advice due to all the stuff that goes on the background, on my setup tho (window manager) i need to tell a settings daemon to reload the settings (xsettingsd) and kill the xdg-portal to have it's theme reloaded, other programs and components of the gnome/gtk stack need a similar approach like the gtk network manager applet.
for KDE i'm not sure, it could need those too or not, also there's the "problem" of updating the env var for the colorscheme to use and that i don't have yet figured out how to cobble together a kde colorscheme file but i'll need to since i've recently picked up on using KDEnlive, tho for the colorscheme env var i can see an easy way to define a path like ~/.config/KDE/current-colorscheme.colors and set _KDE_NET_WM_COLOR_SCHEME(STRING) to point towards that file which will be just a symlink to the actual colorscheme.
@nozerorma does that help?
It does actually, I'm going to give a look at how it could be implemented and report back. thanks!
ah i had forgotten i also got a python script to colorize adw-gtk2, adw-gtk2-colorizer.
it is useful if you have some stuff on your system that will still use gtk2 for themeing (like gimp and the steam systray menu) tho it doesn't yet recolor the image assets...
steam themes are now a thing.
okay worked on https://github.com/eylles/adw-gtk2-colorizer and now the gtk2 theme looks good enough i think.
yes, this is more or less a gradience plugin.
Feature description
Just like you can create a 6 color template with monet, there should be support for pywal as well. It would be relatively easy to implement, as pywal already generates color templates in multiple different formats which can be adapted to.
Additional Context
Link to pywal
There also is wpgtk, but it has NEVER worked for me, instead, it has always badly messed up my current configuration.
Did you read the Code of Conduct?