1
mirror of https://github.com/Shiewk/Widgets.git synced 2026-04-28 11:34:17 +02:00

Make all 'show label' settings use the same translation key

This commit is contained in:
Shy
2024-12-15 12:47:04 +01:00
parent c8579f673c
commit 8d33de5eca
6 changed files with 9 additions and 15 deletions
@@ -16,7 +16,7 @@ public class BiomeWidget extends BasicTextWidget {
public BiomeWidget(Identifier id) { public BiomeWidget(Identifier id) {
super(id, List.of( super(id, List.of(
new ToggleWidgetSetting("show_label", Text.translatable("widgets.widgets.biome.showLabel"), true) new ToggleWidgetSetting("show_label", Text.translatable("widgets.widgets.common.showLabel"), true)
)); ));
} }
@@ -15,7 +15,7 @@ public class MemoryUsageWidget extends BasicTextWidget {
public MemoryUsageWidget(Identifier id) { public MemoryUsageWidget(Identifier id) {
super(id, List.of( super(id, List.of(
new ToggleWidgetSetting("percentage", Text.translatable("widgets.widgets.memory.showPercentage"), true), new ToggleWidgetSetting("percentage", Text.translatable("widgets.widgets.memory.showPercentage"), true),
new ToggleWidgetSetting("label", Text.translatable("widgets.widgets.memory.showLabel"), true) new ToggleWidgetSetting("label", Text.translatable("widgets.widgets.common.showLabel"), true)
)); ));
} }
@@ -12,7 +12,7 @@ import java.util.List;
public class PlayerCountWidget extends BasicTextWidget{ public class PlayerCountWidget extends BasicTextWidget{
public PlayerCountWidget(Identifier id) { public PlayerCountWidget(Identifier id) {
super(id, List.of( super(id, List.of(
new ToggleWidgetSetting("showlabel", Text.translatable("widgets.widgets.playerCount.showLabel"), true) new ToggleWidgetSetting("showlabel", Text.translatable("widgets.widgets.common.showLabel"), true)
)); ));
} }
@@ -13,7 +13,7 @@ import java.util.List;
public class TPSWidget extends BasicTextWidget { public class TPSWidget extends BasicTextWidget {
public TPSWidget(Identifier id) { public TPSWidget(Identifier id) {
super(id, List.of( super(id, List.of(
new ToggleWidgetSetting("show_label", Text.translatable("widgets.widgets.tps.showLabel"), true), new ToggleWidgetSetting("show_label", Text.translatable("widgets.widgets.common.showLabel"), true),
new ToggleWidgetSetting("dynamic_color", Text.translatable("widgets.widgets.tps.dynamicColor"), true) new ToggleWidgetSetting("dynamic_color", Text.translatable("widgets.widgets.tps.dynamicColor"), true)
)); ));
getSettings().optionById("textcolor").setShowCondition(() -> !this.dynamicColor); getSettings().optionById("textcolor").setShowCondition(() -> !this.dynamicColor);
@@ -71,7 +71,6 @@
"widgets.widgets.memory.description": "Zeigt die momentane Arbeitsspeicherauslastung des Spiels an.", "widgets.widgets.memory.description": "Zeigt die momentane Arbeitsspeicherauslastung des Spiels an.",
"widgets.widgets.memory.withLabel": "Arbeitsspeicher: %s", "widgets.widgets.memory.withLabel": "Arbeitsspeicher: %s",
"widgets.widgets.memory.showPercentage": "Prozentsatz anzeigen", "widgets.widgets.memory.showPercentage": "Prozentsatz anzeigen",
"widgets.widgets.memory.showLabel": "Beschriftung anzeigen",
"widgets.widgets.serverIP.dynamicWidth": "Widget-Breite dynamisch festlegen", "widgets.widgets.serverIP.dynamicWidth": "Widget-Breite dynamisch festlegen",
"widgets.widgets.keystrokes.showJumpKey": "Sprungtaste anzeigen", "widgets.widgets.keystrokes.showJumpKey": "Sprungtaste anzeigen",
"widgets.widgets.common.sizePercent": "Widgetgröße (%)", "widgets.widgets.common.sizePercent": "Widgetgröße (%)",
@@ -82,7 +81,6 @@
"widgets.widgets.keystrokes": "Keystrokes", "widgets.widgets.keystrokes": "Keystrokes",
"widgets.widgets.keystrokes.description": "Zeigt an, welche Tasten du momentan drückst.", "widgets.widgets.keystrokes.description": "Zeigt an, welche Tasten du momentan drückst.",
"widgets.widgets.basictext.textshadow": "Textschatten", "widgets.widgets.basictext.textshadow": "Textschatten",
"widgets.widgets.playerCount.showLabel": "Beschriftung anzeigen",
"widgets.widgets.plaintext": "Text", "widgets.widgets.plaintext": "Text",
"widgets.widgets.plaintext.description": "Zeigt einen festgelegten Text an", "widgets.widgets.plaintext.description": "Zeigt einen festgelegten Text an",
"widgets.widgets.plaintext.text": "Text", "widgets.widgets.plaintext.text": "Text",
@@ -92,9 +90,8 @@
"widgets.widgets.tps.dynamicColor": "Farbe dynamisch anzeigen", "widgets.widgets.tps.dynamicColor": "Farbe dynamisch anzeigen",
"widgets.widgets.tps": "TPS", "widgets.widgets.tps": "TPS",
"widgets.widgets.tps.description": "Zeigt die TPS im Einzelspielermodus an oder schätzt die TPS im Mehrspielermodus", "widgets.widgets.tps.description": "Zeigt die TPS im Einzelspielermodus an oder schätzt die TPS im Mehrspielermodus",
"widgets.widgets.tps.showLabel": "Beschriftung anzeigen",
"widgets.widgets.biome.showLabel": "Beschriftung anzeigen",
"widgets.widgets.biome.label": "Biom: %s", "widgets.widgets.biome.label": "Biom: %s",
"widgets.widgets.biome": "Biom", "widgets.widgets.biome": "Biom",
"widgets.widgets.biome.description": "Zeigt das Biom an, in dem du dich befindest." "widgets.widgets.biome.description": "Zeigt das Biom an, in dem du dich befindest.",
"widgets.widgets.common.showLabel": "Beschriftung anzeigen"
} }
@@ -71,7 +71,6 @@
"widgets.widgets.memory.description": "Shows the current memory usage of the game.", "widgets.widgets.memory.description": "Shows the current memory usage of the game.",
"widgets.widgets.memory.withLabel": "Memory: %s", "widgets.widgets.memory.withLabel": "Memory: %s",
"widgets.widgets.memory.showPercentage": "Show percentage", "widgets.widgets.memory.showPercentage": "Show percentage",
"widgets.widgets.memory.showLabel": "Show label",
"widgets.widgets.serverIP.dynamicWidth": "Dynamically set widget width", "widgets.widgets.serverIP.dynamicWidth": "Dynamically set widget width",
"widgets.widgets.keystrokes.showJumpKey": "Show Jump Key", "widgets.widgets.keystrokes.showJumpKey": "Show Jump Key",
"widgets.widgets.common.sizePercent": "Widget size (%)", "widgets.widgets.common.sizePercent": "Widget size (%)",
@@ -82,7 +81,6 @@
"widgets.widgets.keystrokes": "Keystrokes", "widgets.widgets.keystrokes": "Keystrokes",
"widgets.widgets.keystrokes.description": "Shows which keys you are currently pressing.", "widgets.widgets.keystrokes.description": "Shows which keys you are currently pressing.",
"widgets.widgets.basictext.textshadow": "Text shadow", "widgets.widgets.basictext.textshadow": "Text shadow",
"widgets.widgets.playerCount.showLabel": "Show label",
"widgets.widgets.plaintext": "Text", "widgets.widgets.plaintext": "Text",
"widgets.widgets.plaintext.description": "Input a text to display on screen", "widgets.widgets.plaintext.description": "Input a text to display on screen",
"widgets.widgets.plaintext.text": "Text", "widgets.widgets.plaintext.text": "Text",
@@ -92,9 +90,8 @@
"widgets.widgets.tps.dynamicColor": "Dynamic Color", "widgets.widgets.tps.dynamicColor": "Dynamic Color",
"widgets.widgets.tps": "TPS", "widgets.widgets.tps": "TPS",
"widgets.widgets.tps.description": "Shows the current TPS when in singleplayer or estimates server TPS when in multiplayer", "widgets.widgets.tps.description": "Shows the current TPS when in singleplayer or estimates server TPS when in multiplayer",
"widgets.widgets.tps.showLabel": "Show label",
"widgets.widgets.biome.showLabel": "Show label",
"widgets.widgets.biome.label": "Biome: %s", "widgets.widgets.biome.label": "Biome: %s",
"widgets.widgets.biome": "Biome", "widgets.widgets.biome": "Biome",
"widgets.widgets.biome.description": "Shows the biome you're currently in." "widgets.widgets.biome.description": "Shows the biome you're currently in.",
"widgets.widgets.common.showLabel": "Show label"
} }