Commit graph

19 commits

Author SHA1 Message Date
Subhraman Sarkar
43f0e05d57 preferences dialog: expose option for switching gui2 themes 2024-07-16 13:07:57 +05:30
Celtic Minstrel
3cfe0c338d Minor improvement to the schema validation script 2023-05-02 21:04:41 -04:00
Celtic Minstrel
5a1491a6ae Split up the GUI2 schema into multiple files.
The motivation for this is to reuse parts of it for another schema.
2023-05-02 21:04:41 -04:00
Tommy
ebcae03e48 Add a new image tiling mode: "tile_highres" for high-DPI tiled images.
The other options "tile" and "tile_center" work in draw space,
which is consistent with past behaviour, but doesn't look as nice.
2022-06-14 14:48:03 +12:00
Tommy
638c02b59e Rename image_shape.vertical_mirror_ to mirror_.
It is in fact (and always was) mirroring horizontally.
2022-05-31 21:17:33 +12:00
Pentarctagon
c3a5763f03
Fix schema. 2022-04-08 11:49:02 -05:00
Charles Dang
465a5b44b1 Fixup schema 2021-08-09 01:07:47 -04:00
Charles Dang
3d87478a29 GUI2: add resize_mode=scale_sharp for [image] shapes 2021-08-09 00:45:23 -04:00
Celtic Minstrel
0c42cdc038
Enable translation mark validation by the schema (#5800)
- The t_string type is now a schema built-in type and no longer attempts a regex match.
- You can also specify that non-t_string types may be optionally-translatable; this case supports a regex match on the string (but note that the translation mark is not part of the match).
- Error messages involving keys with very large values ( > 128 characters) will now truncate the value.
- To account for occasional cases where the schema is intentionally violated, the --validate command-line option now automatically defines the SCHEMA_VALIDATION preprocessor define.

A key validates as type t_string if one of the following is true:
- The key is not present
- The key has at least one segment with a translation mark
- The key is blank (an empty string)

Any type other than t_string is not allowed to be translatable by default, unless you specify allow_translatable=yes in the [type] tag.

An optionally-translatable string could also be defined as a union of t_string and some other type.
2021-06-14 23:59:52 -04:00
Iris Morelle
3d7f0a6116 schema: GUI2 dropdown menus support the details= attribute 2020-12-14 14:44:08 -03:00
Charles Dang
a22622258e Updated schema 2020-12-12 03:53:48 +11:00
Glen Whitney
f3a472ab96 Modify GUI2 config files to scale font size with screen pixel pitch
These changes to the data/gui subdirectories make it so that above a certain
  screen pixel dimensions (currently 1200x900), text font sizes will be scaled
  with the pixel pitch of the SDL video device. In addition, several dialogues
  (such as the unit recall window, for example) are allowed to take on larger
  pixel dimensions to accommodate the larger (in pixel size) fonts.
2020-05-16 15:01:01 -05:00
Iris Morelle
3beefca899 gui2/text_box: Add hover effect
This gives GUI2 textboxes (and password boxes since they are a subclass)
a simple hover effect by extending the canvas definitions for the widget
accordingly.
2019-11-11 17:16:39 +11:00
Celtic Minstrel
4674e97eb6 Schema: Add a macro for links (and make use of it) 2018-10-23 22:49:53 -04:00
Celtic Minstrel
e3b17d3e9f GUI2 Schema: Make use of the key macros 2018-10-23 22:49:52 -04:00
Celtic Minstrel
844b20da40 GUI2 Schema: Use max=infinite instead of max=-1 2018-10-23 22:49:51 -04:00
Celtic Minstrel
9ab1777851 Enable nesting of [type] tags
Minor cleanup of GUI2 type definitions
Disallow stuff like border=top,all
2018-10-23 22:37:18 -04:00
Celtic Minstrel
34604fdff6 Get game config and schema to use some common types
This also fixes an invalid type issue in the GUI2 schema,
and allows types to be a direct alias for other types.
2018-10-23 22:36:47 -04:00
Celtic Minstrel
3365aef28a Move GUI2 schema into the schema directory 2018-10-23 22:36:46 -04:00
Renamed from data/gui/schema.cfg (Browse further)