Hi Doru,
I think the transformColor: is exactly the relevant direction. But, I think there are still two issues to be addressed:
Yes, Pavel came along with a relatively good formular to transform colors.
Take a look at this example: view := RTMondrian new. view shape circle color: Color black. view nodes: (1 to: 42). view layout grid. view
[…]
Something like ThemedColor new for: RTDarkTheme use: Color lightGray; for: RTWhiteTheme use: Color black
And some derivates:
ThemedColor new forDark: Color lightGray; forWhite: Color black
Having theme raises the relevance of directly specifying colors. In your Mondrian example, why would you want to have black nodes? Or, are you interested in having a color that is distinct from other used colors? And this goes with ThemedColor. Consider this: https://github.com/d3/d3-scale-chromatic
We could have the d3.schemeAccent palette for White Theme and d3.schemeDark2 for the Dark theme. The users would then not directly use a color, but an index in the palette. Maybe something like: -=-=-=-=-=-= view := RTMondrian new. view shape circle color4. view nodes: (1 to: 42). view layout grid. view -=-=-=-=-=-=
Or "view shape circle colorPink.” since pink is the fourth of d3.schemeDark2
What do you think?
Let’s keep this discussion. We need to move on!
Cheers, Alexandre
Cheers, Doru
On Apr 24, 2017, at 4:52 PM, Pavel Krivanek pavel.krivanek@gmail.com wrote:
It's done. Thank you very much, Alex! We only need to tune some colors for the best result in both themes.
-- Pavel
2017-04-23 22:08 GMT+02:00 Tudor Girba tudor@tudorgirba.com: Hi,
As you could see, in Pharo we turned the Dark Theme on by default.
The question is what should we do with Moose. I think it would be great to have it working with the Dark Theme, but the problem is that the Roassal visualizations do not appropriate in the current theme because of two reasons:
- they were conceived on a white canvas
- the colors are hardcoded
Showing a white canvas in the Dark Theme is not an option. Either we introduce a mechanism to adapt the visualizations to the current theme, or we keep a different theme in Moose than in Pharo.
What do you think?
Cheers, Doru
-- www.tudorgirba.com www.feenk.com
"Not knowing how to do something is not an argument for how it cannot be done."
Moose-dev mailing list Moose-dev@list.inf.unibe.ch https://www.list.inf.unibe.ch/listinfo/moose-dev
Moose-dev mailing list Moose-dev@list.inf.unibe.ch https://www.list.inf.unibe.ch/listinfo/moose-dev
-- www.tudorgirba.com www.feenk.com
“The smaller and more pervasive the hardware becomes, the more physical the software gets."
Moose-dev mailing list Moose-dev@list.inf.unibe.ch https://www.list.inf.unibe.ch/listinfo/moose-dev