Opened 7 years ago

Last modified 6 years ago

#1532 new enhancement

GUI - Dropdown improvements — at Version 2

Reported by: historic_bruno Owned by:
Priority: Should Have Milestone: Backlog
Component: Core engine Keywords: design
Cc: Patch:

Description (last modified by historic_bruno)

  • Implement disabled sprite and text color ("sprite_disabled", "textcolor_disabled")
  • Implement hover/mouseover sprite and text color ("sprite_over", "textcolor_over")
  • Implement pressed sprite and text color ("sprite_pressed"?, "textcolor_pressed")
  • Dynamic size adjustment: currently the max height of the dropdown list is specified with "dropdown_size", it would be nice if it could adjust dynamically to fit in the window. Maybe as an option.
  • Jump to the position of the currently selected item, when opening the dropdown. Same problem that CList has.
  • Remember input focus when list is closed, so the dropdown can be navigated by arrow keys (scrollwheel too?) #698 is related.

Dropdowns are a bit weird, the property names are not intuitive or well-documented, here's an explanation I found in styles.xml:

Dropdown button:
	* size=shape
	* sprite=bkg
	* textcolor=text color
Dropdown arrow button:
	* button_width=shape
	* sprite2=bkg
	* sprite2_pressed=bkg clicked
Dropdown list:
	* buffer_zone=margin
	* dropdown_size=height
	* sprite_list=bkg
	* sprite_selectarea=bkg hovered item
	* textcolor_selected=text color hobered item

See GUI_-_Drop-down.

Change History (2)

comment:1 Changed 7 years ago by ben

In 12107:

Increases maximum dropdown list size slightly, allowing up to 10 lines at a time (must be careful that it fits on 1024x768!). Refs #1532

comment:2 Changed 7 years ago by historic_bruno

Description: modified (diff)
Note: See TracTickets for help on using tickets.