I’ve created some pages to help analizing different cases. To support this I made charts too. When I load in the cases, the colors are always similar(light purpule and purple, light green and green). My first idea was that I use “KPI” annotation for the parmeters in the active case, then I realized that we are working with runtime parameters which has other indexes. Do you have any idea?
While I was trying to color charts, I set up a default color for the widget, it works well:
I tried some css from the ‘How to’ too with my annotation.
Thanks for your help!
Bogi
Best answer by laithshadeed
Thank you for sharing screenshots.
The colours of bar charts follow modular arithmetic to rotate. For example in the attached model, I have 50 bar, each bar will get a mix for there CSS classes annotation-Ord1 annotation-Mod7Ord1 annotation-Mod11Ord1 annotation-Mod19Ord1
Those CSS classes will rotate using modular arithmetic like this:
For example, bar with id=bar-1300 (14th bar) will get the follow CSS classes:
annotation-Ord14
annotation-Mod7Ord7 (14 mod 7)
annotation-Mod11Ord3 (14 mod 11)
annotation-Mod19Ord14 (14 mod 19)
Here screenshot of Chrome DevTools:
Using such classes, you can generate your CSS overrides to change the colours in any way you like.
However, I found it strange why different days showed you different colours, could you attach a small model with a reproducible case to help me debug it? Maybe you found a bug :)
Hi @Boglarka Balogh . Thank you for using WebUI. Getting CSS right can be tricky. Can you share a simple example model with screenshots to help me understand better what you are trying to achieve? Maybe I can help.
The colours of bar charts follow modular arithmetic to rotate. For example in the attached model, I have 50 bar, each bar will get a mix for there CSS classes annotation-Ord1 annotation-Mod7Ord1 annotation-Mod11Ord1 annotation-Mod19Ord1
Those CSS classes will rotate using modular arithmetic like this:
For example, bar with id=bar-1300 (14th bar) will get the follow CSS classes:
annotation-Ord14
annotation-Mod7Ord7 (14 mod 7)
annotation-Mod11Ord3 (14 mod 11)
annotation-Mod19Ord14 (14 mod 19)
Here screenshot of Chrome DevTools:
Using such classes, you can generate your CSS overrides to change the colours in any way you like.
However, I found it strange why different days showed you different colours, could you attach a small model with a reproducible case to help me debug it? Maybe you found a bug :)
Sign up
Already have an account? Login Please use your business or academic e-mail address to register