Raygui updated to version 4.0.
This commit is contained in:
651
API.md
651
API.md
@@ -2372,7 +2372,7 @@ Radians to degrees
|
||||
---
|
||||
|
||||
|
||||
## Globals - GuiTextAlignment
|
||||
## Globals - GuiControlTextAlignment
|
||||
> TEXT_ALIGN_LEFT = 0
|
||||
|
||||
---
|
||||
@@ -2386,6 +2386,34 @@ Radians to degrees
|
||||
---
|
||||
|
||||
|
||||
## Globals - GuiControlTextAlignmentVertical
|
||||
> TEXT_ALIGN_TOP = 0
|
||||
|
||||
---
|
||||
|
||||
> TEXT_ALIGN_MIDDLE = 1
|
||||
|
||||
---
|
||||
|
||||
> TEXT_ALIGN_BOTTOM = 2
|
||||
|
||||
---
|
||||
|
||||
|
||||
## Globals - GuiControlTextWrapMode
|
||||
> TEXT_WRAP_NONE = 0
|
||||
|
||||
---
|
||||
|
||||
> TEXT_WRAP_CHAR = 1
|
||||
|
||||
---
|
||||
|
||||
> TEXT_WRAP_WORD = 2
|
||||
|
||||
---
|
||||
|
||||
|
||||
## Globals - GuiControl
|
||||
> DEFAULT = 0
|
||||
|
||||
@@ -2523,10 +2551,6 @@ Uses: BUTTON, VALUEBOX
|
||||
|
||||
---
|
||||
|
||||
> RESERVED = 15
|
||||
|
||||
---
|
||||
|
||||
|
||||
## Globals - GuiDefaultProperty
|
||||
> TEXT_SIZE = 16
|
||||
@@ -2553,6 +2577,24 @@ Background color
|
||||
|
||||
---
|
||||
|
||||
> TEXT_LINE_SPACING = 20
|
||||
|
||||
Text spacing between lines
|
||||
|
||||
---
|
||||
|
||||
> TEXT_ALIGNMENT_VERTICAL = 21
|
||||
|
||||
Text vertical alignment inside text bounds (after border and padding)
|
||||
|
||||
---
|
||||
|
||||
> TEXT_WRAP_MODE = 22
|
||||
|
||||
Text wrap-mode inside text bounds
|
||||
|
||||
---
|
||||
|
||||
|
||||
## Globals - GuiToggleProperty
|
||||
> GROUP_PADDING = 16
|
||||
@@ -2648,16 +2690,10 @@ DropdownBox items separation
|
||||
---
|
||||
|
||||
|
||||
## Globals - GuiTextBoxProperty
|
||||
> TEXT_INNER_PADDING = 16
|
||||
## Globals - TextBox/TextBoxMulti/ValueBox/Spinner
|
||||
> TEXT_READONLY = 16
|
||||
|
||||
TextBox/TextBoxMulti/ValueBox/Spinner inner text padding
|
||||
|
||||
---
|
||||
|
||||
> TEXT_LINES_SPACING = 17
|
||||
|
||||
TextBoxMulti lines separation
|
||||
TextBox in read-only mode: 0-text editable, 1-text no-editable
|
||||
|
||||
---
|
||||
|
||||
@@ -8315,7 +8351,7 @@ Check if gui is locked (global state)
|
||||
|
||||
---
|
||||
|
||||
> RL.GuiFade( float alpha )
|
||||
> RL.GuiSetAlpha( float alpha )
|
||||
|
||||
Set gui controls alpha (global state), alpha goes from 0.0f to 1.0f
|
||||
|
||||
@@ -8371,262 +8407,6 @@ Get one style property
|
||||
|
||||
---
|
||||
|
||||
## Gui - Container/separator controls, useful for controls organization
|
||||
|
||||
---
|
||||
|
||||
> state = RL.GuiWindowBox( Rectangle bounds, string title )
|
||||
|
||||
Window Box control, shows a window that can be closed
|
||||
|
||||
- Success return bool
|
||||
|
||||
---
|
||||
|
||||
> RL.GuiGroupBox( Rectangle bounds, string text )
|
||||
|
||||
Group Box control with text name
|
||||
|
||||
---
|
||||
|
||||
> RL.GuiLine( Rectangle bounds, string text )
|
||||
|
||||
Line separator control, could contain text
|
||||
|
||||
---
|
||||
|
||||
> RL.GuiPanel( Rectangle bounds, string text )
|
||||
|
||||
Panel control, useful to group controls
|
||||
|
||||
---
|
||||
|
||||
> view, scroll = RL.GuiScrollPanel( Rectangle bounds, string text, Rectangle content, Vector2 scroll )
|
||||
|
||||
Scroll Panel control
|
||||
|
||||
- Success return Rectangle, Vector2
|
||||
|
||||
---
|
||||
|
||||
## Gui - Basic controls set
|
||||
|
||||
---
|
||||
|
||||
> RL.GuiLabel( Rectangle bounds, string text )
|
||||
|
||||
Label control, shows text
|
||||
|
||||
---
|
||||
|
||||
> clicked = RL.GuiButton( Rectangle bounds, string text )
|
||||
|
||||
Button control, returns true when clicked
|
||||
|
||||
- Success return boolean
|
||||
|
||||
---
|
||||
|
||||
> clicked = RL.GuiLabelButton( Rectangle bounds, string text )
|
||||
|
||||
Label button control, show true when clicked
|
||||
|
||||
- Success return boolean
|
||||
|
||||
---
|
||||
|
||||
> active = RL.GuiToggle( Rectangle bounds, string text, bool active )
|
||||
|
||||
Toggle Button control, returns true when active
|
||||
|
||||
- Success return boolean
|
||||
|
||||
---
|
||||
|
||||
> index = RL.GuiToggleGroup( Rectangle bounds, string text, int active )
|
||||
|
||||
Toggle Group control, returns active toggle index
|
||||
|
||||
- Success return int
|
||||
|
||||
---
|
||||
|
||||
> active = RL.GuiCheckBox( Rectangle bounds, string text, bool checked )
|
||||
|
||||
Check Box control, returns true when active
|
||||
|
||||
- Success return boolean
|
||||
|
||||
---
|
||||
|
||||
> active = RL.GuiComboBox( Rectangle bounds, string text, int active )
|
||||
|
||||
Combo Box control, returns selected item index
|
||||
|
||||
- Success return int
|
||||
|
||||
---
|
||||
|
||||
> pressed, text = RL.GuiTextBox( Rectangle bounds, string text, int textSize, bool editMode )
|
||||
|
||||
Text Box control, updates input text
|
||||
|
||||
- Success return boolean, string
|
||||
|
||||
---
|
||||
|
||||
> pressed, text = RL.GuiTextBoxMulti( Rectangle bounds, string text, int textSize, bool editMode )
|
||||
|
||||
Text Box control with multiple lines
|
||||
|
||||
- Success return boolean, string
|
||||
|
||||
---
|
||||
|
||||
> pressed, value = RL.GuiSpinner( Rectangle bounds, string text, int value, int minValue, int maxValue, bool editMode )
|
||||
|
||||
Spinner control, returns selected value
|
||||
|
||||
- Success return boolean, int
|
||||
|
||||
---
|
||||
|
||||
> pressed, value = RL.GuiValueBox( Rectangle bounds, string text, int value, int minValue, int maxValue, bool editMode )
|
||||
|
||||
Value Box control, updates input text with numbers
|
||||
|
||||
- Success return boolean, int
|
||||
|
||||
---
|
||||
|
||||
> value = RL.GuiSlider( Rectangle bounds, string textLeft, string textRight, float value, float minValue, float maxValue )
|
||||
|
||||
Slider control, returns selected value
|
||||
|
||||
- Success return float
|
||||
|
||||
---
|
||||
|
||||
> value = RL.GuiSliderBar( Rectangle bounds, string textLeft, string textRight, float value, float minValue, float maxValue )
|
||||
|
||||
Slider Bar control, returns selected value
|
||||
|
||||
- Success return float
|
||||
|
||||
---
|
||||
|
||||
> value = RL.GuiProgressBar( Rectangle bounds, string textLeft, string textRight, float value, float minValue, float maxValue )
|
||||
|
||||
Progress Bar control, shows current progress value
|
||||
|
||||
- Success return float
|
||||
|
||||
---
|
||||
|
||||
> value = RL.GuiScrollBar( Rectangle bounds, int value, int minValue, int maxValue )
|
||||
|
||||
Scroll Bar control
|
||||
|
||||
- Success return int
|
||||
|
||||
---
|
||||
|
||||
> pressed, item = RL.GuiDropdownBox( Rectangle bounds, string text, int active, bool editMode )
|
||||
|
||||
Dropdown Box control, returns selected item
|
||||
|
||||
- Success return bool, int
|
||||
|
||||
---
|
||||
|
||||
> RL.GuiStatusBar( Rectangle bounds, string text )
|
||||
|
||||
Status Bar control, shows info text
|
||||
|
||||
---
|
||||
|
||||
> RL.GuiDummyRec( Rectangle bounds, string text )
|
||||
|
||||
Dummy control for placeholders
|
||||
|
||||
---
|
||||
|
||||
> cell = RL.GuiGrid( Rectangle bounds, string text, float spacing, int subdivs )
|
||||
|
||||
Grid control, returns mouse cell position
|
||||
|
||||
- Success return Vector2
|
||||
|
||||
---
|
||||
|
||||
## Gui - Advance controls set
|
||||
|
||||
---
|
||||
|
||||
> itemIndex, scrollIndex = RL.GuiListView( Rectangle bounds, string text, int scrollIndex, int active )
|
||||
|
||||
List View control, returns selected list item index and scroll index
|
||||
|
||||
- Success return int, int
|
||||
|
||||
---
|
||||
|
||||
> itemIndex, scrollIndex, focus = RL.GuiListViewEx( Rectangle bounds, string text, int focus, int scrollIndex, int active )
|
||||
|
||||
List View with extended parameters, returns selected list item index, scroll index and focus
|
||||
|
||||
- Success return int, int, int
|
||||
|
||||
---
|
||||
|
||||
> buttonIndex = RL.GuiMessageBox( Rectangle bounds, string title, string message, string buttons )
|
||||
|
||||
Message Box control, displays a message, returns button index (0 is x button)
|
||||
|
||||
- Success return int
|
||||
|
||||
---
|
||||
|
||||
> buttonIndex, text, secretViewActive = RL.GuiTextInputBox( Rectangle bounds, string title, string message, string buttons, string text, int textMaxSize, int secretViewActive )
|
||||
|
||||
Text Input Box control, ask for text, supports secret
|
||||
|
||||
- Success return int, string, int
|
||||
|
||||
---
|
||||
|
||||
> color = RL.GuiColorPicker( Rectangle bounds, string text, Color color )
|
||||
|
||||
Color Picker control (multiple color controls)
|
||||
|
||||
- Success return Color
|
||||
|
||||
---
|
||||
|
||||
> color = RL.GuiColorPanel( Rectangle bounds, string text, Color color )
|
||||
|
||||
Color Panel control
|
||||
|
||||
- Success return Color
|
||||
|
||||
---
|
||||
|
||||
> alpha = RL.GuiColorBarAlpha( Rectangle bounds, string text, float alpha )
|
||||
|
||||
Color Bar Alpha control
|
||||
|
||||
- Success return float
|
||||
|
||||
---
|
||||
|
||||
> hue = RL.GuiColorBarHue( Rectangle bounds, string text, float value )
|
||||
|
||||
Color Bar Hue control
|
||||
|
||||
- Success return float
|
||||
|
||||
---
|
||||
|
||||
## Gui - Styles loading functions
|
||||
|
||||
---
|
||||
@@ -8635,7 +8415,7 @@ Color Bar Hue control
|
||||
|
||||
Load style file over global style variable (.rgs)
|
||||
|
||||
- Failure return false
|
||||
- Failure return nil
|
||||
- Success return true
|
||||
|
||||
---
|
||||
@@ -8646,6 +8426,28 @@ Load style default over global style
|
||||
|
||||
---
|
||||
|
||||
## Gui - Tooltips management functions
|
||||
|
||||
---
|
||||
|
||||
> RL.GuiEnableTooltip()
|
||||
|
||||
Enable gui tooltips (global state)
|
||||
|
||||
---
|
||||
|
||||
> RL.GuiDisableTooltip()
|
||||
|
||||
Disable gui tooltips (global state)
|
||||
|
||||
---
|
||||
|
||||
> RL.GuiSetTooltip( string tooltip )
|
||||
|
||||
Set tooltip string
|
||||
|
||||
---
|
||||
|
||||
## Gui - Icons functionality
|
||||
|
||||
---
|
||||
@@ -8658,38 +8460,319 @@ Get text with icon id prepended (if supported)
|
||||
|
||||
---
|
||||
|
||||
> RL.GuiDrawIcon( int iconId, Vector2 pos, int pixelSize, Color color )
|
||||
|
||||
Draw icon
|
||||
|
||||
---
|
||||
|
||||
> RL.GuiSetIconScale( int scale )
|
||||
|
||||
Set icon scale (1 by default)
|
||||
|
||||
---
|
||||
|
||||
> RL.GuiSetIconPixel( int iconId, Vector2 pos )
|
||||
> icons = RL.GuiGetIcons()
|
||||
|
||||
Set icon pixel value
|
||||
Get raygui icons data pointer
|
||||
|
||||
- Success return int
|
||||
|
||||
---
|
||||
|
||||
> RL.GuiClearIconPixel( int iconId, Vector2 pos )
|
||||
> iconNames = RL.GuiLoadIcons( string fileName, bool loadIconsName )
|
||||
|
||||
Clear icon pixel value
|
||||
Load raygui icons file (.rgi) into internal icons data
|
||||
|
||||
- Failure return nil
|
||||
- Success return strings{}
|
||||
|
||||
---
|
||||
|
||||
> value = RL.GuiCheckIconPixel( int iconId, Vector2 pos )
|
||||
> RL.GuiDrawIcon( int iconId, Vector2 pos, int pixelSize, Color color )
|
||||
|
||||
Check icon pixel value
|
||||
Draw icon
|
||||
|
||||
---
|
||||
|
||||
## Gui - Container/separator controls, useful for controls organization
|
||||
|
||||
---
|
||||
|
||||
> result = RL.GuiWindowBox( Rectangle bounds, string title )
|
||||
|
||||
Window Box control, shows a window that can be closed
|
||||
|
||||
- Success return int
|
||||
|
||||
---
|
||||
|
||||
> result = RL.GuiGroupBox( Rectangle bounds, string text )
|
||||
|
||||
Group Box control with text name
|
||||
|
||||
- Success return int
|
||||
|
||||
---
|
||||
|
||||
> result = RL.GuiLine( Rectangle bounds, string text )
|
||||
|
||||
Line separator control, could contain text
|
||||
|
||||
- Success return int
|
||||
|
||||
---
|
||||
|
||||
> result = RL.GuiPanel( Rectangle bounds, string text )
|
||||
|
||||
Panel control, useful to group controls
|
||||
|
||||
- Success return int
|
||||
|
||||
---
|
||||
|
||||
> result, active = RL.GuiTabBar( Rectangle bounds, string text, int active )
|
||||
|
||||
Tab Bar control, returns TAB to be closed or -1
|
||||
|
||||
- Success return int, int
|
||||
|
||||
---
|
||||
|
||||
> result, scroll, view = RL.GuiScrollPanel( Rectangle bounds, string text, Rectangle content, Vector2 scroll, Rectangle view )
|
||||
|
||||
Scroll Panel control
|
||||
|
||||
- Success return int, Vector2, Rectangle
|
||||
|
||||
---
|
||||
|
||||
## Gui - Basic controls set
|
||||
|
||||
---
|
||||
|
||||
> result = RL.GuiLabel( Rectangle bounds, string text )
|
||||
|
||||
Label control, shows text
|
||||
|
||||
- Success return int
|
||||
|
||||
---
|
||||
|
||||
> result = RL.GuiButton( Rectangle bounds, string text )
|
||||
|
||||
Button control, returns true when clicked
|
||||
|
||||
- Success return int
|
||||
|
||||
---
|
||||
|
||||
> result = RL.GuiLabelButton( Rectangle bounds, string text )
|
||||
|
||||
Label button control, show true when clicked
|
||||
|
||||
- Success return int
|
||||
|
||||
---
|
||||
|
||||
> result, active = RL.GuiToggle( Rectangle bounds, string text, bool active )
|
||||
|
||||
Toggle Button control, returns true when active
|
||||
|
||||
- Success return int, bool
|
||||
|
||||
---
|
||||
|
||||
> result, active = RL.GuiToggleGroup( Rectangle bounds, string text, int active )
|
||||
|
||||
Toggle Group control, returns active toggle index
|
||||
|
||||
- Success return int, int
|
||||
|
||||
---
|
||||
|
||||
> result, active = RL.GuiToggleSlider( Rectangle bounds, string text, int active )
|
||||
|
||||
Toggle Slider control, returns true when clicked
|
||||
|
||||
- Success return int, int
|
||||
|
||||
---
|
||||
|
||||
> result, checked = RL.GuiCheckBox( Rectangle bounds, string text, bool checked )
|
||||
|
||||
Check Box control, returns true when active
|
||||
|
||||
- Success return bool
|
||||
|
||||
---
|
||||
|
||||
> result, active = RL.GuiComboBox( Rectangle bounds, string text, int active )
|
||||
|
||||
Combo Box control, returns selected item index
|
||||
|
||||
- Success return int, int
|
||||
|
||||
---
|
||||
|
||||
> result, active = RL.GuiDropdownBox( Rectangle bounds, string text, int active, bool editMode )
|
||||
|
||||
Dropdown Box control, returns selected item
|
||||
|
||||
- Success return int, int
|
||||
|
||||
---
|
||||
|
||||
> result, value = RL.GuiSpinner( Rectangle bounds, string text, int value, int minValue, int maxValue, bool editMode )
|
||||
|
||||
Spinner control, returns selected value
|
||||
|
||||
- Success return int, int
|
||||
|
||||
---
|
||||
|
||||
> result, value = RL.GuiValueBox( Rectangle bounds, string text, int value, int minValue, int maxValue, bool editMode )
|
||||
|
||||
Value Box control, updates input text with numbers
|
||||
|
||||
- Success return int, int
|
||||
|
||||
---
|
||||
|
||||
> result, text = RL.GuiTextBox( Rectangle bounds, string text, int textSize, bool editMode )
|
||||
|
||||
Text Box control, updates input text
|
||||
|
||||
- Success return int, string
|
||||
|
||||
---
|
||||
|
||||
> result, value = RL.GuiSlider( Rectangle bounds, string textLeft, string textRight, float value, float minValue, float maxValue )
|
||||
|
||||
Slider control, returns selected value
|
||||
|
||||
- Success return int, float
|
||||
|
||||
---
|
||||
|
||||
> result, value = RL.GuiSliderBar( Rectangle bounds, string textLeft, string textRight, float value, float minValue, float maxValue )
|
||||
|
||||
Slider Bar control, returns selected value
|
||||
|
||||
- Success return int, float
|
||||
|
||||
---
|
||||
|
||||
> result, value = RL.GuiProgressBar( Rectangle bounds, string textLeft, string textRight, float value, float minValue, float maxValue )
|
||||
|
||||
Progress Bar control, shows current progress value
|
||||
|
||||
- Success return int, float
|
||||
|
||||
---
|
||||
|
||||
> result = RL.GuiStatusBar( Rectangle bounds, string text )
|
||||
|
||||
Status Bar control, shows info text
|
||||
|
||||
- Success return int
|
||||
|
||||
---
|
||||
|
||||
> result = RL.GuiDummyRec( Rectangle bounds, string text )
|
||||
|
||||
Dummy control for placeholders
|
||||
|
||||
- Success return int
|
||||
|
||||
---
|
||||
|
||||
> result, mouseCell = RL.GuiGrid( Rectangle bounds, string text, float spacing, int subdivs, Vector2 mouseCell )
|
||||
|
||||
Grid control, returns mouse cell position
|
||||
|
||||
- Success return int, Vector2
|
||||
|
||||
---
|
||||
|
||||
## Gui - Advance controls set
|
||||
|
||||
---
|
||||
|
||||
> result, scrollIndex, active = RL.GuiListView( Rectangle bounds, string text, int scrollIndex, int active )
|
||||
|
||||
List View control, returns selected list item index
|
||||
|
||||
- Success return int, int, int
|
||||
|
||||
---
|
||||
|
||||
> result, scrollIndex, active, focus = RL.GuiListViewEx( Rectangle bounds, string text, int scrollIndex, int active, int focus )
|
||||
|
||||
List View with extended parameters
|
||||
|
||||
- Success return int, int, int, int
|
||||
|
||||
---
|
||||
|
||||
> result = RL.GuiMessageBox( Rectangle bounds, string title, string message, string buttons )
|
||||
|
||||
Message Box control, displays a message
|
||||
|
||||
- Success return int
|
||||
|
||||
---
|
||||
|
||||
> result, text, secretViewActive = RL.GuiTextInputBox( Rectangle bounds, string title, string message, string buttons, string text, int textMaxSize, bool secretViewActive )
|
||||
|
||||
Text Input Box control, ask for text, supports secret
|
||||
|
||||
- Success return int, string, bool
|
||||
|
||||
---
|
||||
|
||||
> result, color = RL.GuiColorPicker( Rectangle bounds, string text, Color color )
|
||||
|
||||
Color Picker control (multiple color controls)
|
||||
|
||||
- Success return int, Color
|
||||
|
||||
---
|
||||
|
||||
> result, color = RL.GuiColorPanel( Rectangle bounds, string text, Color color )
|
||||
|
||||
Color Panel control
|
||||
|
||||
- Success return int, Color
|
||||
|
||||
---
|
||||
|
||||
> result, alpha = RL.GuiColorBarAlpha( Rectangle bounds, string text, float alpha )
|
||||
|
||||
Color Bar Alpha control
|
||||
|
||||
- Success return int, float
|
||||
|
||||
---
|
||||
|
||||
> result, value = RL.GuiColorBarHue( Rectangle bounds, string text, float value )
|
||||
|
||||
Color Bar Hue control
|
||||
|
||||
- Success return int, float
|
||||
|
||||
---
|
||||
|
||||
> result, colorHsv = RL.GuiColorPickerHSV( Rectangle bounds, string text, Vector3 colorHsv )
|
||||
|
||||
Color Picker control that avoids conversion to RGB on each call (multiple color controls)
|
||||
|
||||
- Success return int, Vector3
|
||||
|
||||
---
|
||||
|
||||
> result, colorHsv = RL.GuiColorPanelHSV( Rectangle bounds, string text, Vector3 colorHsv )
|
||||
|
||||
Color Panel control that returns HSV color value, used by GuiColorPickerHSV()
|
||||
|
||||
- Success return int, Vector3
|
||||
|
||||
---
|
||||
|
||||
## Lights - Light management functions
|
||||
|
||||
---
|
||||
|
||||
Reference in New Issue
Block a user