I try to color features by attribute value. Tried both the FeatureColorSetter and the KML Styler.
I have the color in an attributes for each feature both as hex "#FFCC00" and as decimal "255,204,0" but both don't work when i feed them to "Fill Color" in the KMLStyler or FeatureColorSetter.
How do I have to format the color values?
Best answer by ebygomm
The FeatureColor setter expects an FME color if setting via an attribute i.e. 1,0.8,0 (it will let you copy and paste hex and rgb colours via the interface but does the conversion for you and this doesn't work if you set via attribute)
There are custom transformers that will convert hex and rgb colours to fme colours, e.g. ColorCalculator
This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.
The FeatureColor setter expects an FME color if setting via an attribute i.e. 1,0.8,0 (it will let you copy and paste hex and rgb colours via the interface but does the conversion for you and this doesn't work if you set via attribute)
There are custom transformers that will convert hex and rgb colours to fme colours, e.g. ColorCalculator