Ren'Py help change background color of frame box [SOLVED]

sitayo

Newbie
Game Developer
Apr 3, 2020
43
133
I need help change my frame background color. from white to grey without change it in GUI rpy

Code:
screen displayTextScreen:

    frame:
        xalign 0.5
        yalign 0
        text "[displayText]":
            size 40

framebox.png
 

anne O'nymous

I'm not grumpy, I'm just coded that way.
Modder
Donor
Respected User
Jun 10, 2017
10,963
16,202
I need help change my frame background color. from white to grey without change it in GUI rpy
Just define the you want, then assign it to the frame :

Code:
style myFrame is default:
    background Solid( "#FF0000" )
    [...]

screen displayTextScreen:

    frame:
        style "myFrame"
        [...]
 
  • Like
Reactions: Lou111 and sitayo

sitayo

Newbie
Game Developer
Apr 3, 2020
43
133
Just define the you want, then assign it to the frame :

Code:
style myFrame is default:
    background Solid( "#FF0000" )
    [...]

screen displayTextScreen:

    frame:
        style "myFrame"
        [...]
I see, thank you very much
 

79flavors

Well-Known Member
Respected User
Jun 14, 2018
1,607
2,256
From what I remember, the textbox shown behind any dialogue is actually a picture.
(/game/gui/textbox.png)

When you create your project, you are given a grid of colors to pick the general style used by your project.

renpy-project-color-picker.jpg

If you pick any of the colors on the top two rows, your namebox.png is primarily black/gray. If you pick colors from the bottom two rows, that same picture is primarily white/gray.

It sounds like you maybe have picked the wrong base color options. Thankfully, RenPy will allow you to change it even after you've started work on your project, by using the "Change/Update GUI" option from the RenPy Launcher...

renpy-project-change-gui.jpg

Though obviously, if you've done some extensive reworking of the GUI... that might be a bad idea - since it will probably overwrite everything you've done with the default designs.
But if you've not really reworked the gui.rpy a lot, it might be a quick and dirty solution for you. (Pick the "Choose new colors, then regenerate image files" option most likely).

*** Backup your project before trying... you may not like the results ***

Alternatively, just draw your own /game/gui/textbox.png.

This is the one I usually use in a 1920x1080 project...
 
  • Like
Reactions: Lou111 and sitayo

sitayo

Newbie
Game Developer
Apr 3, 2020
43
133
From what I remember, the textbox shown behind any dialogue is actually a picture.
(/game/gui/textbox.png)

When you create your project, you are given a grid of colors to pick the general style used by your project.

View attachment 750605

If you pick any of the colors on the top two rows, your namebox.png is primarily black/gray. If you pick colors from the bottom two rows, that same picture is primarily white/gray.

It sounds like you maybe have picked the wrong base color options. Thankfully, RenPy will allow you to change it even after you've started work on your project, by using the "Change/Update GUI" option from the RenPy Launcher...

View attachment 750607

Though obviously, if you've done some extensive reworking of the GUI... that might be a bad idea - since it will probably overwrite everything you've done with the default designs.
But if you've not really reworked the gui.rpy a lot, it might be a quick and dirty solution for you. (Pick the "Choose new colors, then regenerate image files" option most likely).

*** Backup your project before trying... you may not like the results ***

Alternatively, just draw your own /game/gui/textbox.png.

This is the one I usually use in a 1920x1080 project...
i just need change one frame not an entire GUI, i need it for hovered text and my problem is just solved right now but thank you for reply