#13626 closed Feature/Enhancement Request (fixed)

Language of Default NextCloud / Collabora Docs

Reported by: https://id.mayfirst.org/bmcneilly Owned by: https://id.mayfirst.org/jamie
Priority: Low Component: Tech
Keywords: Cc:
Sensitive: no


Hi All,

We have been using the default NextCloud instance to create & share documents within our library. However, we noticed that the default langauge for documents created in NextCloud appears to be German. This results in us having to change the language of the document for every item that was created in NextCloud.

From the NextCloud help, it appears that this value is likely being pulled in from the default templates. Is there any way to change this so that either English or Spanish is the default?

Change History (5)

comment:1 Changed 11 months ago by https://id.mayfirst.org/jaimev

  • Owner set to https://id.mayfirst.org/jamie
  • Status changed from new to assigned

Sorry for the delay. Copying jamie here.

comment:2 Changed 11 months ago by https://id.mayfirst.org/jamie

Just confirmed with these steps:

  1. Create new odt document via web
  2. Click Tools -> Language -> For Selection and it says "German"

comment:3 follow-up: Changed 11 months ago by https://id.mayfirst.org/jamie

Can you test it again? I think it should be fixed.

I fixed it by running a script to update the language settings in the provided templates. We'll have to re-run this script on each upgrade:


# Stop immediately if any step fails.
set -e

# First argument should be the template file to change.

if [ -z "$file" ]; then
  printf "Please pass path to file as first argument.\n"
  exit 1

if [ ! -f "$file" ]; then
  printf "Can't locate file (%s).\n" "$file"
  exit 2

# Make a backup
cp "$file" "${file}.bak"

mkdir -p "$staging"

# Unzip the lo template file into a temp directory.
unzip "$file" -d "$staging"

# Make the two substitutions that seem to be required.
sed -i 's#<style:text-properties style:font-name="Open Sans" fo:font-size="12pt" officeooo:rsid="0000614b" officeooo:paragraph-rsid="0000614b" style:font-size-asian="10.5pt" style:font-size-complex="12pt"/>#<style:text-properties style:font-name="Open Sans" fo:font-size="12pt" fo:language="en" fo:country="US" officeooo:rsid="0000614b" officeooo:paragraph-rsid="0000614b" style:font-size-asian="10.5pt" style:font-size-complex="12pt"/>#' "${staging}/content.xml"
sed -i 's#fo:language="de" fo:country="DE"#fo:language="en" fo:country="US"#g' "${staging}/styles.xml"

# Insert the changed files back into the template.
cd "$staging"
zip "$file" styles.xml
zip "$file" content.xml

# Remove the template directory.
rm -rf "$staging"

comment:4 Changed 11 months ago by https://id.mayfirst.org/jamie

  • Resolution set to fixed
  • Status changed from assigned to feedback

comment:5 in reply to: ↑ 3 Changed 11 months ago by https://id.mayfirst.org/bmcneilly

  • Status changed from feedback to closed

Looks good on my end, thanks so much!

Replying to https://id.mayfirst.org/jamie:

Can you test it again? I think it should be fixed.

Please login to add comments to this ticket.

Note: See TracTickets for help on using tickets.