Page 1 of 1

[SOLVED] Menu choice button style messed up after updating

Posted: Tue Apr 04, 2017 1:14 pm
by Lezalith
I was working on a game in Ren'Py 6.99.3, but had to update because a function was not working.

Now, my frames that I'm using for Menu Choices don't work anymore.

Code: Select all

    style.menu_choice_button.background = Frame("GUI/Textbox/choice_idle.png",5,5)
    style.menu_choice_button.hover_background = Frame("GUI/Textbox/choice_hover.png",5,5)
It's acting like it was a regular background, not a frame. It doesn't change it's size at all.
I am, however, using frames in a different section of the game, too...

Code: Select all

style skillcheckFailedStyle:
    background Frame("GUI/Frames/red.png", 10, 10)
    xpadding 20
    ypadding 20
Like this. And that one works just fine even after the update.

Any ideas, please?

Re: Menu choice button style messed up after updating Ren'py

Posted: Tue Apr 04, 2017 5:37 pm
by xela

Re: Menu choice button style messed up after updating Ren'py

Posted: Wed Apr 05, 2017 1:36 am
by Lezalith
That's definitely something I missed and I shouldn't have.

But I added all sorts of things from that page and neither helps. Was you linking it supposed to be a fix, or just letting me know there's nothing I can do with it?

Re: Menu choice button style messed up after updating Ren'py

Posted: Wed Apr 05, 2017 2:19 am
by xela
I thought this might be worth of trying:

Code: Select all

define config.enforce_window_max_size = False
there could be some other things as well...

Re: Menu choice button style messed up after updating Ren'py

Posted: Wed Apr 05, 2017 10:02 am
by Lezalith
It did look like something that would help, but sadly, it doesn't do anything ._.

Any other ideas, anybody?

Re: Menu choice button style messed up after updating Ren'py

Posted: Wed Apr 05, 2017 11:15 am
by indoneko
Perhaps you can try something like this :

Code: Select all

style choice_button is default:
    properties gui.button_properties("choice_button")
    background Frame("GUI/Textbox/choice_idle.png",120, 3, 120, 26)   # Your background
    hover_background Frame("GUI/Textbox/choice_hover.png",120, 3, 120, 26)  # Your background
    yminimum 50  # Testing how big can we resize the button
You might want to follow Xela's suggestion first before you're able to change the button's size.

Re: Menu choice button style messed up after updating Ren'py

Posted: Wed Apr 05, 2017 12:46 pm
by xela
Honestly... when that RenPy version came out, I had to update like 1000 lines of gui code, didn't even bother trying to get old way(s) to work. Any gui issues can be solved by writing proper code for them (all of those issues were there due to gui designers that didn't read Ren'Py docs (it's an open sourced project with free contributions allowed via github)).

Just fix whatever broke down.

Re: Menu choice button style messed up after updating Ren'py

Posted: Wed Apr 05, 2017 1:36 pm
by Lezalith
xela wrote:Just fix whatever broke down.
I wish you weren't saying that to someone who is a complete noob when it comes to programming.

Edit:
I guess I am not a complete noob. I fixed it after all :)