[SOLVED]BGUI Documentation

Hello to everybody. I want to ask a little question, is there any documentation about BGUI, specifically about adding rules to the .cfg file? I’ve been looking around and I fount theese, but I think there must be something else. Thanks a lot

https://code.google.com/p/bgui/wiki/GettingStarted

http://bgui.googlecode.com/svn/tags/0.07/docs/build/html/api/frame_button.html

If you check the latest version of the docs, which is now located here:
http://bgui.readthedocs.org/en/latest/index.html

You can see each Widget’s theme_section and theme_options. Use these values for writing the theme.cfg file. For example, looking at the FrameButton docs, you can see:


    theme_section= 'FrameButton'
    theme_options= {'Color': (0.4, 0.4, 0.4, 1), 'BorderColor': (0, 0, 0, 1), 'LabelSubTheme': '', 'BorderSize': 1}

So, if we wanted to change the color of all FrameButtons to blue, we could do:


[FrameButton]
Color=0.0, 0.0, 1.0, 1.0

Bgui has an example theme that you can look at for examples of how certain values (e.g., colors) work. The example theme also makes use of subthemes.


[Label]
Font=myfont.otf
Color=0.8,0.8,0.8,1
Size=24


[Label:Large]
Font=myfont.otf
Color=0.8,0.8,0.8,1
Size=70


[Frame]
Color1=0.8, 0.8, 0.8, 0.5
Color2=0.8, 0.8, 0.8, 0.5
Color3=0.8, 0.8, 0.8, 0.5
Color4=0.8, 0.8, 0.8, 0.5
BorderSize=3
BorderColor=0.2, 0.2, 0.2, 1.0


[TextInput]
Font=myriad.otf
TextColor=0.0,0.0,0.0,1.0
FrameColor=1, 1, 1, 1.0
BorderSize=1
BorderColor=0.0, 0.8, 1.0, 1.0
HighlightColor=1.0, 0.0, 1.0, 0.5
InactiveFrameColor=.5, .5, .5, 1
InactiveBorderColor=.2, .2, .2, 1
InactiveBorderSize=1
InactiveTextColor=.3, .3, .3, 1
InactiveHighlightColor=0.0, 0.0, 0.0, 0.0


[ProgressBar:Progress]
FillColor1=0.0, 0.42, 0.02, 1.0
FillColor2=0.0, 0.42, 0.02, 1.0
FillColor3=0.0, 0.62, 0.02, 1.0
FillColor4=0.0, 0.62, 0.02, 1.0
BGColor1=0.0, 0.0, 0.0, 1.0
BGColor2=0.0, 0.0, 0.0, 1.0
BGColor3=0.15, 0.15, 0.15, 1.0                                                                                                                                                                                                   
BGColor4=0.15, 0.15, 0.15, 1.0                                                                                                                                                                                                   
BorderSize=1                                                                                                                                                                                                                     
BorderColor=0.0, 0.0, 0.0, 1.0                                                                                                                                                                                                   
                                                                                                                                                                                                                                 
[ProgressBar:Health]                                                                                                                                                                                                             
FillColor1=0.42, 0.0, 0.02, 1.0                                                                                                                                                                                                  
FillColor2=0.42, 0.0, 0.02, 1.0                                                                                                                                                                                                  
FillColor3=0.62, 0.0, 0.02, 1.0                                                                                                                                                                                                  
FillColor4=0.62, 0.0, 0.02, 1.0                                                                                                                                                                                                  
BGColor1=0.0, 0.0, 0.0, 1.0                                                                                                                                                                                                      
BGColor2=0.0, 0.0, 0.0, 1.0                                                                                                                                                                                                      
BGColor3=0.15, 0.15, 0.15, 1.0                                                                                                                                                                                                   
BGColor4=0.15, 0.15, 0.15, 1.0                                                                                                                                                                                                   
BorderSize=1                                                                                                                                                                                                                     
BorderColor=0.0, 0.0, 0.0, 1.0


[ImageButton:Audio]
DefaultImage=img:audio.png, 0, 0, 0.5, 1
Default2Image=img:audio.png, 0.5, 0, 0.5, 1

I’ll work on adding some better theming docs.

Thanks a lot, I cant understand why I wasnt able to find this by Google. :slight_smile: Closing my question by now.