You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Texture UVs are currently hardcoded into the skin ('Init(...)). Move these to a file and read at runtime. This would allow an external tool to edit them.
Colours are read from skin texture. Move these to a file as need to edit the texture to change the colour.
Fonts could also be read from config file.
Config file might be like CSS. Perhaps JSON file with cascade overrides.
Since skinning is quite a lot of code and many values (e.g. colours) are hardcoded into GWEN code this would be best done in a branch, creating a new skin type, and comparing the results with the unchanged branch. For this it would be useful to have automated screen capture comparisons.
The text was updated successfully, but these errors were encountered:
Another feature that would be neat is actually per-element skin. For example right now if I want to have a red progress bar and a blue progress bar, it is not really possible since they are forced to use the same skin.
Skins might also be rendered using an API like nanovg, doesn't have to be a 9 segment texture.
First of all a bit of tidying up is necessary as some things are hardcoded into the controls.
I'm not likely to get round to doing anything on this for while. It is open source, so if you'd like to contribute, perhaps start an issue, I can help with any clarification, and we can make some progress. A lot of the controls in this library have quite advanced functionality compared to other GUI libraries (tree control, multi-line edit, etc). It could be so much better with skinning separated.
I will come back to this later if someone else has not because I will need more advanced skinning functionality. First I need to get the MVP (minimum viable product) of my game finished.
Having a separate API for skins seems like a good idea to me as well, and it might fit nicely between the existing rendering backends and the GUI elements.
Includes:
Init(...)
). Move these to a file and read at runtime. This would allow an external tool to edit them.Since skinning is quite a lot of code and many values (e.g. colours) are hardcoded into GWEN code this would be best done in a branch, creating a new skin type, and comparing the results with the unchanged branch. For this it would be useful to have automated screen capture comparisons.
The text was updated successfully, but these errors were encountered: