jMonkeyEngine-Contributions / Lemur

Lemur is a jMonkeyEngine-based UI toolkit.
http://jmonkeyengine-contributions.github.io/Lemur/
BSD 3-Clause "New" or "Revised" License
116 stars 33 forks source link

Where can I find a list of style attributes #99

Closed tsafs closed 3 years ago

tsafs commented 3 years ago

Hi, I have read through https://github.com/jMonkeyEngine-Contributions/Lemur/wiki/Styling#styling but could not find any list of available style attributes. Could you please point me in the right direction? Thank you

pspeed42 commented 3 years ago

Note: this location is for reporting bugs are requesting specific features. The best place to answer questions is on the JME forum.

However, to answer your question. The available style attributes are completely up to the object as styled components can define whatever style attributes that they like. The easiest way to see what's available for the standard GUI elements is to look in the javadoc. Most of the set/get method pairs are probably stylable but if you look at a specific setter method's javadoc you can tell because it has the StyleAttribute annotation.

In theory, it would be possible to write a utility to go through and extract these for documentation purposes but it so far hasn't been a high priority.

Edit: example of javadoc'ed style attribute can be seen here: http://jmonkeyengine-contributions.github.io/Lemur/javadoc/Lemur/com/simsilica/lemur/Button.html#setFocusColor-com.jme3.math.ColorRGBA-

    setFocusColor
    @StyleAttribute(value="focusColor",
                    lookupDefault=false)
    public void setFocusColor(com.jme3.math.ColorRGBA color)