flex-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alex Harui (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (FLEX-34115) Displaying Chinese in spark List does not work in Android 4.4.2
Date Fri, 28 Feb 2014 05:34:19 GMT

    [ https://issues.apache.org/jira/browse/FLEX-34115?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13915477#comment-13915477

Alex Harui commented on FLEX-34115:

Embedding a full chinese font will make for a pretty big app.

But your finding indicates that the issue may be about device font lookups.  IIRC, the player
asks the OS for whatever font family you have specified.  If the font family doesn't exist,
most OS's return some other font that approximates what you are looking for.  I'm not quite
sure how that works, but there seems to be information about whether serifs are needed, monospacing,

Anyway, it may be that the TextLine subsystem is asking differently than the TextField subsystem,
and the TextLine is being given a font that doesn't have chinese characters in it.  The article
I pointed out indicates that some fonts do not have all of the chinese characters in them.

So, there may be some other things to try, but having a simple test case that takes any Flex
logic out is probably a good idea.  First thing to prove is that TextLine doesn't work and
TextField does, or vice versa.  Then you can use the APIs for whatever one doesn't work to
try to figure out why.  One simple reason may be that you are asking for a font like Verdana
or Arial.  I think Android may only have "Droid" fonts.  If you actually set fontFamily to
a "Droid" font that you know has chinese characters in it, it might solve the problem.

> Displaying Chinese in spark List does not work in Android 4.4.2
> ---------------------------------------------------------------
>                 Key: FLEX-34115
>                 URL: https://issues.apache.org/jira/browse/FLEX-34115
>             Project: Apache Flex
>          Issue Type: Bug
>          Components: Spark: List
>    Affects Versions: Apache Flex 4.11.0
>         Environment: Windows 7 64 bit, Flash Builder 4.6, HTC One Android 4.4.2/ Galaxy
Note 3 Android 4.4.2
>            Reporter: victor yew
>              Labels: android, flex, list, localization, mobile
>         Attachments: LocaleTest.fxp
>   Original Estimate: 1h
>  Remaining Estimate: 1h
> I have come to this bug where localization does not work in Android 4.4.2. Oddly, this
problem only occurs in the spark list component. The dataProvider is showing blank items.

> The following is my code:
> <s:List id="list" width="100%" height="100%" locale="zh_CN">
> 		<s:itemRenderer>
> 			<fx:Component>
> 				<renderers:RoundedListItemRenderer decorator="{data.icon}" labelField="label"
styleName="roundedListStyle" 												   alternatingItemColors="0xdcdcdc" color="0x444444"
downColor="0xb0b0b0"	width="100%" height="100%"/>
> 			</fx:Component>
> 		</s:itemRenderer>
> 		<s:ArrayCollection>
> 			<fx:Object type="current" label="{resourceManager.getString('resources','str1')}"
> 			<fx:Object type="statement" label="{resourceManager.getString('resources','str2')}"
> 			<fx:Object type="history" label="{resourceManager.getString('resources','str3')}"
> 			<fx:Object type="deposit" label="{resourceManager.getString('resources','str4')}"
> 			<fx:Object type="withdrawal" label="{resourceManager.getString('resources','str5')}"
> 		</s:ArrayCollection>
> 	</s:List>
> [Edit]
> I have tried on button. The same thing happens when I removed the skinClass.
> Here is my button code:
> <s:Button id="logoutBtn" label="{resourceManager.getString('resources','accountview.button.signout')}"
> 			  width="100%" height="60" skinClass="skins.LoginButtonSkin"/>

This message was sent by Atlassian JIRA

View raw message