• To improve security, we will soon start forcing password resets for any account that uses a weak password on the next login. If you have a weak password or a defunct email, please update it now to prevent future disruption.

.

Quonix

Newbie
Donor
Game Developer
Nov 21, 2017
70
345
Place bottom_margin 100 after Start().
Like this: textbutton _("Start") style "mm_button" action Start() bottom_margin 100
 

the66

beware, the germans are cumming
Modder
Respected User
Donor
Jan 27, 2017
7,618
23,601
Code:
            textbutton _("START") style "mm_button" bottom_margin 100 action Start() DOES NOT WORK
            textbutton _("Load") style "mm_button" action ShowMenu("load") WORKS
            textbutton _("Preferences") style "mm_button" action ShowMenu("preferences") WORKS
When hovering on the start button, neither the hover color change nor the action "Start()" works. It's like the button cannot be clicked on at all.

On a side note, the font assigned to mm_button does not work at all. This only works when the styling is inherited (via "mm_button_child is mm_button" etc) which doesn't make any sense to me.

Thanks for all help.
your code works for me, there is a 100 pixel space below the start button
you can also try
Code:
            textbutton _("START") style "mm_button" action Start()
            null height 100
            textbutton _("Load") style "mm_button" action ShowMenu("load")
to get this result
 

NamesRed

Member
Game Developer
May 13, 2018
198
133
your code works for me, there is a 100 pixel space below the start button
you can also try
Code:
            textbutton _("START") style "mm_button" action Start()
            null height 100
            textbutton _("Load") style "mm_button" action ShowMenu("load")
to get this result
Code:
screen main_menu():

    ## This ensures that any other menu screen is replaced.
    tag menu

    style_prefix "main_menu"

    add gui.main_menu_background

    ## This empty frame darkens the main menu.
    frame:
        pass
   
    ## The use statement includes another screen inside this one. The actual
    ## contents of the main menu are in the navigation screen.
    if gui.show_name:
        # use navigation
        text "TITLE":
            style "main_menu_title"

        text "SUBTITLE":
            style "main_menu_subtitle"

        text "[config.version]":
            style "main_menu_version"
        vbox:
            textbutton _("START") style "mm_button" action Start() bottom_margin 100
            textbutton _("Load") style "mm_button" action ShowMenu("load")
            textbutton _("Preferences") style "mm_button" action ShowMenu("preferences")

            yalign 0.6
            xalign 0.5
            spacing 10
Full snippet: It just will not work at all.
 

NamesRed

Member
Game Developer
May 13, 2018
198
133
I think I've identified the problem. It's because bottom_margin is a window property. Having been used to css I expected a similar toolkit for ren'py. I was wrong.

Now, on to font issues :(
 

the66

beware, the germans are cumming
Modder
Respected User
Donor
Jan 27, 2017
7,618
23,601
use yminimum instead of ysize in your style definition
 

the66

beware, the germans are cumming
Modder
Respected User
Donor
Jan 27, 2017
7,618
23,601
It works, thank you! Why does size not work?
i think the problem was, that your max size was smaller than the space you wanted to create with the margin