• 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.

Ren'Py How to change the size of this text?

iOtero

Active Member
Aug 4, 2020
924
1,458
Hello,

I wanted to know where you can change the text size of the game menus inside the juice.

If I have not explained myself well, I attach an image indicating it.

2021-10-18 17_08_23-THAMAR.png I have been looking at gui.rpy and have not found anything.

Thanks for your help.
 

79flavors

Well-Known Member
Respected User
Jun 14, 2018
1,560
2,179
The menu: uses a screen called choice.

It looks like this:

Python:
# ---- screens.rpy ---

screen choice(items):
    style_prefix "choice"

    vbox:
        for i in items:
            textbutton i.caption action i.action

The style prefix is "choice"... following that down a bit, and you find these lines...

Python:
# ---- screens.rpy ---

style choice_button is default:
    properties gui.button_properties("choice_button")

style choice_button_text is default:
    properties gui.button_text_properties("choice_button")

So the button itself is linked to the gui properties "choice_button". Following that to gui.rpy....

Python:
# ---- gui.rpy ---

define gui.choice_button_width = 1185
define gui.choice_button_height = None
define gui.choice_button_tile = False
define gui.choice_button_borders = Borders(150, 8, 150, 8)
define gui.choice_button_text_font = gui.text_font
define gui.choice_button_text_size = gui.text_size
define gui.choice_button_text_xalign = 0.5
define gui.choice_button_text_idle_color = "#cccccc"
define gui.choice_button_text_hover_color = "#ffffff"
define gui.choice_button_text_insensitive_color = "#444444"

The important line you care about is define gui.choice_button_text_size = gui.text_size.

So...

Python:
# ---- gui.rpy ---

## The size of normal dialogue text.
define gui.text_size = 33

So if you want to change that size, you have the choice to alter the size for all text within the game by altering gui.text_size. Or just change it for menus only by altering gui.choice_button_text_size.
 

LightmanP

Well-Known Member
Modder
Game Developer
Oct 5, 2020
1,659
15,260
Here's a tip, hover over an element you want to inspect and press Shif+i in the developer mode. That will show you elements, their styles, and where they are located in the files.
 

iOtero

Active Member
Aug 4, 2020
924
1,458
The menu: uses a screen called choice.

It looks like this:

Python:
# ---- screens.rpy ---

screen choice(items):
    style_prefix "choice"

    vbox:
        for i in items:
            textbutton i.caption action i.action

The style prefix is "choice"... following that down a bit, and you find these lines...

Python:
# ---- screens.rpy ---

style choice_button is default:
    properties gui.button_properties("choice_button")

style choice_button_text is default:
    properties gui.button_text_properties("choice_button")

So the button itself is linked to the gui properties "choice_button". Following that to gui.rpy....

Python:
# ---- gui.rpy ---

define gui.choice_button_width = 1185
define gui.choice_button_height = None
define gui.choice_button_tile = False
define gui.choice_button_borders = Borders(150, 8, 150, 8)
define gui.choice_button_text_font = gui.text_font
define gui.choice_button_text_size = gui.text_size
define gui.choice_button_text_xalign = 0.5
define gui.choice_button_text_idle_color = "#cccccc"
define gui.choice_button_text_hover_color = "#ffffff"
define gui.choice_button_text_insensitive_color = "#444444"

The important line you care about is define gui.choice_button_text_size = gui.text_size.

So...

Python:
# ---- gui.rpy ---

## The size of normal dialogue text.
define gui.text_size = 33

So if you want to change that size, you have the choice to alter the size for all text within the game by altering gui.text_size. Or just change it for menus only by altering gui.choice_button_text_size.
A perfect explanation. Thank you very much. As always, your help is exceptional.
 

MJB

Newbie
Jan 10, 2020
64
329
The menu: uses a screen called choice.

It looks like this:

Python:
# ---- screens.rpy ---

screen choice(items):
    style_prefix "choice"

    vbox:
        for i in items:
            textbutton i.caption action i.action

The style prefix is "choice"... following that down a bit, and you find these lines...

Python:
# ---- screens.rpy ---

style choice_button is default:
    properties gui.button_properties("choice_button")

style choice_button_text is default:
    properties gui.button_text_properties("choice_button")

So the button itself is linked to the gui properties "choice_button". Following that to gui.rpy....

Python:
# ---- gui.rpy ---

define gui.choice_button_width = 1185
define gui.choice_button_height = None
define gui.choice_button_tile = False
define gui.choice_button_borders = Borders(150, 8, 150, 8)
define gui.choice_button_text_font = gui.text_font
define gui.choice_button_text_size = gui.text_size
define gui.choice_button_text_xalign = 0.5
define gui.choice_button_text_idle_color = "#cccccc"
define gui.choice_button_text_hover_color = "#ffffff"
define gui.choice_button_text_insensitive_color = "#444444"

The important line you care about is define gui.choice_button_text_size = gui.text_size.

So...

Python:
# ---- gui.rpy ---

## The size of normal dialogue text.
define gui.text_size = 33

So if you want to change that size, you have the choice to alter the size for all text within the game by altering gui.text_size. Or just change it for menus only by altering gui.choice_button_text_size.
I was looking this up tonight, and the was the clearest, most concise answer I found.

Cheers
 

xlRexpect

Newbie
May 31, 2022
40
11
The menu: uses a screen called choice.

It looks like this:

Python:
# ---- screens.rpy ---

screen choice(items):
    style_prefix "choice"

    vbox:
        for i in items:
            textbutton i.caption action i.action

The style prefix is "choice"... following that down a bit, and you find these lines...

Python:
# ---- screens.rpy ---

style choice_button is default:
    properties gui.button_properties("choice_button")

style choice_button_text is default:
    properties gui.button_text_properties("choice_button")

So the button itself is linked to the gui properties "choice_button". Following that to gui.rpy....

Python:
# ---- gui.rpy ---

define gui.choice_button_width = 1185
define gui.choice_button_height = None
define gui.choice_button_tile = False
define gui.choice_button_borders = Borders(150, 8, 150, 8)
define gui.choice_button_text_font = gui.text_font
define gui.choice_button_text_size = gui.text_size
define gui.choice_button_text_xalign = 0.5
define gui.choice_button_text_idle_color = "#cccccc"
define gui.choice_button_text_hover_color = "#ffffff"
define gui.choice_button_text_insensitive_color = "#444444"

The important line you care about is define gui.choice_button_text_size = gui.text_size.

So...

Python:
# ---- gui.rpy ---

## The size of normal dialogue text.
define gui.text_size = 33

So if you want to change that size, you have the choice to alter the size for all text within the game by altering gui.text_size. Or just change it for menus only by altering gui.choice_button_text_size.
Where is the folder?
 

TeamEquipe

Member
Mar 3, 2020
347
1,090
Or alternatively (for simplicity) you could just press the Shift key and the A key at the same time and that will bring you up a simplified way to make the text bigger or smaller. You can also change the font although there are only 2 choices.

1701122094750.png