Interface GuiSetting
- All Known Subinterfaces:
ActionSetting, BindSetting, ColorSetting, EditorSetting, GroupSetting, ModeSetting, NumberSetting, PageSetting, RangeSetting, TextSetting, ToggleSetting
public sealed interface GuiSetting
permits ToggleSetting, NumberSetting, RangeSetting, ModeSetting, BindSetting, ColorSetting, GroupSetting, PageSetting, TextSetting, ActionSetting, EditorSetting
One setting row.
-
Method Details
-
id
String id()- Returns:
- Setting name, stable and used by commands
-
label
String label()- Returns:
- Display name
-
description
String description() -
module
GuiModule module() -
parent
GuiSetting parent()- Returns:
- The setting this one is nested under, or null. Pages are not parents, see
page().
-
page
PageSetting page()- Returns:
- The page this setting is listed on, or null for the main list
-
depth
int depth()- Returns:
- Number of parents above this setting
-
children
List<GuiSetting> children()- Returns:
- Settings nested directly under this one
-
isVisible
boolean isVisible()- Returns:
- Whether the setting is visible by its own conditions, its page and its parents' conditions. Ignores whether parents are expanded.
-
isShown
boolean isShown()- Returns:
- Whether the setting is visible and every parent is expanded
-
isExpanded
boolean isExpanded()- Returns:
- Whether the setting's children are expanded
-
setExpanded
void setExpanded(boolean expanded) -
hasVisibleChildren
boolean hasVisibleChildren() -
option
Option<?> option()- Returns:
- The addon API option behind this setting, or null
-
markDescriptionSeen
void markDescriptionSeen()Marks the description as read.
-