
(set #install-msg               "Installing Argue...")

;-------------------- Installation script begins here ----------------------
(set olduserlevel @user-level)
(user 3)
(transcript "Hi!")
(message "I'll now install Argue on your system...")

;-------------------------- Get options for user install -------------------

(if (= olduserlevel 0)
    (
        (set destdir "C:")
    )
    (
        (set destdir
            (askdir
            (help ":)")
            (prompt "Choose a drawer for Argue. It should be in the command\n"
                    "path anyway, best would be C:... :-)")
            (default "C:")
            )
        )
    )
)

(set @default-dest destdir)

(copyfiles
    (source "bin/Argue")
    (dest destdir)
)

(copyfiles
    (source "bin/Argue.info")
    (dest destdir)
)

(if (= olduserlevel 0)
    (
        (set #logochoice 1)
    )

    (
        (if (= (exists "c:Argue_Logo.iff" (noreq)) 1)
            (message "Warning: A logo has already been installed. MUI might already have 'locked' it for further use. The installer may not be able to replace it with another logo.\n\nAfter a reboot those 'locks' of cource won't be there any more.\n\nPlease note: This is MUI's case, not the one of Argue. I just want to tell you about.\n\nAs the 'logo part' is the last in this installation, you may quit this script with the button below now.")
        )

        (set #logochoice
            (askchoice
                (help ":)")
                (prompt "Argue 0.8 supports nice looking logos that are displayed at the top of the main window. Please pick one out.")
                (choices "Flyer - You like Techno?" "Nice - Pretty straight `Argue`" "Gradient - 8 color gradient ;-)" "Shell - somehow weird..." "Circles - You'll love it" "Pacman - Ehm... Experimental! :)")
            )
        )
    )
)

(select #logochoice
    (set #logoname "logos/Argue_Flyer.logo")
    (set #logoname "logos/Argue_Nice.logo")
    (set #logoname "logos/Argue_Gradient.logo")
    (set #logoname "logos/Argue_Shell.logo")
    (set #logoname "logos/Argue_Circles.logo")
    (set #logoname "logos/Argue_Pacman.logo")
)

(copyfiles
    (source #logoname)
    (dest "C:")
    (newname "Argue_Logo.iff")
)

(message "Thank you! Argue is now ready to use! For further details a look into Argue's documentation is recommended.\n\nYou should now try out the submitted interfaces in the Examples-Drawer.")

