瀏覽代碼

Added updateSelected

Signed-off-by: shedaniel <daniel@shedaniel.me>
shedaniel 5 年之前
父節點
當前提交
c40a6fae3d
共有 32 個文件被更改,包括 142 次插入16 次删除
  1. 1 1
      gradle.properties
  2. 5 2
      src/main/java/me/shedaniel/clothconfig2/ClothConfigInitializer.java
  3. 2 0
      src/main/java/me/shedaniel/clothconfig2/api/AbstractConfigEntry.java
  4. 7 1
      src/main/java/me/shedaniel/clothconfig2/gui/ClothConfigScreen.java
  5. 1 1
      src/main/java/me/shedaniel/clothconfig2/gui/entries/AbstractListListEntry.java
  6. 1 1
      src/main/java/me/shedaniel/clothconfig2/gui/entries/AbstractTextFieldListListEntry.java
  7. 2 0
      src/main/java/me/shedaniel/clothconfig2/gui/entries/BaseListCell.java
  8. 10 1
      src/main/java/me/shedaniel/clothconfig2/gui/entries/BaseListEntry.java
  9. 5 0
      src/main/java/me/shedaniel/clothconfig2/gui/entries/BooleanListEntry.java
  10. 5 0
      src/main/java/me/shedaniel/clothconfig2/gui/entries/DoubleListEntry.java
  11. 4 1
      src/main/java/me/shedaniel/clothconfig2/gui/entries/DoubleListListEntry.java
  12. 2 0
      src/main/java/me/shedaniel/clothconfig2/gui/entries/DropdownBoxEntry.java
  13. 6 0
      src/main/java/me/shedaniel/clothconfig2/gui/entries/EnumListEntry.java
  14. 6 0
      src/main/java/me/shedaniel/clothconfig2/gui/entries/FloatListEntry.java
  15. 4 1
      src/main/java/me/shedaniel/clothconfig2/gui/entries/FloatListListEntry.java
  16. 5 0
      src/main/java/me/shedaniel/clothconfig2/gui/entries/IntegerListEntry.java
  17. 4 1
      src/main/java/me/shedaniel/clothconfig2/gui/entries/IntegerListListEntry.java
  18. 5 0
      src/main/java/me/shedaniel/clothconfig2/gui/entries/IntegerSliderEntry.java
  19. 2 0
      src/main/java/me/shedaniel/clothconfig2/gui/entries/KeyCodeEntry.java
  20. 6 0
      src/main/java/me/shedaniel/clothconfig2/gui/entries/LongListEntry.java
  21. 4 1
      src/main/java/me/shedaniel/clothconfig2/gui/entries/LongListListEntry.java
  22. 5 0
      src/main/java/me/shedaniel/clothconfig2/gui/entries/LongSliderEntry.java
  23. 1 0
      src/main/java/me/shedaniel/clothconfig2/gui/entries/MultiElementListEntry.java
  24. 1 0
      src/main/java/me/shedaniel/clothconfig2/gui/entries/NestedListListEntry.java
  25. 5 1
      src/main/java/me/shedaniel/clothconfig2/gui/entries/SelectionListEntry.java
  26. 5 0
      src/main/java/me/shedaniel/clothconfig2/gui/entries/StringListEntry.java
  27. 4 1
      src/main/java/me/shedaniel/clothconfig2/gui/entries/StringListListEntry.java
  28. 8 1
      src/main/java/me/shedaniel/clothconfig2/gui/entries/SubCategoryListEntry.java
  29. 14 1
      src/main/java/me/shedaniel/clothconfig2/gui/entries/TextFieldListEntry.java
  30. 4 0
      src/main/java/me/shedaniel/clothconfig2/gui/entries/TextListEntry.java
  31. 3 0
      src/main/java/me/shedaniel/clothconfig2/gui/entries/TooltipListEntry.java
  32. 5 1
      src/main/java/me/shedaniel/clothconfig2/gui/widget/DynamicEntryListWidget.java

+ 1 - 1
gradle.properties

@@ -2,6 +2,6 @@ minecraft_version=20w12a
 yarn_mappings=20w12a+build.3
 loader_version=0.7.8+build.186
 fabric_version=0.5.4+build.310-1.16
-mod_version=3.2.1-unstable
+mod_version=3.3-unstable
 modmenu_version=1.11.0+build.2
 nec_version=1.2.3+1.15.1

+ 5 - 2
src/main/java/me/shedaniel/clothconfig2/ClothConfigInitializer.java

@@ -11,6 +11,7 @@ import me.shedaniel.clothconfig2.impl.EasingMethod;
 import me.shedaniel.clothconfig2.impl.EasingMethod.EasingMethodImpl;
 import me.shedaniel.clothconfig2.impl.EasingMethods;
 import me.shedaniel.clothconfig2.impl.builders.DropdownMenuBuilder;
+import me.shedaniel.clothconfig2.impl.builders.SubCategoryBuilder;
 import net.fabricmc.api.ClientModInitializer;
 import net.fabricmc.api.EnvType;
 import net.fabricmc.api.Environment;
@@ -302,8 +303,10 @@ public class ClothConfigInitializer implements ClientModInitializer {
         testing.addEntry(entryBuilder.startDoubleList("A list of Doubles", Arrays.asList(1d, 2d, 3d)).setDefaultValue(Arrays.asList(1d, 2d, 3d)).build());
         testing.addEntry(entryBuilder.startLongList("A list of Longs", Arrays.asList(1L, 2L, 3L)).setDefaultValue(Arrays.asList(1L, 2L, 3L)).build());
         testing.addEntry(entryBuilder.startStrList("A list of Strings", Arrays.asList("abc", "xyz")).setDefaultValue(Arrays.asList("abc", "xyz")).build());
-        testing.addEntry(entryBuilder.startColorField("A color field", 0x00ffff).setDefaultValue(0x00ffff).build());
-        testing.addEntry(entryBuilder.startColorField("An alpha color field", 0xff00ffff).setDefaultValue(0xff00ffff).setAlphaMode(true).build());
+        SubCategoryBuilder colors = entryBuilder.startSubCategory("Colors").setExpanded(true);
+        colors.add(entryBuilder.startColorField("A color field", 0x00ffff).setDefaultValue(0x00ffff).build());
+        colors.add(entryBuilder.startColorField("An alpha color field", 0xff00ffff).setDefaultValue(0xff00ffff).setAlphaMode(true).build());
+        testing.addEntry(colors.build());
         return builder;
     }
     

+ 2 - 0
src/main/java/me/shedaniel/clothconfig2/api/AbstractConfigEntry.java

@@ -47,6 +47,8 @@ public abstract class AbstractConfigEntry<T> extends DynamicElementListWidget.El
         return screen;
     }
     
+    public void updateSelected(boolean isSelected) {}
+    
     @Deprecated
     public final void setScreen(ClothConfigScreen screen) {
         this.screen = screen;

+ 7 - 1
src/main/java/me/shedaniel/clothconfig2/gui/ClothConfigScreen.java

@@ -633,7 +633,6 @@ public abstract class ClothConfigScreen extends Screen {
     }
     
     public class ListWidget<R extends DynamicElementListWidget.ElementEntry<R>> extends DynamicElementListWidget<R> {
-        
         public ListWidget(MinecraftClient client, int width, int height, int top, int bottom, Identifier backgroundLocation) {
             super(client, width, height, top, bottom, backgroundLocation);
             visible = false;
@@ -657,6 +656,13 @@ public abstract class ClothConfigScreen extends Screen {
             this.clearItems();
         }
         
+        @Override
+        protected void renderItem(R item, int index, int y, int x, int entryWidth, int entryHeight, int mouseX, int mouseY, boolean isSelected, float delta) {
+            if (item instanceof AbstractConfigEntry)
+                ((AbstractConfigEntry) item).updateSelected(isSelected);
+            super.renderItem(item, index, y, x, entryWidth, entryHeight, mouseX, mouseY, isSelected, delta);
+        }
+        
         @Override
         public boolean mouseClicked(double double_1, double double_2, int int_1) {
             this.updateScrollingState(double_1, double_2, int_1);

+ 1 - 1
src/main/java/me/shedaniel/clothconfig2/gui/entries/AbstractListListEntry.java

@@ -19,13 +19,13 @@ import java.util.stream.Collectors;
  * @param <SELF> the "curiously recurring template pattern" type parameter
  * @see BaseListEntry
  */
-@ApiStatus.Internal
 @Environment(EnvType.CLIENT)
 public abstract class AbstractListListEntry<T, C extends AbstractListListEntry.AbstractListCell<T, C, SELF>, SELF extends AbstractListListEntry<T, C, SELF>> extends BaseListEntry<T, C, SELF> {
     
     protected final BiFunction<T, SELF, C> createNewCell;
     protected Function<T, Optional<String>> cellErrorSupplier;
     
+    @ApiStatus.Internal
     public AbstractListListEntry(String fieldName, List<T> value, boolean defaultExpanded, Supplier<Optional<String[]>> tooltipSupplier, Consumer<List<T>> saveConsumer, Supplier<List<T>> defaultValue, String resetButtonKey, boolean requiresRestart, boolean deleteButtonEnabled, boolean insertInFront, BiFunction<T, SELF, C> createNewCell) {
         super(fieldName, tooltipSupplier, defaultValue, abstractListListEntry -> createNewCell.apply(null, abstractListListEntry), saveConsumer, resetButtonKey, requiresRestart, deleteButtonEnabled, insertInFront);
         this.createNewCell = createNewCell;

+ 1 - 1
src/main/java/me/shedaniel/clothconfig2/gui/entries/AbstractTextFieldListListEntry.java

@@ -25,10 +25,10 @@ import java.util.function.Supplier;
  * @param <SELF> the "curiously recurring template pattern" type parameter
  * @see AbstractListListEntry
  */
-@ApiStatus.Internal
 @Environment(EnvType.CLIENT)
 public abstract class AbstractTextFieldListListEntry<T, C extends AbstractTextFieldListListEntry.AbstractTextFieldListCell<T, C, SELF>, SELF extends AbstractTextFieldListListEntry<T, C, SELF>> extends AbstractListListEntry<T, C, SELF> {
     
+    @ApiStatus.Internal
     public AbstractTextFieldListListEntry(String fieldName, List<T> value, boolean defaultExpanded, Supplier<Optional<String[]>> tooltipSupplier, Consumer<List<T>> saveConsumer, Supplier<List<T>> defaultValue, String resetButtonKey, boolean requiresRestart, boolean deleteButtonEnabled, boolean insertInFront, BiFunction<T, SELF, C> createNewCell) {
         super(fieldName, value, defaultExpanded, tooltipSupplier, saveConsumer, defaultValue, resetButtonKey, requiresRestart, deleteButtonEnabled, insertInFront, createNewCell);
     }

+ 2 - 0
src/main/java/me/shedaniel/clothconfig2/gui/entries/BaseListCell.java

@@ -32,4 +32,6 @@ public abstract class BaseListCell extends AbstractParentElement {
     
     public abstract void render(int index, int y, int x, int entryWidth, int entryHeight, int mouseX, int mouseY, boolean isSelected, float delta);
     
+    public void updateSelected(boolean isSelected) {}
+    
 }

+ 10 - 1
src/main/java/me/shedaniel/clothconfig2/gui/entries/BaseListEntry.java

@@ -33,7 +33,6 @@ import java.util.stream.Collectors;
  * @param <SELF> the "curiously recurring template pattern" type parameter
  * @implNote See <a href="https://stackoverflow.com/questions/7354740/is-there-a-way-to-refer-to-the-current-type-with-a-type-variable">Is there a way to refer to the current type with a type variable?</href> on Stack Overflow.
  */
-@ApiStatus.Internal
 @Environment(EnvType.CLIENT)
 public abstract class BaseListEntry<T, C extends BaseListCell, SELF extends BaseListEntry<T, C, SELF>> extends TooltipListEntry<List<T>> {
     
@@ -50,16 +49,19 @@ public abstract class BaseListEntry<T, C extends BaseListCell, SELF extends Base
     @NotNull protected Supplier<List<T>> defaultValue;
     @Nullable protected String addTooltip = I18n.translate("text.cloth-config.list.add"), removeTooltip = I18n.translate("text.cloth-config.list.remove");
     
+    @ApiStatus.Internal
     @Deprecated
     public BaseListEntry(@NotNull String fieldName, @Nullable Supplier<Optional<String[]>> tooltipSupplier, @NotNull Supplier<List<T>> defaultValue, @NotNull Function<SELF, C> createNewInstance, @Nullable Consumer<List<T>> saveConsumer, String resetButtonKey) {
         this(fieldName, tooltipSupplier, defaultValue, createNewInstance, saveConsumer, resetButtonKey, false);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public BaseListEntry(@NotNull String fieldName, @Nullable Supplier<Optional<String[]>> tooltipSupplier, @NotNull Supplier<List<T>> defaultValue, @NotNull Function<SELF, C> createNewInstance, @Nullable Consumer<List<T>> saveConsumer, String resetButtonKey, boolean requiresRestart) {
         this(fieldName, tooltipSupplier, defaultValue, createNewInstance, saveConsumer, resetButtonKey, requiresRestart, true, true);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public BaseListEntry(@NotNull String fieldName, @Nullable Supplier<Optional<String[]>> tooltipSupplier, @NotNull Supplier<List<T>> defaultValue, @NotNull Function<SELF, C> createNewInstance, @Nullable Consumer<List<T>> saveConsumer, String resetButtonKey, boolean requiresRestart, boolean deleteButtonEnabled, boolean insertInFront) {
         super(fieldName, tooltipSupplier, requiresRestart);
@@ -215,6 +217,13 @@ public abstract class BaseListEntry<T, C extends BaseListCell, SELF extends Base
         }
     }
     
+    @Override
+    public void updateSelected(boolean isSelected) {
+        for (C cell : cells) {
+            cell.updateSelected(isSelected && getFocused() == cell && expanded);
+        }
+    }
+    
     public boolean insertInFront() {
         return insertInFront;
     }

+ 5 - 0
src/main/java/me/shedaniel/clothconfig2/gui/entries/BooleanListEntry.java

@@ -8,6 +8,7 @@ import net.minecraft.client.gui.Element;
 import net.minecraft.client.gui.widget.ButtonWidget;
 import net.minecraft.client.resource.language.I18n;
 import net.minecraft.client.util.Window;
+import org.jetbrains.annotations.ApiStatus;
 
 import java.util.List;
 import java.util.Optional;
@@ -25,21 +26,25 @@ public class BooleanListEntry extends TooltipListEntry<Boolean> {
     private final Supplier<Boolean> defaultValue;
     private final List<Element> widgets;
     
+    @ApiStatus.Internal
     @Deprecated
     public BooleanListEntry(String fieldName, boolean bool, Consumer<Boolean> saveConsumer) {
         this(fieldName, bool, "text.cloth-config.reset_value", null, saveConsumer);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public BooleanListEntry(String fieldName, boolean bool, String resetButtonKey, Supplier<Boolean> defaultValue, Consumer<Boolean> saveConsumer) {
         this(fieldName, bool, resetButtonKey, defaultValue, saveConsumer, null);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public BooleanListEntry(String fieldName, boolean bool, String resetButtonKey, Supplier<Boolean> defaultValue, Consumer<Boolean> saveConsumer, Supplier<Optional<String[]>> tooltipSupplier) {
         this(fieldName, bool, resetButtonKey, defaultValue, saveConsumer, tooltipSupplier, false);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public BooleanListEntry(String fieldName, boolean bool, String resetButtonKey, Supplier<Boolean> defaultValue, Consumer<Boolean> saveConsumer, Supplier<Optional<String[]>> tooltipSupplier, boolean requiresRestart) {
         super(fieldName, tooltipSupplier, requiresRestart);

+ 5 - 0
src/main/java/me/shedaniel/clothconfig2/gui/entries/DoubleListEntry.java

@@ -4,6 +4,7 @@ import net.fabricmc.api.EnvType;
 import net.fabricmc.api.Environment;
 import net.minecraft.client.gui.widget.TextFieldWidget;
 import net.minecraft.client.resource.language.I18n;
+import org.jetbrains.annotations.ApiStatus;
 
 import java.util.Optional;
 import java.util.function.Consumer;
@@ -27,11 +28,13 @@ public class DoubleListEntry extends TextFieldListEntry<Double> {
     private double minimum, maximum;
     private Consumer<Double> saveConsumer;
     
+    @ApiStatus.Internal
     @Deprecated
     public DoubleListEntry(String fieldName, Double value, Consumer<Double> saveConsumer) {
         this(fieldName, value, "text.cloth-config.reset_value", null, saveConsumer);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public DoubleListEntry(String fieldName, Double value, String resetButtonKey, Supplier<Double> defaultValue, Consumer<Double> saveConsumer) {
         super(fieldName, value, resetButtonKey, defaultValue);
@@ -40,11 +43,13 @@ public class DoubleListEntry extends TextFieldListEntry<Double> {
         this.saveConsumer = saveConsumer;
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public DoubleListEntry(String fieldName, Double value, String resetButtonKey, Supplier<Double> defaultValue, Consumer<Double> saveConsumer, Supplier<Optional<String[]>> tooltipSupplier) {
         this(fieldName, value, resetButtonKey, defaultValue, saveConsumer, tooltipSupplier, false);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public DoubleListEntry(String fieldName, Double value, String resetButtonKey, Supplier<Double> defaultValue, Consumer<Double> saveConsumer, Supplier<Optional<String[]>> tooltipSupplier, boolean requiresRestart) {
         super(fieldName, value, resetButtonKey, defaultValue, tooltipSupplier, requiresRestart);

+ 4 - 1
src/main/java/me/shedaniel/clothconfig2/gui/entries/DoubleListListEntry.java

@@ -12,22 +12,25 @@ import java.util.Optional;
 import java.util.function.Consumer;
 import java.util.function.Supplier;
 
-@ApiStatus.Internal
 @Environment(EnvType.CLIENT)
 public class DoubleListListEntry extends AbstractTextFieldListListEntry<Double, DoubleListListEntry.DoubleListCell, DoubleListListEntry> {
     
     private double minimum, maximum;
     
+    @ApiStatus.Internal
     @Deprecated
     public DoubleListListEntry(String fieldName, List<Double> value, boolean defaultExpanded, Supplier<Optional<String[]>> tooltipSupplier, Consumer<List<Double>> saveConsumer, Supplier<List<Double>> defaultValue, String resetButtonKey) {
         this(fieldName, value, defaultExpanded, tooltipSupplier, saveConsumer, defaultValue, resetButtonKey, false);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public DoubleListListEntry(String fieldName, List<Double> value, boolean defaultExpanded, Supplier<Optional<String[]>> tooltipSupplier, Consumer<List<Double>> saveConsumer, Supplier<List<Double>> defaultValue, String resetButtonKey, boolean requiresRestart) {
         this(fieldName, value, defaultExpanded, tooltipSupplier, saveConsumer, defaultValue, resetButtonKey, requiresRestart, true, true);
     }
     
+    @ApiStatus.Internal
+    @Deprecated
     public DoubleListListEntry(String fieldName, List<Double> value, boolean defaultExpanded, Supplier<Optional<String[]>> tooltipSupplier, Consumer<List<Double>> saveConsumer, Supplier<List<Double>> defaultValue, String resetButtonKey, boolean requiresRestart, boolean deleteButtonEnabled, boolean insertInFront) {
         super(fieldName, value, defaultExpanded, tooltipSupplier, saveConsumer, defaultValue, resetButtonKey, requiresRestart, deleteButtonEnabled, insertInFront, DoubleListCell::new);
         this.minimum = Double.NEGATIVE_INFINITY;

+ 2 - 0
src/main/java/me/shedaniel/clothconfig2/gui/entries/DropdownBoxEntry.java

@@ -25,6 +25,7 @@ import net.minecraft.client.render.VertexFormats;
 import net.minecraft.client.resource.language.I18n;
 import net.minecraft.client.util.Window;
 import net.minecraft.util.math.MathHelper;
+import org.jetbrains.annotations.ApiStatus;
 import org.jetbrains.annotations.NotNull;
 import org.jetbrains.annotations.Nullable;
 
@@ -42,6 +43,7 @@ public class DropdownBoxEntry<T> extends TooltipListEntry<T> {
     @NotNull private Supplier<T> defaultValue;
     @Nullable private Consumer<T> saveConsumer;
     
+    @ApiStatus.Internal
     @Deprecated
     public DropdownBoxEntry(String fieldName, @NotNull String resetButtonKey, @Nullable Supplier<Optional<String[]>> tooltipSupplier, boolean requiresRestart, @Nullable Supplier<T> defaultValue, @Nullable Consumer<T> saveConsumer, @Nullable Iterable<T> selections, @NotNull SelectionTopCellElement<T> topRenderer, @NotNull SelectionCellCreator<T> cellCreator) {
         super(I18n.translate(fieldName), tooltipSupplier, requiresRestart);

+ 6 - 0
src/main/java/me/shedaniel/clothconfig2/gui/entries/EnumListEntry.java

@@ -3,6 +3,7 @@ package me.shedaniel.clothconfig2.gui.entries;
 import net.fabricmc.api.EnvType;
 import net.fabricmc.api.Environment;
 import net.minecraft.client.resource.language.I18n;
+import org.jetbrains.annotations.ApiStatus;
 
 import java.util.Optional;
 import java.util.function.Consumer;
@@ -14,26 +15,31 @@ public class EnumListEntry<T extends Enum<?>> extends SelectionListEntry<T> {
     
     public static final Function<Enum, String> DEFAULT_NAME_PROVIDER = t -> I18n.translate(t instanceof Translatable ? ((Translatable) t).getKey() : t.toString());
     
+    @ApiStatus.Internal
     @Deprecated
     public EnumListEntry(String fieldName, Class<T> clazz, T value, Consumer<T> saveConsumer) {
         super(fieldName, clazz.getEnumConstants(), value, "text.cloth-config.reset_value", null, saveConsumer);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public EnumListEntry(String fieldName, Class<T> clazz, T value, String resetButtonKey, Supplier<T> defaultValue, Consumer<T> saveConsumer) {
         super(fieldName, clazz.getEnumConstants(), value, resetButtonKey, defaultValue, saveConsumer, DEFAULT_NAME_PROVIDER::apply);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public EnumListEntry(String fieldName, Class<T> clazz, T value, String resetButtonKey, Supplier<T> defaultValue, Consumer<T> saveConsumer, Function<Enum, String> enumNameProvider) {
         super(fieldName, clazz.getEnumConstants(), value, resetButtonKey, defaultValue, saveConsumer, enumNameProvider::apply, null);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public EnumListEntry(String fieldName, Class<T> clazz, T value, String resetButtonKey, Supplier<T> defaultValue, Consumer<T> saveConsumer, Function<Enum, String> enumNameProvider, Supplier<Optional<String[]>> tooltipSupplier) {
         super(fieldName, clazz.getEnumConstants(), value, resetButtonKey, defaultValue, saveConsumer, enumNameProvider::apply, tooltipSupplier, false);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public EnumListEntry(String fieldName, Class<T> clazz, T value, String resetButtonKey, Supplier<T> defaultValue, Consumer<T> saveConsumer, Function<Enum, String> enumNameProvider, Supplier<Optional<String[]>> tooltipSupplier, boolean requiresRestart) {
         super(fieldName, clazz.getEnumConstants(), value, resetButtonKey, defaultValue, saveConsumer, enumNameProvider::apply, tooltipSupplier, requiresRestart);

+ 6 - 0
src/main/java/me/shedaniel/clothconfig2/gui/entries/FloatListEntry.java

@@ -4,6 +4,7 @@ import net.fabricmc.api.EnvType;
 import net.fabricmc.api.Environment;
 import net.minecraft.client.gui.widget.TextFieldWidget;
 import net.minecraft.client.resource.language.I18n;
+import org.jetbrains.annotations.ApiStatus;
 
 import java.util.Optional;
 import java.util.function.Consumer;
@@ -27,11 +28,13 @@ public class FloatListEntry extends TextFieldListEntry<Float> {
     private float minimum, maximum;
     private Consumer<Float> saveConsumer;
     
+    @ApiStatus.Internal
     @Deprecated
     public FloatListEntry(String fieldName, Float value, Consumer<Float> saveConsumer) {
         this(fieldName, value, "text.cloth-config.reset_value", null, saveConsumer);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public FloatListEntry(String fieldName, Float value, String resetButtonKey, Supplier<Float> defaultValue, Consumer<Float> saveConsumer) {
         super(fieldName, value, resetButtonKey, defaultValue);
@@ -40,11 +43,14 @@ public class FloatListEntry extends TextFieldListEntry<Float> {
         this.saveConsumer = saveConsumer;
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public FloatListEntry(String fieldName, Float value, String resetButtonKey, Supplier<Float> defaultValue, Consumer<Float> saveConsumer, Supplier<Optional<String[]>> tooltipSupplier) {
         this(fieldName, value, resetButtonKey, defaultValue, saveConsumer, tooltipSupplier, false);
     }
     
+    @ApiStatus.Internal
+    @Deprecated
     public FloatListEntry(String fieldName, Float value, String resetButtonKey, Supplier<Float> defaultValue, Consumer<Float> saveConsumer, Supplier<Optional<String[]>> tooltipSupplier, boolean requiresRestart) {
         super(fieldName, value, resetButtonKey, defaultValue, tooltipSupplier, requiresRestart);
         this.minimum = -Float.MAX_VALUE;

+ 4 - 1
src/main/java/me/shedaniel/clothconfig2/gui/entries/FloatListListEntry.java

@@ -12,22 +12,25 @@ import java.util.Optional;
 import java.util.function.Consumer;
 import java.util.function.Supplier;
 
-@ApiStatus.Internal
 @Environment(EnvType.CLIENT)
 public class FloatListListEntry extends AbstractTextFieldListListEntry<Float, FloatListListEntry.FloatListCell, FloatListListEntry> {
     
     private float minimum, maximum;
     
+    @ApiStatus.Internal
     @Deprecated
     public FloatListListEntry(String fieldName, List<Float> value, boolean defaultExpanded, Supplier<Optional<String[]>> tooltipSupplier, Consumer<List<Float>> saveConsumer, Supplier<List<Float>> defaultValue, String resetButtonKey) {
         this(fieldName, value, defaultExpanded, tooltipSupplier, saveConsumer, defaultValue, resetButtonKey, false);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public FloatListListEntry(String fieldName, List<Float> value, boolean defaultExpanded, Supplier<Optional<String[]>> tooltipSupplier, Consumer<List<Float>> saveConsumer, Supplier<List<Float>> defaultValue, String resetButtonKey, boolean requiresRestart) {
         this(fieldName, value, defaultExpanded, tooltipSupplier, saveConsumer, defaultValue, resetButtonKey, requiresRestart, true, true);
     }
     
+    @ApiStatus.Internal
+    @Deprecated
     public FloatListListEntry(String fieldName, List<Float> value, boolean defaultExpanded, Supplier<Optional<String[]>> tooltipSupplier, Consumer<List<Float>> saveConsumer, Supplier<List<Float>> defaultValue, String resetButtonKey, boolean requiresRestart, boolean deleteButtonEnabled, boolean insertInFront) {
         super(fieldName, value, defaultExpanded, tooltipSupplier, saveConsumer, defaultValue, resetButtonKey, requiresRestart, deleteButtonEnabled, insertInFront, FloatListCell::new);
         this.minimum = Float.NEGATIVE_INFINITY;

+ 5 - 0
src/main/java/me/shedaniel/clothconfig2/gui/entries/IntegerListEntry.java

@@ -4,6 +4,7 @@ import net.fabricmc.api.EnvType;
 import net.fabricmc.api.Environment;
 import net.minecraft.client.gui.widget.TextFieldWidget;
 import net.minecraft.client.resource.language.I18n;
+import org.jetbrains.annotations.ApiStatus;
 
 import java.util.Optional;
 import java.util.function.Consumer;
@@ -27,11 +28,13 @@ public class IntegerListEntry extends TextFieldListEntry<Integer> {
     private int minimum, maximum;
     private Consumer<Integer> saveConsumer;
     
+    @ApiStatus.Internal
     @Deprecated
     public IntegerListEntry(String fieldName, Integer value, Consumer<Integer> saveConsumer) {
         this(fieldName, value, "text.cloth-config.reset_value", null, saveConsumer);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public IntegerListEntry(String fieldName, Integer value, String resetButtonKey, Supplier<Integer> defaultValue, Consumer<Integer> saveConsumer) {
         super(fieldName, value, resetButtonKey, defaultValue);
@@ -40,11 +43,13 @@ public class IntegerListEntry extends TextFieldListEntry<Integer> {
         this.saveConsumer = saveConsumer;
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public IntegerListEntry(String fieldName, Integer value, String resetButtonKey, Supplier<Integer> defaultValue, Consumer<Integer> saveConsumer, Supplier<Optional<String[]>> tooltipSupplier) {
         this(fieldName, value, resetButtonKey, defaultValue, saveConsumer, tooltipSupplier, false);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public IntegerListEntry(String fieldName, Integer value, String resetButtonKey, Supplier<Integer> defaultValue, Consumer<Integer> saveConsumer, Supplier<Optional<String[]>> tooltipSupplier, boolean requiresRestart) {
         super(fieldName, value, resetButtonKey, defaultValue, tooltipSupplier, requiresRestart);

+ 4 - 1
src/main/java/me/shedaniel/clothconfig2/gui/entries/IntegerListListEntry.java

@@ -12,22 +12,25 @@ import java.util.Optional;
 import java.util.function.Consumer;
 import java.util.function.Supplier;
 
-@ApiStatus.Internal
 @Environment(EnvType.CLIENT)
 public class IntegerListListEntry extends AbstractTextFieldListListEntry<Integer, IntegerListListEntry.IntegerListCell, IntegerListListEntry> {
     
     private int minimum, maximum;
     
+    @ApiStatus.Internal
     @Deprecated
     public IntegerListListEntry(String fieldName, List<Integer> value, boolean defaultExpanded, Supplier<Optional<String[]>> tooltipSupplier, Consumer<List<Integer>> saveConsumer, Supplier<List<Integer>> defaultValue, String resetButtonKey) {
         this(fieldName, value, defaultExpanded, tooltipSupplier, saveConsumer, defaultValue, resetButtonKey, false);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public IntegerListListEntry(String fieldName, List<Integer> value, boolean defaultExpanded, Supplier<Optional<String[]>> tooltipSupplier, Consumer<List<Integer>> saveConsumer, Supplier<List<Integer>> defaultValue, String resetButtonKey, boolean requiresRestart) {
         this(fieldName, value, defaultExpanded, tooltipSupplier, saveConsumer, defaultValue, resetButtonKey, requiresRestart, true, true);
     }
     
+    @ApiStatus.Internal
+    @Deprecated
     public IntegerListListEntry(String fieldName, List<Integer> value, boolean defaultExpanded, Supplier<Optional<String[]>> tooltipSupplier, Consumer<List<Integer>> saveConsumer, Supplier<List<Integer>> defaultValue, String resetButtonKey, boolean requiresRestart, boolean deleteButtonEnabled, boolean insertInFront) {
         super(fieldName, value, defaultExpanded, tooltipSupplier, saveConsumer, defaultValue, resetButtonKey, requiresRestart, deleteButtonEnabled, insertInFront, IntegerListCell::new);
         this.minimum = Integer.MIN_VALUE;

+ 5 - 0
src/main/java/me/shedaniel/clothconfig2/gui/entries/IntegerSliderEntry.java

@@ -10,6 +10,7 @@ import net.minecraft.client.gui.widget.SliderWidget;
 import net.minecraft.client.resource.language.I18n;
 import net.minecraft.client.util.Window;
 import net.minecraft.util.math.MathHelper;
+import org.jetbrains.annotations.ApiStatus;
 
 import java.util.List;
 import java.util.Optional;
@@ -30,21 +31,25 @@ public class IntegerSliderEntry extends TooltipListEntry<Integer> {
     private Function<Integer, String> textGetter = integer -> String.format("Value: %d", integer);
     private List<Element> widgets;
     
+    @ApiStatus.Internal
     @Deprecated
     public IntegerSliderEntry(String fieldName, int minimum, int maximum, int value, Consumer<Integer> saveConsumer) {
         this(fieldName, minimum, maximum, value, "text.cloth-config.reset_value", null, saveConsumer);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public IntegerSliderEntry(String fieldName, int minimum, int maximum, int value, String resetButtonKey, Supplier<Integer> defaultValue, Consumer<Integer> saveConsumer) {
         this(fieldName, minimum, maximum, value, resetButtonKey, defaultValue, saveConsumer, null);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public IntegerSliderEntry(String fieldName, int minimum, int maximum, int value, String resetButtonKey, Supplier<Integer> defaultValue, Consumer<Integer> saveConsumer, Supplier<Optional<String[]>> tooltipSupplier) {
         this(fieldName, minimum, maximum, value, resetButtonKey, defaultValue, saveConsumer, tooltipSupplier, false);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public IntegerSliderEntry(String fieldName, int minimum, int maximum, int value, String resetButtonKey, Supplier<Integer> defaultValue, Consumer<Integer> saveConsumer, Supplier<Optional<String[]>> tooltipSupplier, boolean requiresRestart) {
         super(fieldName, tooltipSupplier, requiresRestart);

+ 2 - 0
src/main/java/me/shedaniel/clothconfig2/gui/entries/KeyCodeEntry.java

@@ -10,6 +10,7 @@ import net.minecraft.client.gui.widget.ButtonWidget;
 import net.minecraft.client.resource.language.I18n;
 import net.minecraft.client.util.Window;
 import net.minecraft.util.Formatting;
+import org.jetbrains.annotations.ApiStatus;
 
 import java.util.List;
 import java.util.Optional;
@@ -27,6 +28,7 @@ public class KeyCodeEntry extends TooltipListEntry<ModifierKeyCode> {
     private List<Element> widgets;
     private boolean allowMouse = true, allowKey = true, allowModifiers = true;
     
+    @ApiStatus.Internal
     @Deprecated
     public KeyCodeEntry(String fieldName, ModifierKeyCode value, String resetButtonKey, Supplier<ModifierKeyCode> defaultValue, Consumer<ModifierKeyCode> saveConsumer, Supplier<Optional<String[]>> tooltipSupplier, boolean requiresRestart) {
         super(fieldName, tooltipSupplier, requiresRestart);

+ 6 - 0
src/main/java/me/shedaniel/clothconfig2/gui/entries/LongListEntry.java

@@ -4,6 +4,7 @@ import net.fabricmc.api.EnvType;
 import net.fabricmc.api.Environment;
 import net.minecraft.client.gui.widget.TextFieldWidget;
 import net.minecraft.client.resource.language.I18n;
+import org.jetbrains.annotations.ApiStatus;
 
 import java.util.Optional;
 import java.util.function.Consumer;
@@ -27,11 +28,13 @@ public class LongListEntry extends TextFieldListEntry<Long> {
     private long minimum, maximum;
     private Consumer<Long> saveConsumer;
     
+    @ApiStatus.Internal
     @Deprecated
     public LongListEntry(String fieldName, Long value, Consumer<Long> saveConsumer) {
         this(fieldName, value, "text.cloth-config.reset_value", null, saveConsumer);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public LongListEntry(String fieldName, Long value, String resetButtonKey, Supplier<Long> defaultValue, Consumer<Long> saveConsumer) {
         super(fieldName, value, resetButtonKey, defaultValue);
@@ -40,11 +43,14 @@ public class LongListEntry extends TextFieldListEntry<Long> {
         this.saveConsumer = saveConsumer;
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public LongListEntry(String fieldName, Long value, String resetButtonKey, Supplier<Long> defaultValue, Consumer<Long> saveConsumer, Supplier<Optional<String[]>> tooltipSupplier) {
         this(fieldName, value, resetButtonKey, defaultValue, saveConsumer, tooltipSupplier, false);
     }
     
+    @ApiStatus.Internal
+    @Deprecated
     public LongListEntry(String fieldName, Long value, String resetButtonKey, Supplier<Long> defaultValue, Consumer<Long> saveConsumer, Supplier<Optional<String[]>> tooltipSupplier, boolean requiresRestart) {
         super(fieldName, value, resetButtonKey, defaultValue, tooltipSupplier, requiresRestart);
         this.minimum = -Long.MAX_VALUE;

+ 4 - 1
src/main/java/me/shedaniel/clothconfig2/gui/entries/LongListListEntry.java

@@ -12,22 +12,25 @@ import java.util.Optional;
 import java.util.function.Consumer;
 import java.util.function.Supplier;
 
-@ApiStatus.Internal
 @Environment(EnvType.CLIENT)
 public class LongListListEntry extends AbstractTextFieldListListEntry<Long, LongListListEntry.LongListCell, LongListListEntry> {
     
     private long minimum, maximum;
     
+    @ApiStatus.Internal
     @Deprecated
     public LongListListEntry(String fieldName, List<Long> value, boolean defaultExpanded, Supplier<Optional<String[]>> tooltipSupplier, Consumer<List<Long>> saveConsumer, Supplier<List<Long>> defaultValue, String resetButtonKey) {
         this(fieldName, value, defaultExpanded, tooltipSupplier, saveConsumer, defaultValue, resetButtonKey, false);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public LongListListEntry(String fieldName, List<Long> value, boolean defaultExpanded, Supplier<Optional<String[]>> tooltipSupplier, Consumer<List<Long>> saveConsumer, Supplier<List<Long>> defaultValue, String resetButtonKey, boolean requiresRestart) {
         this(fieldName, value, defaultExpanded, tooltipSupplier, saveConsumer, defaultValue, resetButtonKey, requiresRestart, true, true);
     }
     
+    @ApiStatus.Internal
+    @Deprecated
     public LongListListEntry(String fieldName, List<Long> value, boolean defaultExpanded, Supplier<Optional<String[]>> tooltipSupplier, Consumer<List<Long>> saveConsumer, Supplier<List<Long>> defaultValue, String resetButtonKey, boolean requiresRestart, boolean deleteButtonEnabled, boolean insertInFront) {
         super(fieldName, value, defaultExpanded, tooltipSupplier, saveConsumer, defaultValue, resetButtonKey, requiresRestart, deleteButtonEnabled, insertInFront, LongListCell::new);
         this.minimum = Long.MIN_VALUE;

+ 5 - 0
src/main/java/me/shedaniel/clothconfig2/gui/entries/LongSliderEntry.java

@@ -10,6 +10,7 @@ import net.minecraft.client.gui.widget.SliderWidget;
 import net.minecraft.client.resource.language.I18n;
 import net.minecraft.client.util.Window;
 import net.minecraft.util.math.MathHelper;
+import org.jetbrains.annotations.ApiStatus;
 
 import java.util.List;
 import java.util.Optional;
@@ -30,21 +31,25 @@ public class LongSliderEntry extends TooltipListEntry<Long> {
     private Function<Long, String> textGetter = value -> String.format("Value: %d", value);
     private List<Element> widgets;
     
+    @ApiStatus.Internal
     @Deprecated
     public LongSliderEntry(String fieldName, long minimum, long maximum, long value, Consumer<Long> saveConsumer) {
         this(fieldName, minimum, maximum, value, saveConsumer, "text.cloth-config.reset_value", null);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public LongSliderEntry(String fieldName, long minimum, long maximum, long value, Consumer<Long> saveConsumer, String resetButtonKey, Supplier<Long> defaultValue) {
         this(fieldName, minimum, maximum, value, saveConsumer, resetButtonKey, defaultValue, null);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public LongSliderEntry(String fieldName, long minimum, long maximum, long value, Consumer<Long> saveConsumer, String resetButtonKey, Supplier<Long> defaultValue, Supplier<Optional<String[]>> tooltipSupplier) {
         this(fieldName, minimum, maximum, value, saveConsumer, resetButtonKey, defaultValue, tooltipSupplier, false);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public LongSliderEntry(String fieldName, long minimum, long maximum, long value, Consumer<Long> saveConsumer, String resetButtonKey, Supplier<Long> defaultValue, Supplier<Optional<String[]>> tooltipSupplier, boolean requiresRestart) {
         super(fieldName, tooltipSupplier, requiresRestart);

+ 1 - 0
src/main/java/me/shedaniel/clothconfig2/gui/entries/MultiElementListEntry.java

@@ -31,6 +31,7 @@ public class MultiElementListEntry<T> extends TooltipListEntry<T> {
     private boolean expanded;
     
     @ApiStatus.Internal
+    @Deprecated
     public MultiElementListEntry(String categoryName, T object, List<AbstractConfigListEntry<?>> entries, boolean defaultExpanded) {
         super(categoryName, null);
         this.categoryName = categoryName;

+ 1 - 0
src/main/java/me/shedaniel/clothconfig2/gui/entries/NestedListListEntry.java

@@ -23,6 +23,7 @@ import java.util.function.Supplier;
 public final class NestedListListEntry<T, INNER extends AbstractConfigListEntry<T>> extends AbstractListListEntry<T, NestedListCell<T, INNER>, NestedListListEntry<T, INNER>> {
     
     @ApiStatus.Internal
+    @Deprecated
     public NestedListListEntry(String fieldName, List<T> value, boolean defaultExpanded, Supplier<Optional<String[]>> tooltipSupplier, Consumer<List<T>> saveConsumer, Supplier<List<T>> defaultValue, String resetButtonKey, boolean deleteButtonEnabled, boolean insertInFront, BiFunction<T, NestedListListEntry<T, INNER>, INNER> createNewCell) {
         super(fieldName, value, defaultExpanded, null, null, defaultValue, resetButtonKey, false, deleteButtonEnabled, insertInFront, (t, nestedListListEntry) -> new NestedListCell<>(t, nestedListListEntry, createNewCell.apply(t, nestedListListEntry)));
     }

+ 5 - 1
src/main/java/me/shedaniel/clothconfig2/gui/entries/SelectionListEntry.java

@@ -19,7 +19,6 @@ import java.util.function.Consumer;
 import java.util.function.Function;
 import java.util.function.Supplier;
 
-@ApiStatus.Internal
 @Environment(EnvType.CLIENT)
 public class SelectionListEntry<T> extends TooltipListEntry<T> {
     
@@ -31,26 +30,31 @@ public class SelectionListEntry<T> extends TooltipListEntry<T> {
     private List<Element> widgets;
     private Function<T, String> nameProvider;
     
+    @ApiStatus.Internal
     @Deprecated
     public SelectionListEntry(String fieldName, T[] valuesArray, T value, Consumer<T> saveConsumer) {
         this(fieldName, valuesArray, value, "text.cloth-config.reset_value", null, saveConsumer);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public SelectionListEntry(String fieldName, T[] valuesArray, T value, String resetButtonKey, Supplier<T> defaultValue, Consumer<T> saveConsumer) {
         this(fieldName, valuesArray, value, resetButtonKey, defaultValue, saveConsumer, null);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public SelectionListEntry(String fieldName, T[] valuesArray, T value, String resetButtonKey, Supplier<T> defaultValue, Consumer<T> saveConsumer, Function<T, String> nameProvider) {
         this(fieldName, valuesArray, value, resetButtonKey, defaultValue, saveConsumer, nameProvider, null);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public SelectionListEntry(String fieldName, T[] valuesArray, T value, String resetButtonKey, Supplier<T> defaultValue, Consumer<T> saveConsumer, Function<T, String> nameProvider, Supplier<Optional<String[]>> tooltipSupplier) {
         this(fieldName, valuesArray, value, resetButtonKey, defaultValue, saveConsumer, nameProvider, tooltipSupplier, false);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public SelectionListEntry(String fieldName, T[] valuesArray, T value, String resetButtonKey, Supplier<T> defaultValue, Consumer<T> saveConsumer, Function<T, String> nameProvider, Supplier<Optional<String[]>> tooltipSupplier, boolean requiresRestart) {
         super(fieldName, tooltipSupplier, requiresRestart);

+ 5 - 0
src/main/java/me/shedaniel/clothconfig2/gui/entries/StringListEntry.java

@@ -2,6 +2,7 @@ package me.shedaniel.clothconfig2.gui.entries;
 
 import net.fabricmc.api.EnvType;
 import net.fabricmc.api.Environment;
+import org.jetbrains.annotations.ApiStatus;
 
 import java.util.Optional;
 import java.util.function.Consumer;
@@ -12,22 +13,26 @@ public class StringListEntry extends TextFieldListEntry<String> {
     
     private Consumer<String> saveConsumer;
     
+    @ApiStatus.Internal
     @Deprecated
     public StringListEntry(String fieldName, String value, Consumer<String> saveConsumer) {
         this(fieldName, value, "text.cloth-config.reset_value", null, saveConsumer);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public StringListEntry(String fieldName, String value, String resetButtonKey, Supplier<String> defaultValue, Consumer<String> saveConsumer) {
         super(fieldName, value, resetButtonKey, defaultValue);
         this.saveConsumer = saveConsumer;
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public StringListEntry(String fieldName, String value, String resetButtonKey, Supplier<String> defaultValue, Consumer<String> saveConsumer, Supplier<Optional<String[]>> tooltipSupplier) {
         this(fieldName, value, resetButtonKey, defaultValue, saveConsumer, tooltipSupplier, false);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public StringListEntry(String fieldName, String value, String resetButtonKey, Supplier<String> defaultValue, Consumer<String> saveConsumer, Supplier<Optional<String[]>> tooltipSupplier, boolean requiresRestart) {
         super(fieldName, value, resetButtonKey, defaultValue, tooltipSupplier, requiresRestart);

+ 4 - 1
src/main/java/me/shedaniel/clothconfig2/gui/entries/StringListListEntry.java

@@ -11,20 +11,23 @@ import java.util.Optional;
 import java.util.function.Consumer;
 import java.util.function.Supplier;
 
-@ApiStatus.Internal
 @Environment(EnvType.CLIENT)
 public class StringListListEntry extends AbstractTextFieldListListEntry<String, StringListListEntry.StringListCell, StringListListEntry> {
     
+    @ApiStatus.Internal
     @Deprecated
     public StringListListEntry(String fieldName, List<String> value, boolean defaultExpanded, Supplier<Optional<String[]>> tooltipSupplier, Consumer<List<String>> saveConsumer, Supplier<List<String>> defaultValue, String resetButtonKey) {
         this(fieldName, value, defaultExpanded, tooltipSupplier, saveConsumer, defaultValue, resetButtonKey, false);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public StringListListEntry(String fieldName, List<String> value, boolean defaultExpanded, Supplier<Optional<String[]>> tooltipSupplier, Consumer<List<String>> saveConsumer, Supplier<List<String>> defaultValue, String resetButtonKey, boolean requiresRestart) {
         this(fieldName, value, defaultExpanded, tooltipSupplier, saveConsumer, defaultValue, resetButtonKey, requiresRestart, true, true);
     }
     
+    @ApiStatus.Internal
+    @Deprecated
     public StringListListEntry(String fieldName, List<String> value, boolean defaultExpanded, Supplier<Optional<String[]>> tooltipSupplier, Consumer<List<String>> saveConsumer, Supplier<List<String>> defaultValue, String resetButtonKey, boolean requiresRestart, boolean deleteButtonEnabled, boolean insertInFront) {
         super(fieldName, value, defaultExpanded, tooltipSupplier, saveConsumer, defaultValue, resetButtonKey, requiresRestart, deleteButtonEnabled, insertInFront, StringListCell::new);
     }

+ 8 - 1
src/main/java/me/shedaniel/clothconfig2/gui/entries/SubCategoryListEntry.java

@@ -84,12 +84,19 @@ public class SubCategoryListEntry extends TooltipListEntry<List<AbstractConfigLi
         if (expanded) {
             int yy = y + 24;
             for (AbstractConfigListEntry<?> entry : entries) {
-                entry.render(-1, yy, x + 14, entryWidth - 14, entry.getItemHeight(), mouseX, mouseY, isSelected, delta);
+                entry.render(-1, yy, x + 14, entryWidth - 14, entry.getItemHeight(), mouseX, mouseY, isSelected && getFocused() == entry, delta);
                 yy += entry.getItemHeight();
             }
         }
     }
     
+    @Override
+    public void updateSelected(boolean isSelected) {
+        for (AbstractConfigListEntry<?> entry : entries) {
+            entry.updateSelected(expanded && isSelected && getFocused() == entry);
+        }
+    }
+    
     @Override
     public boolean isMouseInside(int mouseX, int mouseY, int x, int y, int entryWidth, int entryHeight) {
         widget.rectangle.x = x - 15;

+ 14 - 1
src/main/java/me/shedaniel/clothconfig2/gui/entries/TextFieldListEntry.java

@@ -9,6 +9,7 @@ import net.minecraft.client.gui.widget.ButtonWidget;
 import net.minecraft.client.gui.widget.TextFieldWidget;
 import net.minecraft.client.resource.language.I18n;
 import net.minecraft.client.util.Window;
+import org.jetbrains.annotations.ApiStatus;
 
 import java.util.List;
 import java.util.Optional;
@@ -22,15 +23,22 @@ public abstract class TextFieldListEntry<T> extends TooltipListEntry<T> {
     protected Supplier<T> defaultValue;
     protected T original;
     protected List<Element> widgets;
+    private boolean isSelected = false;
     
+    @ApiStatus.Internal
+    @Deprecated
     protected TextFieldListEntry(String fieldName, T original, String resetButtonKey, Supplier<T> defaultValue) {
         this(fieldName, original, resetButtonKey, defaultValue, null);
     }
     
+    @ApiStatus.Internal
+    @Deprecated
     protected TextFieldListEntry(String fieldName, T original, String resetButtonKey, Supplier<T> defaultValue, Supplier<Optional<String[]>> tooltipSupplier) {
         this(fieldName, original, resetButtonKey, defaultValue, tooltipSupplier, false);
     }
     
+    @ApiStatus.Internal
+    @Deprecated
     protected TextFieldListEntry(String fieldName, T original, String resetButtonKey, Supplier<T> defaultValue, Supplier<Optional<String[]>> tooltipSupplier, boolean requiresRestart) {
         super(fieldName, tooltipSupplier);
         this.defaultValue = defaultValue;
@@ -39,7 +47,7 @@ public abstract class TextFieldListEntry<T> extends TooltipListEntry<T> {
             @Override
             public void render(int int_1, int int_2, float float_1) {
                 boolean f = isFocused();
-                setFocused(TextFieldListEntry.this.getParent().getFocused() == TextFieldListEntry.this && TextFieldListEntry.this.getFocused() == this);
+                setFocused(isSelected);
                 textFieldPreRender(this);
                 super.render(int_1, int_2, float_1);
                 setFocused(f);
@@ -80,6 +88,11 @@ public abstract class TextFieldListEntry<T> extends TooltipListEntry<T> {
     
     }
     
+    @Override
+    public void updateSelected(boolean isSelected) {
+        this.isSelected = isSelected;
+    }
+    
     @Override
     public void render(int index, int y, int x, int entryWidth, int entryHeight, int mouseX, int mouseY, boolean isSelected, float delta) {
         super.render(index, y, x, entryWidth, entryHeight, mouseX, mouseY, isSelected, delta);

+ 4 - 0
src/main/java/me/shedaniel/clothconfig2/gui/entries/TextListEntry.java

@@ -4,6 +4,7 @@ import net.fabricmc.api.EnvType;
 import net.fabricmc.api.Environment;
 import net.minecraft.client.MinecraftClient;
 import net.minecraft.client.gui.Element;
+import org.jetbrains.annotations.ApiStatus;
 
 import java.util.Collections;
 import java.util.List;
@@ -17,16 +18,19 @@ public class TextListEntry extends TooltipListEntry<Object> {
     private int color;
     private String text;
     
+    @ApiStatus.Internal
     @Deprecated
     public TextListEntry(String fieldName, String text) {
         this(fieldName, text, -1);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public TextListEntry(String fieldName, String text, int color) {
         this(fieldName, text, color, null);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public TextListEntry(String fieldName, String text, int color, Supplier<Optional<String[]>> tooltipSupplier) {
         super(fieldName, tooltipSupplier);

+ 3 - 0
src/main/java/me/shedaniel/clothconfig2/gui/entries/TooltipListEntry.java

@@ -5,6 +5,7 @@ import me.shedaniel.clothconfig2.api.QueuedTooltip;
 import me.shedaniel.math.Point;
 import net.fabricmc.api.EnvType;
 import net.fabricmc.api.Environment;
+import org.jetbrains.annotations.ApiStatus;
 import org.jetbrains.annotations.Nullable;
 
 import java.util.Optional;
@@ -15,11 +16,13 @@ public abstract class TooltipListEntry<T> extends AbstractConfigListEntry<T> {
     
     @Nullable private Supplier<Optional<String[]>> tooltipSupplier;
     
+    @ApiStatus.Internal
     @Deprecated
     public TooltipListEntry(String fieldName, @Nullable Supplier<Optional<String[]>> tooltipSupplier) {
         this(fieldName, tooltipSupplier, false);
     }
     
+    @ApiStatus.Internal
     @Deprecated
     public TooltipListEntry(String fieldName, @Nullable Supplier<Optional<String[]>> tooltipSupplier, boolean requiresRestart) {
         super(fieldName, requiresRestart);

+ 5 - 1
src/main/java/me/shedaniel/clothconfig2/gui/widget/DynamicEntryListWidget.java

@@ -429,11 +429,15 @@ public abstract class DynamicEntryListWidget<E extends DynamicEntryListWidget.En
             int y = this.getRowTop(renderIndex);
             int x = this.getRowLeft();
             DiffuseLighting.disable();
-            item.render(renderIndex, y, x, itemWidth, itemHeight, int_3, int_4, this.isMouseOver(int_3, int_4) && Objects.equals(this.getItemAtPosition(int_3, int_4), item), float_1);
+            renderItem(item, renderIndex, y, x, itemWidth, itemHeight, int_3, int_4, this.isMouseOver(int_3, int_4) && Objects.equals(this.getItemAtPosition(int_3, int_4), item), float_1);
         }
         
     }
     
+    protected void renderItem(E item, int index, int y, int x, int entryWidth, int entryHeight, int mouseX, int mouseY, boolean isSelected, float delta) {
+        item.render(index, y, x, entryWidth, entryHeight, mouseX, mouseY, isSelected, delta);
+    }
+    
     protected int getRowLeft() {
         return this.left + this.width / 2 - this.getItemWidth() / 2 + 2;
     }