[Launch]
ProgramExecutable=FocusWriter\FocusWriter.exe
ProgramExecutable64=FocusWriter64\FocusWriter.exe
WorkingDirectory=%PAL:FullAppDir%
DirectoryMoveOK=yes
SupportsUNC=yes

[DirectoriesMove]
FocusWriterData=%PAL:FullAppDir%\data

[Activate]
Registry=true

[QtKeysCleanup]
1="Qt Factory Cache 4.8\com.trolltech.Qt.QImageIOHandlerFactoryInterface:"
2="Qt Plugin Cache 4.8.false"
3="FileDialog"

[RegistryKeys]
customColors=HKCU\Software\Trolltech\OrganizationDefaults\Qt\customColors
FocusWriter=HKCU\Software\GottCode\FocusWriter

[RegistryCleanupIfEmpty]
1=HKCU\Software\GottCode
2=HKCU\Software\QtProject\OrganizationDefaults\Qt
3=HKCU\Software\QtProject\OrganizationDefaults
4=HKCU\Software\QtProject

[FileWrite1]
Type=Replace
File=%PAL:DataDir%\FocusWriterData\Settings\GottCode\FocusWriter.ini
Find=%PAL:LastDrive%%PAL:LastPackagePartialDir:ForwardSlash%/
Replace=%PAL:Drive%%PAL:PackagePartialDir:ForwardSlash%/

[FileWrite2]
Type=Replace
File=%PAL:DataDir%\FocusWriterData\Settings\GottCode\FocusWriter.ini
Find=%PAL:LastPortableAppsBaseDir:ForwardSlash%/
Replace=%PAL:PortableAppsBaseDir:ForwardSlash%/

[FileWrite3]
Type=Replace
File=%PAL:DataDir%\FocusWriterData\Settings\GottCode\FocusWriter.ini
Find=%PAL:LastDrive%/
Replace=%PAL:Drive%/

[FileWrite4]
Type=Replace
File=%PAL:DataDir%\FocusWriterData\Settings\GottCode\FocusWriter.ini
Find=DEFAULTPORTABLEAPPS.COMDOCUMENTSPATH
Replace=%PortableApps.comDocuments:ForwardSlash%/

[FileWrite5]
Type=INI
File=%PAL:DataDir%\FocusWriterData\Settings\GottCode\FocusWriter.ini
Section=Locale
Key=Language
Value=%PAL:LanguageCustom%

[Language]
Base=%PortableApps.comLocaleglibc%
CheckIfExists=%PAL:FullAppDir%\translations\focuswriter_%PAL:Languagecustom%.qm
DefaultIfNotExists=en

[LanguageFile]
Type=INI
File=%PAL:DataDir%\FocusWriterData\Settings\GottCode\FocusWriter.ini
Section=Locale
Key=Language