-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Support multiple colors for different buttons. #5274
Comments
The widget APIs are based on semantics - I.e. what does a coloured button /convey/. For this you can use the The blog you posted is out of date - from when buttons were transparent. You can of course create a simple custom widget that includes a coloured rectangle that is tappable. |
@andydotxyz
However, I want to set the color of the text as well, but there is no fyne.ThemeSizeName for text. I tried matching 'text', but it didn't work. |
Maybe you are interested in #4959 then? |
Currently, I can work around it by overriding the theme theme.ColorNameForeground to change the button text color. Thank you for your support, I will close this as completed. |
Checklist
Is your feature request related to a problem?
I want to create a table with multiple buttons, each button having a different color.
Is it possible to construct a solution with the existing API?
As far as I know, the button color can currently only be assigned through the theme.
I've tried https://blogvali.com/button-color-background-image-fyne-gui-golang-tutorial-44/, the color only show at the four small corners of each button.
Describe the solution you'd like to see.
Add single field like color to Button struct
The text was updated successfully, but these errors were encountered: