About Text Plugin

Discussion and feedback on Construct 2

Post » Mon Feb 14, 2011 4:44 pm

Some questions:

1. Does the current plugin already supports other fonts other than Arial ? Or is this work in progress ?

2. Are there plans to make text plugin be able to use any font not only the ones that are in Windows/Fonts ?

3. (Technical) The current text plugin uses Canvas native text rendering method 'fillText' . Is this a final decision or a bitmap font system could be added ? Maybe rasterizing the font files and rendering them as bitmap ?

Thanks :D
B
58
S
13
G
10
Posts: 632
Reputation: 12,505

Post » Mon Feb 14, 2011 5:35 pm

It should support TrueType fonts - under the hood it uses FreeType, which supports a lot of formats, just not *all* of the ones in Windows. It is by no means limited only to Arial.

However, you also need to be sure that the browser has the font, which means you should probably stick to the standard web development fonts like Arial, Helvetica and so on. HTML5 also has downloadable fonts support but that's not something on the immediate agenda to implement.

The plugin system allows anyone to make any kind of plugin. Even if the Text object only ever used fillText, someone can make a plugin that uses bitmap fonts. There's no reason to be limited by official plugins.
Scirra Founder
B
359
S
214
G
72
Posts: 22,952
Reputation: 178,600

Post » Mon Feb 14, 2011 6:02 pm

Well, there is this @font-face property, which lets you use any font within the canvas. Worth considering!
B
62
S
21
G
12
Posts: 1,910
Reputation: 13,155

Post » Mon Feb 14, 2011 7:21 pm

I'm not sure if that can load fonts the user doesn't have though
Image Image
Scirra Founder
B
125
S
37
G
25
Posts: 3,945
Reputation: 44,922

Post » Mon Feb 14, 2011 7:38 pm

Yeah @font-face seems promising :D
B
58
S
13
G
10
Posts: 632
Reputation: 12,505


Return to Construct 2 General

Who is online

Users browsing this forum: rekjl and 8 guests