• skip to content

Wiki

User Tools

  • Admin
  • Log In

Site Tools

  • Recent Changes
  • Media Manager
  • Sitemap
Trace:

dev:v3:gui_api:dialog:inputgui3

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
dev:v3:gui_api:dialog:inputgui3 [2020/07/09 14:56] – created jedi18dev:v3:gui_api:dialog:inputgui3 [2020/07/10 03:49] (current) – jedi18
Line 68: Line 68:
  
   * <code lua> text1:addOnChangeCallback(function(newtext) message(tostring(newtext)) end) </code>   * <code lua> text1:addOnChangeCallback(function(newtext) message(tostring(newtext)) end) </code>
 +
 +----
 +
 +===== Color Picker GUI Class =====
 +
 +----
 +
 +[[https://github.com/LibreCAD/LibreCAD_3/blob/master/lcUI/widgets/guiAPI/colorgui.h|Github Link]]
 +<code cpp-qt> namespace lc::ui::api </code>
 +
 +The Color Picker GUI widget allows the user to enter color data by choosing it visually.
 +----
 +
 +==== Constructor ====
 +
 +----
 +
 +=== Description ===
 +
 +Constructs a Color GUI widget.
 +
 +=== Examples ===
 +
 +  * <code lua> local color1 = gui.Color("Color1") </code>
 +
 +----
 +
 +==== Get and Set Values ====
 +
 +----
 +
 +=== Description ===
 +
 +Used to get and set the desired value for the color widget. Data of type //lc::Color// is returned. setValue expects a //lc::Color// as parameter.
 +
 +=== Examples ===
 +
 +  * <code lua> local col = color1:value() </code>
 +  * <code lua> color1:setValue(lc.Color(1,1,1)) </code>
 +
 +----
 +
 +==== Add Callback ====
 +
 +----
 +
 +=== Description ===
 +
 +Adds a callback which is called whenever a color is selected in the color gui widget.
 +
 +=== Examples ===
 +
 +  * <code lua> color1:addCallback(function(col) message("Color picked") end) </code>
 +
 +----
 +
 +===== Horizontal Group GUI Class =====
 +
 +----
 +
 +[[https://github.com/LibreCAD/LibreCAD_3/blob/master/lcUI/widgets/guiAPI/horizontalgroupgui.h|Github Link]]
 +<code cpp-qt> namespace lc::ui::api </code>
 +
 +The Horizontal Group GUI widget allows the user to store the input gui widgets in a horizontal layout.
 +----
 +
 +==== Constructor ====
 +
 +----
 +
 +=== Description ===
 +
 +Constructs a Horizontal Group GUi widget. The input gui widgets in the group are added to the final value table but not the horizontal group.
 +
 +=== Examples ===
 +
 +  * <code lua> local horiz1 = gui.HorizontalGroup("Horizontal1") </code>
 +
 +----
 +
 +==== Add Input GUI Widget ====
 +
 +----
 +
 +=== Description ===
 +
 +Add an Input GUI widget to the horizontal group. Expects a key and gui widget as parameters.
 +
 +=== Examples ===
 +
 +  * <code lua> local angle1 = gui.Angle("Angle1") 
 + horiz1:addWidget("angle1", angle1) </code>
 +
 +----
 +
 +===== RadioButton Group GUI Class =====
 +
 +----
 +
 +[[https://github.com/LibreCAD/LibreCAD_3/blob/master/lcUI/widgets/guiAPI/radiogroupgui.h|Github Link]]
 +<code cpp-qt> namespace lc::ui::api </code>
 +
 +The RadioButton Group GUI widget allows the user to store the radio buttons in a group so that only one radio button can be selected in the group.
 +----
 +
 +==== Constructor ====
 +
 +----
 +
 +=== Description ===
 +
 +Constructs a RadioButton Group GUI class.
 +
 +=== Examples ===
 +
 +  * <code lua> local radiogroup1 = gui.RadioGroup("RadioGroup1") </code>
 +
 +----
 +
 +==== Add Radio Button ====
 +
 +----
 +
 +=== Description ===
 +
 +Add an RadioButton GUI widget to the radio group. Expects a key and radiobutton as parameters.
 +
 +=== Examples ===
 +
 +  * <code lua> local radio1 = gui.RadioButton("Radio1") 
 + radiogroup1:addButton("radio1", radio1) </code>
  
 ---- ----
dev/v3/gui_api/dialog/inputgui3.1594306609.txt.gz · Last modified: 2020/07/09 14:56 by jedi18

Page Tools

  • Show page
  • Old revisions
  • Backlinks
  • Export to PDF
  • Rename Page
  • Back to top
Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki