Partially changing color of text

Hi,

I’m trying to partially change color of text.

Example:

So one half is in another color than the other half. I would like to keep it as a text object if at all possible. Can I achieve this with a mask perhaps?

Thanks!
Jonjon [import]uid: 65415 topic_id: 33410 reply_id: 333410[/import]

How about using a reverse font? http://www.fontspace.com/category/inverse

The font itself would act as a mask, allowing colors to show through the letter bodies.

You would match the ‘backward font’ color to your background, then slip a colored item underneath it, scale it, etc.

I’ll hit you up in the IRC!

[import]uid: 135765 topic_id: 33410 reply_id: 132737[/import]

Great idea, and it works. It is a bit tricky however. I use text.height to know how high my rect needs to be in the background. text.heightgives the font height, which is lower and higher than what you actually see, I guess its because of subscript and superscript and such. Since I need to have this really dynamic (size will be changing with slider) I don’t think this will work for me unless I go in and edit my font perhaps.

Thanks,
Jonjon [import]uid: 65415 topic_id: 33410 reply_id: 132760[/import]

How about using a reverse font? http://www.fontspace.com/category/inverse

The font itself would act as a mask, allowing colors to show through the letter bodies.

You would match the ‘backward font’ color to your background, then slip a colored item underneath it, scale it, etc.

I’ll hit you up in the IRC!

[import]uid: 135765 topic_id: 33410 reply_id: 132737[/import]

Great idea, and it works. It is a bit tricky however. I use text.height to know how high my rect needs to be in the background. text.heightgives the font height, which is lower and higher than what you actually see, I guess its because of subscript and superscript and such. Since I need to have this really dynamic (size will be changing with slider) I don’t think this will work for me unless I go in and edit my font perhaps.

Thanks,
Jonjon [import]uid: 65415 topic_id: 33410 reply_id: 132760[/import]