Configuration File | Qt Installer Framework Manual

Qt Installer Framework Manual | Configuration File

Reference ◦ Package Directory

# Configuration File

The configuration file customizes the UI and behavior of an installer. The file is typically called `config.xml` and located in the `config` directory.

A minimal configuration file consists of an `<Installer>` root element with `<Name>` and `<Version>` elements as children. All other elements are optional, and can appear in arbitrary order.

The following example shows a typical configuration file:

      <?xml version="1.0"?>
      <Installer>
          <Name>Some Application</Name>
          <Version>1.0.0</Version>
          <Title>Some Application Setup</Title>
          <Publisher>Your Company</Publisher>
          <ProductUrl>http://www.your-fantastic-company.com</ProductUrl>
          <InstallerWindowIcon>installericon</InstallerWindowIcon>
          <InstallerApplicationIcon>installericon</InstallerApplicationIcon>
          <Logo>logo.png</Logo>
          <Watermark>watermark.png</Watermark>
          <RunProgram>@TargetDir@/YourAppToRun</RunProgram>
          <RunProgramArguments>
              <Argument>Argument 1</Argument>
              <Argument>Argument 2</Argument>
          </RunProgramArguments>
          <RunProgramDescription>My nice application</RunProgramDescription>
          <StartMenuDir>Some Application Entry Dir</StartMenuDir>
          <MaintenanceToolName>SDKMaintenanceTool</MaintenanceToolName>
          <AllowNonAsciiCharacters>true</AllowNonAsciiCharacters>
          <Background>background.png</Background>

          <TargetDir>@HomeDir@/testinstall</TargetDir>
          <AdminTargetDir>@RootDir@/testinstall</AdminTargetDir>
          <RemoteRepositories>
              <Repository>
                  <Url>http://www.your-repo-location/packages/</Url>
              </Repository>
          </RemoteRepositories>
      </Installer>

## Summary of Configuration File Elements

The following table summarizes the elements in the configuration file.

Note: We recommend that you place all files that you refer to in the configuration file in the `config` directory. However, you can also use relative paths, which the tools resolve relative to the location of the config.xml file.

You can use predefined variables (embedded in @ characters) as values of the elements. For more information, see Predefined Variables.

Element | Description
--- | ---
Name | Name of the product being installed. This is mandatory.
Version | Version of the product being installed in the following format: [0-9]+((\.|-)[0-9]+)* such as 1-1; 1.2-2; 3.4.7. This is mandatory.
Title | Name of the installer as displayed on the title bar.
Publisher | Publisher of the software (as shown in the Windows Control Panel).
ProductUrl | URL to a page that contains product information on your web site.
Icon | Filename for a custom installer icon. The actual file is looked up by attaching a '.icns' (OS X), '.ico' (Windows) or '.png' (Unix) suffix. Deprecated, use `<InstallerApplicationIcon>` or `<InstallerWindowIcon>` instead.
InstallerApplicationIcon | Filename for a custom installer icon. The actual file is looked up by attaching a '.icns' (OS X), '.ico' (Windows). No functionality on Unix.
InstallerWindowIcon | Filename for a custom window icon in PNG format for the Installer application.
Logo | Filename for a logo used as `QWizard::LogoPixmap`.
Watermark | Filename for a watermark used as `QWizard::WatermarkPixmap`.
Banner | Filename for a banner used as `QWizard::BannerPixmap` (only used by ModernStyle).
Background | Filename for an image used as `QWizard::BackgroundPixmap` (only used by MacStyle).
WizardStyle | Set the wizard style to be used ("Modern", "Mac", "Aero" or "Classic").
StyleSheet | Set the stylesheet file.
WizardDefaultWidth | Sets the default width of the wizard in pixels. Setting a banner image will override this. You can add the `em` or `ex` suffix to the specified value to use the em or ex unit, as in a CSS file.
WizardDefaultHeight | Sets the default height of the wizard in pixels. Setting a watermark image will override this. You can add the `em` or `ex` suffix to the specified value to use the em or ex unit, as in a CSS file.
TitleColor | Set the color of the titles and subtitles (takes an HTML color code, such as "#88FF33").
RunProgram | Command executed after the installer is done if the user accepts the action. Provide the full path to the application.
RunProgramArguments | Arguments passed to the program specified in `<RunProgram>`. You can add several `<Argument>` child elements that each specify an argument to `<RunProgram>`.
RunProgramDescription | Text shown next to the check box for running the program after the installation. If `<RunProgram>` is set but no description provided, the UI will display Run <Name> now. instead.
StartMenuDir | Name of the default program group for the product in the Windows Start menu.
TargetDir | Default target directory for installation. On Linux, this is usually the user's home directory.
AdminTargetDir | Default target directory for installation with administrator rights. Only available on Linux, where you usually do not want to install in the administrator user's home directory.
RemoteRepositories | List of remote repositories. This element can contain several `<Repository>` child elements that each contain the `<Url>` child element that specifies the URL to access the repository. For more information, see Configuring Repositories.
MaintenanceToolName | Filename of the generated maintenance tool. Defaults to maintenancetool. The platform-specific executable file extension is appended.
MaintenanceToolIniFile | Filename for the configuration of the generated maintenance tool. Defaults to MaintenanceToolName.ini.
RemoveTargetDir | Set to `false` if the target directory should not be deleted when uninstalling.
AllowNonAsciiCharacters | Set to `true` if the installation path can contain non-ASCII characters.
DisableAuthorizationFallback | Set to `true` if the installation should not ask users to run the authorization fallback in case of authorization errors. Instead abort the installation immediately.
RepositorySettingsPageVisible | Set to `false` to hide the repository settings page inside the settings dialog.
AllowSpaceInPath | Set to `false` if the installation path cannot contain space characters.
DependsOnLocalInstallerBinary | Set to `true` if you want to prohibit installation from an external resource, such as a network drive. This might make sense for e.g. very big installers. The option is only used on Windows.
TargetConfigurationFile | Filename for the configuration file on the target. Default is components.xml.
Translations | List of language codes to be used for translating the user interface. To add several language variants, specify several `<Translation>` child elements that each specify the name of a language variant. Optional. For more information, see Translating Pages.
UrlQueryString | This string needs to be in the form "key=value" and will be appended to archive download requests. This can be used to transmit information to the webserver hosting the repository.
ControlScript | Filename for a custom installer control script. See Controller Scripting.
CreateLocalRepository | Set to `true` if you want to create a local repository inside the installation directory. This option has no effect on online installers. The repository will be automatically added to the list of default repositories.
InstallActionColumnVisible | Set to `true` if you want to add an extra column into component tree showing install actions. This extra column indicates whether a component is going to be installed or uninstalled, or just stay installed or uninstalled.
SupportsModify | Set to `false` if the product does not support modifying an existing installation.

Reference ◦ Package Directory