[Solved] Default language not permanent

Discuss the word processor
brucewol
Posts: 23
Joined: Fri Mar 11, 2016 9:19 pm

[Solved] Default language not permanent

Post by brucewol »

For some reason, my default language always reverts back to german tools/options/language settings/languages/. and then the spell checker doesn't work. the only way that i've found to fix this is to go to tools/languages/for all texts and set to english usa. now everything works for the document and the language is permanent after exiting writer but only for that document. if i create a new document, the default language is german and changing this option to english is not permanent. the only thing that works is for all texts.

this is on a new installation where only 4.1.6 has been installed. i have removed the profile and the problem persists. i've read numerous posts and none of them have solved my problem. My problem seems easy to reproduce. do a 4.1.6 install on a clean machine, open writer, change default language from german to english usa, save and and exit. then reopen writer - is the default language german. if it works for you, then what parameters on a system override user input.
Last edited by brucewol on Thu Mar 28, 2019 5:05 pm, edited 3 times in total.
Open Office 4.1.6 Windows 10 Home
Bill
Volunteer
Posts: 8934
Joined: Sat Nov 24, 2007 6:48 am

Re: Default language not permanent

Post by Bill »

Does this happen when using File > New in OpenOffice or only when creating documents in File Explorer by right-clicking and selecting New? If the latter, then you should change the language in the template used by File Explorer. See the instructions for Windows 7 (not XP) posted here:

Re: Spell Checker Not Working in 4.1.1
AOO 4.1.14 on Ubuntu MATE 22.04
brucewol
Posts: 23
Joined: Fri Mar 11, 2016 9:19 pm

Re: Default language not permanent

Post by brucewol »

thanks. the files are created by a right click in file explorer. but if there is an option that i set in the writer program, this should be a global option for all of writer. makes no sense at all that there are options for the program as well as setting a value in a template and that the writer program does not have the final say. will look into this and post my results in a day or two.
Open Office 4.1.6 Windows 10 Home
brucewol
Posts: 23
Joined: Fri Mar 11, 2016 9:19 pm

Re: Default language not permanent

Post by brucewol »

per the w7 link suggested, i did not find an soffice.odt searching all of appdata for my user. and this is a new computer that open office was just installed on. so if something is causing the default language to be different from what i modify in the program, it comes from open office, not some customization i have done.
Open Office 4.1.6 Windows 10 Home
John_Ha
Volunteer
Posts: 9584
Joined: Fri Sep 18, 2009 5:51 pm
Location: UK

Re: Default language not permanent

Post by John_Ha »

See Choosing language settingsin Chapter 2 - Setting up Writer of the Writer Guide.
LO 6.4.4.2, Windows 10 Home 64 bit

See the Writer Guide, the Writer FAQ, the Writer Tutorials and Writer for students.

Remember: Always save your Writer files as .odt files. - see here for the many reasons why.
User avatar
Villeroy
Volunteer
Posts: 31279
Joined: Mon Oct 08, 2007 1:35 am
Location: Germany

Re: Default language not permanent

Post by Villeroy »

How to enforce the use of a language:

Open a new document.
Apply the right "Western Language" in Tools>Options>LangSetting>Languages and check "Current document only". Side note: The "Locale" setting (2nd from top) has nothing to do with human language.
Now the spell checker and the auto-correct feature should work properly with text that is written in your chosen language.
OK, clear contents from that document.
Call menu:File>Templates>Save... and save it under some name like "Default_en_US" or something.
Call menu:File>Templates>Organize..., select your newly saved template and call "Default template" from the command button.

From now on, when you call menu:File>New>Text_Document, you get a new text document derived from the template that has been prepared with explicit language settings.
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
Bill
Volunteer
Posts: 8934
Joined: Sat Nov 24, 2007 6:48 am

Re: Default language not permanent

Post by Bill »

brucewol wrote:per the w7 link suggested, i did not find an soffice.odt searching all of appdata for my user. and this is a new computer that open office was just installed on. so if something is causing the default language to be different from what i modify in the program, it comes from open office, not some customization i have done.
The soffice.odt file that is causing the problem is in programdata, not appdata for the user. You have to add the soffice.odt file in appdata for the user. After you add the soffice.odt file in appdata, that file will be used instead of the soffice.odt file in programdata.
AOO 4.1.14 on Ubuntu MATE 22.04
brucewol
Posts: 23
Joined: Fri Mar 11, 2016 9:19 pm

Re: Default language not permanent

Post by brucewol »

I looked at See Choosing language settings in Chapter 2 - Setting up Writer of the Writer Guide. and there is nothing about creating and saving a template. There are a lot of user posts about spell checker not working and that is what caused me to initiate this post. In fact so many posts I suspect most users looking for a reason why spell checker doesn't work, give up in frustration and find some kind of workaround. For me, that was to use for "all text" every time i create a new file. all my file creations were created with explorer, i just find it easier to navigate with explorer to where i want the file and use the right click. I posted about this issue several years ago and was finally told that it was bug and don't hope to ever see a fix.

so if this is the way it works, it needs to be documented. most users want a spell checker so it should be fairly easy for a new user to find how to do this. And I think a lot of users use the right click explorer option. Someone in Open Office thought this was a useful option since the explorer options were added at installation.

So what documentation does a user need to reference if they use the explorer right click option to create a file and want spell checker to work.
Open Office 4.1.6 Windows 10 Home
John_Ha
Volunteer
Posts: 9584
Joined: Fri Sep 18, 2009 5:51 pm
Location: UK

Re: Default language not permanent

Post by John_Ha »

brucewol wrote:I looked at See Choosing language settings in Chapter 2 - Setting up Writer of the Writer Guide. and there is nothing about creating and saving a template.
See Chapter 10 - Working with Templates or read the Tutorial on creating a new default template.
brucewol wrote:In fact so many posts I suspect most users looking for a reason why spell checker doesn't work, give up in frustration and find some kind of workaround
I don't think so. We have noticed that most people seem to spot the first post in the forum which is [Solved] Spell Check Not Working (words red underlined). It's right above your thread as I write.

You will find much useful information in the Writer FAQ, the Writer Tutorials, the up to date Writer guide and the Writer Manual. May I suggest you bookmark the pages.

Press F1 to access the Help screen and search for your problem

The chapter headings in the manual are:

1 - Introducing Writer
2 - Setting up Writer
3 - Working with Text
4 - Formatting Pages
5 - Printing, Exporting, Faxing and E-Mailing
6 - Introduction to Styles
7 - Working with Styles
8 - Working with Graphics
9 - Working with Tables
10 - Working with Templates
11 - Using Mail Merge
12 - Tables of Contents, Indexes and Bibliographies
13 - Working with Master Documents
14 - Working with Fields
15 - Using Forms in Writer
16 - Customizing Writer – Keyboard shortcuts.

When a pop-up window opens, click the Help button for extensive help on that function - it is often more comprehensive than the manual.
LO 6.4.4.2, Windows 10 Home 64 bit

See the Writer Guide, the Writer FAQ, the Writer Tutorials and Writer for students.

Remember: Always save your Writer files as .odt files. - see here for the many reasons why.
Bill
Volunteer
Posts: 8934
Joined: Sat Nov 24, 2007 6:48 am

Re: Default language not permanent

Post by Bill »

brucewol wrote:I posted about this issue several years ago and was finally told that it was bug and don't hope to ever see a fix...

...So what documentation does a user need to reference if they use the explorer right click option to create a file and want spell checker to work.
There are two solutions. You can either change the language setting in the soffice.odt file that Windows uses or you can set the language in a document and set that document as the default template. In your posts of Feb 2017, you were directed to Corner Case 2 of the tutorial [Tutorial] Spell check and Language configuration which tells you where to find the soffice.odt file. The tutorial has a link to the bug report Issue 40233 - Making a new document from a context menu doesn't use a template which was fixed in 2010 and was still working last year before I stopped using Windows.

I see several remarks on the bug report about the bug not being fixed, but I surmise that those complaints are due to a misunderstanding about what the bug fix is supposed to do. The bug is not about changing the language setting in the soffice.odt file. It is only about applying a default template to documents created from the right-click menu in Windows Explorer. For the fix to be effective, the user must set the correct language in a document, save the document as a template, then set the template as the default template. If there is no set default template, then the language setting in the soffice.odt file is used.

Those are the only two ways to automatically change the language setting for new documents created from the File Explorer context menu. Changing the language setting using Tools > Options > Language Settings > Languages with the "For the current document only" option unchecked only applies to new documents created using File > New in OpenOffice. Changing that setting does not change the soffice.odt file setting or the setting in the default template, or the setting in any other existing document or template unless the document or template is the currently open document or template and the "For the current document only" option is checked.
AOO 4.1.14 on Ubuntu MATE 22.04
User avatar
Villeroy
Volunteer
Posts: 31279
Joined: Mon Oct 08, 2007 1:35 am
Location: Germany

Re: Default language not permanent

Post by Villeroy »

The Windows NT file system NTFS supports symlinks. It should be possible to link the default template with the shell-new template.
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
brucewol
Posts: 23
Joined: Fri Mar 11, 2016 9:19 pm

Re: Default language not permanent

Post by brucewol »

okay, i've tried the suggestion to create and empty text file with the options i want - language default western english (usa) and writing aids - check spelling as you type. then i save this as a template. seems name isn't important, i used en-usa. then use file/template/organize/commands to make this the default template. From what I've seen, this appears to work.


but, but, but

for a new user to open office that just wants to create a document with spell checker working, what documentation is provided for spell checker to work correctly when you use file explorer right click. you can create an open office document using the file option within the program or file explorer right click. open office added the options to file explorer right click so it should be just as straight forward to get spell checker working. but it isn't and and documentation on how to do this is lacking.
Open Office 4.1.6 Windows 10 Home
User avatar
Hagar Delest
Moderator
Posts: 32662
Joined: Sun Oct 07, 2007 9:07 pm
Location: France

Re: [Solved] Default language not permanent

Post by Hagar Delest »

Indeed. Quite a poor situation.
See the discussion in the Issue 120610 bug report.
No easy solution.
LibreOffice 7.6.2.1 on Xubuntu 23.10 and 7.6.4.1 portable on Windows 10
Bill
Volunteer
Posts: 8934
Joined: Sat Nov 24, 2007 6:48 am

Re: [Solved] Default language not permanent

Post by Bill »

brucewol wrote:thanks. the files are created by a right click in file explorer. but if there is an option that i set in the writer program, this should be a global option for all of writer. makes no sense at all that there are options for the program as well as setting a value in a template and that the writer program does not have the final say.
I disagree. Template settings should have the final say, not the program option. One purpose of a template is to create documents which have settings that are different from the program options. That allows a user who creates many different types of documents to use different templates with different settings when creating new documents. If the program settings overrode the template settings, then the user would have to change the settings in every new document.
AOO 4.1.14 on Ubuntu MATE 22.04
User avatar
Villeroy
Volunteer
Posts: 31279
Joined: Mon Oct 08, 2007 1:35 am
Location: Germany

Re: [Solved] Default language not permanent

Post by Villeroy »

https://www.howtogeek.com/howto/16226/c ... -or-linux/
https://answers.microsoft.com/en-us/win ... 5838d1b35c

We can create a default template MyDefault.ott and a hard link soffice.odt in that ShellNew folder.
A hard link works within the same file system and the file system has to be NTFS. All hard linked files point to the same data in the file system, therefore fou can delete either one without losing any other one.

Code: Select all

mklink /H  "C:\Program Files (x86)\OpenOffice\share\template\shellnew\soffice.odt" %APPDATA%\OpenOffice\4\user\template\MyDefault.ott
The above command is a blind shot. I don't have any Windows system with Open/LibreOffice at hand.
-----------------------
If your ShellNew folder and the %APPDATA% folder reside on different file systems, remove the /H switch in order to create a soft link. A soft link is more like a "traditional" Windows link. There is one original source file (MyDefault.ott in the above example) and the target file(s) contain only the link data pointing to the original source file. When you delete the source of a soft link, the target file(s) will point to nowhere. The other way round you can delete the target without affecting the source.
Last edited by Villeroy on Fri Mar 29, 2019 9:47 pm, edited 1 time in total.
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
brucewol
Posts: 23
Joined: Fri Mar 11, 2016 9:19 pm

Re: [NO NOT Solved] Default language not permanent

Post by brucewol »

I edited my initial post to show not solved. I have been a user of Open Office after Microsoft discontinued support of Office/XP and mostly a very happy user. The products meets my needs well.

But the continual problems getting spell checker have been annoying. A couple of years ago, I put in a post about the problem but never got a satisfactory answer. I found a work around, once I create a document, I select all text and set it to English USA. Recently a friend of mine, also a long time user of AOO, was unable to get spell checker to work. Eventually he gave up and switched to Google Docs.

So I decided to look into this again. With this post I found that using File Explorer right click uses a different code path than Writer, file/new. Might not be the best design but I don't understand the internals well enough to see the value in this design. I have looked at numerous posts on spell checker problems. The fact that there continues to be numerous posts is indicative that the problem has not been resolved. In a post it stated that spell checker problems generated the most posts to the forums. A sticky on spell checker

[Troubleshooting] Spell check in OpenOffice does not mention that there is a difference in using File Explorer right click. So if File Explorer, right click is your normal way of creating a Writer document, this post is of no help.

I agree that templates should override the program defaults as mentioned in a post on this topic. I hadn't thought through this well enough. But what I disagree with is suggesting that a new user to AOO can possibly understand that using templates will solve their spell checker issues. There is no correlation between spell checking and templates. and since the problem seems to only occurs with using File Explorer right click how is a new user how is a new user ever to discover how to solve the problem. That is why I changed the topic to No Not Solved.

Spell checking is a basic feature of any word processor and it should just work. It justs works for this forum. It justs works for Google Docs. It should just work for Writer.

However, after looking in to this further, I found something very interesting. It seems the problem is caused by a template in program data/ microsoft soffice.dta. I thought it odd that AOO would be in a position that Microsoft could so adversely impact Writer. But when I did a few uninstalls / installs, I found that soffice.odt is installed by aoo 4.1.6. And the language setting is set to german. So it appears this issue can be fixed by AOO. I'm not sure if the templates are even necessary . But if the are, maybe it would be better to install them in users / Open Office where they would be less hidden. And certainly when i download the english version, a template with language set to german should not be used.

As Hagar pointed out in Issue 120610 bug report. this issue has been going on since 2012-08-18. has it all been caused by the german language in the soffice.odt?

Hopefully this info will be useful. I don't have access to the code so I can only do so much by reverse engineering the process. But it certainly looks to me like AOO can fix this issue. And jopefully you guys will.
Open Office 4.1.6 Windows 10 Home
User avatar
Hagar Delest
Moderator
Posts: 32662
Joined: Sun Oct 07, 2007 9:07 pm
Location: France

Re: [NO NOT Solved] Default language not permanent

Post by Hagar Delest »

The right click feature is an Operating System feature. It's just something to "help" users or spare them the time it takes to look for the right application in the OS menus and launch it.

Spell check configuration can be complex because it allows a very fine tuning of it inside documents and have paragraphs and words set to different languages, which is not possible when you write a post in this forum. You can't ask for a professional tool that comes with a simplistic configuration.

There is often a glitch with AOO with the initial installation but once the dics are correctly installed, then it's OK. But as long as users don't understand how it works, they won't benefit the power of the tool.
LibreOffice 7.6.2.1 on Xubuntu 23.10 and 7.6.4.1 portable on Windows 10
John_Ha
Volunteer
Posts: 9584
Joined: Fri Sep 18, 2009 5:51 pm
Location: UK

Re: [NO NOT Solved] Default language not permanent

Post by John_Ha »

I doubt anyone has the time or the inclination to read a wall of text. Can we please reset.

Please describe, simply and clearly, exactly what you want to do.

For example please say something like:

1. I want to use Writer with an English interface (ie English menus). I use an English keyboard.

2. I want Writer to default to using German text when it starts with a new document so that I spell check in German with a German dictionary.

3. I want to type in English and spell check in English with an English dictionary. I want to do this by adding English text to my German document created from my default German template.

4. I want to type in English and spell check in English with an English dictionary. I want to do this by having a default English template as well, so my entire document is in English.

Someone can then give precise instructions for each numbered requirement.
LO 6.4.4.2, Windows 10 Home 64 bit

See the Writer Guide, the Writer FAQ, the Writer Tutorials and Writer for students.

Remember: Always save your Writer files as .odt files. - see here for the many reasons why.
Bill
Volunteer
Posts: 8934
Joined: Sat Nov 24, 2007 6:48 am

Re: [NO NOT Solved] Default language not permanent

Post by Bill »

brucewol wrote:I don't have access to the code so I can only do so much by reverse engineering the process.
Everyone has access to the code. Look for the "Source" link on the right side of the AOO Downloads page.
AOO 4.1.14 on Ubuntu MATE 22.04
brucewol
Posts: 23
Joined: Fri Mar 11, 2016 9:19 pm

Re: [NO NOT Solved] Default language not permanent

Post by brucewol »

Okay, I will mark this post as solved and open other posts specifically for what i see the remaining issues to be. While I could read the code, i don't think it would be wise for me to request a code change without much better knowledge of the overall code. i can focus on the external behavior of the code and let those with the appropriate expertise can make decisions if a change should be made.

Yes, writer is a sophisticated program. But new users are not experts with it's use, they initially are beginners. And if they are unable to get spell checker to easily work, i think many would look elsewhere for another solution. Many have responded to my posts with technical answers but the issue is really more about usability. I don't think that point has been appropriately considered.
Open Office 4.1.6 Windows 10 Home
User avatar
Hagar Delest
Moderator
Posts: 32662
Joined: Sun Oct 07, 2007 9:07 pm
Location: France

Re: [NO NOT Solved] Default language not permanent

Post by Hagar Delest »

brucewol wrote:the issue is really more about usability. I don't think that point has been appropriately considered.
I see what you mean.
I've to admit that if we had not that glitch for the dictionary installation, that would avoid most of the users frustration.
The right click feature is not that frequent in the forum.

But you should discuss that on the dev mailing list if you want to ask for changes.
LibreOffice 7.6.2.1 on Xubuntu 23.10 and 7.6.4.1 portable on Windows 10
User avatar
Villeroy
Volunteer
Posts: 31279
Joined: Mon Oct 08, 2007 1:35 am
Location: Germany

Re: [Solved] Default language not permanent

Post by Villeroy »

Today I got the chance to test my idea of linking the ShellNew file with a default template on MS Windows 10, LibreOffice6.1 and an existing default template "Standard.ots" for Calc. It worked as expected.
First I looked up the location where the ShellNew "templates" reside. They reside in the share/template/shellnew folder of the installation folder. There are normal files in that directory rather than templates. Otherwise you would create a new template from the ShellNew command. That was C:\Program Files\LibreOffice\share\template\shellnew\soffice.ods. I renamed this file to soffice.old.ods; otherwise the link command would fail because the file exists already.
The office suite was set up with a default template for Calc C:\Users\Reszeption\AppData\Roaming\LibreOffice\4\user\template\Standard.ots (this is a true ots template), so I could use that one for testing.

I ran the following command in an administrative command shell:

Code: Select all

mklink C:\Program Files\LibreOffice\share\template\shellnew\soffice.ods C:\Users\Reszeption\AppData\Roaming\LibreOffice\4\user\template\Standard.ots
glitch: link target first before the source.

I create a new ods document with right-click>New>OpenDocument Spreadsheet and it has a German language setting.
Then I edit my default template Standard.ots and switch its language to English(Australia) via Tools>Options>LangSettings>Languages>WesternLanguage with "current document only". After saving and closing the modified template I create another right-click>New>OpenDocument Spreadsheet and it has an English(Australian) language setting.
And back to German, another ShellNew document follows again.
--------------------
I think you could also use a ShellNew link other than soffice.ods and change the registry entry accordingly but I did not want to touch the holy reg.
I did not test switch /H for a hard link. SInce both paths are on the same file system, this should have worked also.
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
John_Ha
Volunteer
Posts: 9584
Joined: Fri Sep 18, 2009 5:51 pm
Location: UK

Re: [Solved] Default language not permanent

Post by John_Ha »

 Edit: I have struck out this entire post as I think much of it is incorrect. See my next post.

One thing which is definitely wrong is my statement "I then checked my Default template C:\ProgramData\Microsoft\Windows\Templates\soffice.odt".

That file is definitely not the AOO Default Template.

I think the confusing behaviour reported below may be because I created a new user profile which did not have a user set Default Profile
There is something quite strange happening.

I first gave AOO a new profile.

I then checked my Default template C:\ProgramData\Microsoft\Windows\Templates\soffice.odt which is dated 18 Oct 2018. I have never knowingly edited it and all four templates had the same date so I am pretty certain it is as installed.

1. I closed AOO and then opened C:\ProgramData\Microsoft\Windows\Templates\soffice.odt. I clicked Edit File to make it editable. Type a few characters. Highlight them > Format > Character ..., shows they have no language!

Clipboard01.gif
2. When I go Tools > Options > Language Settings > Languages ..., the Default language is set to German!
Clipboard02.gif
3. I shut AOO. I started AOO and File > New > Text document. Type a few characters > highlight them > Format > Character ..., shows they are French!

4. Tools > Options > Language Settings > Languages .... I changed the language to Italian. File > New > Text document. The language was Italian as expected. Save the document. Close AOO.

5 Start AOO. File > New > Text document. The language was Italian as expected. Examination of registrymodifications.xcu shows that the only reference to Italian was "it-IT" in the DefaultLocale as below:

Code: Select all

<item oor:path="/org.openoffice.Office.Linguistic/General">
	<prop oor:name="DefaultLocale" oor:op="fuse">
		<value>it-IT</value>
	</prop>
</item>
However when repeating Step 5, sometimes the language did not stick.

I then changed the language to Zulu. The only occurrence of Zu in registrymodifications.xcu (apart from the multiple entries for every language) was similar to above, namely DefaultLocale

Code: Select all

<item oor:path="/org.openoffice.Office.Linguistic/General">
	<prop oor:name="DefaultLocale" oor:op="fuse">
		<value>zu-ZA</value>
	</prop>
</item>
6. I noticed earlier today that my Impress was set to French.

My conclusions are that something is going wrong but it seems to be a bit random and sometimes happens and sometimes does not. The language seems to be getting mixed up with the locale setting.

I am on W7 so it is not a W10 funny.
Last edited by John_Ha on Sun Mar 31, 2019 4:54 pm, edited 2 times in total.
LO 6.4.4.2, Windows 10 Home 64 bit

See the Writer Guide, the Writer FAQ, the Writer Tutorials and Writer for students.

Remember: Always save your Writer files as .odt files. - see here for the many reasons why.
User avatar
Villeroy
Volunteer
Posts: 31279
Joined: Mon Oct 08, 2007 1:35 am
Location: Germany

Re: [Solved] Default language not permanent

Post by Villeroy »

Weird. How does it fall back to German when the installed office package and the operating system is not German by any means? Looks like a reminiscence of the German great-grandfather StarOffice by Star Division in Hamburg, Germany.
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
John_Ha
Volunteer
Posts: 9584
Joined: Fri Sep 18, 2009 5:51 pm
Location: UK

Re: [Solved] Default language not permanent

Post by John_Ha »

I went back to a disk image dated September 2016 and checked C:\ProgramData\Microsoft\Windows\Templates\soffice.odt. It too has no language set. It turns out that C:\ProgramData\Microsoft\Windows\Templates\soffice.odt is not the Default template.

The reason for my confusion is that I had created a completely new User Profile which did not have a user defined Default Template. Hence I could not find it. :crazy: AOO was using the in-built template as downloaded.

I went back to my original User Profile and all became clear.

File > Templates > Organise ..., brings up the Template Management window below. Note how I am actually editing fred.odt and fred appears in the right window.

I double clicked on My Templates and all the template files in C:\Users\xxxxxx\AppData\Roaming\OpenOffice\4\user\template were displayed.

I right clicked any of those files and a pop-up window had the option of Set as Default Template. When I set it, that file became my Default Template.

The option below it was Reset Default Template > Text Document. I presume it removes the Default Template set by the user and goes back to the internal one.

So, AOO as downloaded uses some inbuilt "default template".

If a user wants to change that inbuilt template they need to create a text document and save it as a template (.odt file) in C:\Users\xxxxxx\AppData\Roaming\OpenOffice\4\user\template. This can also be done with the File > New > Templates and Documents menu. They then need to go File > Templates > Organise ..., > double click My Templates > right click the file they want to be the default > select Set as Default Template.
File &gt; Templates &gt; Organise opens this window.<br />Double click My Templates to see the template files (.odt files)
File > Templates > Organise opens this window.
Double click My Templates to see the template files (.odt files)
Last edited by John_Ha on Sat Mar 30, 2019 7:10 pm, edited 3 times in total.
LO 6.4.4.2, Windows 10 Home 64 bit

See the Writer Guide, the Writer FAQ, the Writer Tutorials and Writer for students.

Remember: Always save your Writer files as .odt files. - see here for the many reasons why.
John_Ha
Volunteer
Posts: 9584
Joined: Fri Sep 18, 2009 5:51 pm
Location: UK

Re: [Solved] Default language not permanent

Post by John_Ha »

brucewol wrote:For some reason, my default language always reverts back to german tools/options/language settings/languages/. and then the spell checker doesn't work.
1. Download Default Template - USA.ott which is set to English (US). Edit it as required for page size, margins, fonts etc. Save it as a template Default Template - USA.ott.

2. Place it in C:\Users\xxxxxx\AppData\Roaming\OpenOffice\4\user\template

3. Start AOO. File > Templates > Organise ..., > Double click My Templates

4. right-click Default Template - USA > select Set as Default Template.

Does that fix it? If it fixes the problem it means that the problem arises when the user has not set a Default template as in steps 3 and 4, and is using AOO's built-in default template.
Attachments
Default template - USA.ott
Template file where the language is set to English - USA
(8.76 KiB) Downloaded 223 times
LO 6.4.4.2, Windows 10 Home 64 bit

See the Writer Guide, the Writer FAQ, the Writer Tutorials and Writer for students.

Remember: Always save your Writer files as .odt files. - see here for the many reasons why.
brucewol
Posts: 23
Joined: Fri Mar 11, 2016 9:19 pm

Re: [Solved] Default language not permanent

Post by brucewol »

John Ha - I didn't use you template but in an earlier post, I created my own user template with the language and check spell as you type set how i wanted. I also made sure at the bottom center of document i was editing it was set to English USA and not none. You are correct, when this is done, file explorer right click spell checker works. I then carried this process forward and applied it to programdata/microsoft/windows/templates/soffice.odt.

Do do this I had to copy soffice.odt to a folder where it could be edited. My modifications were to change the tools/language/settings/languages from german to english usa, make sure writing aids was set to check spelling as you type and then in the bottom center of the document, change from none to english usa. elevating to admin, i was able to replace this modified soffice from what is installed in the product. now file explorer/right click produced a writer document where spell checker worked as you type. no user template required in the profile,

this might just be terms, but i don't think there is no built in template in writer software, it uses soffice.odt. a user can override by creating a template in their profile and setting this as the default. but in an initial install, there is no default template defined in the users profile.

so my belief is if that the soffice.odt is modified as i have done, writer will properly spell check without the user doing anything. Clearly the default language should not be set to german for an english installation. And the none should also be changed to english usa. but spell check as you type is my personal preference.

a potential problem can happen because file explorer/right click using a different code path than writer/file/new. Say a user did not want to check spelling as you type. They set this in writer but it doesn't work. How can they figure out that it only doesn't work with file explorer right click. You could post something in the forum but how many users go to the forum for problems, most probably just do a google.

it is a design problem when you perform what the user thinks are the same thing with different code as there is always the potential that you can different results. in a perfect world, this would never happen. but we don't live in a perfect world.

now, in an earlier post, it was mentioned that right click is a system operating feature. well, this feature is supplied by code and files installed by AOO. the code needs to work correctly, if it doesn't then it is a bug. You can evaluate the severity of the bug, but it is a bug.

i will be creating a post with a better subject soon - like spell check doesn't work with file explorer right click to help others if they have this problem and not need to read the wall of posts to get to a workaround. at best, in this forum i found few references that the issue was related to file explorer, right click. if there is a product fix to cover the language setting and none, this could be updated. not sure about the personal preference of spell check as you type but i'm sure there are others out there that are a lot smarter then me that might be able to come up with a better solution.
Open Office 4.1.6 Windows 10 Home
John_Ha
Volunteer
Posts: 9584
Joined: Fri Sep 18, 2009 5:51 pm
Location: UK

Re: [Solved] Default language not permanent

Post by John_Ha »

1. I do not believe C:\ProgramData\Microsoft\Windows\Templates\soffice.odt is ever used on a PC apart, perhaps, from being used to rebuild the profile. Editing it should therefore have no effect.

2. I deleted my old User Profile (including my Default Template) and created a new User Profile. I started AOO and went File > New > Text document. The document created used the "as downloaded with AOO" template.

3. I then I right-clicked the desktop > New > OpenDocument Text. The document created did not use the "as downloaded with AOO" template" as in Step 2. It used the Default template I had previously saved. I cannot understand this because that file was no longer in my User Profile.

4. The completely new registrymodifications.xcu in my new User Profile was set to English (GB) for language and locale as below. This suggests that if there is no user-defined Default Template AOO gets it language setting from registrymodifications.xcu. AOO presumably sets these values because I downloaded the English - UK version.

Code: Select all

<item oor:path="/org.openoffice.Office.UI.WriterWindowState/UIElements/States/org.openoffice.Office.UI.WindowState:WindowStateType['private:resource/toolbar/textobjectbar']/UIName">
	<value xml:lang="en-GB">Formatting</value>
</item>
...
<item oor:path="/org.openoffice.Office.UI.WriterWindowState/UIElements/States/org.openoffice.Office.UI.WindowState:WindowStateType['private:resource/toolbar/standardbar']/UIName">
	<value xml:lang="en-GB">Standard</value>
</item>
... locale ...
<item oor:path="/org.openoffice.Setup/L10N">
	<prop oor:name="ooLocale" oor:op="fuse">
		<value>en-GB</value>
	</prop>
</item>
5. There is a (not template) file C:\Program Files (x86)\OpenOffice 4\share\template\en-GB\internal\idxexample.odt. I don't know what it does as editing it made no change.
LO 6.4.4.2, Windows 10 Home 64 bit

See the Writer Guide, the Writer FAQ, the Writer Tutorials and Writer for students.

Remember: Always save your Writer files as .odt files. - see here for the many reasons why.
brucewol
Posts: 23
Joined: Fri Mar 11, 2016 9:19 pm

Re: [Solved] Default language not permanent

Post by brucewol »

from my experience, soffice.odt was effective in activating spell checker in right clicking. I also found on one computer, after deleting the default template that i created, still performed spell checker as if the template was there. I did not expect this. i think the only way to fully understand the issue is to have someone with expertise review the actual code.
Open Office 4.1.6 Windows 10 Home
John_Ha
Volunteer
Posts: 9584
Joined: Fri Sep 18, 2009 5:51 pm
Location: UK

Re: [Solved] Default language not permanent

Post by John_Ha »

John_Ha wrote:3. I then I right-clicked the desktop > New > OpenDocument Text. The document created did not use the "as downloaded with AOO" template" as in Step 2. It used the Default template I had previously saved. I cannot understand this because that file was no longer in my User Profile.
...
5. There is a (not template) file C:\Program Files (x86)\OpenOffice 4\share\template\en-GB\internal\idxexample.odt. I don't know what it does as editing it made no change.
See Re: [Tutorial] Creating a new default template which says
Hagar Delest wrote:In Windows, if you want to create documents with the right click menu in your file browser (Explorer), then you have to follow the following steps. The New document feature is indeed an Operating System feature that can't reflect the changes made in the OpenOffice configuration after installation.
  • Create a new document from within AOO (will be based on your default template)
  • save it as soffice.odt, overwriting the file (if already existing) in the folder (you may have to do that as administrator):
    • C:\Documents and Settings\All Users\Templates for Windows before Vista
    • C:\Users\All Users\Templates or C:\ProgramData\Microsoft\Windows\Templates in Windows Vista and versions above.
Hence creating a new file with right click menu in your file browser (Explorer) needs a file C:\ProgramData\Microsoft\Windows\Templates\soffice.odt for a template.
LO 6.4.4.2, Windows 10 Home 64 bit

See the Writer Guide, the Writer FAQ, the Writer Tutorials and Writer for students.

Remember: Always save your Writer files as .odt files. - see here for the many reasons why.
Post Reply