XML:WMDD: Difference between revisions
Jump to navigation
Jump to search
m (copy-edit) |
m (→General information: wording) |
||
Line 4: | Line 4: | ||
[[Image:Changed_Load_Menu.png|thumb|right]] | [[Image:Changed_Load_Menu.png|thumb|right]] | ||
* The XML on this page is compatible with OniSplit '''v0.9.61.0'''. | * The XML on this page is compatible with OniSplit '''v0.9.61.0'''. | ||
* "WM" stands for "Window Manager". | * The "WM" in "WM Dialog Data" stands for "Window Manager", the name of the UI subsystem. | ||
* WMDD files are global (level0_Final.dat). | * WMDD files are global (level0_Final.dat). | ||
* A WMDD file contains either a screen with controls or a dialog with buttons (e.g. WMDDdialog_ChangeRestart). | * A WMDD file contains either a screen with controls (e.g. WMDDdialog_mainmenu) or a dialog with buttons (e.g. WMDDdialog_ChangeRestart). | ||
* Does WMDDdialog_text_console define the size of "text consoles" as 460x410? | * Open question: Does WMDDdialog_text_console define the size of "text consoles" as 460x410? | ||
* Oni's out-of-game windows overlay each other. The parent window becomes visible if you remove the background (see image on right). | * Oni's out-of-game windows overlay each other. The parent window becomes visible if you remove the background (see image on right). | ||
Latest revision as of 15:56, 9 October 2023
WMDD : WM Dialog Data | ||
---|---|---|
XML
WMCL << Other file types >> WMM |
General information
- The XML on this page is compatible with OniSplit v0.9.61.0.
- The "WM" in "WM Dialog Data" stands for "Window Manager", the name of the UI subsystem.
- WMDD files are global (level0_Final.dat).
- A WMDD file contains either a screen with controls (e.g. WMDDdialog_mainmenu) or a dialog with buttons (e.g. WMDDdialog_ChangeRestart).
- Open question: Does WMDDdialog_text_console define the size of "text consoles" as 460x410?
- Oni's out-of-game windows overlay each other. The parent window becomes visible if you remove the background (see image on right).
XML structure
<?xml version="1.0" encoding="utf-8"?> <Oni> <WMDD id="0"> <Caption>Options</Caption> <Id>152</Id> <State>Visible</State> <Style>Center</Style> <X>0</X> <Y>0</Y> <Width>640</Width> <Height>480</Height> <Controls> [...] </Controls> </Instance> </Oni>
[...] means at least one WMDDControl block.
Example
<WMDDControl> <Text>Options</Text> <Class>Label</Class> <Id>0</Id> <State>1</State> <Style>1114112</Style> <X>5</X> <Y>10</Y> <Width>70</Width> <Height>20</Height> <Font> <Family>TSFFTahoma</Family> <Style>Bold</Style> <Color>255 127 0</Color> <Size>10</Size> </Font> </WMDDControl>
- If you have a TXMB in your WMDD, don't put additional <WMDDControl> blocks under the block with the TXMB or your new blocks will be hidden.
- The block is always the same if <Text> contains "outline":
<Text>outline</Text> <Class>Title</Class> <Id>0</Id> <State>5</State> <Style>65536</Style>
Header
XML tag | Type | Flags and descriptions |
---|---|---|
<Caption> | char[256] | page name/title |
<Id> | int16 | page ID, looked up by the game application |
<State> | flag |
|
<Style> | flag/int32 |
|
<X> | int16 | align (always 0 in the header) |
<Y> | int16 | align (always 0 in the header) |
<Width> | int16 | X dimension (always 640 in the header?) |
<Height> | int16 | Y dimension (always 480 in the header?) |
<WMDDControl>
XML tag | Type | Flags and descriptions |
---|---|---|
<Text> | char[256] |
|
<Class> | flag |
|
<Id> | int16 | page ID, looked up by game application |
<State> | flag |
|
<Style> | flag |
Control specific stylesGroupbox/box:
Button:
Checkbox:
Radio button:
Edit field:
Listbox:
Picture:
Popup menu:
Text field:
|
<X> | int16 | align (relative to the top left corner of the window) |
<Y> | int16 | align (relative to the top left corner of the window) |
<Width> | int16 | X dimension |
<Height> | int16 | Y dimension |
<Family> | link32 | link to TSFF, usually "TSFFTahoma" |
<Style> | flag |
|
<Color> | color32 | RGB range, e.g. 255 127 0 (for orange) |
<Size> | int16 | font size is usually 10; 7 for "<Text>outline</Text>" |