You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
Using egui::widgets::color_picker::color_picker_hsva_2d (or similar) by itself results in a color slider that's much smaller than the row with the drag values:
This is because the color area draws its size from style.spacing.slider_with (which is slightly unintuitive if you haven't looked at the code / know that the area is a slider). This can be scaled up in a child UI
However, I don't actually need the ability to change the color format or to copy the color, and would prefer to keep the color slider small.
Describe the solution you'd like
I would like the ability to configure the style and layout of the color picker widget, so that you can specify:
the size of the color slider in a more explicit fashion
whether or not the color format is shown
whether or not the copy button is shown
whether or not the raw values of the color are shown
I suspect the best way to do this would be to convert it into a formal Widget so that it can be configured and placed as the user requires.
In addition to this, breaking apart the widget into its constituent components and exposing them would help users pick and choose what they want. For example, making color_slider_2d (or its Widget equivalent) public would be perfect for what I need.
Describe alternatives you've considered
The only solution I can see that would work externally would be to copy the code from egui or to fork it, neither of which is ideal. A short-term fix would be to make all of the relevant constituent functions public, so that they can be used without using the full color_picker.
Additional context
I believe the disparity in size between the color picker and the value row was exacerbated by #2734.
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem? Please describe.
Using
egui::widgets::color_picker::color_picker_hsva_2d
(or similar) by itself results in a color slider that's much smaller than the row with the drag values:This is because the color area draws its size from
style.spacing.slider_with
(which is slightly unintuitive if you haven't looked at the code / know that the area is a slider). This can be scaled up in a child UIto get reasonable results:
However, I don't actually need the ability to change the color format or to copy the color, and would prefer to keep the color slider small.
Describe the solution you'd like
I would like the ability to configure the style and layout of the color picker widget, so that you can specify:
I suspect the best way to do this would be to convert it into a formal
Widget
so that it can be configured and placed as the user requires.In addition to this, breaking apart the widget into its constituent components and exposing them would help users pick and choose what they want. For example, making
color_slider_2d
(or itsWidget
equivalent) public would be perfect for what I need.Describe alternatives you've considered
The only solution I can see that would work externally would be to copy the code from
egui
or to fork it, neither of which is ideal. A short-term fix would be to make all of the relevant constituent functions public, so that they can be used without using the fullcolor_picker
.Additional context
I believe the disparity in size between the color picker and the value row was exacerbated by #2734.
The text was updated successfully, but these errors were encountered: