cpw.mods.fml.client.config

## Class GuiConfigEntries

- java.lang.Object
- - net.minecraft.client.gui.GuiSlot
  - - net.minecraft.client.gui.GuiListExtended
    - - cpw.mods.fml.client.config.GuiConfigEntries

-     public class GuiConfigEntries
      extends GuiListExtended

  This class implements the scrolling list functionality of the config GUI screens. It also provides all the default control handlers for the various property types.

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `GuiConfigEntries.ArrayEntry` ArrayEntry Provides a GuiButton with the list contents as the displayString.
    `static class` | `GuiConfigEntries.BooleanEntry` BooleanPropEntry Provides a GuiButton that toggles between true and false.
    `static class` | `GuiConfigEntries.ButtonEntry` ButtonEntry Provides a basic GuiButton entry to be used as a base for other entries that require a button for the value.
    `static class` | `GuiConfigEntries.CategoryEntry` CategoryEntry Provides an entry that consists of a GuiButton for navigating to the child category GuiConfig screen.
    `static class` | `GuiConfigEntries.ChatColorEntry` ChatColorEntry Provides a GuiButton that cycles through the list of chat color codes.
    `static class` | `GuiConfigEntries.CycleValueEntry` CycleValueEntry Provides a GuiButton that cycles through the prop's validValues array.
    `static class` | `GuiConfigEntries.DoubleEntry` DoubleEntry Provides a GuiTextField for user input.
    `static interface` | `GuiConfigEntries.IConfigEntry<T>` Provides an interface for defining GuiPropertyList.listEntry objects.
    `static class` | `GuiConfigEntries.IntegerEntry` IntegerEntry Provides a GuiTextField for user input.
    `static class` | `GuiConfigEntries.ListEntryBase` ListEntryBase Provides a base entry for others to extend.
    `static class` | `GuiConfigEntries.SelectValueEntry` SelectValueEntry Provides a GuiButton with the current value as the displayString.
    `static class` | `GuiConfigEntries.StringEntry` StringEntry Provides a GuiTextField for user input.

    - ### Nested classes/interfaces inherited from class net.minecraft.client.gui.GuiListExtended

      `GuiListExtended.IGuiListEntry`

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `int` | `controlWidth` The width of the control.
    `int` | `controlX` The x position where the control should be drawn.
    `int` | `labelX` The x position where the label should be drawn.
    `java.util.List<GuiConfigEntries.IConfigEntry>` | `listEntries`
    `int` | `maxEntryRightBound` The max x boundary of all IConfigEntry objects.
    `int` | `maxLabelTextWidth` The max width of the label of all IConfigEntry objects.
    `Minecraft` | `mc`
    `GuiConfig` | `owningScreen`
    `int` | `resetX` The minimum x position where the Undo/Default buttons will start
    `int` | `scrollBarX` The x position of the scroll bar.

    - ### Fields inherited from class net.minecraft.client.gui.GuiSlot

      `bottom, field_148163_i, headerPadding, height, left, mouseX, mouseY, right, slotHeight, top, width`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `GuiConfigEntries(GuiConfig parent, Minecraft mc)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `areAllEntriesDefault(boolean includeChildren)` Returns true if all IConfigEntry objects on this screen are set to default.
    `boolean` | `areAnyEntriesEnabled(boolean includeChildren)` Returns true if any IConfigEntry objects on this screen are enabled.
    `void` | `drawScreenPost(int mouseX, int mouseY, float partialTicks)` Calls the drawToolTip() method for all IConfigEntry objects on this screen.
    `GuiConfigEntries.IConfigEntry` | `getListEntry(int index)` Gets the IGuiListEntry object for the given index
    `int` | `getListWidth()` Gets the width of the list
    `int` | `getScrollBarX()`
    `int` | `getSize()`
    `boolean` | `hasChangedEntry(boolean includeChildren)` Returns true if any IConfigEntry objects on this screen are changed.
    `protected void` | `initGui()`
    `void` | `keyTyped(char eventChar, int eventKey)` This method is a pass-through for IConfigEntry objects that require keystrokes.
    `void` | `mouseClicked(int mouseX, int mouseY, int mouseEvent)` This method is a pass-through for IConfigEntry objects that contain GuiTextField elements.
    `void` | `onGuiClosed()` This method is a pass-through for IConfigListEntry objects that need to perform actions when the containing GUI is closed.
    `boolean` | `saveConfigElements()` Saves all properties on this screen / child screens.
    `void` | `setAllToDefault(boolean includeChildren)` Sets all IConfigEntry objects on this screen to default.
    `void` | `undoAllChanges(boolean includeChildren)` Reverts changes to all IConfigEntry objects on this screen.
    `void` | `updateScreen()` This method is a pass-through for IConfigEntry objects that contain GuiTextField elements.

    - ### Methods inherited from class net.minecraft.client.gui.GuiListExtended

      `drawBackground, drawSlot, elementClicked, func_148179_a, func_148181_b, isSelected`

    - ### Methods inherited from class net.minecraft.client.gui.GuiSlot

      `actionPerformed, drawContainerBackground, drawListHeader, drawScreen, drawSelectionBox, func_148122_a, func_148124_c, func_148125_i, func_148132_a, func_148135_f, func_148141_e, func_148142_b, func_148143_b, getAmountScrolled, getContentHeight, getSlotHeight, registerScrollButtons, scrollBy, setHasListHeader, setShowSelectionBox, setSlotXBoundsFromLeft`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### owningScreen

          public final GuiConfig owningScreen

    - #### mc

          public final Minecraft mc

    - #### listEntries

          public java.util.List<GuiConfigEntries.IConfigEntry> listEntries

    - #### maxLabelTextWidth

          public int maxLabelTextWidth

      The max width of the label of all IConfigEntry objects.

    - #### maxEntryRightBound

          public int maxEntryRightBound

      The max x boundary of all IConfigEntry objects.

    - #### labelX

          public int labelX

      The x position where the label should be drawn.

    - #### controlX

          public int controlX

      The x position where the control should be drawn.

    - #### controlWidth

          public int controlWidth

      The width of the control.

    - #### resetX

          public int resetX

      The minimum x position where the Undo/Default buttons will start

    - #### scrollBarX

          public int scrollBarX

      The x position of the scroll bar.

  - ### Constructor Detail

    - #### GuiConfigEntries

          public GuiConfigEntries(GuiConfig parent,
                          Minecraft mc)

  - ### Method Detail

    - #### initGui

          protected void initGui()

    - #### getSize

          public int getSize()

      Specified by:
        `getSize` in class `GuiSlot`

    - #### getListEntry

          public GuiConfigEntries.IConfigEntry getListEntry(int index)

      Gets the IGuiListEntry object for the given index
      Specified by:
        `getListEntry` in class `GuiListExtended`

    - #### getScrollBarX

          public int getScrollBarX()

      Overrides:
        `getScrollBarX` in class `GuiSlot`

    - #### getListWidth

          public int getListWidth()

      Gets the width of the list
      Overrides:
        `getListWidth` in class `GuiSlot`

    - #### keyTyped

          public void keyTyped(char eventChar,
                      int eventKey)

      This method is a pass-through for IConfigEntry objects that require keystrokes. Called from the parent GuiConfig screen.

    - #### updateScreen

          public void updateScreen()

      This method is a pass-through for IConfigEntry objects that contain GuiTextField elements. Called from the parent GuiConfig screen.

    - #### mouseClicked

          public void mouseClicked(int mouseX,
                          int mouseY,
                          int mouseEvent)

      This method is a pass-through for IConfigEntry objects that contain GuiTextField elements. Called from the parent GuiConfig screen.

    - #### onGuiClosed

          public void onGuiClosed()

      This method is a pass-through for IConfigListEntry objects that need to perform actions when the containing GUI is closed.

    - #### saveConfigElements

          public boolean saveConfigElements()

      Saves all properties on this screen / child screens. This method returns true if any elements were changed that require a restart for proper handling.

    - #### areAllEntriesDefault

          public boolean areAllEntriesDefault(boolean includeChildren)

      Returns true if all IConfigEntry objects on this screen are set to default. If includeChildren is true sub-category objects are checked as well.

    - #### setAllToDefault

          public void setAllToDefault(boolean includeChildren)

      Sets all IConfigEntry objects on this screen to default. If includeChildren is true sub-category objects are set as well.

    - #### hasChangedEntry

          public boolean hasChangedEntry(boolean includeChildren)

      Returns true if any IConfigEntry objects on this screen are changed. If includeChildren is true sub-category objects are checked as well.

    - #### areAnyEntriesEnabled

          public boolean areAnyEntriesEnabled(boolean includeChildren)

      Returns true if any IConfigEntry objects on this screen are enabled. If includeChildren is true sub-category objects are checked as well.

    - #### undoAllChanges

          public void undoAllChanges(boolean includeChildren)

      Reverts changes to all IConfigEntry objects on this screen. If includeChildren is true sub-category objects are reverted as well.

    - #### drawScreenPost

          public void drawScreenPost(int mouseX,
                            int mouseY,
                            float partialTicks)

      Calls the drawToolTip() method for all IConfigEntry objects on this screen. This is called from the parent GuiConfig screen after drawing all other elements.