I have buttons with categories. I click on the button, the category of the product changes and the products of a certain category are displayed on the screen. It's a textbutton because I'm not using an imagebutton.
But I want the button to change its background after clicking. And I can't find any examples of how to do it...
I don't know if the button has a "selected" property so that when I click the button?
That is, it is easily applied in styles,
Code: Select all
stylesort_button:
background '#904848'
hover_background '#a52d2d'Code: Select all
renpy.selected_button(background...) - something like that.Then I could apply a function to the button and change its color through python through the loop index, and remove this color from the previously selected button