Translation text is still in English #54423

Closed
opened 2018-03-25 23:50:06 +02:00 by Hoang Duy Tran · 6 comments
Member

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.

Screenshot from 2018-03-25 22-48-42.png

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." 9. Now go to the menu 'File->User Preferences->System' 10. Click on the 'International Fonts' and select a language of choice, other than English. 11. 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. ![Screenshot from 2018-03-25 22-48-42.png](https://archive.blender.org/developer/F2507477/Screenshot_from_2018-03-25_22-48-42.png)
Aaron Carlisle was assigned by Hoang Duy Tran 2018-03-25 23:50:06 +02:00
Author
Member

Added subscriber: @hoanguk

Added subscriber: @hoanguk
Aaron Carlisle removed their assignment 2018-03-26 02:18:42 +02:00
Member

Added subscriber: @Blendify

Added subscriber: @Blendify
Member

Added subscriber: @lichtwerk

Added subscriber: @lichtwerk
Member

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 P651: #54423 snippet

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

If you then make an entry in the .po of choice like P652: #54423 snippet 2

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

and rebuild blender it actually shows up as expected.

More info [to do it properly :)] [here ]] and [ https:*wiki.blender.org/index.php/Dev:Doc/Process/Translate_Blender | 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?

This is because right now this msg is still hardcoded in english [in rna_access.c ](https://developer.blender.org/diffusion/B/browse/master/source/blender/makesrna/intern/rna_access.c;d2e1a14a570b899c528fdcbc54396a0d58d0a28b$1845) Afaik this will only enter the realm of translation if this is changed to [P651: #54423 snippet](https://archive.blender.org/developer/P651.txt) ``` diff --git a/source/blender/makesrna/intern/rna_access.c b/source/blender/makesrna/intern/rna_access.c index 18e42488829..415c85e6f24 100644 --- a/source/blender/makesrna/intern/rna_access.c +++ b/source/blender/makesrna/intern/rna_access.c @@ -1842,7 +1842,7 @@ bool RNA_property_editable_info(PointerRNA *ptr, PropertyRNA *prop, const char * else { flag = prop->flag; if ((flag & PROP_EDITABLE) == 0 || (flag & PROP_REGISTER)) { - *r_info = "This property is for internal use only and can't be edited."; + *r_info = N_("This property is for internal use only and can't be edited."); } } ``` If you then make an entry in the .po of choice like [P652: #54423 snippet 2](https://archive.blender.org/developer/P652.txt) ``` msgid "This property is for internal use only and can't be edited." msgstr "translation of your choice" ``` and rebuild blender it actually shows up as expected. More info [to do it properly :)] [here ]] and [[ https:*wiki.blender.org/index.php/Dev:Doc/Process/Translate_Blender | here ](https:*wiki.blender.org/index.php/Dev:Source/Interface/Internationalization) 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?
Bastien Montagne was assigned by Aaron Carlisle 2018-04-06 18:16:48 +02:00

This issue was referenced by 814f143acf

This issue was referenced by 814f143acf5ffdcb0cba6706823bd509d2105f63

Changed status from 'Open' to: 'Resolved'

Changed status from 'Open' to: 'Resolved'
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
5 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#54423
No description provided.