#textdomain wesnoth-lib

[window]
	id = "editor_set_starting_position"
	description = "Map editor dialog for setting player starting positions."

	[resolution]
		definition = "default"

		automatic_placement = "true"
		vertical_placement = "center"
		horizontal_placement = "center"

		maximum_width = 500
		maximum_height = 600

		[linked_group]
			id = "players"
			fixed_width = "true"
		[/linked_group]
		
		[linked_group]
			id = "locations"
			fixed_width = "true"
		[/linked_group]

		[tooltip]
			id = "tooltip_large"
		[/tooltip]

		[helptip]
			id = "tooltip_large"
		[/helptip]

		[grid]

			[row]
				grow_factor = 0

				[column]
					grow_factor = 1

					border = "all"
					border_size = 5
					horizontal_alignment = "left"

					[label]
						id =  "title"
						definition = "title"
						label = _ "Choose Player"
					[/label]

				[/column]

			[/row]

			[row]
				grow_factor = 0

				[column]
					grow_factor = 0

					border = "all"
					border_size = 5
					horizontal_alignment = "left"

					[label]
						id = "message"
						definition = "default"
						label = _ "Which player should start here?"
						wrap = "true"
					[/label]

				[/column]

			[/row]

			[row]
				grow_factor = 1

				[column]
					grow_factor = 1

					horizontal_grow = "true"
					vertical_grow = "true"

					border = "all"
					border_size = 5

					[listbox]
						id = "listbox"
						definition = "default"

						[list_definition]

							[row]

								[column]
								 	vertical_grow = "true"
								 	horizontal_grow = "true"
								 	[toggle_panel]
										definition = "default"
										return_value_id = "ok"
										[grid]
											[row]
												[column]
													grow_factor = 1
													horizontal_grow = "true"
													border = "all"
													border_size = 5
													[label]
														id = "player"
														definition = "default"
														linked_group = "players"
													[/label]
												[/column]
												[column]
													grow_factor = 1
													horizontal_grow = "true"
													border = "all"
													border_size = 5
													[label]
														id = "location"
														definition = "default"
														linked_group = "locations"
													[/label]
												[/column]
											[/row]
										[/grid]
									[/toggle_panel]
								[/column]

							[/row]

						[/list_definition]

					[/listbox]

				[/column]

			[/row]

			[row]
				grow_factor = 0

				[column]
					grow_factor = 1
					horizontal_grow = "true"

					[grid]

						[row]
							grow_factor = 0

							[column]
								border = "all"
								border_size = 5
								horizontal_alignment = "right"

								[button]
									id = "ok"
									definition = "default"
									label = _ "OK"
								[/button]

							[/column]

							[column]
								border = "all"
								border_size = 5
								horizontal_alignment = "right"

								[button]
									id = "cancel"
									definition = "default"
									label = _ "Cancel"
								[/button]

							[/column]

						[/row]

					[/grid]

				[/column]

			[/row]

		[/grid]

	[/resolution]

[/window]
