Debian Codegraph @

Contrib/Modern UI/Readme.html

raw
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3 <html xmlns="http://www.w3.org/1999/xhtml">
4 <head>
5 <title>NSIS Modern User Interface - Documentation</title>
6 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
7 <meta name="viewport" content="width=device-width, initial-scale=1" />
8 <style type="text/css">
9 /*<![CDATA[*/
10 html, body { font-family: Verdana, Arial, Helvetica, sans-serif; color: #000000; }
11 html { font-size: 0.80em; }
12 body { font-size: 1em; font-size: 1rem; }
13 pre, code { font-family: Courier New, Courier, monospace,serif; font-size: 100%; }
14 body
15 {
16 padding:1.5em 0; margin:0;
17 background-color: #F0F0F0;
18 font-family: Verdana, Arial, Helvetica, sans-serif;
19 font-weight: normal;
20 text-align: justify;
21 }
22 p, li
23 {
24 font-size: 100%;
25 }
26 table
27 {
28 margin: auto;
29 background-color: #FFFFFF;
30 }
31 .maintable
32 {
33 border: 2px solid #376EAB;
34 width: 90%;
35 }
36 .parameter
37 {
38 font-weight: bold;
39 color: #6586AC;
40 }
41 h1
42 {
43 font-size: 140%;
44 color: #7A7272;
45 font-weight: normal;
46 }
47 h2
48 {
49 font-size: 130%;
50 font-weight: bold;
51 color: #303030;
52 }
53 h3
54 {
55 font-size: 120%;
56 font-weight: bold;
57 color: #2B5885;
58 }
59 div
60 {
61 margin: 1.1em;
62 }
63 div.settings
64 {
65 margin-right: 0;
66 }
67 a:link, a:visited, a:active
68 {
69 color: #294F75;
70 text-decoration: none;
71 }
72 a:hover
73 {
74 color: #182634;
75 text-decoration: underline;
76 }
77 .trigger
78 {
79 cursor: pointer;
80 cursor: hand;
81 height: 14px;
82 }
83 .toggle
84 {
85 display: block;
86 }
87 .options
88 {
89 text-align: center;
90 cursor: pointer;
91 cursor: hand;
92 color: #294F75;
93 }
94 /*]]>*/</style>
95
96 <script type="text/javascript">
97 //<![CDATA[
98
99 var image_open = new Image();
100 image_open.src = "images/open.gif";
101 var image_closed = new Image();
102 image_closed.src = "images/closed.gif";
103
104 function GEBY(d, i) { return d.getElementById ? d.getElementById(i) : document.all ? document.all[i] : 0 }
105
106 function toggle(image, section) {
107
108 if (section = GEBY(document, section))
109 {
110 image = GEBY(document, image);
111 if (section.style.display != "none")
112 {
113 section.style.display = "none";
114 image.src = image_closed.src;
115 }
116 else
117 {
118 section.style.display = "block";
119 image.src = image_open.src;
120 }
121 }
122 }
123
124 function expandall() {
125
126 var divNodeList = document.getElementsByTagName('div');
127 for (i = 0; i < divNodeList.length; i++) {
128 if(divNodeList[i].id) {
129 divNodeList[i].style.display = "block";
130 document.getElementById('trigger_' + divNodeList[i].id.substr(7)).src = "images/open.gif";
131 }
132 }
133
134 }
135
136 function collapseall() {
137
138 var divNodeList = document.getElementsByTagName('div');
139 for (i = 0; i < divNodeList.length; i++) {
140 if(divNodeList[i].id) {
141 divNodeList[i].style.display = "none";
142 document.getElementById('trigger_' + divNodeList[i].id.substr(7)).src = "images/closed.gif";
143 }
144 }
145
146 }
147
148 function onDocLoad() {
149
150 toggle('trigger_scr', 'toggle_scr');
151 toggle('trigger_lic', 'toggle_lic');
152 }
153
154 //]]>
155 </script>
156
157 </head>
158 <body onLoad="onDocLoad()">
159 <table width="750" class="maintable" cellspacing="0" cellpadding="0" align="center">
160 <tr>
161 <td>
162 <img src="images/header.gif" width="750" height="80" alt="" />
163 <p class="options">
164 <a onclick="expandall()">[Expand all]</a>&nbsp; &nbsp;<a onclick="collapseall()">[Collapse
165 all]</a></p>
166 <div>
167 <h1>
168 Introduction</h1>
169 <div>
170 <p>
171 The Modern UI provides a user interface for NSIS installers with a modern wizard
172 style, similar to the wizards of recent Windows versions. It is based on the basic
173 user interface that is provided by the NSIS compiler itself and extends it with
174 more interface features and pages.</p>
175 <p>
176 All standard NSIS pages (such as the pages to select components and the installation
177 folder) are supported as well as a number of additional pages. The welcome page
178 allows you to provide an introduction to the installation process, while the finish
179 page provides a way to let the user decide what steps should be performed after
180 the setup wizard is closed (for example, whether the application should be started
181 immediately). A finish page can also be used to ask for a system restart is necessary.</p>
182 <h3>
183 <img class="trigger" alt="Open/Close section" id="trigger_scr" src="images/open.gif"
184 onclick="toggle('trigger_scr', 'toggle_scr');" />
185 Screenshots</h3>
186 <div class="toggle" id="toggle_scr">
187 <p><img src="images/screen1.png" width="503" height="393" alt="" /></p>
188 <p><img src="images/screen2.png" width="503" height="393" alt="" /></p>
189 </div>
190 </div>
191 <h1>
192 Script header</h1>
193 <div>
194 <p>
195 The settings for the Modern UI should be inserted in the header of the script file.
196 It&#39;s important to follow the same order as the items below.&nbsp;For example,
197 interface settings should be defined before you insert pages, because the pages
198 depend on the interface configuration. It may be useful to look at the <a href="#examples">
199 example scripts</a> too see how this is done in actual script files.</p>
200 <p>
201 Parameters are given in this format: <span class="parameter">required (option1 | option2)
202 [optional]</span></p>
203 <h2>
204 1. Header file</h2>
205 <div>
206 <p>
207 First of all, add this line to the top of script to include the Modern UI:</p>
208 <pre>
209 !include &quot;MUI.nsh&quot;
210 </pre>
211 </div>
212 <h2>
213 2. Interface configuration</h2>
214 <div>
215 <p>
216 Then, you may want to use interface settings to change the look and feel of the
217 installer. These settings apply to all pages.<p>
218 The interface settings provided by the NSIS compiler itself (such as LicenseText,
219 Icon, CheckBitmap, InstallColors) should not be used in Modern UI scripts. The Modern
220 UI provides equalivent or extended versions of these settings.<p>
221 Examples:</p>
222 <pre>
223 !define MUI_COMPONENTSPAGE_SMALLDESC ;No value
224 !define MUI_UI &quot;myUI.exe&quot; ;Value
225 !define MUI_INSTFILESPAGE_COLORS &quot;FFFFFF 000000&quot; ;Two colors
226 </pre>
227 <h3>
228 <img class="trigger" alt="Open/Close section" id="trigger_in" src="images/open.gif"
229 onclick="toggle('trigger_in', 'toggle_in');" />
230 Interface settings</h3>
231 <div class="toggle" id="toggle_in">
232 <h3>
233 <img class="trigger" alt="Open/Close section" id="trigger_ingen" src="images/open.gif"
234 onclick="toggle('trigger_ingen', 'toggle_ingen');" />
235 Page header</h3>
236 <div class="toggle" id="toggle_ingen">
237 <p>
238 <strong>MUI_ICON</strong> <span class="parameter">icon_file</span><br />
239 The icon for the installer.<br />
240 <em>Default: ${NSISDIR}\Contrib\Graphics\Icons\modern-install.ico</em></p>
241 <p>
242 <strong>MUI_UNICON</strong> <span class="parameter">icon_file</span><br />
243 The icon for the uninstaller.<br />
244 <em>Default: ${NSISDIR}\Contrib\Graphics\Icons\modern-uninstall.ico</em></p>
245 <p>
246 <strong>MUI_HEADERIMAGE</strong><br />
247 Display an image on the header of the page.</p>
248 <div class="settings">
249 <p>
250 <strong>MUI_HEADERIMAGE_BITMAP</strong> <span class="parameter">bmp_file</span><br />
251 Bitmap image to display on the header of installers pages (recommended size: 150x57
252 pixels).<br />
253 <em>Default: ${NSISDIR}\Contrib\Graphics\Header\nsis.bmp</em></p>
254 <div class="settings">
255 <p>
256 <strong>MUI_HEADERIMAGE_BITMAP_NOSTRETCH</strong><br />
257 Do not stretch the installer header bitmap to fit the size of the field. Use this
258 option only if you have an image that does not use the whole space. If you have
259 a full size bitmap that fits exactly, you should not use this option because the
260 size of the field will be different if the user has a custom DPI setting.</p>
261 <p>
262 <strong>MUI_HEADERIMAGE_BITMAP_RTL</strong> <span class="parameter">bmp_file</span><br />
263 Bitmap image to display on the header of installers pages when using a RTL language
264 (recommended size: 150x57 pixels).<br />
265 <em>Default: Non-RTL bitmap</em></p>
266 <div class="settings">
267 <p>
268 <strong>MUI_HEADERIMAGE_BITMAP_RTL_NOSTRETCH</strong><br />
269 Do not stretch the installer header bitmap when using a RTL language to fit the
270 size of the field. Use this option only if you have an image that does not use the
271 whole space. If you have a full size bitmap that fits exactly, you should not use
272 this option because the size of the field will be different if the user has a custom
273 DPI setting.</p>
274 </div>
275 </div>
276 <p>
277 <strong>MUI_HEADERIMAGE_UNBITMAP</strong> <span class="parameter">bmp_file</span><br />
278 Bitmap image to display on the header of uninstaller pages (recommended size: 150x57
279 pixels).<br />
280 <em>Default: Installer header bitmap</em></p>
281 <div class="settings">
282 <p>
283 <strong>MUI_HEADERIMAGE_UNBITMAP_NOSTRETCH</strong><br />
284 Do not stretch the uninstaller header bitmap to fit the size of the field. Use this
285 option only if you have an image that does not use the whole space. If you have
286 a full size bitmap that fits exactly, you should not use this option because the
287 size of the field will be different if the user has a custom DPI setting.</p>
288 <p>
289 <strong>MUI_HEADERIMAGE_UNBITMAP_RTL</strong> <span class="parameter">bmp_file</span><br />
290 Bitmap image to display on the header of uninstallers pages when using a RTL language
291 (recommended size: 150x57 pixels).<br />
292 <em>Default: Installer RTL header bitmap</em></p>
293 <div class="settings">
294 <p>
295 <strong>MUI_HEADERIMAGE_UNBITMAP_RTL_NOSTRETCH</strong><br />
296 Do not stretch the uninstaller header bitmap when using a RTL language to fit the
297 size of the field. Use this option only if you have an image that does not use the
298 whole space. If you have a full size bitmap that fits exactly, you should not use
299 this option because the size of the field will be different if the user has a custom
300 DPI setting.</p>
301 </div>
302 </div>
303 <p>
304 <strong>MUI_HEADERIMAGE_RIGHT</strong><br />
305 Display the header image on the right side instead of the left side (when using
306 a RTL language it will be displayed on the left side instead of the right side).</p>
307 </div>
308 <p>
309 <strong>MUI_BGCOLOR</strong> <span class="parameter">(color: RRGGBBR hexadecimal)</span><br />
310 Background color for the header, the Welcome page and the Finish page.<br />
311 <em>Default: FFFFFF</em></p>
312 <p>
313 <strong>MUI_HEADER_TRANSPARENT_TEXT</strong><br />
314 Set a transparent background for the header's label controls. Useful for custom
315 user interfaces that set a bigger header image.</p>
316 <p>
317 <strong>MUI_TEXTCOLOR</strong> <span class="parameter">(color: RRGGBBR hexadecimal)</span><br />
318 Text color for the header, the Welcome page and the Finish page.<br />
319 <em>Default: 000000</em></p>
320 </div>
321 <h3>
322 <img class="trigger" alt="Open/Close section" id="trigger_inres" src="images/open.gif"
323 onclick="toggle('trigger_inres', 'toggle_inres');" />
324 Interface resources</h3>
325 <div class="toggle" id="toggle_inres">
326 <p>
327 <strong>MUI_UI</strong> <span class="parameter">ui_file</span><br />
328 The interface file with the dialog resources. Change this if you have made your
329 own customized UI.<br />
330 <em>Default: ${NSISDIR}\Contrib\UIs\modern.exe</em></p>
331 <p>
332 <strong>MUI_UI_HEADERIMAGE</strong> <span class="parameter">ui_file</span><br />
333 The interface files with the dialog resource IDD_INST that contains a bitmap control
334 and space for the header bitmap.<br />
335 <em>Default: ${NSISDIR}\Contrib\UIs\modern_headerbmp.exe</em></p>
336 <p>
337 <strong>MUI_UI_HEADERIMAGE_RIGHT</strong> <span class="parameter">ui_file</span><br />
338 The interface files with the dialog resource IDD_INST that contains a bitmap control
339 and space for the header bitmap on the right side.<br />
340 <em>Default: ${NSISDIR}\Contrib\UIs\modern_headerbmpr.exe</em></p>
341 <p>
342 <strong>MUI_UI_COMPONENTSPAGE_SMALLDESC</strong> <span class="parameter">ui_file</span><br />
343 The interface files with a customized dialog resource IDD_SELCOM with a small description
344 area.<br />
345 <em>Default: ${NSISDIR}\Contrib\UIs\modern_smalldesc.exe</em></p>
346 <p>
347 <strong>MUI_UI_COMPONENTSPAGE_NODESC</strong> <span class="parameter">ui_file</span><br />
348 The interface files with a customized dialog resource IDD_SELCOM without a description
349 area.<br />
350 <em>Default: ${NSISDIR}\Contrib\UIs\modern_nodesc.exe</em></p>
351 </div>
352 <h3>
353 <img class="trigger" alt="Open/Close section" id="trigger_inwf" src="images/open.gif"
354 onclick="toggle('trigger_inwf', 'toggle_inwf');" />
355 Installer welcome/finish page</h3>
356 <div class="toggle" id="toggle_inwf">
357 <p>
358 <strong>MUI_WELCOMEFINISHPAGE_BITMAP</strong> <span class="parameter">bmp_file</span><br />
359 Bitmap for the Welcome page and the Finish page (recommended size: 164x314 pixels).<br />
360 <em>Default: ${NSISDIR}\Contrib\Graphics\Wizard\win.bmp</em></p>
361 <div class="settings">
362 <p>
363 <strong>MUI_WELCOMEFINISHPAGE_BITMAP_NOSTRETCH</strong><br />
364 Do not stretch the bitmap for the Welcome and Finish page to fit the size of the
365 field. Use this option only if you have an image that does not use the whole space.
366 If you have a full size bitmap that fits exactly, you should not use this option
367 because the size of the field will be different if the user has a custom DPI setting.</p>
368 </div>
369 <p>
370 <strong>MUI_WELCOMEFINISHPAGE_INI</strong> <span class="parameter">ini_file</span><br />
371 InstallOptions INI file for the Welcome page and the Finish page.<br />
372 <em>Default: ${NSISDIR}\Contrib\Modern UI\ioSpecial.ini</em></p>
373 </div>
374 <h3>
375 <img class="trigger" alt="Open/Close section" id="trigger_inuwf" src="images/open.gif"
376 onclick="toggle('trigger_inuwf', 'toggle_inuwf');" />
377 Uninstaller welcome/finish page</h3>
378 <div class="toggle" id="toggle_inuwf">
379 <p>
380 <strong>MUI_UNWELCOMEFINISHPAGE_BITMAP</strong> <span class="parameter">bmp_file</span><br />
381 Bitmap for the Welcome page and the Finish page (recommended size: 164x314 pixels).<br />
382 <em>Default: ${NSISDIR}\Contrib\Graphics\Wizard\win.bmp</em></p>
383 <div class="settings">
384 <p>
385 <strong>MUI_UNWELCOMEFINISHPAGE_BITMAP_NOSTRETCH</strong><br />
386 Do not stretch the bitmap for the Welcome and Finish page to fit the size of the
387 field. Use this option only if you have an image that does not use the whole space.
388 If you have a full size bitmap that fits exactly, you should not use this option
389 because the size of the field will be different if the user has a custom DPI setting.</p>
390 </div>
391 <p>
392 <strong>MUI_UNWELCOMEFINISHPAGE_INI</strong> <span class="parameter">ini_file</span><br />
393 InstallOptions INI file for the uninstaller Welcome page and the Finish page.<br />
394 <em>Default: ${NSISDIR}\Contrib\Modern UI\ioSpecial.ini</em></p>
395 </div>
396 <h3>
397 <img class="trigger" alt="Open/Close section" id="trigger_inl" src="images/open.gif"
398 onclick="toggle('trigger_inl', 'toggle_inl');" />
399 License page</h3>
400 <div class="toggle" id="toggle_inl">
401 <p>
402 <strong>MUI_LICENSEPAGE_BGCOLOR</strong> <span class="parameter">(/windows | /grey |
403 (color: RRGGBB hexadecimal))</span><br />
404 The background color for the license textbox. Use /windows for the Windows text
405 background color (usually white). Use the /grey for the window background color
406 (usually grey).<br />
407 <em>Default: /windows</em></p>
408 </div>
409 <h3>
410 <img class="trigger" alt="Open/Close section" id="trigger_inc" src="images/open.gif"
411 onclick="toggle('trigger_inc', 'toggle_inc');" />
412 Components page</h3>
413 <div class="toggle" id="toggle_inc">
414 <p>
415 <strong>MUI_COMPONENTSPAGE_CHECKBITMAP</strong> <span class="parameter">bitmap_file</span><br />
416 The bitmap with images for the checks of the component select treeview.<br />
417 <em>Default: ${NSISDIR}\Contrib\Graphics\Checks\modern.bmp</em></p>
418 <p>
419 <strong>MUI_COMPONENTSPAGE_SMALLDESC</strong><br />
420 A small description area on the bottom of the page. Use this layout if you have
421 a lot of sections and don't need large descriptions.</p>
422 <p>
423 <strong>MUI_COMPONENTSPAGE_NODESC</strong><br />
424 No description area.</p>
425 </div>
426 <h3>
427 <img class="trigger" alt="Open/Close section" id="trigger_ind" src="images/open.gif"
428 onclick="toggle('trigger_ind', 'toggle_ind');" />
429 Directory page</h3>
430 <div class="toggle" id="toggle_ind">
431 <p>
432 <strong>MUI_DIRECTORYPAGE_BGCOLOR</strong> <span class="parameter">(color: RRGGBB hexadecimal)</span><br />
433 The background color for the directory textbox.</p>
434 </div>
435 <h3>
436 <img class="trigger" alt="Open/Close section" id="trigger_ins" src="images/open.gif"
437 onclick="toggle('trigger_ins', 'toggle_ins');" />
438 Start Menu folder page</h3>
439 <div class="toggle" id="toggle_ins">
440 <p>
441 <strong>MUI_STARTMENUPAGE_BGCOLOR</strong> <span class="parameter">(color: RRGGBB hexadecimal)</span><br />
442 The background color for the startmenu directory list and textbox.</p>
443 </div>
444 <h3>
445 <img class="trigger" alt="Open/Close section" id="trigger_ini" src="images/open.gif"
446 onclick="toggle('trigger_ini', 'toggle_ini');" />
447 Installation page</h3>
448 <div class="toggle" id="toggle_ini">
449 <p>
450 <strong>MUI_INSTFILESPAGE_COLORS</strong> <span class="parameter">(/windows | &quot;(foreground
451 color: RRGGBB hexadecimal) (background color: RRGGBB hexadecimal)&quot;)</span><br />
452 The colors of the details screen. Use /windows for the default Windows colors.<br />
453 <em>Default: /windows</em></p>
454 <p>
455 <strong>MUI_INSTFILESPAGE_PROGRESSBAR</strong> <span class="parameter">(&quot;&quot;
456 | colored | smooth)</span><br />
457 The style of the progress bar. Colored makes it use the MUI_INSTALLCOLORS.<br />
458 <em>Default: smooth</em></p>
459 </div>
460 <h3>
461 <img class="trigger" alt="Open/Close section" id="trigger_inf" src="images/open.gif"
462 onclick="toggle('trigger_inf', 'toggle_inf');" />
463 Installer finish page</h3>
464 <div class="toggle" id="toggle_inf">
465 <p>
466 <strong>MUI_FINISHPAGE_NOAUTOCLOSE</strong><br />
467 Do not automatically jump to the finish page, to allow the user to check the install
468 log.</p>
469 </div>
470 <h3>
471 <img class="trigger" alt="Open/Close section" id="trigger_uinf" src="images/open.gif"
472 onclick="toggle('trigger_uinf', 'toggle_uinf');" />
473 Uninstaller finish page</h3>
474 <div class="toggle" id="toggle_uinf">
475 <p>
476 <strong>MUI_UNFINISHPAGE_NOAUTOCLOSE</strong><br />
477 Do not automatically jump to the finish page, to allow the user to check the uninstall
478 log.</p>
479 </div>
480 <h3>
481 <img class="trigger" alt="Open/Close section" id="trigger_inaw" src="images/open.gif"
482 onclick="toggle('trigger_inaw', 'toggle_inaw');" />
483 Abort warning</h3>
484 <div class="toggle" id="toggle_inaw">
485 <p>
486 <strong>MUI_ABORTWARNING</strong><br />
487 Show a message box with a warning when the user wants to close the installer.</p>
488 <div class="settings">
489 <p>
490 <strong>MUI_ABORTWARNING_TEXT</strong> <span class="parameter">text</span><br />
491 Text to display on the abort warning message box.</p>
492 <p>
493 <strong>MUI_ABORTWARNING_CANCEL_DEFAULT</strong><br />
494 Set the Cancel button as the default button on the message box.</p>
495 </div>
496 </div>
497 <h3>
498 <img class="trigger" alt="Open/Close section" id="trigger_inuaw" src="images/open.gif"
499 onclick="toggle('trigger_inuaw', 'toggle_inuaw');" />
500 Uninstaller abort warning</h3>
501 <div class="toggle" id="toggle_inuaw">
502 <p>
503 <strong>MUI_UNABORTWARNING</strong><br />
504 Show a message box with a warning when the user wants to close the uninstaller.</p>
505 <div class="settings">
506 <p>
507 <strong>MUI_UNABORTWARNING_TEXT</strong> <span class="parameter">text</span><br />
508 Text to display on the abort warning message box.</p>
509 <p>
510 <strong>MUI_UNABORTWARNING_CANCEL_DEFAULT</strong><br />
511 Set the Cancel button as the default button on the message box.</p>
512 </div>
513 </div>
514 </div>
515 </div>
516 <h2>
517 3. Pages</h2>
518 <div>
519 <p>
520 Insert the following macros to set the pages you want to use. The pages will appear
521 in the order in which you insert them in the script. You can also insert custom
522 Page commands between the macros to add custom pages.</p>
523 <p>
524 You can add multiple pages of certain types (for example, if you want the user to
525 specify multiple folders).</p>
526 <p>
527 Examples:</p>
528 <pre>
529 !insertmacro MUI_PAGE_LICENSE &quot;License.rtf&quot;
530 !insertmacro MUI_PAGE_COMPONENTS
531
532 Var StartMenuFolder
533 !insertmacro MUI_PAGE_STARTMENU &quot;Application&quot; $StartMenuFolder
534 </pre>
535 <p>
536 You will need the page ID for the Start Menu folder page when using the Start Menu
537 folder macros. The folder will be stored in the specified variable.</p>
538 <p>
539 <strong>Installer pages</strong><br />
540 MUI_PAGE_WELCOME<br />
541 MUI_PAGE_LICENSE <span class="parameter">textfile</span><br />
542 MUI_PAGE_COMPONENTS<br />
543 MUI_PAGE_DIRECTORY<br />
544 MUI_PAGE_STARTMENU <span class="parameter">pageid variable</span><br />
545 MUI_PAGE_INSTFILES<br />
546 MUI_PAGE_FINISH</p>
547 <p>
548 <strong>Uninstaller pages</strong><br />
549 MUI_UNPAGE_WELCOME<br />
550 MUI_UNPAGE_CONFIRM<br />
551 MUI_UNPAGE_LICENSE <span class="parameter">textfile</span><br />
552 MUI_UNPAGE_COMPONENTS<br />
553 MUI_UNPAGE_DIRECTORY<br />
554 MUI_UNPAGE_INSTFILES<br />
555 MUI_UNPAGE_FINISH</p>
556 <h3>
557 <img class="trigger" alt="Open/Close section" id="trigger_pg" src="images/open.gif"
558 onclick="toggle('trigger_pg', 'toggle_pg');" />
559 Page settings</h3>
560 <div class="toggle" id="toggle_pg">
561 <p>
562 Page settings apply to a single page and should be set before inserting a page macro.
563 The same settings can be used for installer and uninstaller pages. You have to repeat
564 the setting if you want it to apply to multiple pages. Example:</p>
565 <pre>
566 ;Add a directory page to let the user specify a plug-ins folder
567 ;Store the folder in $PluginsFolder
568
569 Var PLUGINS_FOLDER
570 !define MUI_DIRECTORYPAGE_VARIABLE $PluginsFolder
571 !insertmacro MUI_PAGE_DIRECTORY
572 </pre>
573 <p>
574 <p>
575 All standard texts in the user interface are loaded from language files, which are
576 available for all languages supported by NSIS. So you only need to define these
577 texts if you want to change the default.</p>
578 <p>
579 If the parameter is a text that should be different for each language, define a
580 language string using LangString and use $(LangStringName) as value. For a license
581 text in multiple languages, LicenseLangString can be used. Refer the NSIS Users
582 Manual for more information about installers with multiple languages.</p>
583 <p>
584 In all text settings, the doublequote character (&quot;) should be escaped in the
585 following form: $\&quot;</p>
586 <h3>
587 <img class="trigger" alt="Open/Close section" id="trigger_pgg" src="images/open.gif"
588 onclick="toggle('trigger_pgg', 'toggle_pgg');" />
589 General page settings</h3>
590 <div class="toggle" id="toggle_pgg">
591 <p>
592 <strong>MUI_PAGE_HEADER_TEXT</strong> <span class="parameter">text</span><br />
593 Text to display on the header of the page.</p>
594 <p>
595 <strong>MUI_PAGE_HEADER_SUBTEXT</strong> <span class="parameter">text</span><br />
596 Subtext to display on the header of the page.</p>
597 </div>
598 <h3>
599 <img class="trigger" alt="Open/Close section" id="trigger_pgw" src="images/open.gif"
600 onclick="toggle('trigger_pgw', 'toggle_pgw');" />
601 Welcome page settings</h3>
602 <div class="toggle" id="toggle_pgw">
603 <p>
604 To add a newline to any of these texts, use \r\n instead of $\r$\n.</p>
605 <p>
606 <strong>MUI_WELCOMEPAGE_TITLE</strong> <span class="parameter">title</span><br />
607 Title to display on the top of the page.</p>
608 <p>
609 <strong>MUI_WELCOMEPAGE_TITLE_3LINES</strong><br />
610 Extra space for the title area.</p>
611 <p>
612 <strong>MUI_WELCOMEPAGE_TEXT</strong> <span class="parameter">text</span><br />
613 Text to display on the page.</p>
614 </div>
615 <h3>
616 <img class="trigger" alt="Open/Close section" id="trigger_pgl" src="images/open.gif"
617 onclick="toggle('trigger_pgl', 'toggle_pgl');" />
618 License page settings</h3>
619 <div class="toggle" id="toggle_pgl">
620 <p>
621 <strong>MUI_LICENSEPAGE_TEXT_TOP</strong> <span class="parameter">text</span><br />
622 Text to display on the top of the page.</p>
623 <p>
624 <strong>MUI_LICENSEPAGE_TEXT_BOTTOM</strong> <span class="parameter">text</span><br />
625 Text to display on the bottom of the page.</p>
626 <p>
627 <strong>MUI_LICENSEPAGE_BUTTON</strong> <span class="parameter">button_text</span><br />
628 Text to display on the 'I Agree' button.</p>
629 <p>
630 <strong>MUI_LICENSEPAGE_CHECKBOX</strong><br />
631 Display a checkbox the user has to check to agree with the license terms.</p>
632 <div class="settings">
633 <p>
634 <strong>MUI_LICENSEPAGE_CHECKBOX_TEXT</strong> <span class="parameter">text</span><br />
635 Text to display next to the checkbox to agree with the license terms.</p>
636 </div>
637 <p>
638 <strong>MUI_LICENSEPAGE_RADIOBUTTONS</strong><br />
639 Display two radio buttons to allow the user to choose between accepting the license
640 terms or not.</p>
641 <div class="settings">
642 <p>
643 <strong>MUI_LICENSEPAGE_RADIOBUTTONS_TEXT_ACCEPT</strong> <span class="parameter">text</span><br />
644 Text to display next to the checkbox to accept the license terms.</p>
645 <p>
646 <strong>MUI_LICENSEPAGE_RADIOBUTTONS_TEXT_DECLINE</strong> <span class="parameter">text</span><br />
647 Text to display next to the checkbox to decline the license terms.</p>
648 </div>
649 </div>
650 <h3>
651 <img class="trigger" alt="Open/Close section" id="trigger_pgc" src="images/open.gif"
652 onclick="toggle('trigger_pgc', 'toggle_pgc');" />
653 Components page settings</h3>
654 <div class="toggle" id="toggle_pgc">
655 <p>
656 <strong>MUI_COMPONENTSPAGE_TEXT_TOP</strong> <span class="parameter">text</span><br />
657 Text to display on the top of the page.</p>
658 <p>
659 <strong>MUI_COMPONENTSPAGE_TEXT_COMPLIST</strong> <span class="parameter">text</span><br />
660 Text to display on next to the components list.</p>
661 <p>
662 <strong>MUI_COMPONENTSPAGE_TEXT_INSTTYPE</strong> <span class="parameter">text</span><br />
663 Text to display on next to the installation type combo box.</p>
664 <p>
665 <strong>MUI_COMPONENTSPAGE_TEXT_DESCRIPTION_TITLE</strong> <span class="parameter">text</span><br />
666 Text to display on the of the top of the description box.</p>
667 <p>
668 <strong>MUI_COMPONENTSPAGE_TEXT_DESCRIPTION_INFO</strong> <span class="parameter">text</span><br />
669 Text to display inside the description box when no section is selected.</p>
670 </div>
671 <h3>
672 <img class="trigger" alt="Open/Close section" id="trigger_pgd" src="images/open.gif"
673 onclick="toggle('trigger_pgd', 'toggle_pgd');" />
674 Directory page settings</h3>
675 <div class="toggle" id="toggle_pgd">
676 <p>
677 <strong>MUI_DIRECTORYPAGE_TEXT_TOP</strong> <span class="parameter">text</span><br />
678 Text to display on top of the page.</p>
679 <p>
680 <strong>MUI_DIRECTORYPAGE_TEXT_DESTINATION</strong> <span class="parameter">text</span><br />
681 Text to display on the destination folder frame.</p>
682 <p>
683 <strong>MUI_DIRECTORYPAGE_VARIABLE</strong> <span class="parameter">variable</span><br />
684 Variable in which to store the selected folder.<br />
685 <em>Default: $INSTDIR</em></p>
686 <p>
687 <strong>MUI_DIRECTORYPAGE_VERIFYONLEAVE</strong><br />
688 Does not disable the Next button when a folder is invalid but allows you to use
689 GetInstDirError in the leave function to handle an invalid folder.</p>
690 </div>
691 <h3>
692 <img class="trigger" alt="Open/Close section" id="trigger_pgs" src="images/open.gif"
693 onclick="toggle('trigger_pgs', 'toggle_pgs');" />
694 Start Menu folder page settings</h3>
695 <div class="toggle" id="toggle_pgs">
696 <p>
697 <strong>MUI_STARTMENUPAGE_TEXT_TOP</strong> <span class="parameter">text</span><br />
698 Text to display on the top of the page.</p>
699 <p>
700 <strong>MUI_STARTMENUPAGE_TEXT_CHECKBOX</strong> <span class="parameter">text</span><br />
701 Text to display next to the checkbox to disable the Start Menu folder creation.</p>
702 <p>
703 <strong>MUI_STARTMENUPAGE_DEFAULTFOLDER</strong> <span class="parameter">folder</span><br />
704 The default Start Menu Folder.</p>
705 <p>
706 <strong>MUI_STARTMENUPAGE_NODISABLE</strong><br />
707 Do not display the checkbox to disable the creation of Start Menu shortcuts.</p>
708 <p>
709 <strong>MUI_STARTMENUPAGE_REGISTRY_ROOT</strong> <span class="parameter">root</span><br />
710 <strong>MUI_STARTMENUPAGE_REGISTRY_KEY</strong> <span class="parameter">key</span><br />
711 <strong>MUI_STARTMENUPAGE_REGISTRY_VALUENAME</strong> <span class="parameter">value_name</span><br />
712 The registry key to store the Start Menu folder. The page will use it to remember
713 the users preference. You should also use for the uninstaller to remove the Start
714 Menu folders. Don't forget to remove this key during uninstallation.</p>
715 <p>
716 For the uninstaller, use the MUI_STARTMENU_GETFOLDER macro to get the Start Menu
717 folder:</p>
718 <pre>
719 !insertmacro MUI_STARTMENU_GETFOLDER page_id $R0
720 Delete &quot;$SMPROGRAMS\$R0\Your Shortcut.lnk&quot;
721 </pre>
722 </div>
723 <h3>
724 <img class="trigger" alt="Open/Close section" id="trigger_pgi" src="images/open.gif"
725 onclick="toggle('trigger_pgi', 'toggle_pgi');" />
726 Installation page settings</h3>
727 <div class="toggle" id="toggle_pgi">
728 <p>
729 <strong>MUI_INSTFILESPAGE_FINISHHEADER_TEXT</strong> <span class="parameter">text</span><br />
730 Text to display on the header of the installation page when the installation has
731 been completed (won't be displayed when using a Finish page without MUI_(UN)FINISHPAGE_NOAUTOCLOSE).</p>
732 <p>
733 <strong>MUI_INSTFILESPAGE_FINISHHEADER_SUBTEXT</strong> <span class="parameter">text</span><br />
734 Subtext to display on the header of the installation page when the installation
735 has been completed (won't be displayed when using a Finish page without MUI_(UN)FINISHPAGE_NOAUTOCLOSE).</p>
736 <p>
737 <strong>MUI_INSTFILESPAGE_ABORTHEADER_TEXT</strong> <span class="parameter">text</span><br />
738 Text to display on the header of the installation page when the installation has
739 been aborted.</p>
740 <p>
741 <strong>MUI_INSTFILESPAGE_ABORTHEADER_SUBTEXT</strong> <span class="parameter">text</span><br />
742 Subext to display on the header of the installation page when the installation has
743 been aborted.</p>
744 </div>
745 <h3>
746 <img class="trigger" alt="Open/Close section" id="trigger_pgf" src="images/open.gif"
747 onclick="toggle('trigger_pgf', 'toggle_pgf');" />
748 Finish page settings</h3>
749 <div class="toggle" id="toggle_pgf">
750 <p>
751 To add a newline to any of these texts, use \r\n instead of $\r$\n.</p>
752 <p>
753 <strong>MUI_FINISHPAGE_TITLE</strong> <span class="parameter">title</span><br />
754 Title to display on the top of the page.</p>
755 <p>
756 <strong>MUI_FINISHPAGE_TITLE_3LINES</strong><br />
757 Extra space for the title area.</p>
758 <p>
759 <strong>MUI_FINISHPAGE_TEXT</strong> <span class="parameter">text</span><br />
760 Text to display on the page.</p>
761 <p>
762 <strong>MUI_FINISHPAGE_TEXT_LARGE</strong><br />
763 Extra space for the text area (if using checkboxes).</p>
764 <p>
765 <strong>MUI_FINISHPAGE_BUTTON</strong> <span class="parameter">text</span><br />
766 Text to display on the Finish button.</p>
767 <p>
768 <strong>MUI_FINISHPAGE_CANCEL_ENABLED</strong><br />
769 Enable the Cancel button so the user can skip any options displayed on the finish
770 page.</p>
771 <p>
772 <strong>MUI_FINISHPAGE_TEXT_REBOOT</strong> <span class="parameter">text</span><br />
773 Text to display on the finish page when asking for a system reboot.</p>
774 <p>
775 <strong>MUI_FINISHPAGE_TEXT_REBOOTNOW</strong> <span class="parameter">text</span><br />
776 Text to display next to the 'Reboot now' option button.</p>
777 <p>
778 <strong>MUI_FINISHPAGE_TEXT_REBOOTLATER</strong> <span class="parameter">text</span><br />
779 Text to display next to the 'Reboot later' option button.</p>
780 <p>
781 <strong>MUI_FINISHPAGE_REBOOTLATER_DEFAULT</strong><br />
782 Sets the 'Reboot later' option as the default option.</p>
783 <p>
784 <strong>MUI_FINISHPAGE_RUN</strong> <span class="parameter">exe_file</span><br />
785 Application which the user can select to run using a checkbox. You don't need to
786 put quotes around the filename when it contains spaces.</p>
787 <div class="settings">
788 <p>
789 <strong>MUI_FINISHPAGE_RUN_TEXT</strong> <span class="parameter">text</span><br />
790 Texts to display next to the 'Run program' checkbox.</p>
791 <p>
792 <strong>MUI_FINISHPAGE_RUN_PARAMETERS</strong> <span class="parameter">parameters</span><br />
793 Parameters for the application to run. Don't forget to escape double quotes in the
794 value (use $\&quot;).</p>
795 <p>
796 <strong>MUI_FINISHPAGE_RUN_NOTCHECKED</strong><br />
797 Do not check the 'Run program' checkbox by default</p>
798 <p>
799 <strong>MUI_FINISHPAGE_RUN_FUNCTION</strong> <span class="parameter">function</span><br />
800 Call a function instead of executing an application (define MUI_FINISHPAGE_RUN without
801 parameters). You can use the function to execute multiple applications or you can
802 change the checkbox name and use it for other things.</p>
803 </div>
804 <p>
805 <strong>MUI_FINISHPAGE_SHOWREADME</strong> <span class="parameter">file/url</span><br />
806 File or website which the user can select to view using a checkbox. You don't need
807 to put quotes around the filename when it contains spaces.</p>
808 <div class="settings">
809 <p>
810 <strong>MUI_FINISHPAGE_SHOWREADME_TEXT</strong> <span class="parameter">text</span><br />
811 Texts to display next to the 'Show Readme' checkbox.</p>
812 <p>
813 <strong>MUI_FINISHPAGE_SHOWREADME_NOTCHECKED</strong><br />
814 Do not check the 'Show Readme' checkbox by default</p>
815 <p>
816 <strong>MUI_FINISHPAGE_SHOWREADME_FUNCTION</strong> <span class="parameter">function</span><br />
817 Call a function instead of showing a file (define MUI_FINISHPAGE_SHOWREADME without
818 parameters). You can use the function to show multiple files or you can change the
819 checkbox name and use it for other things.</p>
820 </div>
821 <p>
822 <strong>MUI_FINISHPAGE_LINK</strong> <span class="parameter">link_text</span><br />
823 Text for a link on the which the user can click to view a website or file.</p>
824 <div class="settings">
825 <p>
826 <strong>MUI_FINISHPAGE_LINK_LOCATION</strong> <span class="parameter">file/url</span><br />
827 Website or file which the user can select to view using the link. You don't need
828 to put quotes around the filename when it contains spaces.</p>
829 <p>
830 <strong>MUI_FINISHPAGE_LINK_COLOR</strong> <span class="parameter">(color: RRGGBB hexadecimal)</span><br />
831 Text color for the link on the Finish page.<br />
832 <em>Default: 000080</em></p>
833 </div>
834 <p>
835 <strong>MUI_FINISHPAGE_NOREBOOTSUPPORT</strong><br />
836 Disables support for the page that allows the user to reboot the system. Define
837 this option to save some space if you are not using the /REBOOTOK flag or SetRebootFlag.</p>
838 </div>
839 <h3>
840 <img class="trigger" alt="Open/Close section" id="trigger_pgu" src="images/open.gif"
841 onclick="toggle('trigger_pgu', 'toggle_pgu');" />
842 Uninstall confirm page settings</h3>
843 <div class="toggle" id="toggle_pgu">
844 <p>
845 <strong>MUI_UNCONFIRMPAGE_TEXT_TOP</strong> <span class="parameter">text</span><br />
846 Text to display on the top of the page.</p>
847 <p>
848 <strong>MUI_UNCONFIRMPAGE_TEXT_LOCATION</strong> <span class="parameter">text</span><br />
849 Text to display next to the uninstall location text box.</p>
850 <p>
851 <strong>MUI_UNCONFIRMPAGE_VARIABLE</strong> <span class="parameter">variable</span><br />
852 Variable in which to store the uninstall source folder.<br />
853 <em>Default: $INSTDIR</em></p>
854 </div>
855 </div>
856 </div>
857 <h2>
858 4. Language files</h2>
859 <div>
860 <p>
861 Insert the Modern UI language files for the languages to want to include.</p>
862 <pre>
863 !insertmacro MUI_LANGUAGE &quot;English&quot;
864 </pre>
865 <p>
866 The standard NSIS language files are loaded automatically, there is no need to use
867 LoadLanguageFile.</p>
868 </div>
869 <h2>
870 5. Reserve files</h2>
871 <div>
872 <p>
873 If you are using solid compression, files that are required before the actual installation
874 should be stored first in the data block, because this will make your installer
875 start faster. Include reserve file commands for such files before your sections
876 and functions:</p>
877 <pre>
878 ReserveFile &quot;ioFile.ini&quot; ;Your own InstallOptions INI files
879 !insertmacro MUI_RESERVEFILE_INSTALLOPTIONS ;InstallOptions plug-in
880 !insertmacro MUI_RESERVEFILE_LANGDLL ;Language selection dialog
881 </pre>
882 </div>
883 </div>
884 <h1>
885 Script code for pages</h1>
886 <div>
887 <p>
888 Some pages allow you to show additional information or can be used to get user input.
889 Here you can find the script code to use these features.</p>
890 <h2>
891 Components page descriptions</h2>
892 <div>
893 <p>
894 The Modern UI components page has a text box in which a description can be shown
895 when the user hovers the mouse over a component. If you don't want to use these
896 descriptions, insert the MUI_COMPONENTSPAGE_NODESC interface setting.</p>
897 <p>
898 To set a description for a section, an additional parameter needs to be added to
899 Section command with a unique identifier for the section. This name can later be
900 used to set the description for this section.</p>
901 <pre>
902 Section &quot;Section Name 1&quot; Section1
903 ...
904 SectionEnd
905 </pre>
906 <p>
907 After the sections, use these macros to set the descriptions:</p>
908 <pre>
909 LangString DESC_Section1 ${LANG_ENGLISH} &quot;Description of section 1.&quot;
910 LangString DESC_Section2 ${LANG_ENGLISH} &quot;Description of section 2.&quot;
911
912 !insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
913 !insertmacro MUI_DESCRIPTION_TEXT ${Section1} $(DESC_Section1)
914 !insertmacro MUI_DESCRIPTION_TEXT ${Section2} $(DESC_Section2)
915 !insertmacro MUI_FUNCTION_DESCRIPTION_END
916 </pre>
917 <p>
918 For the uninstaller, use the MUI_UNFUNCTION_DESCRIPTION_BEGIN and MUI_UNFUNCTION_DESCRIPTION_END
919 macros.</p>
920 </div>
921 <h2>
922 Start Menu folder</h2>
923 <div>
924 <p>
925 Put the code to write the shortcuts (using CreateShortcut) between the MUI_STARTMENU_WRITE_BEGIN
926 and MUI_STARTMENU_WRITE_END macros:</p>
927 <pre>
928 !insertmacro MUI_STARTMENU_WRITE_BEGIN pageid
929 ...create shortcuts...
930 !insertmacro MUI_STARTMENU_WRITE_END
931 </pre>
932 <p>
933 The page ID should be the ID of the page on which the user has selected the folder
934 for the shortcuts you want to write.</p>
935 <p>
936 The variable which contains the folder and the page ID are set as parameters of
937 the page macro.</p>
938 </div>
939 </div>
940 <h1>
941 Language selection dialog</h1>
942 <div>
943 <p>
944 If you want the installer to display a language selection dialog (see the the <a
945 href="../../Examples/Modern%20UI/MultiLanguage.nsi">MultiLanguage.nsi</a> example),
946 insert the MUI_LANGDLL_DISPLAY macro in the .onInit function:</p>
947 <pre>
948 Function .onInit
949
950 !insertmacro MUI_LANGDLL_DISPLAY
951
952 FunctionEnd
953 </pre>
954 <p>
955 This macro can also be used in the un.onInit function.</p>
956 <h3>
957 <img class="trigger" alt="Open/Close section" id="trigger_lss" src="images/open.gif"
958 onclick="toggle('trigger_lss', 'toggle_lss');" />
959 Settings for registry storage of selected language</h3>
960 <div class="toggle" id="toggle_lss">
961 <p>
962 To remember the user's preference, you can define a registry key. These defines
963 should be set before inserting the installation page macro.</p>
964 <p>
965 <strong>MUI_LANGDLL_REGISTRY_ROOT</strong> <span class="parameter">root</span><br />
966 <strong>MUI_LANGDLL_REGISTRY_KEY</strong> <span class="parameter">key</span><br />
967 <strong>MUI_LANGDLL_REGISTRY_VALUENAME</strong> <span class="parameter">value_name</span><br />
968 The registry key to store the language. The users preference will be remembered.
969 You can also use it for the uninstaller to display the right language. Don't forget
970 to remove this key in the uninstaller.</p>
971 <p>
972 For the uninstaller, insert the MUI_UNGETLANGUAGE macro in un.onInit to get the
973 stored language preference:</p>
974 <pre>
975 Function un.onInit
976
977 !insertmacro MUI_UNGETLANGUAGE
978
979 FunctionEnd
980 </pre>
981 </div>
982 <h3>
983 <img class="trigger" alt="Open/Close section" id="trigger_lsin" src="images/open.gif"
984 onclick="toggle('trigger_lsin', 'toggle_lsin');" />
985 Interface settings for selection dialog</h3>
986 <div class="toggle" id="toggle_lsin">
987 <p>
988 To customize the language selection dialog interface, use these defines before inserting
989 the MUI_LANGDLL_DISPLAY macro.</p>
990 <p>
991 <strong>MUI_LANGDLL_WINDOWTITLE</strong> <span class="parameter">text</span><br />
992 The window title of the language selection dialog.</p>
993 <p>
994 <strong>MUI_LANGDLL_INFO</strong> <span class="parameter">text</span><br />
995 The text to display on the language selection dialog.</p>
996 <p>
997 <strong>MUI_LANGDLL_ALWAYSSHOW</strong><br />
998 Always show the language selection dialog, even if a language has been stored in
999 the registry. The language stored in the registry will be selected by default.</p>
1000 <p>
1001 <strong>MUI_LANGDLL_ALLLANGUAGES</strong><br />
1002 Always show all available languages and don't filter according to their codepage.</p>
1003 </div>
1004 </div>
1005 <h1>
1006 Custom pages</h1>
1007 <div>
1008 <p>
1009 If you want add your custom pages to your installer, you can insert your own page
1010 commands between the page macros. The <a href="../InstallOptions/Readme.html">InstallOptions
1011 documentation</a> provides information about creating custom pages using InstallOptions.</p>
1012 <pre>
1013 !insertmacro MUI_PAGE_WELCOME
1014 Page custom FunctionName ;Custom page
1015 !insertmacro MUI_PAGE_COMPONENTS
1016
1017 ;Uninstaller
1018 !insertmacro MUI_UNPAGE_CONFIRM
1019 UninstPage custom un.FunctionName ;Custom page
1020 !insertmacro MUI_UNPAGE_INSTFILES
1021 </pre>
1022 <p>
1023 Use the MUI_HEADER_TEXT macro to set the text on the page header in a page function:</p>
1024 <pre>
1025 LangString PAGE_TITLE ${LANG_ENGLISH} &quot;Title&quot;
1026 LangString PAGE_SUBTITLE ${LANG_ENGLISH} &quot;Subtitle&quot;
1027
1028 Function CustomPageFunction
1029 !insertmacro MUI_HEADER_TEXT $(PAGE_TITLE) $(PAGE_SUBTITLE)
1030 !insertmacro MUI_INSTALLOPTIONS_DISPLAY &quot;ioFile.ini&quot;
1031 FunctionEnd
1032 </pre>
1033 </div>
1034 <h1>
1035 Custom functions</h1>
1036 <div>
1037 <p>
1038 Interface functions provided by NSIS, like the .onGUIInit function and the page
1039 functions are automatically included by the Modern UI and filled with code to support
1040 new interface features. If you want to add additional code to these function, create
1041 a function with the custom script code in the script use the Modern UI functions
1042 call them.</p>
1043 <p>
1044 Example:</p>
1045 <pre class="text">
1046 !define MUI_CUSTOMFUNCTION_GUIINIT myGuiInit
1047
1048 Function myGUIInit
1049 ...your own code...
1050 FunctionEnd
1051 </pre>
1052 <h3>
1053 <img class="trigger" alt="Open/Close section" id="trigger_cfg" src="images/open.gif"
1054 onclick="toggle('trigger_cfg', 'toggle_cfg');" />
1055 General Custom Functions</h3>
1056 <div class="toggle" id="toggle_cfg">
1057 <p>
1058 These defines should be set before inserting the language macros.</p>
1059 <p>
1060 <strong>MUI_CUSTOMFUNCTION_GUIINIT</strong> <span class="parameter">function</span><br />
1061 <strong>MUI_CUSTOMFUNCTION_UNGUIINIT</strong> <span class="parameter">function</span><br />
1062 <strong>MUI_CUSTOMFUNCTION_ABORT</strong> <span class="parameter">function</span><br />
1063 <strong>MUI_CUSTOMFUNCTION_UNABORT</strong> <span class="parameter">function</span><br />
1064 <strong>MUI_CUSTOMFUNCTION_ONMOUSEOVERSECTION</strong> <span class="parameter">function</span><br />
1065 <strong>MUI_CUSTOMFUNCTION_UNONMOUSEOVERSECTION</strong> <span class="parameter">function</span></p>
1066 <p>
1067 Mouse over functions are only available when the description macros
1068 (MUI_FUNCTION_DESCRIPTION_BEGIN) are used. When component page descriptions are not
1069 used, regular .onMouseOverSection and un.onMouseOverSection must be used.</p>
1070 </div>
1071 <h3>
1072 <img class="trigger" alt="Open/Close section" id="trigger_cfpg" src="images/open.gif"
1073 onclick="toggle('trigger_cfpg', 'toggle_cfpg');" />
1074 Page Custom Functions</h3>
1075 <div class="toggle" id="toggle_cfpg">
1076 <p>
1077 These defines should be set before inserting a page macro.</p>
1078 <p>
1079 <strong>MUI_PAGE_CUSTOMFUNCTION_PRE</strong> <span class="parameter">function</span><br />
1080 <strong>MUI_PAGE_CUSTOMFUNCTION_SHOW</strong> <span class="parameter">function</span><br />
1081 <strong>MUI_PAGE_CUSTOMFUNCTION_LEAVE</strong> <span class="parameter">function</span></p>
1082 <p>
1083 <strong>Notes:</strong></p>
1084 <ul>
1085 <li>In the Pre function of the Welcome page and the Finish page, you can write to the
1086 InstallOptions INI file of the page (ioSpecial.ini)</li>
1087 <li>In the Show function of the Welcome, Finish and StartMenu pages, $MUI_HWND contains
1088 the HWND of the inner dialog</li>
1089 </ul>
1090 </div>
1091 <h3>
1092 <img class="trigger" alt="Open/Close section" id="trigger_cfwf" src="images/open.gif"
1093 onclick="toggle('trigger_cfwf', 'toggle_cfwf');" />
1094 Welcome/Finish Page Custom Functions</h3>
1095 <div class="toggle" id="toggle_cfwf">
1096 <p>
1097 This define should be inserted before a single Welcome or Finish page.</p>
1098 <p>
1099 <strong>MUI_WELCOMEFINISHPAGE_CUSTOMFUNCTION_INIT</strong> <span class="parameter">function</span></p>
1100 <p>
1101 This Init function is called before the InstallOptions INI file for the page is
1102 written, so you can use it to initialize any variables used in the page settings.</p>
1103 </div>
1104 </div>
1105 <h1>
1106 <a name="examples" id="examples">Example scripts</a></h1>
1107 <div>
1108 <p>
1109 Basic: <a href="../../Examples/Modern%20UI/Basic.nsi">Basic.nsi</a><br />
1110 Welcome/Finish page: <a href="../../Examples/Modern%20UI/WelcomeFinish.nsi">WelcomeFinish.nsi</a><br />
1111 Multiple languages: <a href="../../Examples/Modern%20UI/MultiLanguage.nsi">MultiLanguage.nsi</a><br />
1112 Header image: <a href="../../Examples/Modern%20UI/HeaderBitmap.nsi">HeaderBitmap.nsi</a><br />
1113 Custom pages: <strike><a href="../../Examples/Modern%20UI/InstallOptions.nsi">InstallOptions.nsi</a></strike><br />
1114 Start Menu Folder page: <a href="../../Examples/Modern%20UI/StartMenu.nsi">StartMenu.nsi</a></p>
1115 </div>
1116 <h1>
1117 Credits</h1>
1118 <div>
1119 <p>
1120 Written by Joost Verburg.<br />
1121 Icons designed by Nikos Adamamas, aka adni18.<br />
1122 Thanks to Amir Szekely, aka KiCHiK, for his work on NSIS to make this possible.</p>
1123 </div>
1124 <h1>
1125 License</h1>
1126 <div>
1127 <p>
1128 The zlib/libpng license applies to the Modern UI.</p>
1129 <h3>
1130 <img class="trigger" alt="Open/Close section" id="trigger_lic" src="images/open.gif"
1131 onclick="toggle('trigger_lic', 'toggle_lic');" />
1132 License Terms</h3>
1133 <div class="toggle" id="toggle_lic">
1134 <pre>
1135 Copyright &copy; 2002-2026 Joost Verburg
1136
1137 This software is provided 'as-is', without any express or implied
1138 warranty. In no event will the authors be held liable for any damages
1139 arising from the use of this software.
1140
1141 Permission is granted to anyone to use this software for any purpose,
1142 including commercial applications, and to alter it and redistribute
1143 it freely, subject to the following restrictions:
1144
1145 1. The origin of this software must not be misrepresented;
1146 you must not claim that you wrote the original software.
1147 If you use this software in a product, an acknowledgment in the
1148 product documentation would be appreciated but is not required.
1149 2. Altered versions must be plainly marked as such,
1150 and must not be misrepresented as being the original software.
1151 3. This notice may not be removed or altered from any distribution.
1152 </pre>
1153 </div>
1154 </div>
1155 </div>
1156 </td>
1157 </tr>
1158 </table>
1159 </body>
1160 </html>