Sharing AutoCorrect entries in a Git-hosted project

chrispitude
Posts: 201
Joined: Thu May 02, 2019 2:32 pm

Sharing AutoCorrect entries in a Git-hosted project

Post by chrispitude » Tue May 19, 2020 5:12 pm

Hi all,

I'd like to provide some company-specific AutoCorrect entries to our writing team. We store our project on a Git server.

From the documentation at

https://www.oxygenxml.com/doc/versions/ ... rrect.html

I see that I can provide an incremental AutoCorrect dictionary .dat file to augment the built-in dictionary. And from the web page at

https://ask.libreoffice.org/en/question ... rect-list/

I see that the .dat file is really a .zip file that has a hierarchy of files within it. But my questions are:

1. What is the minimum set of files required by Oxygen XML Author for an incremental AutoCorrect dictionary?
2. Are there any special naming requirements (language codes, etc.) for the incremental AutoCorrect .dat files?

Thanks!

sorin_carbunaru
Posts: 316
Joined: Mon May 09, 2016 9:37 am

Re: Sharing AutoCorrect entries in a Git-hosted project

Post by sorin_carbunaru » Wed May 20, 2020 3:51 pm

Hello Chris,

From what I tried a few moments ago, having a *.dat archive containing only a DocumentList.xml file, with the proper structure, is enough.

In regard to the name of the *.dat file, you should first read https://www.oxygenxml.com/doc/versions/ ... additional. You could name it, for example, en_synopsys.dat or en_US_synopsys.dat.

All the best wishes,
Sorin Carbunaru
oXygen XML

chrispitude
Posts: 201
Joined: Thu May 02, 2019 2:32 pm

Re: Sharing AutoCorrect entries in a Git-hosted project

Post by chrispitude » Thu May 21, 2020 6:53 pm

sorin_carbunaru wrote:
Wed May 20, 2020 3:51 pm
Hello Chris,

From what I tried a few moments ago, having a *.dat archive containing only a DocumentList.xml file, with the proper structure, is enough.

In regard to the name of the *.dat file, you should first read https://www.oxygenxml.com/doc/versions/ ... additional. You could name it, for example, en_synopsys.dat or en_US_synopsys.dat.

All the best wishes,
Sorin Carbunaru
oXygen XML
Excellent, thank you Sorin!! I appreciate you running the experiments to confirm.

I had read that documentation page but it was not clear to me that a user-defined suffix could be included after the language code. It would be a nice documentation enhancement to mention this.

sorin_carbunaru
Posts: 316
Joined: Mon May 09, 2016 9:37 am

Re: Sharing AutoCorrect entries in a Git-hosted project

Post by sorin_carbunaru » Fri May 22, 2020 9:02 am

Added a documentation task ;).

Have a nice day and a relaxing weekend!

chrispitude
Posts: 201
Joined: Thu May 02, 2019 2:32 pm

Re: Sharing AutoCorrect entries in a Git-hosted project

Post by chrispitude » Sun May 24, 2020 10:50 pm

Thanks Sorin! Based on your findings, I was able to create a simple file named "DocumentList.xml" in the current directory:

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<bl:block-list xmlns:bl="http://openoffice.org/2001/block-list">
  <bl:block bl:abbreviated-name="foo" bl:name="bar2"/>
</bl:block-list>
then zip this directly into a file with no directory structure:

Code: Select all

zip en_US.dat DocumentList.xml  ;# linux command line
and it was detected. I also found that:
  • The original file must be named DocumentList.xml. It cannot have another name.
  • The namespace must be present on every element and attribute. A default namespace defined on the root caused the file not to be detected.

sorin_carbunaru
Posts: 316
Joined: Mon May 09, 2016 9:37 am

Re: Sharing AutoCorrect entries in a Git-hosted project

Post by sorin_carbunaru » Mon May 25, 2020 8:18 am

Great! Thanks for sharing this on the forum!

Post Reply