[PD] theme all the things

Sebastian Shader sebfumaster at aol.com
Sun Jan 3 05:55:07 CET 2021

The pr should be good to go, maybe it should be consolidated it into fewer commits and some whitespace issues could be fixed but other than that I think all of the requested changes have been made..In order to set the array element colors there had to be some odd workaround in g_templateand g_array (setting the scalar color to a negative value will use the set tcl variable)
But I think if you want system colors you might be able to set them from tcl variables that correspond to system themes. Idk that much about x11 but on aqua and windows there are colors like systemHighlight that correspond to system theme colors.
I think on x11 the way to do it might be through setting .Xresources/.Xdefaults and xrdb, then perhaps you can get the tcl color variables by getting the option? (with the tk "option get" command)
basically, if there is a way to get system colors stored in some system config/theme file/database from within tk then we can do that within the tcl-plugin file that we're using to set the color variables anyways.
-----Original Message-----
From: Andre Osku Schmidt <andre at osku.de>
To: pd-list at lists.iem.at
Sent: Sat, Jan 2, 2021 3:17 pm
Subject: Re: [PD] theme all the things

On Sat, 02 Jan 2021 14:47:53 +0100
IOhannes m zmölnig <zmoelnig at iem.at> wrote:

> Am 2. Jänner 2021 13:27:05 MEZ schrieb Andre Osku Schmidt <andre at osku.de>:
> > hello people,
> > 
> > - is someone working on this already? (i haven't used pd in a
> > ~decade...)
> check out: https://github.com/pure-data/pure-data/pull/196

but of course, i remember now... >.<*

well, at least i "learned" couple things while re-inventing the wheel ;P

sorry but i could not follow the hundreds of comments in that pull-request, what is there still todo?

fwiw, i agree that the scope should be kept minimal (i would even go as far as to not change tk(k) theme colors (it currently overwrites my tk(k) theme colors used by pd-window "terminal". but ultimately i don't actually care where i need to change the colors...))

not sure if i should comment on that pull-request that my "end-goal" would be to load the colors from system theme in /etc/whatever (and i assume some would like to load from ~/whatever & other os system/user config paths). and while i was doing my experiment, the "pkgIndex way" felt like a good place to add this new tcl code?

so maybe that pull-request could/should add the colors to tcl/pd_colors.tcl (or something, but instead tcl/pd-gui.tcl) and the system/user theme loading code could then later be added there?

but i don't actually know what i'm talking about, and mostly go by trial-and-error and "feel", so...

fwiw, i'll now keep using this pull-request (in case the merge is waiting for bug testing). it at least changes all the (and more) colors i need, cool!


Pd-list at lists.iem.at mailing list
UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20210103/dfbbbc3a/attachment.html>

More information about the Pd-list mailing list