[Launch]
ProgramExecutable=libreoffice\program\soffice.exe
MinOS=2000
DirectoryMoveOK=yes
SupportsUNC=yes

[Activate]
Java=find
XML=true
Registry=true

[Language]
Base=%PortableApps.comLocaleglibc%
CheckIfExists=%PAL:AppDir%\libreoffice\readmes\readme_%PAL:LanguageCustom%.txt
DefaultIfNotExists=en-US

[LanguageFile]
Type=XML text
File=%PAL:DataDir%\settings\user\registrymodifications.xcu
XPath=//prop[normalize-space(@oor:name)="UILocale"]/value

[LanguageStrings]
en_GB=en-GB
en_US=en-US
pt_BR=pt-BR
zh_CN=zh-CN
zh_TW=zh-TW

[FileWrite1]
Type=ini
File=%PAL:AppDir%\libreoffice\program\bootstrap.ini
Section=ErrorReport
Key=ErrorReportServer
Value=

[FileWrite2]
Type=ini
File=%PAL:AppDir%\libreoffice\program\bootstrap.ini
Section=Bootstrap
Key=UserInstallation
Value=$ORIGIN/../../../Data/settings

[FileWrite3]
File=%PAL:DataDir%\settings\user\config\javasettings_Windows_x86.xml
Type=XML text
XPath=/java/javaInfo/location
Value=%JAVA_HOME%

[FileWrite4]
File=%PAL:DataDir%\settings\user\registrymodifications.xcu
Type=XML text
XPath=//item[normalize-space(@oor:path)="/org.openoffice.Office.Paths/Paths/org.openoffice.Office.Paths:NamedPath['Temp']"]/prop/value
Value=file:///%TEMP:ForwardSlash%/temp

[FileWrite5]
File=%PAL:DataDir%\settings\user\registrymodifications.xcu
Type=Replace
Find=DEFAULT--WORK--PATH
Replace=file:///%PortableApps.comDocuments:ForwardSlash%

[FileWrite6]
File=%PAL:DataDir%\settings\user\registrymodifications.xcu
Type=XML text
XPath=//prop[normalize-space(@oor:name)="UILocale"]/value
Value=%PAL:LanguageCustom%

[FileWrite7]
File=%PAL:DataDir%\settings\user\registrymodifications.xcu
Type=Replace
Find=file:///%PAL:LastDrive%%PAL:LastPackagePartialDir:ForwardSlash%
Replace=file:///%PAL:Drive%%PAL:PackagePartialDir:ForwardSlash%

[FileWrite8]
File=%PAL:DataDir%\settings\user\registrymodifications.xcu
Type=Replace
Find=file:///PAL:LastPortableAppsBaseDir:ForwardSlash%
Replace=file:///PAL:PortableAppsBaseDir:ForwardSlash%

[FileWrite9]
File=%PAL:DataDir%\settings\user\registrymodifications.xcu
Type=Replace
Find=file:///%PAL:LastDrive%/
Replace=file:///%PAL:Drive%/

[FileWrite10]
Type=ini
File=%PAL:AppDir%\libreoffice\program\setup.ini
Section=Bootstrap
Key=BASISINSTALLLOCATION
Value=%PAL:AppDir%\libreoffice\

[FileWrite11]
Type=ini
File=%PAL:AppDir%\libreoffice\program\setup.ini
Section=Bootstrap
Key=INSTALLLOCATION
Value=%PAL:AppDir%\libreoffice\

[FileWrite12]
Type=ini
File=%PAL:AppDir%\libreoffice\program\setup.ini
Section=Bootstrap
Key=OFFICEINSTALLLOCATION
Value=%PAL:AppDir%\libreoffice\

[FileWrite13]
Type=ini
File=%PAL:AppDir%\libreoffice\program\setup.ini
Section=Bootstrap
Key=UREINSTALLLOCATION
Value=%PAL:AppDir%\libreoffice\URE\\
