Newgrounds.com — Everything, By Everyone.

Checking login status…

USERNAME:

PASSWORD:

Logging in…

Logged in as:
.
Logging out…
Inbox My Account Log Out


Forum Topic: Bold part of a textbox

(71 views • 9 replies)

This topic is 1 page long.

<< < > >>
None

johnfn

Reply To Post Reply & Quote

Posted at: 6/8/08 01:17 PM

johnfn LIGHT LEVEL 19

Sign-Up: 08/16/03

Posts: 2,852

How do I only make some of the text in a textbox bold?


None

johnfn

Reply To Post Reply & Quote

Posted at: 6/8/08 01:25 PM

johnfn LIGHT LEVEL 19

Sign-Up: 08/16/03

Posts: 2,852

Actually, just turning part of it a different color would be cool too, if bolding is impossible or something.


Shouting

ReNaeNae

Reply To Post Reply & Quote

Posted at: 6/8/08 01:37 PM

ReNaeNae NEUTRAL LEVEL 27

Sign-Up: 09/01/04

Posts: 1,971

Select the text and... change it?

...it's criminal!

BBS Signature

None

johnfn

Reply To Post Reply & Quote

Posted at: 6/8/08 01:49 PM

johnfn LIGHT LEVEL 19

Sign-Up: 08/16/03

Posts: 2,852

Eh, it figures that I still wasn't clear enough. I mean, how do I bold it dynamically (with ActionScript) ?


None

gankro

Reply To Post Reply & Quote

Posted at: 6/8/08 02:41 PM

gankro EVIL LEVEL 11

Sign-Up: 09/16/06

Posts: 1,133

well, if message length isn't variant then you can just have a seperate box for the bold section beyond that I'm pretty sure you have to use the api to create letters without a box.

My Coding Portfolio (updated frequently)
If you stay in bed for long enough it will be socially acceptable to go to bed again

BBS Signature

None

Theodor

Reply To Post Reply & Quote

Posted at: 6/8/08 02:42 PM

Theodor NEUTRAL LEVEL 07

Sign-Up: 06/08/08

Posts: 18

I am not quite sure about what you mean, you could try outline tool.


None

authorblues

Reply To Post Reply & Quote

Posted at: 6/8/08 02:44 PM

authorblues FAB LEVEL 12

Sign-Up: 06/21/05

Posts: 6,289

At 6/8/08 01:17 PM, johnfn wrote: How do I only make some of the text in a textbox bold?

set the textbox's html property to true, and then make sure instead of setting textbox.text, you use textbox.htmltext. just use html like you normally would to make it bold.

textbox.html = true;
textbox.htmltext = "These words are <b>bold</b>.";

my blog. smash code: 3523-1700-9216 [AUTHR]

BBS Signature

Elated

gankro

Reply To Post Reply & Quote

Posted at: 6/8/08 02:52 PM

gankro EVIL LEVEL 11

Sign-Up: 09/16/06

Posts: 1,133

hmm... the more you know.

My Coding Portfolio (updated frequently)
If you stay in bed for long enough it will be socially acceptable to go to bed again

BBS Signature

None

GustTheASGuy

Reply To Post Reply & Quote

Posted at: 6/8/08 03:20 PM

GustTheASGuy LIGHT LEVEL 08

Sign-Up: 11/02/05

Posts: 9,218

At 6/8/08 02:44 PM, authorblues wrote: textbox.html = true;
textbox.htmltext = "These words are bold.";

I find it easier to use setTextStyle.

haXe AliceML Box2dLite Learn AS
#ngprogramming at irc.freenode.net
OVER NINE THOUSAAAAND!!!


None

johnfn

Reply To Post Reply & Quote

Posted at: 6/9/08 07:09 PM

johnfn LIGHT LEVEL 19

Sign-Up: 08/16/03

Posts: 2,852

At 6/8/08 02:44 PM, authorblues wrote: set the textbox's html property to true, and then make sure instead of setting textbox.text, you use textbox.htmltext. just use html like you normally would to make it bold.

textbox.html = true;
textbox.htmltext = "These words are bold.";

I knew it was something like this. Thank you. You are awesome.


All times are Eastern Daylight Time (GMT -4) | Current Time: 02:48 AM

<< Back

This topic is 1 page long.

<< < > >>
You need a Grounds Gold Account to post on the NG BBS! If you don't have one, click here to sign up now! It's fast, free, and easy — and opens up tons of great NG features!