Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-14000] Internationalization: textid can only be set on create?

GitHub Issuen/a
TypeBug
Priorityn/a
StatusOpen
ResolutionUnresolved
Affected Version/sn/a
Fix Version/sn/a
Componentsn/a
Labelsi18n, internationalization, label, textid
ReporterCarter Lathrop
AssigneeUnknown
Created2013-05-27T18:37:03.000+0000
Updated2018-02-28T20:04:09.000+0000

Description

It seams like - contrary to docs - the textid of a Label can only be set on create:
var w = Ti.UI.createWindow({
	backgroundColor: 'white'
});

var l = Ti.UI.createLabel({
	color: 'black'
	/* Works:
	,textid: 'hello_world'//*/
});

w.add(l);
w.open();

/* Works:
l.text = L('hello_world');//*/

// Does not work
l.textid = 'hello_world';

/* Does not work:
l.setTextid('hello_world');//*/

/* Does not work:
l.applyProperties({
	textid: 'hello_world'
});//*/
The i18n/en/strings.xml for these tests was:
<?xml version="1.0" encoding="UTF-8"?>
<resources>
    <string name="hello_world">Hello world!</string>
</resources>

Comments

  1. Fokke Zandbergen 2013-05-27

    Why was this moved to Alloy? I don't see how it has anything to do with Alloy.

JSON Source