Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow to_color to work with Cycled(n::Int) #2893

Open
Datseris opened this issue Apr 23, 2023 · 4 comments
Open

Allow to_color to work with Cycled(n::Int) #2893

Datseris opened this issue Apr 23, 2023 · 4 comments

Comments

@Datseris
Copy link
Contributor

Not much more to say here, it would make themeing and UX much more pleasant if I could just get the color of the cycled as an actual RGBf color, as many things that dispatch on RGB don't dispatch on Cycled. cgrad for example.

@jkrumbiegel
Copy link
Collaborator

the problem here is that Cycled looks up the value in the cycler of an axis during plotting, so it's not stateless. Maybe we can redesign so Cycled computes the values directly from the theme

@Datseris
Copy link
Contributor Author

Computing values during the cycling and being state dependent is fine for Cycled(). However, here I am talking specifically about Cycled(n::Int), which is stateless (or rather, should be, as I thought Cycled(n::Int) means n-th color of the theme cycle).

@jkrumbiegel
Copy link
Collaborator

it is currently implemented Axis-theme-dependent, so you cannot call it without one. We could maybe make it only theme-dependent.

@Datseris
Copy link
Contributor Author

Datseris commented Apr 25, 2023

We could maybe make it only theme-dependent.

Yes, that makes the most sense for Cycled(n::Int) because users that theme their own colors would typically want to use them also outside the axis cycling features (like in my case here).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: No status
Development

No branches or pull requests

2 participants