Closed Akuli closed 6 years ago
I have been following some basic Tcl tutorials to understand how other code than just the themes work, and I could split the library into two separate parts. However, for now it is already possible to load the themes into Tcl, it's just a little more complicated than using the Python package.
In the Tcl file you would like to load the themes, you can use
package require Tk 8.4
source ../path/to/themes/pkgIndex.tcl
If you load Tk elsewhere in your library, you can skip the package require line. After that, the themes are available as normal ttk themes, and can be loaded using
ttk::setTheme theme_name
Each pkgIndex.tcl
provides the themes in its sub-folders. Some documentation is indeed probaby a good idea. I will see what I can do when I get back to working on it.
Tk 8.4 is quite old. Do the themes really work with it?
Anyway, this looks nice. Thanks :)
Yes, all themes should work with it, I believe. I can guarantee it for Tk 8.5 for all GIF themes (or PNG themes too with TkImg), and all themes work with Tk 8.6.
Nice :)
I hope you don't mind that I have marked this issue as the TODO-issue for documenting the Tcl loading mechanism. I will close it once I have sufficiently documented:
Awesome. I'm especially interested in the last 2 things, the first one is mostly a "nice to know" thing.
It has taken me a long time to get to do this, as I have been very busy, but I still wanted to let you know that I have written the documentation. It is available here. If you have the time, please let me know what you think.
I like it.
I really like this library, but it can't be used without tkinter. Would it be possible to refactor the library so that the themes could be loaded directly from Tcl? The themes are just Tcl code, so it shouldn't be hard. If it's already doable, I would appreciate some documentation that shows how to load all themes from Tcl code.