A theme is a collection of colors to be used by a script's GUI. The colors are meant to provide a pleasing and coherent experience. dh_ThemeDesigner provides a GUI to design user themes for scripts which use dh_Toolkit and the Lokasenna GUI. The script window (herein referred to as App) consists of two main parts. The top is a Tabbed section, and the bottom is the Tools section.
Workflow:
The Preferences tab has selection boxes where you select a
theme to use as a starting point. The name of the selected theme
is displayed in the 'User Theme Name' textbox. This is merely a
convenience for saving and renaming user themes
(see 3.01 Preference Tab).
Then you select a theme color to edit by clicking on a color
swatch on the Colors tab, or selecting it from the Color Names
selection box in the Tools panel. Use the color sliders in the
Tools panel to edit the selected theme color.
The edits appear in the "New Color" swatch.
Clicking on the "New Color" swatch updates the GUI with its color.
The loaded theme is not changed when editing. The current
'edit state' can be saved at any time as a user theme.
When exiting dh_ThemeDesigner the current 'edit state' is
preserved. It will appear the next time dh_ThemeDesigner
is opened.
Side Note: I pushed the limits with this. The script used 135 elements although there were, from what I could gather, only 127 buffers available for elements to use. Another source says that 1024 buffers are available. I could not find any definitive answer for that. Plus some elements require more than one buffer.
During development the script would often crash claiming a buffer error. I eventually found the issue. dh_ThemeDesigner is constantly reinitializing all of its elements. And the Lokasenna text elements were not reusing their buffers. Coupled with the way the GUI places a possibly narrow range limit on available buffers. I addressed these issues by overriding the pertinent functions in the library file 'GUI_overrides.lua'. But even before I addressed those issues the current workspace was preserved. Restart the script and pick up where you left off.