Skip to content
⌘ NSIS Forum Archive

Two License Pages

44 posts

Brummelchen#
does not work so far 🙁

After MUI_PAGE_WELCOME

MUI_PAGE_LICENSE
image
Page license "" "showLicense" "leaveLicense"
image
MUI_PAGE_COMPONENTS
image
then back to Page license
image

and so on ...

i always get the correct readme when i step back.

script is attached so far (sorry for inconvenience)
o_owd#
i don't know why it does not display the borh license pages.

try with this script. (it works in my script)
Brummelchen#
Greta move - u da man 😁

it works. i have made a little change to get different pageheaders

> Page license "" "showLicense" "leaveLicense"
> Page license "" "showLicense1" "leaveLicense"

but one little teardrop

> !define MUI_LICENSEPAGE_CHECKBOX

no checkbox so far
kichik#
Brummelchen, you have to use the MUI macros all the way if you are using the MUI. Using Page as a replacment for the MUI_PAGE_LICENSE macro is what causing you all of the problems above.

o_owd, please attach the script, or describe the logic you've tried to include 3 license pages.
Brummelchen#
@kichik

> !define MUI_LICENSEPAGE_CHECKBOX

exist there a MUI macro for that?

> or describe the logic you've tried to include 3 license pages.

I made an example to this, i hope that helps - it is based on the script from o_owd

The MUI section must be like this

> Page license "" "showLicense" "leaveLicense"
> Page license "" "showLicense1" "leaveLicense"
> Page license "" "showLicense2" "leaveLicense"
...

the first function is reduced 'cause it only displays the normal license.txt
kichik#
No, "Using Page as a replacment for the MUI_PAGE_LICENSE macro is what causing you all of the problems above. "

MUI_LICENSEPAGE_CHECKBOX is a MUI define and is OK, but worth nothing if you don't use the MUI macro to insert the license page.
Brummelchen#edited
@kichik

So there is no alternative for that? Not a problem at all - the checkbox is only preventing from "klick - klick - klick - installed" must be "klick - read - check - klick - installed" 😉
But the other way dont work.

Is it possible to get the checkbox additional from InstallOption?
kichik#
The other way is the only right way and it can work, you only need to find the right logic to make it show the right license in the right page. The logic implemented in my examples works for two pages that come one after the other. If you have another case you'd have to find another logic and implement it.
Brummelchen#
>> you only need to find the right logic to make it show the right license in the right page. The logic implemented in my examples works for two pages that come one after the other.

Thats what i am doing to - Welcome/license/readme
but so far i have no check button only the "accept" button.

to prevent misunderstandings...
you have a solution for that (2pages with check button) or not?
kichik#
Again, you don't have a check button because you have told the MUI to add a check button but haven't used the MUI's way of including pages, you have used the Page command.

The code I have attached above implements a logic to show two license pages that come one after another. All you need to do is translate it to MUI macros (change Page commands to the appropriate !insertmacro, define the right values, etc.)
o_owd#
for kichik,

i am trying to make a codec pack. there are a lots of them, so everybody knows what i'm talking about.
i try to include 3 license pages because there are 3 diffrent licenses:
the DivX codec has it's own license, then XviD and AC3 Filter are open source, so GNU license file, and Windows Media Player - Microsoft. so EULA is the 3rd.

for showing 2 of them i was using the code you showed me. but i need 3 of them. thanks to Brummelchen i have now 3 of them, but as you said - Page is just a replacement for MUI_PAGE_LICENSE.

so kichik, the logic was yours. you gave me the idea with "Page". why do i need 3 ? i just explained.
as for Brummelchen, is not my code, so the credit is not mine. it's kichik.

i'll attach the script. i think the script it's really nice, and maybe it will inspire others:

multiple license pages, custom page that appear only if one section was selected, as for uninstaller, it remembers what sections were installed. so it won't delete everything.

in a few words: everything that you helped me in the past few weeks.

really, a big thank you, man. to all of you.
kichik#
Attached are two scripts that will hopefully clear this up. One with the MUI and one without. The one with the MUI uses the same show and leave function for all three pages and therefor requires a certain logic to know which page should be shown where the script without the MUI uses the Page command and therefor has a different show and leave function for every license page. The second script, using Page, doesn't require any logic because you know in which page you are by the function called.

Once again, do NOT use the Page command for non custom (Page custom - InstallOptions and such) in a MUI script! It's not only the checkbox missing, there's a lot more. Just don't.

The logic in the MUI script is required because you can't define a separate function for every license page but only one for all three. Therefor you must know in which page you're manually and not by the function called because there is just one function.

Last time, do NOT use Page license instead of !insertmacro MUI_PAGE_LICENSE in a MUI script.