From e2c5b923fb86d5e8fe594cc79da4a3790dde18c9 Mon Sep 17 00:00:00 2001 From: Iris Morelle Date: Mon, 6 Jul 2020 21:23:36 -0400 Subject: [PATCH] gui2/toggle_button: Add a radio button variation without a label --- .../widget/toggle_button_radio_no_label.cfg | 112 ++++++++++++++++++ 1 file changed, 112 insertions(+) create mode 100644 data/gui/widget/toggle_button_radio_no_label.cfg diff --git a/data/gui/widget/toggle_button_radio_no_label.cfg b/data/gui/widget/toggle_button_radio_no_label.cfg new file mode 100644 index 000000000000..a2de2e4e869c --- /dev/null +++ b/data/gui/widget/toggle_button_radio_no_label.cfg @@ -0,0 +1,112 @@ +#textdomain wesnoth-lib +### +### Definition of a radio toggle button without a label. +### + +#define _GUI_RESOLUTION RESOLUTION WIDTH HEIGHT + [resolution] + + {RESOLUTION} + + min_width = {WIDTH} + min_height = {HEIGHT} + + default_width = {WIDTH} + default_height = {HEIGHT} + + max_width = 0 + max_height = {HEIGHT} + + [state] + [enabled] + + [draw] + + [image] + name = "buttons/radiobox.png" + [/image] + + [/draw] + + [/enabled] + + [disabled] + + [draw] + + [image] + name = "buttons/radiobox.png~GS()" + [/image] + + [/draw] + + [/disabled] + + [focused] + + [draw] + + [image] + name = "buttons/radiobox-active.png" + [/image] + + [/draw] + + [/focused] + [/state] + +### +### Selected +### + + [state] + [enabled] + + [draw] + + [image] + name = "buttons/radiobox-pressed.png" + [/image] + + [/draw] + + [/enabled] + + [disabled] + + [draw] + + [image] + name = "buttons/radiobox-pressed.png~GS()" + [/image] + + [/draw] + + [/disabled] + + [focused] + + [draw] + + [image] + name = "buttons/radiobox-active-pressed.png" + [/image] + + [/draw] + + [/focused] + [/state] + + [/resolution] +#enddef + +[toggle_button_definition] + + id = "radio_no_label" + description = "Radio button without a text label." + + {_GUI_RESOLUTION () 20 18} + +[/toggle_button_definition] + +#undef _GUI_RESOLUTION