Author Topic: Font selection problem on UIPopupList  (Read 10524 times)

netics

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 16
    • View Profile
Font selection problem on UIPopupList
« on: November 09, 2015, 02:29:51 AM »
In the inspector of UIPopupList, font selection have a problem.
It behaves different with other NGUI font selection.

For example, I can't select reference font to there.
When I click "Font" button, it lists all selectable fonts.
Reference font is also included.
But after I click reference font, font value becomes "None"


NGUI 3.9.4
Unity 5.2.2

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Font selection problem on UIPopupList
« Reply #1 on: November 10, 2015, 08:14:17 PM »
Seems to work fine here... be sure to change the drop-down to "Bitmap" first.

netics

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 16
    • View Profile
Re: Font selection problem on UIPopupList
« Reply #2 on: November 11, 2015, 12:13:11 AM »

I attached the screenshot.

Step 1. I clicked the 'font' button of UIPopupList
Step 2. I selected 'Font_B_Ref' in the font selection window
Step 3. Result. Font became "None"

 - Resource structure -
Font_B_Ref reference Font_B_KR.
Font_B_KR is dynamic font.

But, if I click 'font' button with 'dynamic' option, selection list don't include Font_B_Ref.


ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Font selection problem on UIPopupList
« Reply #3 on: November 12, 2015, 08:53:03 PM »
Did you set up the reference font with an actual reference first?

Here's what I did:

1. New game object (ALT+SHIFT+N)
2. Attached UIFont script to it and set it to Reference, with reference set to an actual font.
3. Saved this game object as a prefab and deleted it from the scene.
4. Dragged in a Simple Popup List prefab.
5. Chose the "GameObject" font I created from the popup list's drop-down.

Works as expected.

netics

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 16
    • View Profile
Re: Font selection problem on UIPopupList
« Reply #4 on: November 12, 2015, 10:58:52 PM »
- Resource structure -
Font_B_Ref reference Font_B_KR.
Font_B_KR is dynamic font.

2. Attached UIFont script to it and set it to Reference, with reference set to an actual font.

Pleae check the actual font you used is dynamic.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Font selection problem on UIPopupList
« Reply #5 on: November 18, 2015, 03:53:13 PM »
Dynamic font works the same -- seems fine here.

1. New game object, attach UIFont, set to dynamic and referencing a TTF that exists in the project (not built-in fonts!)
2. Saved object from #1 as a prefab, deleted it from the scene.
3. New game object, attach UIFont, set to reference, drag & drop the prefab from #2.

netics

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 16
    • View Profile
Re: Font selection problem on UIPopupList
« Reply #6 on: November 18, 2015, 11:58:42 PM »
1. New game object, attach UIFont, set to dynamic and referencing a TTF that exists in the project (not built-in fonts!)
2. Saved object from #1 as a prefab, deleted it from the scene.
3. New game object, attach UIFont, set to reference, drag & drop the prefab from #2.

I tried to follow your steps with new scene.
And the bug happened.

I am using Prefab Evolution. (It's in assetstore).
Maybe this could be the reason of bug.

Anyway, I found an workaround.
Anyone who exprerienced same problem may try below steps.

1. change Bitmap -> Dynamic -> Bitmap.... several times.
2. select other object.
3. select again UIPopupList object.
4. change Bitmap -> Dynamic -> Bitmap.... again.
But this time, the font I want is appeared.


netics

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 16
    • View Profile
Re: Font selection problem on UIPopupList
« Reply #7 on: November 19, 2015, 03:54:32 AM »
.......
Above workaround was useless.
It didn't save state as displayed.
(I am using it by prefab form. and prefab is not changed)

I tried above steps from new project(only NGUI imported).
It happens again. so Prefab Evolution is not guilty.
I feel so stuffy.

I sent you the font by mail(support@tasharen.com)
Please try with the font

Unity version is 5.2.2p2

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Font selection problem on UIPopupList
« Reply #8 on: November 25, 2015, 04:51:16 PM »
I didn't receive your email. Can you double check to ensure you sent it to the right place? The email you listed was correct.

netics

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 16
    • View Profile
Re: Font selection problem on UIPopupList
« Reply #9 on: November 25, 2015, 07:53:17 PM »
Oopps.

I re-sent the mail twice.

First is mistaken one(I missed the font attaching)
Second one has the font.

Thank you.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Font selection problem on UIPopupList
« Reply #10 on: December 01, 2015, 07:11:17 AM »
Well repeated the process with the font you provided in Unity 5.2.2p3... still works fine.

1. New game object, attach UIFont, set to dynamic and referencing a TTF that exists in the project (not built-in fonts!)
2. Saved the object from #1 as a prefab, deleted it from the scene.
3. New game object, attach UIFont, set to reference, drag & drop the prefab from #2.
4. Saved the object from #2 as a prefab, deleted it from the scene.
5. Dragged in a Control - Simple Popup List.
6. Under "Font" chose the font prefab from #4 -- the font field indeed disappeared, but that's because it's set to "Bitmap". Choosing "Dynamic" made the font show up.