You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@flex.apache.org by Frank Dahmen <fr...@dahmenia.de> on 2016/02/10 10:19:11 UTC
font awesome
Hi,
I'm using font awesome in a mobile air app.
I've added a second label in a Skin which I us for some buttons, which
is showing the icon.
The issue is that it's not working on the buttons which are in the
ViewNavigatorApplication file.
(they do work in a view)
AND ONLY on my android 5 nexus, on my android 4 phone they work everywhere.
Any help?
thanks
Re: font awesome
Posted by Frank Dahmen <fr...@dahmenia.de>.
yes you were right:)
somewhat forced the labels to be bold when inside a skin of a Button
which is in the viewNavigatorApplication
Am 10.02.2016 um 19:48 schrieb Alex Harui:
> Could it be that the ViewNavigatorApplication, plus some other
> device-specific configuration is specifying a Bold font for the Button in
> the failure scenarios? I think you may have to embed the font twice, once
> with fontStyle:Bold or specify fontStyle:Normal on the iconLabel or
> whatever is supposed to use that font.
>
> -Alex
>
> On 2/10/16, 10:36 AM, "Frank Dahmen" <fr...@dahmenia.de> wrote:
>
>> I have a skin (mxml) with 2 labels
>> oncreationcomplete -> iconLabel.setStyle("fontFamily", "FontAwesome");
>>
>> in the main file (ViewNavigatorApplication):
>> <fx:Style>
>> @font-face {
>> fontFamily: FontAwesome;
>> embed-as-cff: true;
>> src: url("assets/FontAwesome.otf");
>> fontStyle:normal;
>> }
>> </fx:Style>
>>
>> it does work on my htc, does not work on a nexus and does not work on a
>> galaxy s2
>> !!!!but only in the navigationContent of the ViewNavigatorApplication,
>> in a View it works on all devices
>>
>> meanwhile I ended up in making a custom component (Group) with 2 Labels
>> instead of a button with custom skin
>>
>>
>>
>>
>> Am 10.02.2016 um 18:29 schrieb Alex Harui:
>>> Is it now behaving consistently across devices? How are you specifying
>>> the fontFamily?
>>>
>>> -Alex
>>>
>>> On 2/10/16, 4:30 AM, "Frank Dahmen" <fr...@dahmenia.de> wrote:
>>>
>>>> more strange:
>>>> when i put a label (with fontawesome as fontfamily) in the same HGroup
>>>> in the ViewNavigatorApplication
>>>> where the button is, the label is showing the icon correct
>>>>
>>>> - ViewNavigatorApplication -> label->works
>>>> - ViewNavigatorApplication -> Button with custom skin -> doesn't work
>>>> - in a View -> Button with same custom skin -> works
>>>>
>>>>
>>>> Am 10.02.2016 um 10:19 schrieb Frank Dahmen:
>>>>> Hi,
>>>>> I'm using font awesome in a mobile air app.
>>>>> I've added a second label in a Skin which I us for some buttons, which
>>>>> is showing the icon.
>>>>> The issue is that it's not working on the buttons which are in the
>>>>> ViewNavigatorApplication file.
>>>>> (they do work in a view)
>>>>> AND ONLY on my android 5 nexus, on my android 4 phone they work
>>>>> everywhere.
>>>>>
>>>>> Any help?
>>>>> thanks
>>>>>
Re: font awesome
Posted by Alex Harui <ah...@adobe.com>.
Could it be that the ViewNavigatorApplication, plus some other
device-specific configuration is specifying a Bold font for the Button in
the failure scenarios? I think you may have to embed the font twice, once
with fontStyle:Bold or specify fontStyle:Normal on the iconLabel or
whatever is supposed to use that font.
-Alex
On 2/10/16, 10:36 AM, "Frank Dahmen" <fr...@dahmenia.de> wrote:
>I have a skin (mxml) with 2 labels
>oncreationcomplete -> iconLabel.setStyle("fontFamily", "FontAwesome");
>
>in the main file (ViewNavigatorApplication):
><fx:Style>
>@font-face {
> fontFamily: FontAwesome;
> embed-as-cff: true;
> src: url("assets/FontAwesome.otf");
> fontStyle:normal;
>}
></fx:Style>
>
>it does work on my htc, does not work on a nexus and does not work on a
>galaxy s2
>!!!!but only in the navigationContent of the ViewNavigatorApplication,
>in a View it works on all devices
>
>meanwhile I ended up in making a custom component (Group) with 2 Labels
>instead of a button with custom skin
>
>
>
>
>Am 10.02.2016 um 18:29 schrieb Alex Harui:
>> Is it now behaving consistently across devices? How are you specifying
>> the fontFamily?
>>
>> -Alex
>>
>> On 2/10/16, 4:30 AM, "Frank Dahmen" <fr...@dahmenia.de> wrote:
>>
>>> more strange:
>>> when i put a label (with fontawesome as fontfamily) in the same HGroup
>>> in the ViewNavigatorApplication
>>> where the button is, the label is showing the icon correct
>>>
>>> - ViewNavigatorApplication -> label->works
>>> - ViewNavigatorApplication -> Button with custom skin -> doesn't work
>>> - in a View -> Button with same custom skin -> works
>>>
>>>
>>> Am 10.02.2016 um 10:19 schrieb Frank Dahmen:
>>>> Hi,
>>>> I'm using font awesome in a mobile air app.
>>>> I've added a second label in a Skin which I us for some buttons, which
>>>> is showing the icon.
>>>> The issue is that it's not working on the buttons which are in the
>>>> ViewNavigatorApplication file.
>>>> (they do work in a view)
>>>> AND ONLY on my android 5 nexus, on my android 4 phone they work
>>>> everywhere.
>>>>
>>>> Any help?
>>>> thanks
>>>>
>
Re: font awesome
Posted by Frank Dahmen <fr...@dahmenia.de>.
I have a skin (mxml) with 2 labels
oncreationcomplete -> iconLabel.setStyle("fontFamily", "FontAwesome");
in the main file (ViewNavigatorApplication):
<fx:Style>
@font-face {
fontFamily: FontAwesome;
embed-as-cff: true;
src: url("assets/FontAwesome.otf");
fontStyle:normal;
}
</fx:Style>
it does work on my htc, does not work on a nexus and does not work on a
galaxy s2
!!!!but only in the navigationContent of the ViewNavigatorApplication,
in a View it works on all devices
meanwhile I ended up in making a custom component (Group) with 2 Labels
instead of a button with custom skin
Am 10.02.2016 um 18:29 schrieb Alex Harui:
> Is it now behaving consistently across devices? How are you specifying
> the fontFamily?
>
> -Alex
>
> On 2/10/16, 4:30 AM, "Frank Dahmen" <fr...@dahmenia.de> wrote:
>
>> more strange:
>> when i put a label (with fontawesome as fontfamily) in the same HGroup
>> in the ViewNavigatorApplication
>> where the button is, the label is showing the icon correct
>>
>> - ViewNavigatorApplication -> label->works
>> - ViewNavigatorApplication -> Button with custom skin -> doesn't work
>> - in a View -> Button with same custom skin -> works
>>
>>
>> Am 10.02.2016 um 10:19 schrieb Frank Dahmen:
>>> Hi,
>>> I'm using font awesome in a mobile air app.
>>> I've added a second label in a Skin which I us for some buttons, which
>>> is showing the icon.
>>> The issue is that it's not working on the buttons which are in the
>>> ViewNavigatorApplication file.
>>> (they do work in a view)
>>> AND ONLY on my android 5 nexus, on my android 4 phone they work
>>> everywhere.
>>>
>>> Any help?
>>> thanks
>>>
Re: font awesome
Posted by Alex Harui <ah...@adobe.com>.
Is it now behaving consistently across devices? How are you specifying
the fontFamily?
-Alex
On 2/10/16, 4:30 AM, "Frank Dahmen" <fr...@dahmenia.de> wrote:
>more strange:
>when i put a label (with fontawesome as fontfamily) in the same HGroup
>in the ViewNavigatorApplication
>where the button is, the label is showing the icon correct
>
>- ViewNavigatorApplication -> label->works
>- ViewNavigatorApplication -> Button with custom skin -> doesn't work
>- in a View -> Button with same custom skin -> works
>
>
>Am 10.02.2016 um 10:19 schrieb Frank Dahmen:
>> Hi,
>> I'm using font awesome in a mobile air app.
>> I've added a second label in a Skin which I us for some buttons, which
>> is showing the icon.
>> The issue is that it's not working on the buttons which are in the
>> ViewNavigatorApplication file.
>> (they do work in a view)
>> AND ONLY on my android 5 nexus, on my android 4 phone they work
>> everywhere.
>>
>> Any help?
>> thanks
>>
>
Re: font awesome
Posted by Frank Dahmen <fr...@dahmenia.de>.
more strange:
when i put a label (with fontawesome as fontfamily) in the same HGroup
in the ViewNavigatorApplication
where the button is, the label is showing the icon correct
- ViewNavigatorApplication -> label->works
- ViewNavigatorApplication -> Button with custom skin -> doesn't work
- in a View -> Button with same custom skin -> works
Am 10.02.2016 um 10:19 schrieb Frank Dahmen:
> Hi,
> I'm using font awesome in a mobile air app.
> I've added a second label in a Skin which I us for some buttons, which
> is showing the icon.
> The issue is that it's not working on the buttons which are in the
> ViewNavigatorApplication file.
> (they do work in a view)
> AND ONLY on my android 5 nexus, on my android 4 phone they work
> everywhere.
>
> Any help?
> thanks
>