Date: prev next · Thread: first prev next last
2019 Archives by date, by thread · List index


On 11/04/2019 21:17, Jelle de Jong wrote:
I am trying to convert changes to /home/$USER/.config/libreoffice/4/user/registrymodifications.xcu into systemwide configuration for users that start libreoffice for the first time under linux with systemwide settings.

I tried placing a xml file in /usr/lib/libreoffice/share/registry/registrymodifications-system-wide.xcu but I can not seem to get the syntax right.

Directly in share/registry/ the file would need to have .xcd extension and adhere to officecfg/registry/data.dtd. That means that those <item oor:path="..."> elements would not be supported, just the more tedious hierarchical <node oor:name="..."> ones (see officecfg/registry/component-update.dtd for details; seems I never came around to lifting the requirement that an .xcu nested inside an .xcd can only have an oor:component-data top-level element, not an oor:items one).

However, the share/registry/ config layer also supports .xcu files in a data/ sub-dir, so similar to the hack of adding a share/registry/registrymodifications-system-wide.xcd you could use the hack of adding a share/registry/data/registrymodifications-system-wide.xcu into which you could easily copy-paste items from a registrymodifications.xcu:

<?xml version="1.0"?>
<oor:items xmlns:xs="http://www.w3.org/2001/XMLSchema"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
 xmlns:oor="http://openoffice.org/2001/registry";>
  <item oor:path="/org.openoffice.Office.Common/Save/Document"><prop oor:name="WarnAlienFormat" 
oor:op="fuse"><value>false</value></prop></item>
  <item oor:path="/org.openoffice.Setup/Office/Factories/org.openoffice.Setup:Factory['com.sun.star.text.TextDocument']"><prop 
oor:name="ooSetupFactoryDefaultFilter" oor:op="fuse"><value>MS Word 2007 XML</value></prop></item>
  <item oor:path="/org.openoffice.Setup/Office/Factories/org.openoffice.Setup:Factory['com.sun.star.presentation.PresentationDocument']"><prop 
oor:name="ooSetupFactoryDefaultFilter" oor:op="fuse"><value>Impress MS PowerPoint 2007 XML</value></prop></item>
  <item oor:path="/org.openoffice.Setup/Office/Factories/org.openoffice.Setup:Factory['com.sun.star.sheet.SpreadsheetDocument']"><prop 
oor:name="ooSetupFactoryDefaultFilter" oor:op="fuse"><value>Calc MS Excel 2007 XML</value></prop></item>
</oor:items>

(The non-hacky way, of course, is to create an .oxt LO extension that you install system-wide.)

Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.