Rainie3535 / sigil

Automatically exported from code.google.com/p/sigil
GNU General Public License v3.0
0 stars 0 forks source link

Option to manually set UI language #1265

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
It would be nice if the language auto detection mechanism could be overruled 
manually.
As I live in the Netherlands, my locale is set to NL, but all software I use is 
in English. So it comes in handy to be able to set the app-language manually.

Original issue reported on code.google.com by laurens....@gmail.com on 14 Feb 2012 at 7:11

GoogleCodeExporter commented 9 years ago
The language is determined by the system locale. Only Sigil and not components 
like FlightCrew support translation. I do not see a need to have the language 
configurable.

Original comment by john@nachtimwald.com on 15 Feb 2012 at 2:31

GoogleCodeExporter commented 9 years ago
Though my system locale is set to English, I need to keep all other locale 
settings set on Dutch to be able to use correct decimal separators, date and 
time notation etc.
Somehow, Sigil detects that the language used for the app should be Dutch, but 
for me that's very inconvenient as I prefer my system and all my apps to be in 
English. Though I'm native Dutch speaking, using apps in Dutch is very 
confusing as I'm used to English apps. Furthermore, when an error occurs or one 
needs to find some info on the internet, there is much more info available in 
English than in Dutch (very small community), but I always find it difficult to 
translate the (error)messages in Dutch to its exact English counterpart to be 
able to quickly find relevant info.

Original comment by laurens....@gmail.com on 15 Feb 2012 at 1:11

GoogleCodeExporter commented 9 years ago
I agree with laurens, it would be very useful to be able to overrule the 
default. I'm using a German Windows, but the programs I work with on a daily 
basis are in English. I prefer to have all programs in the same language, if 
possible, so I would like to override the language detection in Sigil.

@laurens: As a workaround, I just replaced sigil_de.qm with a copy of 
sigil_en.qm. It works ;-)

Original comment by Bert.Al...@googlemail.com on 24 Feb 2012 at 3:02

GoogleCodeExporter commented 9 years ago
@Bert: Works fine, my Sigil is English again. Thx!

Original comment by laurens....@gmail.com on 24 Feb 2012 at 4:20

GoogleCodeExporter commented 9 years ago

Original comment by meme90...@gmail.com on 29 Feb 2012 at 5:55

GoogleCodeExporter commented 9 years ago

Original comment by meme90...@gmail.com on 5 Mar 2012 at 5:11

GoogleCodeExporter commented 9 years ago
Patch attached

- Allows setting the UI language in Preferences->Language, requires restart of 
Sigil
- Supports translating of language names
- Language choices saved in ISO code so old preferences will be ignored
- Implements 1295 to make Metadata descriptions translatable and Metadata 
language names translatable (also part of issue 1097)
- Implements 77 to allow extra optional languages added to a book's metadata

Original comment by meme90...@gmail.com on 6 Mar 2012 at 6:20

Attachments:

GoogleCodeExporter commented 9 years ago
The metadata entries such as "Subject" are being translated and the translated 
versions are going to be written to the OPF. This is going to cause numerous 
problems. Also, it does not appear that translated metadata tags are even valid 
in the OPF.

This would need to be reworked to show the metadata in the localized language 
but written to the OPF in English.

---

While not an issue per say, the following construct is unnecessary. It's going 
to be slow and use unnecessary memory.

QStringList data;
data << ...
...
for ( int i = 0; i < data.count(); i++ )

Since the attributes are defined in the code it is better to do load the QMaps 
directly. However, since a MetaInfo object needs to be loaded into the map 
using the QStringList construct is nicer looking. In this case it's a choice of 
a bit slower initialization versus a lot more code.

Original comment by john@nachtimwald.com on 7 Mar 2012 at 1:04

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
New patch attached.

The loop is for readability.

Original comment by meme90...@gmail.com on 8 Mar 2012 at 8:46

Attachments:

GoogleCodeExporter commented 9 years ago

Original comment by john@nachtimwald.com on 9 Mar 2012 at 1:36

GoogleCodeExporter commented 9 years ago

Original comment by daveheil...@gmail.com on 19 May 2012 at 3:20

GoogleCodeExporter commented 9 years ago
I live in Belgium and speak little French and no Dutch.  The program sets 
itself in Dutch and I cannot change it.  No idea how the patch works.  Help!!

Original comment by nestor.v...@gmail.com on 31 Jul 2013 at 12:25