Author Topic: Fonts  (Read 3616 times)

rain

  • Jr. Member
  • **
  • Thank You
  • -Given: 2
  • -Receive: 4
  • Posts: 79
    • View Profile
Fonts
« on: May 06, 2012, 01:56:54 PM »
Hi!

I want my application to work with all languages' fonts. How can I do that?

Regards

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Fonts
« Reply #1 on: May 06, 2012, 06:54:03 PM »
You need to export the glyphs of all languages you need from the font generation program such as BMFont.

Keep in mind that if you want to support eastern languages, your texture will be huge with just those glyphs alone.

ENAY

  • Full Member
  • ***
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 248
    • View Profile
Re: Fonts
« Reply #2 on: May 07, 2012, 02:40:56 AM »
Hi there,

I am interested in being able to use Japanese fonts. Unity supports Japanese text in the IDE so I am just wondering if it is as easy as to simply copy a text string and it automatically work as long as you have the atlas with all the text already generated.

For example

thewords.text = "JAPANESE TEXT HERE";

Thanks for reading.

rain

  • Jr. Member
  • **
  • Thank You
  • -Given: 2
  • -Receive: 4
  • Posts: 79
    • View Profile
Re: Fonts
« Reply #3 on: May 07, 2012, 07:04:21 AM »
So basically i gotta have a huge Atlas with all the fonts i need to display?

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Fonts
« Reply #4 on: May 07, 2012, 10:42:17 AM »
@Enay: Yeah, as long as your font was exported with Japanese glyphs, it will work fine.

@rain: Yup. I'd suggest only exporting glyphs you need though, or you're going to run into texture size issues.

rain

  • Jr. Member
  • **
  • Thank You
  • -Given: 2
  • -Receive: 4
  • Posts: 79
    • View Profile
Re: Fonts
« Reply #5 on: July 19, 2012, 05:23:26 PM »
I'm using BMGlyph, and I wondered if i wanted to display a string with unknown content( means that it can be english, chinese or hungarian text, this text changes runtime) and I am a bit confused here because in BMGlyph you can export an image file from a font package for example:  latin font. I set the label's font to my default font which has the standard latin font in it. How can this label display chinese text when the label's text changes to a chinese text?

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Fonts
« Reply #6 on: July 19, 2012, 05:35:02 PM »
In BMFont you can specify which glyphs get exported. Select all that you'll need.

rain

  • Jr. Member
  • **
  • Thank You
  • -Given: 2
  • -Receive: 4
  • Posts: 79
    • View Profile
Re: Fonts
« Reply #7 on: July 19, 2012, 06:20:36 PM »
So basically i can get glyphs from different fonts and merge them?

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Fonts
« Reply #8 on: July 19, 2012, 08:45:59 PM »
No, it has to be one font. Some fonts have all the glyphs in them, others don't. You need to find one that has everything.