Tilted Forum Project Discussion Community  

Go Back   Tilted Forum Project Discussion Community > Interests > Tilted Technology


 
 
LinkBack Thread Tools
Old 10-04-2004, 04:11 AM   #1 (permalink)
Femme Fatale
 
Nancy's Avatar
 
Location: Elysium
Need tabulators in Flash MX text box

hey all.

I'm currently working on a website in Flash MX and it containts numbers in the text that needs to be aligned perfectly by using tabulators. The problem is that Flash itself does not have that feature so I have to link the text box to an external text file such as txt. But notepad doesn't have the tabulator feature either so what the heck do I do?! Help! *sniff*

__________________
I have all the characteristics of a human being: blood, flesh, skin, hair; but not a single, clear, identifiable emotion, except for greed and disgust. Something horrible is happening inside of me and I don't know why. My nightly bloodlust has overflown into my days. I feel lethal, on the verge of frenzy.
I think my mask of sanity is about to slip.
Nancy is offline  
Old 10-05-2004, 04:05 AM   #2 (permalink)
Crazy
 
Location: Belgium
Hey Nancy,

There are a few (possible) work-arounds for this:
1. you can make textboxes on top of each other. Most people put all there text in just one textbox, but sometimes it is handier (or more beautifull) to make a textbox per paragraph or so. If you want to have the textbox-look you can make a big one without any text for the looks and the paragraph-textboxes (transparant) on top of it.
2. Dynamic and input textboxes (not static) can preserve rich text formating (aka some basic HTML tags). The folowing tags are supported:
<A>, <B>, <FONT COLOR>, <FONT FACE>, <FONT SIZE>, <I>, <P>, and <U>.
and the following attributes are supported:
LEFTMARGIN, RIGHTMARGIN, ALIGN, INDENT, and LEADING.
alltough no tab, the LeftMargin and/or Indent attributes will do the trick.

To enable HTML, be sure to use dynamic text, Select the Render Text as HTML button in the Property inspector (Button looks like this: [<>] )
and use the HTML-tags in your dynamicly loaded .txt file.

Hope this is of any help...
__________________
Amerika by Franz Kafka
“As Karl Rossman, a poor boy of sixteen who had been packed off to America by his parents because a servant girl had seduced him and got herself a child by him, stood on the liner slowly entering the harbour of New York, a sudden burst of sunshine seemed to illumine the Statue of Liberty, so that he saw it in a new light, although he had sighted it long before. The arm with the sword rose up as if newly stretched aloft, and round the figure blew the free winds of heaven.”
T.U.B. is offline  
Old 10-05-2004, 04:38 AM   #3 (permalink)
Femme Fatale
 
Nancy's Avatar
 
Location: Elysium
Quote:
Originally Posted by T.U.B.
Hey Nancy,

There are a few (possible) work-arounds for this:
1. you can make textboxes on top of each other. Most people put all there text in just one textbox, but sometimes it is handier (or more beautifull) to make a textbox per paragraph or so. If you want to have the textbox-look you can make a big one without any text for the looks and the paragraph-textboxes (transparant) on top of it.
How will the result be when it's meant for a scrollable text box?
__________________
I have all the characteristics of a human being: blood, flesh, skin, hair; but not a single, clear, identifiable emotion, except for greed and disgust. Something horrible is happening inside of me and I don't know why. My nightly bloodlust has overflown into my days. I feel lethal, on the verge of frenzy.
I think my mask of sanity is about to slip.
Nancy is offline  
Old 10-05-2004, 06:03 AM   #4 (permalink)
Crazy
 
Location: Belgium
Quote:
Originally Posted by Nancy
How will the result be when it's meant for a scrollable text box?
Argh... didn't think of it to be scrollable...
Well, again there is a workaround... but not quite a simple one...
(First rule of programming/scripting/designing: there is always a solution)

I do not know if I make sense if I explain it here, it involves quite a bit of Actionscript and making objects.
I do not know how familiar you are with Flash & Actionscript, if you are, let's go for it. (If you aren't it could be nice first steps, if you have the time)

just to be sure, is it something like this you're making? (but then in flash and scrollable)

Quote:
this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text.
Here comes the numbers!!
506
24549
3
64
this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text. this is a bunch of text.
__________________
Amerika by Franz Kafka
“As Karl Rossman, a poor boy of sixteen who had been packed off to America by his parents because a servant girl had seduced him and got herself a child by him, stood on the liner slowly entering the harbour of New York, a sudden burst of sunshine seemed to illumine the Statue of Liberty, so that he saw it in a new light, although he had sighted it long before. The arm with the sword rose up as if newly stretched aloft, and round the figure blew the free winds of heaven.”
T.U.B. is offline  
Old 10-05-2004, 10:24 AM   #5 (permalink)
Femme Fatale
 
Nancy's Avatar
 
Location: Elysium
Quote:
Originally Posted by T.U.B.
just to be sure, is it something like this you're making? (but then in flash and scrollable)
yes.. sort of. I need this:

http://www.the-numbers.com/index.php as shown below the Daily Chart - Sunday, October 3 part. Perfectly aligned numbers!
__________________
I have all the characteristics of a human being: blood, flesh, skin, hair; but not a single, clear, identifiable emotion, except for greed and disgust. Something horrible is happening inside of me and I don't know why. My nightly bloodlust has overflown into my days. I feel lethal, on the verge of frenzy.
I think my mask of sanity is about to slip.
Nancy is offline  
Old 10-06-2004, 03:04 PM   #6 (permalink)
Crazy
 
Location: Belgium
I made this:
Quote:
Originally Posted by T.U.B.
1. you can make textboxes on top of each other. Most people put all there text in just one textbox, but sometimes it is handier (or more beautifull) to make a textbox per paragraph or so. If you want to have the textbox-look you can make a big one without any text for the looks and the paragraph-textboxes (transparant) on top of it.
and the scrollbars work together.

I made an example for you here:
http://users.skynet.be/fa878553/ForNancy/index.html
the .swf file is here:
http://users.skynet.be/fa878553/ForNancy/Nancy.swf
and I uploaded the .fla source-file for ya:
http://users.skynet.be/fa878553/ForNancy/Nancy.fla

Downside of this is:
The text is static. i.e.: a lot of work when you have to update the numbers.
as usual, there is a solution for this, but I didn't had the time to make it (yet).

The above example works by not using a textbox with scrollbar, but a scrollplane (you can find it in the Flash UI window) instead. Inside this scrollplane I loaded a movieclip (called TextfieldsAllTogether in the example) and in that movieclip I dropped a bunch of textfields that are displaying the text. (push F11 in Flash MX to display the library, and double-click on the movieclip "TextfieldsAllTogether" to view them).

I hope this is a bit helpfull...
__________________
Amerika by Franz Kafka
“As Karl Rossman, a poor boy of sixteen who had been packed off to America by his parents because a servant girl had seduced him and got herself a child by him, stood on the liner slowly entering the harbour of New York, a sudden burst of sunshine seemed to illumine the Statue of Liberty, so that he saw it in a new light, although he had sighted it long before. The arm with the sword rose up as if newly stretched aloft, and round the figure blew the free winds of heaven.”

Last edited by T.U.B.; 10-06-2004 at 03:06 PM..
T.U.B. is offline  
Old 10-06-2004, 10:27 PM   #7 (permalink)
Femme Fatale
 
Nancy's Avatar
 
Location: Elysium
Quote:
Originally Posted by T.U.B.
I made this:

and the scrollbars work together.

I made an example for you here:
http://users.skynet.be/fa878553/ForNancy/index.html
the .swf file is here:
http://users.skynet.be/fa878553/ForNancy/Nancy.swf
and I uploaded the .fla source-file for ya:
http://users.skynet.be/fa878553/ForNancy/Nancy.fla

Downside of this is:
The text is static. i.e.: a lot of work when you have to update the numbers.
as usual, there is a solution for this, but I didn't had the time to make it (yet).

The above example works by not using a textbox with scrollbar, but a scrollplane (you can find it in the Flash UI window) instead. Inside this scrollplane I loaded a movieclip (called TextfieldsAllTogether in the example) and in that movieclip I dropped a bunch of textfields that are displaying the text. (push F11 in Flash MX to display the library, and double-click on the movieclip "TextfieldsAllTogether" to view them).

I hope this is a bit helpfull...
that's exactly how I want it to look like! Thanks so much T.U.B.! *stoked*

I've never used a scrollplane before but I guess this is as good a time as any to give it a try. I hope it'll work!
__________________
I have all the characteristics of a human being: blood, flesh, skin, hair; but not a single, clear, identifiable emotion, except for greed and disgust. Something horrible is happening inside of me and I don't know why. My nightly bloodlust has overflown into my days. I feel lethal, on the verge of frenzy.
I think my mask of sanity is about to slip.
Nancy is offline  
Old 10-07-2004, 02:56 AM   #8 (permalink)
Femme Fatale
 
Nancy's Avatar
 
Location: Elysium
of course it doesn't work *sigh*

I've tried making a new movieclip then naming it cv and then changing the scroll content to "cv" but it doesn't work. I've tried to make a completely new movieclip and scrollpanel but I still can't make it work.
__________________
I have all the characteristics of a human being: blood, flesh, skin, hair; but not a single, clear, identifiable emotion, except for greed and disgust. Something horrible is happening inside of me and I don't know why. My nightly bloodlust has overflown into my days. I feel lethal, on the verge of frenzy.
I think my mask of sanity is about to slip.
Nancy is offline  
Old 10-07-2004, 03:45 AM   #9 (permalink)
Crazy
 
Location: Belgium
Quote:
Originally Posted by Nancy
of course it doesn't work *sigh*

I've tried making a new movieclip then naming it cv and then changing the scroll content to "cv" but it doesn't work. I've tried to make a completely new movieclip and scrollpanel but I still can't make it work.
no problem, I didn't explain that clearly...
The new movieclip you created has to be exported for using with actionscript.
To do that, go to the library and find your movieclip, right click on it, click on properties and then in the 'Linkage' part click "Export for Actionscript" and "Export in first frame" on. As Identifier name I usually take exact the same as the movieclip's name.

Flash is indeed a bit tricky on the naming part. If you want to adress something on Stage, it has to have an "Instance Name", alltough it has a movieclip name. The reason behind this is that you can have multiple copy's (instances) of the same movieclip on stage, all those instances do need a unique name, because their movieclip name is the same.
In the library, things are adressed by their "Identifier" name for the same reason.

Hope it works now...
I learned also a lot with your question. It was quite chalanging to find a solution for this.
If you have anymore questions, keep them coming
__________________
Amerika by Franz Kafka
“As Karl Rossman, a poor boy of sixteen who had been packed off to America by his parents because a servant girl had seduced him and got herself a child by him, stood on the liner slowly entering the harbour of New York, a sudden burst of sunshine seemed to illumine the Statue of Liberty, so that he saw it in a new light, although he had sighted it long before. The arm with the sword rose up as if newly stretched aloft, and round the figure blew the free winds of heaven.”
T.U.B. is offline  
Old 10-07-2004, 04:54 AM   #10 (permalink)
Femme Fatale
 
Nancy's Avatar
 
Location: Elysium
Ooooooooooooo! Well that's a whole other matter! I'll get right on it and see if I can get it work..

thank you for all your help T.U.B! I actually do have another question that's been bugging me for some time now. When ever I make a text box and throw in some text I can't resize it withought the text getting thinner/fatter as well. It's really annoying because so far I'd been forced to CTRL + C all the text, then resize the box and finally throw the text back in. It's sooo annoying
__________________
I have all the characteristics of a human being: blood, flesh, skin, hair; but not a single, clear, identifiable emotion, except for greed and disgust. Something horrible is happening inside of me and I don't know why. My nightly bloodlust has overflown into my days. I feel lethal, on the verge of frenzy.
I think my mask of sanity is about to slip.
Nancy is offline  
Old 10-07-2004, 11:44 AM   #11 (permalink)
Crazy
 
Location: Belgium
Don't know a solution for that either... That is bothering me also...
__________________
Amerika by Franz Kafka
“As Karl Rossman, a poor boy of sixteen who had been packed off to America by his parents because a servant girl had seduced him and got herself a child by him, stood on the liner slowly entering the harbour of New York, a sudden burst of sunshine seemed to illumine the Statue of Liberty, so that he saw it in a new light, although he had sighted it long before. The arm with the sword rose up as if newly stretched aloft, and round the figure blew the free winds of heaven.”
T.U.B. is offline  
Old 10-07-2004, 11:24 PM   #12 (permalink)
Femme Fatale
 
Nancy's Avatar
 
Location: Elysium
Quote:
Originally Posted by T.U.B.
Don't know a solution for that either... That is bothering me also...
what?! there's actually something about Flash you don't know?! I'm ..shocked!
__________________
I have all the characteristics of a human being: blood, flesh, skin, hair; but not a single, clear, identifiable emotion, except for greed and disgust. Something horrible is happening inside of me and I don't know why. My nightly bloodlust has overflown into my days. I feel lethal, on the verge of frenzy.
I think my mask of sanity is about to slip.
Nancy is offline  
Old 10-08-2004, 12:12 AM   #13 (permalink)
Femme Fatale
 
Nancy's Avatar
 
Location: Elysium
woo hoo! It works! Allthough... there are some lines at the top and at the buttom of the scrollpanel and.. the text seems to be bigger than the rest even though it's set for 10 pt.
__________________
I have all the characteristics of a human being: blood, flesh, skin, hair; but not a single, clear, identifiable emotion, except for greed and disgust. Something horrible is happening inside of me and I don't know why. My nightly bloodlust has overflown into my days. I feel lethal, on the verge of frenzy.
I think my mask of sanity is about to slip.
Nancy is offline  
 

Tags
box, flash, tabulators, text

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -8. The time now is 02:32 PM.

Tilted Forum Project

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2020, vBulletin Solutions, Inc.
Search Engine Optimization by vBSEO 3.6.0 PL2
© 2002-2012 Tilted Forum Project

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360