[Launch]
ProgramExecutable=Gnumeric\bin\gnumeric.exe
WorkingDirectory=%PAL:AppDir%\Gnumeric\bin
DirectoryMoveOK=yes
SupportsUNC=yes

[Activate]
Registry=true

[Environment]
HOME=%PAL:DataDir%
LC_ALL=%PAL:LanguageCustom%

[RegistryKeys]
gnumeric_portable=HKCU\Software\gnumeric

[FilesMove]
gtkfilechooser.ini=%APPDATA%\gtk-2.0
recently-used.xbel=%LOCALAPPDATA%\

[DirectoriesCleanupIfEmpty]
1=%AppData%\gtk-2.0

[FileWrite1]
Type=Replace
File=%PAL:AppDir%\Gnumeric\lib\gdk-pixbuf-2.0\2.10.0\loaders.cache
Find=GNUMERICPATHREPLACE
Replace=%PAL:AppDir:ForwardSlash%/Gnumeric

[FileWrite2]
Type=Replace
File=%PAL:AppDir%\Gnumeric\lib\pango\1.8.0\modules.cache
Find=GNUMERICPATHREPLACE
Replace=%PAL:AppDir:DoubleBackslash%\\Gnumeric

[FileWrite3]
Type=Replace
File=%PAL:DataDir%\recently-used.xbel
Find=%PAL:LastDrive%%PAL:LastPackagePartialDir:ForwardSlash%/
Replace=%PAL:Drive%%PAL:PackagePartialDir:ForwardSlash%/

[FileWrite4]
Type=Replace
File=%PAL:DataDir%\recently-used.xbel
Find=%PAL:LastPortableAppsBaseDir:ForwardSlash%/
Replace=%PAL:PortableAppsBaseDir:ForwardSlash%/

[FileWrite5]
Type=Replace
File=%PAL:DataDir%\recently-used.xbel
Find=%PAL:LastDrive%/
Replace=%PAL:Drive%/

[FileWrite6]
Type=Replace
File=%PAL:DataDir%\settings\gnumeric_portable.reg
Find=\\\\
Replace=\\

[FileWrite7]
Type=Replace
File=%PAL:DataDir%\settings\gnumeric_portable.reg
Find=%PAL:LastDrive%%PAL:LastPackagePartialDir:DoubleBackslash%\\
Replace=%PAL:Drive%%PAL:PackagePartialDir:DoubleBackslash%\\

[FileWrite8]
Type=Replace
File=%PAL:DataDir%\settings\gnumeric_portable.reg
Find=%PAL:LastPortableAppsBaseDir:DoubleBackslash%\\
Replace=%PAL:PortableAppsBaseDir:DoubleBackslash%\\

[FileWrite9]
Type=Replace
File=%PAL:DataDir%\settings\gnumeric_portable.reg
Find=%PAL:LastDrive%\\
Replace=%PAL:Drive%\\

[FileWrite10]
Type=Replace
File=%PAL:DataDir%\settings\gnumeric_portable.reg
Find=\\
Replace=~~\~\~~

[FileWrite11]
Type=Replace
File=%PAL:DataDir%\settings\gnumeric_portable.reg
Find=~~\~\~~
Replace=\\\\

[Language]
Base=%PortableApps.comLocaleglibc%
CheckIfExists=%PAL:AppDir%\Gnumeric\share\locale\%PAL:LanguageCustom%\*.*
DefaultIfNotExists=

[LanguageFile]
Type=INI
File=%PAL:DataDir%\settings\GnumericPortableSettings.ini
Section=GnumericPortableSettings
Key=Language

[LanguageStrings]
en_US=en
