This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
gui_api [2018/09/07 07:45] – fxfire | gui_api [2019/08/16 08:29] – [Style] jorith | ||
---|---|---|---|
Line 3: | Line 3: | ||
====GUI API Documentation==== | ====GUI API Documentation==== | ||
You can easily build your own ingame GUI or draw custom shapes / icons / pictures through LUA. | You can easily build your own ingame GUI or draw custom shapes / icons / pictures through LUA. | ||
- | Each rendered frame the " | + | Each rendered frame the " |
Simple demo code {{ :: | Simple demo code {{ :: | ||
+ | |||
+ | Example: | ||
To get you started, let's draw a simple window with a slider, create a new .lua file, add it to your addon' | To get you started, let's draw a simple window with a slider, create a new .lua file, add it to your addon' | ||
<code lua> | <code lua> | ||
Line 237: | Line 240: | ||
*size (also height in pixels) of current font with current scale applied | *size (also height in pixels) of current font with current scale applied | ||
- | ***'' | + | ***'' |
*per-window font scale. Adjust IO.FontGlobalScale if you want to scale all windows | *per-window font scale. Adjust IO.FontGlobalScale if you want to scale all windows | ||
Line 248: | Line 251: | ||
===Layout=== | ===Layout=== | ||
- | ***'' | + | ***'' |
* If a line does not start with text but with an Icon or other GUI Element, call this before drawing the text to align the height correctly. | * If a line does not start with text but with an Icon or other GUI Element, call this before drawing the text to align the height correctly. | ||
Line 871: | Line 874: | ||
* GUI.InputTextFlags_NoUndoRedo | * GUI.InputTextFlags_NoUndoRedo | ||
* GUI.InputTextFlags_CharsScientific | * GUI.InputTextFlags_CharsScientific | ||
+ | * GUI.InputTextFlags_Password | ||