Author Topic: Updating Fonts  (Read 6710 times)

Tripwire

  • Full Member
  • ***
  • Thank You
  • -Given: 9
  • -Receive: 0
  • Posts: 163
    • View Profile
Updating Fonts
« on: March 24, 2013, 06:33:03 PM »
Hi,

What is the best way to update fonts? I have some symbols i need to add to my existing font in the project. What i tried so far:
  • Tried to rebuild the Font with new txt and png but that makes my text jibberish
  • Tried deleting my font and recreating it (but that involves placing the prefab of the font in every label used again)
  • Tried just replacing the txt and material without recreating the Font itself but also gives jibberish

So what's the best way? Is it option 2, or is there a faster way?

PebbleBug

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 14
    • View Profile
Re: Updating Fonts
« Reply #1 on: March 25, 2013, 07:08:56 AM »
I'd like to know as well. It used to be pretty easy and you could just drag the font data file to the correct field of the font asset. That field is gone now and it is impossible to update a font with changed font data (like added characters or padding changes) without first deleting the font and recreating a new one... forcing you to assign the font asset to all the objects that use it.

Could we get a fix for this please? This is a major workflow setback (or maybe I'm missing something trivial).

Tripwire

  • Full Member
  • ***
  • Thank You
  • -Given: 9
  • -Receive: 0
  • Posts: 163
    • View Profile
Re: Updating Fonts
« Reply #2 on: March 26, 2013, 07:07:03 AM »
Bump :)

GaVaR

  • Guest
Re: Updating Fonts
« Reply #3 on: March 26, 2013, 07:13:33 AM »
Try such way:
1. Create new prefab
2. Add required font there
3. Place it on scene
4. Overwrite existing font atlas with new prefab
5. Delete newly created prefab

PebbleBug

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 14
    • View Profile
Re: Updating Fonts
« Reply #4 on: March 27, 2013, 03:50:44 AM »
Thanks for that workaround, I managed to make some changes that way.

Although I still consider it a very annoying bug that it is impossible to update a font once it is created and I hope for a better solution than fiddling with replacing prefabs.

Tripwire

  • Full Member
  • ***
  • Thank You
  • -Given: 9
  • -Receive: 0
  • Posts: 163
    • View Profile
Re: Updating Fonts
« Reply #5 on: March 28, 2013, 06:08:46 AM »
Try such way:
1. Create new prefab
2. Add required font there
3. Place it on scene
4. Overwrite existing font atlas with new prefab
5. Delete newly created prefab

Thanks! If this is the best way to do it for now i'll check it out! I hope dat Arenmook reads this topic so maybe he can make it easier in the next version of NGUI :)

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Updating Fonts
« Reply #6 on: March 28, 2013, 04:58:38 PM »
Replace the font inspector with this.