]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
HUD panrel dialogs: shorten strings in items that enable/disable panels (a few of...
authorterencehill <piuntn@gmail.com>
Sat, 3 Mar 2018 12:31:02 +0000 (13:31 +0100)
committerterencehill <piuntn@gmail.com>
Sat, 3 Mar 2018 12:31:02 +0000 (13:31 +0100)
40 files changed:
qcsrc/menu/xonotic/dialog_hudpanel_ammo.qc
qcsrc/menu/xonotic/dialog_hudpanel_ammo.qh
qcsrc/menu/xonotic/dialog_hudpanel_centerprint.qc
qcsrc/menu/xonotic/dialog_hudpanel_centerprint.qh
qcsrc/menu/xonotic/dialog_hudpanel_chat.qc
qcsrc/menu/xonotic/dialog_hudpanel_chat.qh
qcsrc/menu/xonotic/dialog_hudpanel_engineinfo.qc
qcsrc/menu/xonotic/dialog_hudpanel_engineinfo.qh
qcsrc/menu/xonotic/dialog_hudpanel_healtharmor.qc
qcsrc/menu/xonotic/dialog_hudpanel_healtharmor.qh
qcsrc/menu/xonotic/dialog_hudpanel_infomessages.qc
qcsrc/menu/xonotic/dialog_hudpanel_infomessages.qh
qcsrc/menu/xonotic/dialog_hudpanel_itemstime.qc
qcsrc/menu/xonotic/dialog_hudpanel_itemstime.qh
qcsrc/menu/xonotic/dialog_hudpanel_modicons.qc
qcsrc/menu/xonotic/dialog_hudpanel_modicons.qh
qcsrc/menu/xonotic/dialog_hudpanel_notification.qc
qcsrc/menu/xonotic/dialog_hudpanel_notification.qh
qcsrc/menu/xonotic/dialog_hudpanel_physics.qc
qcsrc/menu/xonotic/dialog_hudpanel_physics.qh
qcsrc/menu/xonotic/dialog_hudpanel_powerups.qc
qcsrc/menu/xonotic/dialog_hudpanel_powerups.qh
qcsrc/menu/xonotic/dialog_hudpanel_pressedkeys.qc
qcsrc/menu/xonotic/dialog_hudpanel_pressedkeys.qh
qcsrc/menu/xonotic/dialog_hudpanel_quickmenu.qc
qcsrc/menu/xonotic/dialog_hudpanel_quickmenu.qh
qcsrc/menu/xonotic/dialog_hudpanel_racetimer.qc
qcsrc/menu/xonotic/dialog_hudpanel_racetimer.qh
qcsrc/menu/xonotic/dialog_hudpanel_radar.qc
qcsrc/menu/xonotic/dialog_hudpanel_radar.qh
qcsrc/menu/xonotic/dialog_hudpanel_score.qc
qcsrc/menu/xonotic/dialog_hudpanel_score.qh
qcsrc/menu/xonotic/dialog_hudpanel_timer.qc
qcsrc/menu/xonotic/dialog_hudpanel_timer.qh
qcsrc/menu/xonotic/dialog_hudpanel_vote.qc
qcsrc/menu/xonotic/dialog_hudpanel_vote.qh
qcsrc/menu/xonotic/dialog_hudpanel_weapons.qc
qcsrc/menu/xonotic/dialog_hudpanel_weapons.qh
qcsrc/menu/xonotic/util.qc
qcsrc/menu/xonotic/util.qh

index 2e67e7acf861294bb39a6d97bf2a5155e008eaac..611ef4a45e714de1b8292f68904659f3891e9b98 100644 (file)
@@ -10,7 +10,9 @@ void XonoticHUDAmmoDialog_fill(entity me)
        entity e;
        string panelname = "ammo";
 
-       DIALOG_HUDPANEL_COMMON();
+       dialog_hudpanel_main_checkbox(me, panelname);
+
+       dialog_hudpanel_main_settings(me, panelname);
 
        me.TR(me);
                me.TD(me, 1, 4, e = makeXonoticTextLabel(0, _("Ammunition display:")));
index 9113a02794b1b08f810b009dd491c06fd8be7ab6..3af373e4388d30ee7b9c5623c623625f2b789e60 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDAmmoDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDAmmoDialog, title, string, _("Ammo Panel"));
        ATTRIB(XonoticHUDAmmoDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT);
        ATTRIB(XonoticHUDAmmoDialog, intendedWidth, float, 0.4);
-       ATTRIB(XonoticHUDAmmoDialog, rows, float, 15);
+       ATTRIB(XonoticHUDAmmoDialog, rows, float, 15.5);
        ATTRIB(XonoticHUDAmmoDialog, columns, float, 4);
        ATTRIB(XonoticHUDAmmoDialog, name, string, "HUDammo");
        ATTRIB(XonoticHUDAmmoDialog, requiresConnection, float, true);
index 332f6753f76d62273411801ab6cd584f46077a9a..938f69a8c57be823a7d95857e70101d37569c2c2 100644 (file)
@@ -10,7 +10,9 @@ void XonoticHUDCenterprintDialog_fill(entity me)
        entity e;
        string panelname = "centerprint";
 
-       DIALOG_HUDPANEL_COMMON();
+       dialog_hudpanel_main_checkbox(me, panelname);
+
+       dialog_hudpanel_main_settings(me, panelname);
 
        me.TR(me);
                me.TDempty(me, 0.2);
index 9fc6846eb9a0d5d044a27ed4c99937190ab3137c..2b952580ecb6e055ae51a1b6bd219d091f73d5de 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDCenterprintDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDCenterprintDialog, title, string, _("Centerprint Panel"));
        ATTRIB(XonoticHUDCenterprintDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT);
        ATTRIB(XonoticHUDCenterprintDialog, intendedWidth, float, 0.4);
-       ATTRIB(XonoticHUDCenterprintDialog, rows, float, 15);
+       ATTRIB(XonoticHUDCenterprintDialog, rows, float, 15.5);
        ATTRIB(XonoticHUDCenterprintDialog, columns, float, 4);
        ATTRIB(XonoticHUDCenterprintDialog, name, string, "HUDcenterprint");
        ATTRIB(XonoticHUDCenterprintDialog, requiresConnection, float, true);
index 1ffa41f68c802d9c1cdb96995f2aa50619db762e..d1612412e66c8d419f0887b002534c070c091c88 100644 (file)
@@ -9,7 +9,9 @@ void XonoticHUDChatDialog_fill(entity me)
        entity e;
        string panelname = "chat";
 
-       DIALOG_HUDPANEL_COMMON();
+       dialog_hudpanel_main_checkbox(me, panelname);
+
+       dialog_hudpanel_main_settings(me, panelname);
 
        me.TR(me);
                me.TD(me, 1, 2, e = makeXonoticTextLabel(0, _("Chat entries:")));
index 570c2d616cde334e7402acc4d061ccad7c299d5d..da2f329bbaa57503569d16c8d1ed5630a2d59052 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDChatDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDChatDialog, title, string, _("Chat Panel"));
        ATTRIB(XonoticHUDChatDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT);
        ATTRIB(XonoticHUDChatDialog, intendedWidth, float, 0.4);
-       ATTRIB(XonoticHUDChatDialog, rows, float, 15);
+       ATTRIB(XonoticHUDChatDialog, rows, float, 15.5);
        ATTRIB(XonoticHUDChatDialog, columns, float, 4);
        ATTRIB(XonoticHUDChatDialog, name, string, "HUDchat");
        ATTRIB(XonoticHUDChatDialog, requiresConnection, float, true);
index b46d3aa02eff1fbd791331d3ac731c394506f426..ef63756870dd8d587901593ab2511efd65b99395 100644 (file)
@@ -8,7 +8,9 @@ void XonoticHUDEngineInfoDialog_fill(entity me)
        entity e;
        string panelname = "engineinfo";
 
-       DIALOG_HUDPANEL_COMMON();
+       dialog_hudpanel_main_checkbox(me, panelname);
+
+       dialog_hudpanel_main_settings(me, panelname);
 
        me.TR(me);
                me.TD(me, 1, 4, e = makeXonoticTextLabel(0, _("Engine info:")));
index b741465024d78a9917639aedabd61c209ae026ca..706767146c776c621c6304fe618be4f2164eabf0 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDEngineInfoDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDEngineInfoDialog, title, string, _("Engine Info Panel"));
        ATTRIB(XonoticHUDEngineInfoDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT);
        ATTRIB(XonoticHUDEngineInfoDialog, intendedWidth, float, 0.4);
-       ATTRIB(XonoticHUDEngineInfoDialog, rows, float, 15);
+       ATTRIB(XonoticHUDEngineInfoDialog, rows, float, 15.5);
        ATTRIB(XonoticHUDEngineInfoDialog, columns, float, 4);
        ATTRIB(XonoticHUDEngineInfoDialog, name, string, "HUDengineinfo");
        ATTRIB(XonoticHUDEngineInfoDialog, requiresConnection, float, true);
index ac305b83258638cd4352305a7071d338a5d85b3d..e67f63ffcda27281ceb077c18c979baa3f097700 100644 (file)
@@ -9,7 +9,9 @@ void XonoticHUDHealthArmorDialog_fill(entity me)
        entity e;
        string panelname = "healtharmor";
 
-       DIALOG_HUDPANEL_COMMON();
+       dialog_hudpanel_main_checkbox(me, panelname);
+
+       dialog_hudpanel_main_settings(me, panelname);
 
        me.TR(me);
                me.TD(me, 1, 4, e = makeXonoticCheckBox(0, "hud_panel_healtharmor_combined", _("Combine health and armor")));
index b37f41b76ef5f1ecf91a8d2056d2fe8cab68a98e..9342e293306137427ea3d339b34dcf49b749cc85 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDHealthArmorDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDHealthArmorDialog, title, string, _("Health/Armor Panel"));
        ATTRIB(XonoticHUDHealthArmorDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT);
        ATTRIB(XonoticHUDHealthArmorDialog, intendedWidth, float, 0.4);
-       ATTRIB(XonoticHUDHealthArmorDialog, rows, float, 16);
+       ATTRIB(XonoticHUDHealthArmorDialog, rows, float, 16.5);
        ATTRIB(XonoticHUDHealthArmorDialog, columns, float, 4);
        ATTRIB(XonoticHUDHealthArmorDialog, name, string, "HUDhealtharmor");
        ATTRIB(XonoticHUDHealthArmorDialog, requiresConnection, float, true);
index d758ad206643dcdba154fbfe48be74eca5726b58..6b11a691513c236689e8395df6f798968abd85ff 100644 (file)
@@ -8,7 +8,9 @@ void XonoticHUDInfoMessagesDialog_fill(entity me)
        entity e;
        string panelname = "infomessages";
 
-       DIALOG_HUDPANEL_COMMON();
+       dialog_hudpanel_main_checkbox(me, panelname);
+
+       dialog_hudpanel_main_settings(me, panelname);
 
        me.TR(me);
                me.TD(me, 1, 4, e = makeXonoticTextLabel(0, _("Info messages:")));
index 5d9032ffb0fdf3e307190fd5a77353b425b5a099..a6370d33e30e88d9566d3508d8ad49d0f3cabf22 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDInfoMessagesDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDInfoMessagesDialog, title, string, _("Info Messages Panel"));
        ATTRIB(XonoticHUDInfoMessagesDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT);
        ATTRIB(XonoticHUDInfoMessagesDialog, intendedWidth, float, 0.4);
-       ATTRIB(XonoticHUDInfoMessagesDialog, rows, float, 15);
+       ATTRIB(XonoticHUDInfoMessagesDialog, rows, float, 15.5);
        ATTRIB(XonoticHUDInfoMessagesDialog, columns, float, 4);
        ATTRIB(XonoticHUDInfoMessagesDialog, name, string, "HUDinfomessages");
        ATTRIB(XonoticHUDInfoMessagesDialog, requiresConnection, float, true);
index aeb8c8c774d639fa11a2073135e343e9d8c78f33..32264c5bcd32789aa21add5f6644a67e8a3d95ff 100644 (file)
@@ -13,12 +13,12 @@ void XonoticHUDItemsTimeDialog_fill(entity me)
 
        me.TR(me);
                me.TD(me, 1, 4, e = makeXonoticTextSlider("hud_panel_itemstime"));
-                       e.addValue(e, ZCTX(_("PNL^Disabled")), "0");
-                       e.addValue(e, ZCTX(_("PNL^Enabled spectating")), "1");
-                       e.addValue(e, ZCTX(_("PNL^Enabled even playing in warmup")), "2");
+                       e.addValue(e, _("Disable"), "0");
+                       e.addValue(e, _("Enable spectating"), "1");
+                       e.addValue(e, _("Enable even playing in warmup"), "2");
                        e.configureXonoticTextSliderValues(e);
 
-       DIALOG_HUDPANEL_COMMON_NOTOGGLE();
+       dialog_hudpanel_main_settings(me, panelname);
 
        me.TR(me);
                me.TD(me, 1, 1.4, e = makeXonoticTextLabel(0, _("Align icon:")));
index 507dedb7c95cc068adc2d478cf4a83795c72e620..0cb74ea6770fd64031c99f00a93ba45c70076327 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDItemsTimeDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDItemsTimeDialog, title, string, _("Items Time Panel"));
        ATTRIB(XonoticHUDItemsTimeDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT);
        ATTRIB(XonoticHUDItemsTimeDialog, intendedWidth, float, 0.4);
-       ATTRIB(XonoticHUDItemsTimeDialog, rows, float, 15);
+       ATTRIB(XonoticHUDItemsTimeDialog, rows, float, 15.5);
        ATTRIB(XonoticHUDItemsTimeDialog, columns, float, 4);
        ATTRIB(XonoticHUDItemsTimeDialog, name, string, "HUDitemstime");
 ENDCLASS(XonoticHUDItemsTimeDialog)
index 53cad1a930383ca693df2d8c5aa2419255df556b..afc47af30d4570768fb95cc48d12bfd4fb93ef97 100644 (file)
@@ -7,5 +7,7 @@ void XonoticHUDModIconsDialog_fill(entity me)
        entity e;
        string panelname = "modicons";
 
-       DIALOG_HUDPANEL_COMMON();
+       dialog_hudpanel_main_checkbox(me, panelname);
+
+       dialog_hudpanel_main_settings(me, panelname);
 }
index 3a3b72f6c9989df94d4695b135ed30f96f6186e5..a59d09af4b008950114dd03ee860cec51a0e694d 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDModIconsDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDModIconsDialog, title, string, _("Mod Icons Panel"));
        ATTRIB(XonoticHUDModIconsDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT);
        ATTRIB(XonoticHUDModIconsDialog, intendedWidth, float, 0.4);
-       ATTRIB(XonoticHUDModIconsDialog, rows, float, 15);
+       ATTRIB(XonoticHUDModIconsDialog, rows, float, 15.5);
        ATTRIB(XonoticHUDModIconsDialog, columns, float, 4);
        ATTRIB(XonoticHUDModIconsDialog, name, string, "HUDmodicons");
        ATTRIB(XonoticHUDModIconsDialog, requiresConnection, float, true);
index 490051846e378fd7835c50d684d9294083ef0ddc..1dc0a15b70617ec0cc42d17a90b93c9bacfca8bb 100644 (file)
@@ -9,7 +9,9 @@ void XonoticHUDNotificationDialog_fill(entity me)
        entity e;
        string panelname = "notify";
 
-       DIALOG_HUDPANEL_COMMON();
+       dialog_hudpanel_main_checkbox(me, panelname);
+
+       dialog_hudpanel_main_settings(me, panelname);
 
        me.TR(me);
                me.TD(me, 1, 4, e = makeXonoticTextLabel(0, _("Notifications:")));
index f816e4ffe042fd9d6f6f6ba84c46cecbdddc97b6..be51051f6c2b9acd138acd192c2677a5e46d606e 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDNotificationDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDNotificationDialog, title, string, _("Notification Panel"));
        ATTRIB(XonoticHUDNotificationDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT);
        ATTRIB(XonoticHUDNotificationDialog, intendedWidth, float, 0.4);
-       ATTRIB(XonoticHUDNotificationDialog, rows, float, 15);
+       ATTRIB(XonoticHUDNotificationDialog, rows, float, 15.5);
        ATTRIB(XonoticHUDNotificationDialog, columns, float, 4);
        ATTRIB(XonoticHUDNotificationDialog, name, string, "HUDnotify");
        ATTRIB(XonoticHUDNotificationDialog, requiresConnection, float, true);
index eabc93dab51021e7c44b1ac2cbe8dab9eda843ec..3a1e0bee1822a42e2fd363323e8f41cec73296f4 100644 (file)
@@ -12,13 +12,13 @@ void XonoticHUDPhysicsDialog_fill(entity me)
 
        me.TR(me);
                me.TD(me, 1, 4, e = makeXonoticTextSlider("hud_panel_physics"));
-                       e.addValue(e, _("Panel disabled"), "0");
-                       e.addValue(e, _("Panel enabled"), "1");
-                       e.addValue(e, _("Panel enabled even observing"), "2");
-                       e.addValue(e, _("Panel enabled only in Race/CTS"), "3");
+                       e.addValue(e, _("Disable"), "0");
+                       e.addValue(e, _("Enable"), "1");
+                       e.addValue(e, _("Enable even observing"), "2");
+                       e.addValue(e, _("Enable only in Race/CTS"), "3");
                        e.configureXonoticTextSliderValues(e);
 
-       DIALOG_HUDPANEL_COMMON_NOTOGGLE();
+       dialog_hudpanel_main_settings(me, panelname);
 
        me.TR(me);
                me.TD(me, 1, 1.4, e = makeXonoticCheckBox(0, "hud_panel_physics_progressbar", _("Status bar")));
index f6f19135d1f7a257d001d4af567bd01d50d03adc..2a52bef91b8841e8f60e42a6f83e31f476e6363f 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDPhysicsDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDPhysicsDialog, title, string, _("Physics Panel"));
        ATTRIB(XonoticHUDPhysicsDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT);
        ATTRIB(XonoticHUDPhysicsDialog, intendedWidth, float, 0.4);
-       ATTRIB(XonoticHUDPhysicsDialog, rows, float, 15);
+       ATTRIB(XonoticHUDPhysicsDialog, rows, float, 15.5);
        ATTRIB(XonoticHUDPhysicsDialog, columns, float, 4);
        ATTRIB(XonoticHUDPhysicsDialog, name, string, "HUDphysics");
        ATTRIB(XonoticHUDPhysicsDialog, sliderTopspeedTime, entity);
index 1b490d10272fdb3dc8bb28ee3d337b483afd751b..7e0ffae1a4137a46d20cccd1b96269d56349de6f 100644 (file)
@@ -9,7 +9,9 @@ void XonoticHUDPowerupsDialog_fill(entity me)
        entity e;
        string panelname = "powerups";
 
-       DIALOG_HUDPANEL_COMMON();
+       dialog_hudpanel_main_checkbox(me, panelname);
+
+       dialog_hudpanel_main_settings(me, panelname);
 
        me.TR(me);
                me.TD(me, 1, 4, e = makeXonoticCheckBox(0, "hud_panel_powerups_progressbar", _("Enable status bar")));
index 7f67fa6007b6f2423dfd54158ead5a20f038f36d..c82f98278095b5aed91d1501e59657be65aa3b64 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDPowerupsDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDPowerupsDialog, title, string, _("Powerups Panel"));
        ATTRIB(XonoticHUDPowerupsDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT);
        ATTRIB(XonoticHUDPowerupsDialog, intendedWidth, float, 0.4);
-       ATTRIB(XonoticHUDPowerupsDialog, rows, float, 14);
+       ATTRIB(XonoticHUDPowerupsDialog, rows, float, 15.5);
        ATTRIB(XonoticHUDPowerupsDialog, columns, float, 4);
        ATTRIB(XonoticHUDPowerupsDialog, name, string, "HUDpowerups");
        ATTRIB(XonoticHUDPowerupsDialog, requiresConnection, float, true);
index 4e24ff998eeb67f2b0351d999056784898dfc7af..30d95721090c17406c900b865d8ccab8d7bac3d6 100644 (file)
@@ -11,12 +11,12 @@ void XonoticHUDPressedKeysDialog_fill(entity me)
 
        me.TR(me);
                me.TD(me, 1, 4, e = makeXonoticTextSlider("hud_panel_pressedkeys"));
-                       e.addValue(e, _("Panel disabled"), "0");
-                       e.addValue(e, _("Panel enabled when spectating"), "1");
-                       e.addValue(e, _("Panel always enabled"), "2");
+                       e.addValue(e, ("Disable"), "0");
+                       e.addValue(e, ("Enable when spectating"), "1");
+                       e.addValue(e, ("Always enable"), "2");
                        e.configureXonoticTextSliderValues(e);
 
-       DIALOG_HUDPANEL_COMMON_NOTOGGLE();
+       dialog_hudpanel_main_settings(me, panelname);
 
        me.TR(me);
                me.TDempty(me, 0.2);
index cc82959e6443af3c3ffc594da63504f66cf399dd..46452c696dfa76469fa3fe3b3ccd2b1dec78ed56 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDPressedKeysDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDPressedKeysDialog, title, string, _("Pressed Keys Panel"));
        ATTRIB(XonoticHUDPressedKeysDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT);
        ATTRIB(XonoticHUDPressedKeysDialog, intendedWidth, float, 0.4);
-       ATTRIB(XonoticHUDPressedKeysDialog, rows, float, 15);
+       ATTRIB(XonoticHUDPressedKeysDialog, rows, float, 15.5);
        ATTRIB(XonoticHUDPressedKeysDialog, columns, float, 4);
        ATTRIB(XonoticHUDPressedKeysDialog, name, string, "HUDpressedkeys");
        ATTRIB(XonoticHUDPressedKeysDialog, requiresConnection, float, true);
index 4012bc61ac13b64975a57ff9c47e8bf356432af6..128951c0c8acfbde8bc5d33e84af28d49ca74776 100644 (file)
@@ -9,7 +9,10 @@ void XonoticHUDQuickMenuDialog_fill(entity me)
        entity e;
        string panelname = "quickmenu";
 
-       DIALOG_HUDPANEL_COMMON_NOTOGGLE();
+       // this panel has no main cvar
+       //dialog_hudpanel_main_checkbox(me, panelname);
+
+       dialog_hudpanel_main_settings(me, panelname);
 
        me.TR(me);
                me.TD(me, 1, 4, e = makeXonoticTextLabel(0, _("Text alignment:")));
index 16f93c13d584579397f754ca3a78ec9dcdba7de4..ac6693a648155fe71a93257c7f7cc42d36ce583c 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDQuickMenuDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDQuickMenuDialog, title, string, _("Quick Menu Panel"));
        ATTRIB(XonoticHUDQuickMenuDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT);
        ATTRIB(XonoticHUDQuickMenuDialog, intendedWidth, float, 0.4);
-       ATTRIB(XonoticHUDQuickMenuDialog, rows, float, 15);
+       ATTRIB(XonoticHUDQuickMenuDialog, rows, float, 15.5);
        ATTRIB(XonoticHUDQuickMenuDialog, columns, float, 4);
        ATTRIB(XonoticHUDQuickMenuDialog, name, string, "HUDquickmenu");
 ENDCLASS(XonoticHUDQuickMenuDialog)
index 2673e546039a5afc5fb86d72e25e78193f1ce201..d4bbe51f56451c941c4ac312b0384b46f48ab00e 100644 (file)
@@ -7,5 +7,7 @@ void XonoticHUDRaceTimerDialog_fill(entity me)
        entity e;
        string panelname = "racetimer";
 
-       DIALOG_HUDPANEL_COMMON();
+       dialog_hudpanel_main_checkbox(me, panelname);
+
+       dialog_hudpanel_main_settings(me, panelname);
 }
index 7c814e3823e3586d7a2c9d14edb9a2a688f67cd0..81a8f005341aa3c5be0c3b4549ecc39710a6ce56 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDRaceTimerDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDRaceTimerDialog, title, string, _("Race Timer Panel"));
        ATTRIB(XonoticHUDRaceTimerDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT);
        ATTRIB(XonoticHUDRaceTimerDialog, intendedWidth, float, 0.4);
-       ATTRIB(XonoticHUDRaceTimerDialog, rows, float, 15);
+       ATTRIB(XonoticHUDRaceTimerDialog, rows, float, 15.5);
        ATTRIB(XonoticHUDRaceTimerDialog, columns, float, 4);
        ATTRIB(XonoticHUDRaceTimerDialog, name, string, "HUDracetimer");
        ATTRIB(XonoticHUDRaceTimerDialog, requiresConnection, float, true);
index de9ed6898b821e7df49781fcb2176c85fcd103a1..3e8db6686c09b79c96b6096eb6d9052a245b65b1 100644 (file)
@@ -12,12 +12,12 @@ void XonoticHUDRadarDialog_fill(entity me)
 
        me.TR(me);
                me.TD(me, 1, 4, e = makeXonoticTextSlider("hud_panel_radar"));
-                       e.addValue(e, _("Panel disabled"), "0");
-                       e.addValue(e, _("Panel enabled in teamgames"), "1");
-                       e.addValue(e, _("Panel always enabled"), "2");
+                       e.addValue(e, _("Disable"), "0");
+                       e.addValue(e, _("Enable in team games"), "1");
+                       e.addValue(e, _("Always enable"), "2");
                        e.configureXonoticTextSliderValues(e);
 
-       DIALOG_HUDPANEL_COMMON_NOTOGGLE();
+       dialog_hudpanel_main_settings(me, panelname);
 
        me.TR(me);
                me.TD(me, 1, 4, e = makeXonoticTextLabel(0, _("Radar:")));
index 04617b677f4c04a7444cf5de08444c1c67532f25..d02f5cd59298fe3b45bba6ca0aefd81f0c8c6d06 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDRadarDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDRadarDialog, title, string, _("Radar Panel"));
        ATTRIB(XonoticHUDRadarDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT);
        ATTRIB(XonoticHUDRadarDialog, intendedWidth, float, 0.4);
-       ATTRIB(XonoticHUDRadarDialog, rows, float, 15);
+       ATTRIB(XonoticHUDRadarDialog, rows, float, 15.5);
        ATTRIB(XonoticHUDRadarDialog, columns, float, 4);
        ATTRIB(XonoticHUDRadarDialog, name, string, "HUDradar");
        ATTRIB(XonoticHUDRadarDialog, requiresConnection, float, true);
index f04ca30da9397f358055366fa8bb726398847078..afb97e5fd42de9a8fed0ce82d6352bb22a9fddd9 100644 (file)
@@ -9,7 +9,9 @@ void XonoticHUDScoreDialog_fill(entity me)
        entity e;
        string panelname = "score";
 
-       DIALOG_HUDPANEL_COMMON();
+       dialog_hudpanel_main_checkbox(me, panelname);
+
+       dialog_hudpanel_main_settings(me, panelname);
 
        me.TR(me);
                me.TD(me, 1, 4, e = makeXonoticTextLabel(0, _("Score:")));
index d97787404e921121ce3453be7f8a42bfd1a940fb..20fa6cf967f86aa1a26a4644f32aaf4ae652e2a3 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDScoreDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDScoreDialog, title, string, _("Score Panel"));
        ATTRIB(XonoticHUDScoreDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT);
        ATTRIB(XonoticHUDScoreDialog, intendedWidth, float, 0.4);
-       ATTRIB(XonoticHUDScoreDialog, rows, float, 15);
+       ATTRIB(XonoticHUDScoreDialog, rows, float, 15.5);
        ATTRIB(XonoticHUDScoreDialog, columns, float, 4);
        ATTRIB(XonoticHUDScoreDialog, name, string, "HUDscore");
        ATTRIB(XonoticHUDScoreDialog, requiresConnection, float, true);
index dd9a7b8788923f0a5f424e9e76c6655ce248c226..84c6d862dbebb8a4644e2546516a9d9b70a71de1 100644 (file)
@@ -8,7 +8,9 @@ void XonoticHUDTimerDialog_fill(entity me)
        entity e;
        string panelname = "timer";
 
-       DIALOG_HUDPANEL_COMMON();
+       dialog_hudpanel_main_checkbox(me, panelname);
+
+       dialog_hudpanel_main_settings(me, panelname);
 
        me.TR(me);
                me.TD(me, 1, 4, e = makeXonoticTextLabel(0, _("Timer:")));
index 61955495edd4c7ac985ee989c39fe2d23b27cf3c..dac91cc2a67a57ec9fe1e79f9568a98857179931 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDTimerDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDTimerDialog, title, string, _("Timer Panel"));
        ATTRIB(XonoticHUDTimerDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT);
        ATTRIB(XonoticHUDTimerDialog, intendedWidth, float, 0.4);
-       ATTRIB(XonoticHUDTimerDialog, rows, float, 15);
+       ATTRIB(XonoticHUDTimerDialog, rows, float, 15.5);
        ATTRIB(XonoticHUDTimerDialog, columns, float, 4);
        ATTRIB(XonoticHUDTimerDialog, name, string, "HUDtimer");
        ATTRIB(XonoticHUDTimerDialog, requiresConnection, float, true);
index e8afa7ca706b91a71b050c9af2c12de684924bf4..39c9a69f707a0465aee72da99363c2c5123ae72c 100644 (file)
@@ -9,7 +9,9 @@ void XonoticHUDVoteDialog_fill(entity me)
        entity e;
        string panelname = "vote";
 
-       DIALOG_HUDPANEL_COMMON();
+       dialog_hudpanel_main_checkbox(me, panelname);
+
+       dialog_hudpanel_main_settings(me, panelname);
 
        me.TR(me);
                me.TD(me, 1, 1.4, e = makeXonoticTextLabel(0, _("Alpha after voting:")));
index 061c69e56c4797b3d904739b0adcedfe97d79bba..b07b189e5b81d031ccd8069a053e117eec7271d5 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDVoteDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDVoteDialog, title, string, _("Vote Panel"));
        ATTRIB(XonoticHUDVoteDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT);
        ATTRIB(XonoticHUDVoteDialog, intendedWidth, float, 0.4);
-       ATTRIB(XonoticHUDVoteDialog, rows, float, 15);
+       ATTRIB(XonoticHUDVoteDialog, rows, float, 15.5);
        ATTRIB(XonoticHUDVoteDialog, columns, float, 4);
        ATTRIB(XonoticHUDVoteDialog, name, string, "HUDvote");
        ATTRIB(XonoticHUDVoteDialog, requiresConnection, float, true);
index 61339b6b938cc54800e1326bba256b00d08488a4..116b8ae2f06798a47e1854b5306c6eb58130acf9 100644 (file)
@@ -13,7 +13,9 @@ void XonoticHUDWeaponsDialog_fill(entity me)
        string panelname = "weapons";
        float i;
 
-       DIALOG_HUDPANEL_COMMON();
+       dialog_hudpanel_main_checkbox(me, panelname);
+
+       dialog_hudpanel_main_settings(me, panelname);
 
        me.TR(me);
                me.TDempty(me, 0.2);
index fad14749e6f4665f00b4c460c238a018811d0f37..4f877d4d3f3419e444f0fbbab65c7bbde913d970 100644 (file)
@@ -6,7 +6,7 @@ CLASS(XonoticHUDWeaponsDialog, XonoticRootDialog)
        ATTRIB(XonoticHUDWeaponsDialog, title, string, _("Weapons Panel"));
        ATTRIB(XonoticHUDWeaponsDialog, color, vector, SKINCOLOR_DIALOG_TEAMSELECT);
        ATTRIB(XonoticHUDWeaponsDialog, intendedWidth, float, 0.4);
-       ATTRIB(XonoticHUDWeaponsDialog, rows, float, 21);
+       ATTRIB(XonoticHUDWeaponsDialog, rows, float, 21.5);
        ATTRIB(XonoticHUDWeaponsDialog, columns, float, 4);
        ATTRIB(XonoticHUDWeaponsDialog, name, string, "HUDweapons");
        ATTRIB(XonoticHUDWeaponsDialog, requiresConnection, float, true);
index 7b381b544588ae4d9049d972ad0d74d44c7c9a23..450c034fde2a151badded14aa5d94b2000d88880 100644 (file)
@@ -758,12 +758,21 @@ entity makeXonoticCheckBoxString(string, string, string, string);
 entity makeXonoticCheckBox(float, string, string);
 .bool sendCvars;
 
-void dialog_hudpanel_common_notoggle(entity me, string panelname)
+void dialog_hudpanel_main_checkbox(entity me, string panelname)
 {
-       float i;
        entity e;
 
        me.TR(me);
+               me.TDempty(me, 1.5);
+               me.TD(me, 1, 2.5, e = makeXonoticCheckBox(0, strzone(strcat("hud_panel_", panelname)), _("Enable")));
+}
+
+void dialog_hudpanel_main_settings(entity me, string panelname)
+{
+       float i;
+       entity e;
+
+       me.gotoRC(me, me.currentRow + 1.5, 0);
                me.TD(me, 1, 1.4, e = makeXonoticTextLabel(0, _("Background:")));
                        me.TD(me, 1, 2.6, e = makeXonoticTextSlider(strzone(strcat("hud_panel_", panelname, "_bg"))));
                                e.addValue(e, _("Default"), "");
index 96fef2ad4006f553a3bd8a5b22dd594b684df5c3..f5bd636d81f98c1b481b0919776ed2051d5fddaf 100644 (file)
@@ -36,13 +36,8 @@ string GameType_GetIcon(int cnt);
 int GameType_GetCount();
 int GameType_GetTotalCount();
 
-void dialog_hudpanel_common_notoggle(entity me, string panelname);
-#define DIALOG_HUDPANEL_COMMON_NOTOGGLE() \
-       dialog_hudpanel_common_notoggle(me, panelname)
-#define DIALOG_HUDPANEL_COMMON() \
-       me.TR(me); \
-               me.TD(me, 1, 4, e = makeXonoticCheckBox(0, strzone(strcat("hud_panel_", panelname)), _("Enable panel"))); \
-       DIALOG_HUDPANEL_COMMON_NOTOGGLE()
+void dialog_hudpanel_main_checkbox(entity me, string panelname);
+void dialog_hudpanel_main_settings(entity me, string panelname);
 
 float getFadedAlpha(float currentAlpha, float startAlpha, float targetAlpha);