User Tools

Site Tools



gui_api

Differences

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

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
gui_api [2020/05/14 13:22] moderagui_api [2024/06/23 13:09] (current) – [Layout] husbandomax
Line 324: Line 324:
     *Returns: //number//  FontSize + style.FramePadding.y * 2 + style.ItemSpacing.y (distance in pixels between 2 consecutive lines of framed widgets)     *Returns: //number//  FontSize + style.FramePadding.y * 2 + style.ItemSpacing.y (distance in pixels between 2 consecutive lines of framed widgets)
  
 +  ***''GUI:BeginTable()''**
 +    *Description: Begins a new table.
  
 +  ***''GUI:EndTable()''**
 +    *Description: Ends the current table.
 +
 +  ***''GUI:TableNextRow()''**
 +    *Description: Moves to the next row in the table.
 +
 +  ***''GUI:TableNextColumn()''**
 +    *Description: Moves to the next column in the current row of the table.
 +
 +  ***''GUI:TableSetColumnIndex(//number// column_index)''**
 +    *Description: Sets the current column index.
 +    *Parameter:
 +    *column_index: //number// — The index of the column to set.
 +
 +  ***''GUI:TableGetColumnIndex()''**
 +    *Returns: //number// — The current column index.
 +
 +  ***''GUI:TableGetRowIndex()''**
 +    *Returns: //number// — The current row index.
 +
 +  ***''GUI:TableGetColumnCount()''**
 +    *Returns: //number// — The //number// of columns in the table.
 +
 +  ***''GUI:TableGetColumnFlags(//number// column_index)''**
 +    *Returns: //number// — The flags of the specified column.
 +    *Parameter:
 +    *column_index: //number// — The index of the column.
 +
 +  ***''GUI:TableSetBgColor(//number// color)''**
 +    *Description: Sets the background color for the table.
 +    *Parameter:
 +    *color: //number// — The color value.
 +
 +  ***''GUI:TableSetColumnWidth(//number// column_index, //number// width)''**
 +    *Description: Sets the width of the specified column.
 +    *Parameters:
 +    *column_index: //number// — The index of the column.
 +    *width: //number// — The width to set.
 +
 +  ***''GUI:TableSetColumnSortDirection(//number// column_index, //boolean// ascending)''**
 +    *Description: Sets the sort direction for the specified column.
 +    *Parameters:
 +    *column_index: //number// — The index of the column.
 +    *ascending: //boolean// — true for ascending, false for descending.
 +
 +  ***''GUI:TableSetupColumn(//string// label, //number// flags, //number// init_width_or_weight)''**
 +    *Description: Sets up a column with the specified label and parameters.
 +    *Parameters:
 +    *label: //string// — The label of the column.
 +    *flags: //number// — The flags for the column.
 +    *init_width_or_weight: //number// — The initial width or weight of the column.
 +
 +  ***''GUI:TableHeadersRow()''**
 +    *Description: Adds a row of headers to the table.
 +
 +  ***''GUI:TableHeader(//string// label)''**
 +    *Description: Adds a header to the table.
 +    *Parameter:
 +    *label: //string// — The label of the header.
 +
 +  ***''GUI:TableSetupScrollFreeze(//number// cols, //number// rows)''**
 +    *Description: Freezes the specified number of columns and rows for scrolling.
 +    *Parameters:
 +    *cols: //number// — The number of columns to freeze.
 +    *rows: //number// — The number of rows to freeze.
 +
 +  ***''GUI:TableGetColumnName(//number// column_index)''**
 +    *Returns: //string// — The name of the specified column.
 +    *Parameter:
 +    *column_index: //number// — The index of the column.
 +
 +  ***''GUI:TableSetColumnEnabled(//number// column_index, //boolean// enabled)''**
 +    *Description: Sets the specified column as enabled or disabled.
 +    *Parameters:
 +    *column_index: //number// — The index of the column.
 +    *enabled: //boolean// — true to enable, false to disable.
 +
 +  ***''GUI:BeginTabBar()''**
 +    *Description: Begins a new tab bar.
 +
 +  ***''GUI:EndTabBar()''**
 +    *Description: Ends the current tab bar.
 +
 +  ***''GUI:BeginTabItem(//string// label)''**
 +    *Description: Begins a new tab item with the specified label.
 +    *Parameter:
 +    *label: //string// — The label of the tab item.
 +
 +  ***''GUI:EndTabItem()''**
 +    *Description: Ends the current tab item.
 +
 +  ***''GUI:TabItemButton(//string// label)''**
 +    *Description: Adds a button to the tab item with the specified label.
 +    *Parameter:
 +    *label: //string// — The label of the button.
 +
 +  ***''GUI:SetTabItemClosed(//string// label)''**
 +    *Description: Closes the tab item with the specified label.
 +    *Parameter:
 +    *label: //string// — The label of the tab item to close.
 ===Cursor=== ===Cursor===
   ***''GUI:GetCursorPos( )''**   ***''GUI:GetCursorPos( )''**
Line 610: Line 712:
 ===Widgets Tooltip=== ===Widgets Tooltip===
   ***''GUI:SetTooltip( //string// label )''**   ***''GUI:SetTooltip( //string// label )''**
-    *set tooltip under mouse-cursor, typically use with GUI:IsHovered(). last call wins+    *set tooltip under mouse-cursor, typically use with GUI:IsItemHovered. last call wins
   ***''GUI:BeginTooltip( )''**   ***''GUI:BeginTooltip( )''**
     *use to create full-featured tooltip windows that aren't just text     *use to create full-featured tooltip windows that aren't just text
Line 809: Line 911:
   ***''GUI:ResetMouseDragDelta( __//number// button__)''**   ***''GUI:ResetMouseDragDelta( __//number// button__)''**
     *Banana ;)     *Banana ;)
 +
 +  ***''GUI:GetMouseScroll( __//number// button__)''**
 +    *Returns: //number// scrollV, //number// scrollH     
  
   ***''GUI:GetClipboardText()''**   ***''GUI:GetClipboardText()''**
Line 816: Line 921:
     *set text data to the clipboard     *set text data to the clipboard
  
 +  ***''GUI:IsItemEdited()''**
 +    *Returns: //boolean// — true if the item was edited.
 +
 +  ***''GUI:IsItemActivated()''**
 +    *Returns: //boolean// — true if the item was activated.
 +
 +  ***''GUI:IsItemDeactivated()''**
 +    *Returns: //boolean// — true if the item was deactivated.
 +
 +  ***''GUI:IsItemDeactivatedAfterEdit()''**
 +    *Returns: //boolean// — true if the item was deactivated after an edit.
 +
 +  ***''GUI:IsItemToggledOpen()''**
 +    *Returns: //boolean// — true if the item was toggled open.
 +
 +  ***''GUI:GetItemID()''**
 +    *Returns: //number// — The ID of the item.
 +
 +  ***''GUI:GetMouseClickedCount(//number// button)''**
 +    *Returns: //number// — The number of times the specified mouse button was clicked.
 +    *Parameter:
 +    *button: //number// — The mouse button.
 +
 +  ***''GUI:IsMousePosValid()''**
 +    *Returns: //boolean// — true if the mouse position is valid.
  
 +  ***''GUI:IsAnyMouseDown()''**
 +    *Returns: //boolean// — true if any mouse button is down.
  
 ===Custom Widgets=== ===Custom Widgets===
gui_api.1589462566.txt.gz · Last modified: 2020/05/14 13:22 by modera