|
|
| (3 intermediate revisions by one other user not shown) |
| Line 1: |
Line 1: |
| − | <div class="toccolours mw-collapsible mw-collapsed tbl-ds">
| + | #REDIRECT [[Global Command: setWindowTitle]] |
| − | <span class="bold">Command History</span>
| |
| − | <div class="mw-collapsible-content">
| |
| − | <div class="alt-bg">Available since v3.8</div>
| |
| − | </div></div>
| |
| − | | |
| − | | |
| − | Allows you to set a custom title in the game application title bar! (window mode only)
| |
| − | | |
| − | | |
| − | Syntax:
| |
| − | <syntaxhighlight>
| |
| − | setWindowTitle("title") | |
| − | </syntaxhighlight>
| |
| − | | |
| − | | |
| − | Example 1: basic set window title command!
| |
| − | <syntaxhighlight>
| |
| − | setWindowTitle("my new game title")
| |
| − | </syntaxhighlight>
| |
| − | | |
| − | Example 2: set window title based on current users system language!
| |
| − | <syntaxhighlight>
| |
| − | -- let's get the current users os language & store it in a variable!
| |
| − | sysLang = getProperty("system_language")
| |
| − | | |
| − | -- let's set the window title based on users language!
| |
| − | if sysLang == "English" then
| |
| − | setWindowTitle("my new game in english")
| |
| − | elseif sysLang == "German" then
| |
| − | setWindowTitle("mein neues spiel auf deutsch")
| |
| − | end
| |
| − | </syntaxhighlight>
| |
| − | | |
| − | | |
| − | | |
| − | <span class="bold underline">Arguments</span>
| |
| − | | |
| − | <span class="bold">title</span>: "string" <br/>
| |
| − | This should include the text you want to be displayed in the application title bar! (window mode)
| |
| − | | |
| − | | |
| − | <span class="bold underline">Flags</span>
| |
| − | | |
| − | none
| |
| − | | |
| − | | |
| − | <span class="bold underline">Return</span>
| |
| − | | |
| − | none
| |
| − | {{i18n|SetWindowTitle}}
| |