Commit Graph

44 Commits

Author SHA1 Message Date
c407ffd248 allow ELLIPSIS mode through dialogxml 2025-05-11 10:50:08 -05:00
8af5eb6c38 dialogs can have a button respond to Escape
I'm planning to make it so the Enter key will never cancel a yes/no dialog. To do this, I'm adding an Escape button to dialogs. So cancel/accept keyboard shortcuts will be predictable and intuitive. Dialogs that require extra confirmation will have a 'really confirm' LED.
2025-03-30 11:51:11 -05:00
ab952db0cd note in dialog.xsd for doc file I can't ever find 2025-03-30 11:51:10 -05:00
8b08b46ea0 Unbake the special help texts.
The text in the various help dialogs that was previously baked into an image is now drawn as text, meaning that it benefits from text unblurring when scaling is active.

This entails some small changes to layout, since it's a different font.

Dialog engine changes:
* A new picture type allowing to draw the inventory button icons directly into a dialog.
* A new widget type that simply draws a line between two points.
2025-03-16 14:03:53 -04:00
4c4c70648c Add a fill-color attribute to <pict> 2025-03-08 20:05:12 -05:00
cabec65cdf xml schema allow anchors in containers 2025-03-07 08:31:35 -05:00
3d48cb14e7 Add an SDF picker for selecting a stuff done flag and optionally giving it a name.
In effect, this is a combination of two of the previous pickers:
the location picker, and the editable string picker.

This required quite a significant rework of how the tilemap places its children.

Currently it's only used in special node editing.
I plan to add its use in many other places too though.
2025-03-02 19:13:01 -05:00
e1a03ce881 Add a 'filled' option to dialogxml pict and use it in get-items
Fix #629
2025-03-02 19:13:01 -05:00
f018f051f6 Add a new tilemap control that replicates its children into a fixed grid.
Use it for the Edit Terrain Object dialog.
2025-03-02 19:13:01 -05:00
a669fe0223 handle showPipes in code only. Fix #609 2025-02-18 09:37:29 -05:00
fcf0bcc324 add show-pipes attribute to <text> 2025-02-09 20:37:46 -06:00
c079d0f5a9 Allow int value for text size in dialogxml 2025-02-09 11:16:24 -06:00
de45b379e3 add max-chars attribute to text field 2025-01-23 20:12:32 -06:00
270b2bb802 fix last case of textSide 2024-12-03 09:44:40 -05:00
3bd9154412 rename new led attribute 'label-pos' 2024-12-03 09:44:40 -05:00
c35ba7cc62 LEDs allow text on the left side 2024-12-03 09:44:40 -05:00
2b01a18bb3 make text-size an optional attribute of button 2024-12-03 09:44:40 -05:00
7a1297b2c8 specify align attribute type as enum 2024-11-23 17:06:15 -06:00
af2253e5ce reconfigure about-boe.xml with right alignment convention 2024-11-16 17:47:07 -06:00
7e063ab1ed dialogxml schema: fix <field> missing positioning attributes 2024-09-10 22:18:59 -04:00
7f12c6eea4 Support underlined text in DialogXML 2020-02-26 01:20:11 -05:00
49d88c76e2 Add page definition facility to the DialogXML <stack> widget
- New <page> element in <stack>
- Visibility of elements is now remembered when switching pages
- Unstoring a <pict> on a stack page no longer resets default values
- Documentation updated for new features
2020-02-25 21:05:59 -05:00
c8549ca680 DialogXML: Support <key> in <text> with optional ref= 2020-02-23 23:02:16 -05:00
c65bac2a8f Implement relative positioning system for DialogXML
This allows widgets to be positioned relative to other widgets.

Two dialogs have been converted to use relative positioning.

Also fix some issues with calculating the dialog rect.
2020-02-23 22:00:01 -05:00
bd3aa33807 Schemas: Fix indentation 2015-10-06 22:17:27 -04:00
5667849835 Dialog schema: Convert indentation to tabs 2015-10-06 22:17:27 -04:00
f0af9ff67f Schemas: Enforce root element by eliminating global element declarations 2015-10-06 22:17:27 -04:00
8afd3825b0 Refactor the dialog engine's event handling to make it easier to add new events in the future
- Focus event split into focus and defocus
- Scroll event added but not yet properly implemented

Also:
- Remove the useless (and ignored) clickable attributes from the schema
- Pave the way for controls other than fields to be able to recieve keyboard focus
2015-10-03 19:49:33 -04:00
8b90fa614b Make stack control a real container instead of a controller
- Also add framed/outlined attributes to it and to LED groups
2015-10-03 12:30:26 -04:00
b176918dda DialogXML: Make the frame style format parameter a first-class citizen
- It's now exposed in the schema with a new attribute, outline, on all elements that accept framed
- It now has four possible values: solid, outset, inset, double. Dashed or dotted may be added later; they're a lot harder.
- Second make scenario dialog uses a custom frame style
2015-10-03 11:13:33 -04:00
03bc3d05e6 Remove key-mod attribute from dialog schema
- Modifiers are now given in the def-key attribute, as originally intended
- Dialogs that have a help button now assign F1 to that button (replacing shift+/ in some cases)
- F1 also brings up help in the main game (in addition to shift+/)
2015-10-03 00:53:32 -04:00
1b75bb4755 Add constraint for defbtn attribute to refer to a valid name in the dialog schema 2015-10-02 23:31:02 -04:00
b39ac35298 New alternate scrollbar style, used by default in dialogs 2015-10-02 23:31:01 -04:00
4aea031914 Add linked element to scrollbars
The linked element will be updated dynamically as the scrollbar's value changes.
Also: Added long-missing hasControl() method to cDialog
2015-10-02 22:59:04 -04:00
f7daba4ead Scrollbars are finally a first-class citizen in the dialog engine.
- Add <slider> tag to put an unbound scrollbar in the dialog
- Add support for horizontal scrollbars
2015-10-02 21:44:17 -04:00
a455941d92 New scroll pane control in the dialog engine
Also:
- Use a scroll pane for the credits in the about dialog, so that new credits can be added without altering other elements
- Use a scroll pane for the list of sections to be deleted in the resize outdoors dialog
- New cContainer superclass for controls that contain other controls
- Scrollbars consider their maximum as part of their state
2015-10-02 17:03:25 -04:00
4104e08481 Factor out some common definitions from the XML schemas 2015-07-10 15:02:50 -04:00
e055b97c9f Add dialog allowing you to alter the scenario's graphics sheets from within the scenario editor
- You can copy/paste images into the sheet, or import/export to/from png files

Also:
- Picture controls in the dialog engine have a new "scaled" flag; if set, the picture will be scaled into the provided bounds rather than overflowing. Currently, only full sheets honour the setting.
2015-06-15 16:20:03 -04:00
Ben Scott
6b275c9ed9 Little fixes 2015-02-11 21:00:47 -05:00
4efcb08932 Implement a quest system and job board
- The job board is loosely based on Exile III's job board; the dialog is converted from the one contained as a relic of E3 in BoE
- Quest system is loosely based on a mix of Exile III jobs and Blades of Avernum quests
- Talking to a monster (even a hostile one) can now trigger an arbitrary special node

Dialog engine:
- LED's now support wrapped labels
2015-02-01 01:30:15 -05:00
dcd28b363b Finally implemented the stack control, and used it for town comments in the town details dialog 2014-12-22 13:22:06 -05:00
4f6ce11dd9 Convert create scenario dialogs, reimplement part of the scenario creation process, and allow text edit fields to contain default values in the XML definition.
- Note: This does not mean that scenario creation is now possible, since it relies on scenario saving which is still not implemented.
2014-12-04 22:34:37 -05:00
ecd0867b65 Convert scenario details dialog and make numeric fields validate their contents 2014-12-04 16:54:21 -05:00
d64770b1e0 Use folder references for strings and dialogs.
This means I won't have to remember to explicitly add each new file to the build.
It also means they'll be automatically kept sorted.
2014-12-01 22:51:18 -05:00