GUI2/Help Browser: refined layout

This commit is contained in:
Charles Dang 2025-03-24 11:26:21 -04:00
parent 9cc5911bc8
commit 3d316a5705

View File

@ -96,6 +96,80 @@
[/tree_view]
#enddef
#define _GUI_TOP_GRID
[grid]
[row]
[column]
grow_factor = 1
border = "all"
border_size = 5
horizontal_grow = true
vertical_grow = true
[label]
definition = "default_large_script"
id = "topic_title"
[/label]
[/column]
[column]
border = "all"
border_size = 5
horizontal_alignment = "right"
[toggle_button]
id = "contents"
label = _ "Show Topics"
[/toggle_button]
[/column]
[column]
border = "all"
border_size = 5
horizontal_alignment = "right"
[button]
id = "back"
definition = "left_arrow_ornate"
[/button]
[/column]
[column]
border = "all"
border_size = 5
horizontal_alignment = "right"
[button]
id = "next"
definition = "right_arrow_ornate"
[/button]
[/column]
[column]
border = "all"
border_size = 5
horizontal_grow = true
[text_box]
id = "filter_box"
definition = "default"
{FILTER_TEXT_BOX_HINT}
tooltip = _ "Search help topic names"
[/text_box]
[/column]
[/row]
[/grid]
#enddef
[window]
id = "help_browser"
description = "Battle for Wesnoth Help."
@ -123,87 +197,15 @@
[row]
grow_factor = 0
[column]
grow_factor = 1
horizontal_grow = true
[grid]
[row]
[column]
grow_factor = 1
border = "all"
border_size = 5
horizontal_alignment = "left"
[label]
definition = "title"
label = _ "Battle For Wesnoth Help"
[/label]
[/column]
[column]
grow_factor = 0
border = "all"
border_size = 5
horizontal_alignment = "right"
[toggle_button]
id = "contents"
label = _ "Show Topics"
[/toggle_button]
[/column]
[column]
border = "all"
border_size = 5
horizontal_alignment = "right"
[text_box]
id = "filter_box"
definition = "default"
{FILTER_TEXT_BOX_HINT}
tooltip = _ "Search help topic names"
[/text_box]
[/column]
[column]
grow_factor = 0
border = "all"
border_size = 5
horizontal_alignment = "right"
[button]
id = "back"
definition = "left_arrow_ornate"
[/button]
[/column]
[column]
grow_factor = 0
border = "all"
border_size = 5
horizontal_alignment = "right"
[button]
id = "next"
definition = "right_arrow_ornate"
[/button]
[/column]
[/row]
[/grid]
border = "all"
border_size = 5
vertical_grow = true
horizontal_alignment = "left"
{_GUI_HELP_TREEVIEW}
[/column]
[/row]
[row]
grow_factor = 1
[column]
grow_factor = 1
horizontal_grow = true
@ -212,95 +214,65 @@
[grid]
[row]
grow_factor = 0
[column]
grow_factor = 0
border = "all"
border_size = 5
vertical_grow = true
horizontal_alignment = "left"
horizontal_grow = true
{_GUI_HELP_TREEVIEW}
{_GUI_TOP_GRID}
[/column]
[/row]
[row]
grow_factor = 1
[column]
grow_factor = 1
border = "all"
border_size = 5
horizontal_grow = true
vertical_grow = true
[grid]
[scrollbar_panel]
id = "topic_scroll_panel"
[row]
grow_factor = 0
[definition]
[column]
border = "all"
border_size = 5
horizontal_grow = true
vertical_grow = true
[row]
[label]
definition = "default_large_script"
id = "topic_title"
[/label]
[/column]
[column]
horizontal_grow = true
vertical_grow = true
[/row]
[rich_label]
width = 950
id = "topic_text"
[/rich_label]
[row]
grow_factor = 1
[/column]
[column]
border = "all"
border_size = 5
horizontal_grow = true
vertical_grow = true
[/row]
[scrollbar_panel]
id = "topic_scroll_panel"
[definition]
[/definition]
[row]
[/scrollbar_panel]
[column]
horizontal_grow = true
vertical_grow = true
[/column]
[rich_label]
width = 950
id = "topic_text"
[/rich_label]
[/column]
[/row]
[/row]
[row]
grow_factor = 0
[/definition]
[column]
border = "all"
border_size = 5
horizontal_alignment = "right"
[/scrollbar_panel]
[/column]
[/row]
[row]
grow_factor = 0
[column]
grow_factor = 1
border = "all"
border_size = 5
horizontal_alignment = "right"
[button]
id = "cancel"
label = _ "Close"
[/button]
[/column]
[/row]
[/grid]
[button]
id = "ok"
label = _ "Close"
[/button]
[/column]
@ -319,4 +291,4 @@
[/window]
#undef _GUI_TOPIC_TREE
#undef _GUI_NODE
#undef _GUI_TOP_GRID