Maniphest T54423

Translation text is still in English
Closed, Resolved

Assigned To
Bastien Montagne (mont29)
Authored By
Hoang Duy Tran (hoangduytran)
Mar 25 2018, 11:50 PM
Tags
  • BF Blender
  • Translations
Subscribers
Aaron Carlisle (Blendify)
Hoang Duy Tran (hoangduytran)
Philipp Oeser (lichtwerk)

Description

A few pieces of texts are still in English.

  1. "cell_size" (this is not even in proper English, it's more like name of an internal variable)
  2. "This property is for internal use only and can't be edited." (rna_access.c)

To see them:
Reproduce procedure:

  1. New Blend file, leave the default cube as is.
  2. Select the default cube, then Object->Quick Effects->Quick Smoke
  3. On Outliner, next to 'Search', select 'Data-Blocks' ('All Scenes' by default)
  4. Go down to section for 'Objects'
  5. Select 'Smoke Domain' object.
  6. Scroll down to 'Modifiers' section
  7. Expand 'Smoke', 'Domain Settings'
  8. Scroll down to see 'cell_size', and move the mouse pointer to the first value text box for 'X' value, you should see the text

"Disabled: This property is for internal use only and can't be edited."

  1. Now go to the menu 'File->User Preferences->System'
  2. Click on the 'International Fonts' and select a language of choice, other than English.
  3. Move the mouse pointer back to the text box 'X' value mentioned above and you should see the first piece of text 'Disabled' has been translated, but the remain part is NOT.

Revisions and Commits

rB Blender

Event Timeline

Hoang Duy Tran (hoangduytran) lowered the priority of this task from 90 to Normal.Mar 25 2018, 11:50 PM
Hoang Duy Tran (hoangduytran) created this task.
Aaron Carlisle (Blendify) removed Aaron Carlisle (Blendify) as the assignee of this task.Mar 26 2018, 2:18 AM
Aaron Carlisle (Blendify) triaged this task as 90 priority.
Aaron Carlisle (Blendify) added a project: BF Blender.
Aaron Carlisle (Blendify) added a subscriber: Aaron Carlisle (Blendify).
Philipp Oeser (lichtwerk) added a subscriber: Philipp Oeser (lichtwerk).Apr 6 2018, 2:52 PM

This is because right now this msg is still hardcoded in english in rna_access.c

Afaik this will only enter the realm of translation if this is changed to

1diff --git a/source/blender/makesrna/intern/rna_access.c b/source/blender/makesrna/intern/rna_access.c
2index 18e42488829..415c85e6f24 100644
3--- a/source/blender/makesrna/intern/rna_access.c
4+++ b/source/blender/makesrna/intern/rna_access.c
5@@ -1842,7 +1842,7 @@ bool RNA_property_editable_info(PointerRNA *ptr, PropertyRNA *prop, const char *
6 else {
7 flag = prop->flag;
8 if ((flag & PROP_EDITABLE) == 0 || (flag & PROP_REGISTER)) {
9- *r_info = "This property is for internal use only and can't be edited.";
10+ *r_info = N_("This property is for internal use only and can't be edited.");
11 }
12 }

If you then make an entry in the .po of choice like

1msgid "This property is for internal use only and can't be edited."
2msgstr "translation of your choice"

and rebuild blender it actually shows up as expected.

More info [to do it properly :)] here and here though I am not sure if they are a bit outdated... looking further into this and try to find out if we track places that could use internationalization somewhere...

Tempted to not call this a bug though but more of a TODO?

Aaron Carlisle (Blendify) assigned this task to Bastien Montagne (mont29).Apr 6 2018, 6:16 PM
Aaron Carlisle (Blendify) added a project: Translations.
Bastien Montagne (mont29) changed the task status from Unknown Status to Resolved by committing rB814f143acf5f: Fix T54423: Messages from RNA_property_editable_info() were not translatable..Apr 10 2018, 10:24 AM
Bastien Montagne (mont29) added a commit: rB814f143acf5f: Fix T54423: Messages from RNA_property_editable_info() were not translatable..