[Flashcoders] Unicode and shared font

2006-08-17 Thread Pravin Ranjan

Hi,
Im working on a multilingual application. I am using shared fonts. Its
working very fine for english, german, french and chinese[In some fonts].
But now I need for russian and thai language.
Problem is that...when I embed fontstextfield becomes blank for russian
and thaiI ve also used Mario klingmann's technique
quasimondo.com/archives/000211.php
Could anyone explain me or more precisely help me to solve this problem?
DELFLASH
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


RE: [Flashcoders] OT: Flashmaps - anybody used it before?

2006-08-17 Thread Mike Mountain
There's also this free google map component:

http://www.afcomponents.com/map_google/ 

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED] On Behalf 
 Of David Rorex
 Sent: 17 August 2006 04:48
 To: Flashcoders mailing list
 Subject: Re: [Flashcoders] OT: Flashmaps - anybody used it before?
 
 FYI, Yahoo Maps also provides maps in flash, and they have a 
 developer site, and free API and everything. I didn't look at 
 flashmaps much, but they may work for you.
 
 -David R
 
 On 8/16/06, Anggie Bratadinata [EMAIL PROTECTED] wrote:
  One of my prospective clients want to have flash app with 
 US map. My 
  partner found this nice tools, www.flashmaps.com and I'm 
 wondering if 
  you guys have some experience with it.
 
  note:
  this message is cross-posted to Flashnewbie list, hope you 
 wouldn't mind.
 
  --
  Anggie Bratadinata
  Web|Graphic|Flash
  Jl. Raya Langsep 21
  Malang - East Java
  I N D O N E S I A
  http://design.ibshastautama.com
 
  ___
  Flashcoders@chattyfig.figleaf.com
  To change your subscription options or search the archive:
  http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
 
  Brought to you by Fig Leaf Software
  Premier Authorized Adobe Consulting and Training 
  http://www.figleaf.com http://training.figleaf.com
 
 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the archive:
 http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
 
 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training 
 http://www.figleaf.com http://training.figleaf.com
 
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


RE: [Flashcoders] MovieClip loader IE Caching bug

2006-08-17 Thread Mike Mountain
OK I've narrowed it down to when IE is set to never check or
automatic for page update checking in the settings - I can't believe
there's so little information out there on such a serious bug. I had to
completely scrap using the MovieClip Loader, fortunately there's a few
AS2 conversions of qlod which slotted neatly in.

I wonder if flash 9 will have similar problems with its Loader events?

M

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED] On Behalf 
 Of Mike Mountain
 Sent: 16 August 2006 15:58
 To: Flashcoders mailing list
 Subject: [Flashcoders] MovieClip loader IE Caching bug
 
 I don't do too much online work to be honest so I've only 
 just found this out - but I cannot believe Adobe haven't 
 fixed this bug.
 http://livedocs.macromedia.com/flash/8/main/wwhelp/wwhimpl/com
 mon/html/w
 whelp.htm?context=LiveDocs_Partsfile=2538.html
 
 Using listeners for the movieclip loader, events only fire 
 the first time the swf is loaded, if it's cached in ie then 
 the listeners don't fire!
 
 How fundamentally flawed is this!?!
 
 Is their an elegant workaround or do I really have to use the 'old'
 onEnterFrame bytesLoaded v bytesTotal comparision?
 
 OMG Arrgh! Etc.
 
 M
 
 
 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the archive:
 http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
 
 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training 
 http://www.figleaf.com http://training.figleaf.com
 
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Play Sound Backwards or in Slow Motion during RunTime

2006-08-17 Thread Martin Wood

nice, follow the trail and you can get source code for doing audio DSP in flash 
9 :

http://www.flashcodersbrighton.org/wordpress/?p=9

I knew it would work :)

Andy Makely wrote:

On 8/11/06, Helmut Granda [EMAIL PROTECTED] wrote:


Does anyone knows of a technique to play a sound backwards or in Slow
Motion
with AS?

So far this task seems imposible, bt I was wondering if some one would
have
some pointers.

Thanks!
...helmut




Andre Michelle knows how to do it in AS3.
Look at F9:audio/scratch

http://lab.andre-michelle.com/

--
andy makely

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] passing variable through callback function

2006-08-17 Thread eric dolecki

I am going to assume that this[m+i] is a movieclip created/attached
somewhere else. When its attached/created, give it an index number. Then you
can use it later.

this[m+i].indx = i;

//then later in your showImages function...

this[m+i].onPress = function()
{
   var nIndex:Number = this.indx;
   ...







On 8/17/06, ilteris kaplan [EMAIL PROTECTED] wrote:


Hi Everyone,

I am wondering what could be the way to pass an arg through a
callback function like in a scenario below. I really appreciate any
advice on this.


*
function showImages() {
for (var i = 1; i4; i++) {
this[m+i].onPress = function(i) { // passing the value
of i
var obj:Number = i;
opened = !opened;
if (opened) {
this.enabled = false;
trace(opened);
trace(obj); // well this is undefined.
trace(this[img+i]);
this[img+i]._visible = true;
// var tween+i = new Tween(img+i,
_alpha,
mx.transitions.easing.Regular.easeOut, -20, 100, 1.5, true);

} else {
this.enabled = true;
trace(closing);
}
};
}
}



thanks in advance.
ilteris

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


[Flashcoders] Load Order - bottom up / top down - maybe OT?

2006-08-17 Thread Miles Thompson

Never having had any formal Flash training I've wondered ...

Why, when the Load Order in the publishing parameters is set Bottom Up 
does the .swf  compile from top down?

Why is this option even provided?

Probably lost in the mists of Flash history, but if anyone knows why and 
the advantages, I'm all ears.


Regards - Miles Thompson


--
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.1.405 / Virus Database: 268.11.1/421 - Release Date: 8/16/2006


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] OT: Flashmaps - anybody used it before?

2006-08-17 Thread Matthew Ganz
i've been seriously considering using flashmaps for the last couple of 
weeks. a client of ours really likes the transitions from 
national-state-country levels as well as the drawing of the counties on the 
state. i have to say that i really liked it, too. it's a slick looking map 
component, no doubt about it.


i had a couple of conversations with a non-technical sales guy there and he 
was explaining to me what they hand you off after purchasing the component, 
i.e. flas for the points-of-interest icons, xml config files, 
etc...basically how you can change the look and feel of the smaller icons. 
they do not hand over the fla to the map component.


the examples they have in their showcase look real nice but basically once 
you get to the county level there are buttons that launch getURL() actions 
and such...and that's it. for my case, i wanted to seamlessly move from the 
county level to a served map option from s/thing like yahoo, google or the 
like. in that manner, i asked on more than one occassion to speak with one 
of their developers about how extendible their api was and well, that was 
two weeks ago and no one has gotten back to me. i called back three times.


hth, matt.
- Original Message - 
From: Mike Mountain [EMAIL PROTECTED]

To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
Sent: Thursday, August 17, 2006 4:15 AM
Subject: RE: [Flashcoders] OT: Flashmaps - anybody used it before?


There's also this free google map component:

http://www.afcomponents.com/map_google/


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf
Of David Rorex
Sent: 17 August 2006 04:48
To: Flashcoders mailing list
Subject: Re: [Flashcoders] OT: Flashmaps - anybody used it before?

FYI, Yahoo Maps also provides maps in flash, and they have a
developer site, and free API and everything. I didn't look at
flashmaps much, but they may work for you.

-David R

On 8/16/06, Anggie Bratadinata [EMAIL PROTECTED] wrote:
 One of my prospective clients want to have flash app with
US map. My
 partner found this nice tools, www.flashmaps.com and I'm
wondering if
 you guys have some experience with it.

 note:
 this message is cross-posted to Flashnewbie list, hope you
wouldn't mind.

 --
 Anggie Bratadinata
 Web|Graphic|Flash
 Jl. Raya Langsep 21
 Malang - East Java
 I N D O N E S I A
 http://design.ibshastautama.com

 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the archive:
 http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training
 http://www.figleaf.com http://training.figleaf.com

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com 


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


[Flashcoders] Blur background html with flash overlay

2006-08-17 Thread Nick Weekes
Hi all,
 
Im playing with a flash menu that Id like to dynamically show/hide from an
html page.  The overlay is not a problem using DIV and Z depth, but is there
anyway of controlling the parent (background) html in a way similar to the
Flex effect when showing dialog boxes etc, i.e. make the background blur?
 
Or Darken the background or anything really.  Just something that suggests
the menu is now foreground, and the parent html page is background.
 
Thanks,
 
Nick
 
 
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] OT: Flashmaps - anybody used it before?

2006-08-17 Thread Matthew Ganz

i've been seriously considering using flashmaps for the last couple of
weeks. a client of ours really likes the transitions from
national-state-country levels as well as the drawing of the counties on the
state. i have to say that i really liked it, too. it's a slick looking map
component, no doubt about it.

i had a couple of conversations with a non-technical sales guy there and he
was explaining to me what they hand you off after purchasing the component,
i.e. flas for the points-of-interest icons, xml config files,
etc...basically how you can change the look and feel of the smaller icons.
they do not hand over the fla to the map component.

the examples they have in their showcase look real nice but basically once
you get to the county level there are buttons that launch getURL() actions
and such...and that's it. for my case, i wanted to seamlessly move from the
county level to a served map option from s/thing like yahoo, google or the
like. in that manner, i asked on more than one occassion to speak with one
of their developers about how extendible their api was and well, that was
two weeks ago and no one has gotten back to me. i called back three times.

hth, matt.
- Original Message - 
From: Mike Mountain [EMAIL PROTECTED]

To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
Sent: Thursday, August 17, 2006 4:15 AM
Subject: RE: [Flashcoders] OT: Flashmaps - anybody used it before?


There's also this free google map component:

http://www.afcomponents.com/map_google/


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf
Of David Rorex
Sent: 17 August 2006 04:48
To: Flashcoders mailing list
Subject: Re: [Flashcoders] OT: Flashmaps - anybody used it before?

FYI, Yahoo Maps also provides maps in flash, and they have a
developer site, and free API and everything. I didn't look at
flashmaps much, but they may work for you.

-David R

On 8/16/06, Anggie Bratadinata [EMAIL PROTECTED] wrote:
 One of my prospective clients want to have flash app with
US map. My
 partner found this nice tools, www.flashmaps.com and I'm
wondering if
 you guys have some experience with it.

 note:
 this message is cross-posted to Flashnewbie list, hope you
wouldn't mind.

 --
 Anggie Bratadinata
 Web|Graphic|Flash
 Jl. Raya Langsep 21
 Malang - East Java
 I N D O N E S I A
 http://design.ibshastautama.com

 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the archive:
 http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training
 http://www.figleaf.com http://training.figleaf.com

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

- Original Message - 
From: Mike Mountain [EMAIL PROTECTED]

To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
Sent: Thursday, August 17, 2006 4:15 AM
Subject: RE: [Flashcoders] OT: Flashmaps - anybody used it before?


There's also this free google map component:

http://www.afcomponents.com/map_google/


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf
Of David Rorex
Sent: 17 August 2006 04:48
To: Flashcoders mailing list
Subject: Re: [Flashcoders] OT: Flashmaps - anybody used it before?

FYI, Yahoo Maps also provides maps in flash, and they have a
developer site, and free API and everything. I didn't look at
flashmaps much, but they may work for you.

-David R

On 8/16/06, Anggie Bratadinata [EMAIL PROTECTED] wrote:
 One of my prospective clients want to have flash app with
US map. My
 partner found this nice tools, www.flashmaps.com and I'm
wondering if
 you guys have some experience with it.

 note:
 this message is cross-posted to Flashnewbie list, hope you
wouldn't mind.

 --
 Anggie Bratadinata
 Web|Graphic|Flash
 Jl. Raya Langsep 21
 Malang - East Java
 I N D O N E S I A
 http://design.ibshastautama.com

 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the archive:
 http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training
 http://www.figleaf.com http://training.figleaf.com

___

[Flashcoders] How do I make a dynamically created input text box retain text formatting?

2006-08-17 Thread David Sharek

What am I doing wrong here?

  1. Copy the code below into a new Flash file and test it.
  2. The text in teh box should be selected
  3. Try typing in your name
  4. Notice that the text format is lost
  5. How do I make a dynamically created input text box retain text
 formatting?

//create text style
var txt_style1:TextFormat = new TextFormat();
txt_style1.font = arial;
txt_style1.align = left;
txt_style1.bold = true;
txt_style1.size = 40;
txt_style1.color = 0x003366;
//create input text box
this.createTextField(name_txt, this.getNextHighestDepth(), 50, 50, 
500, 100);

name_txt.multiline = false;
name_txt.wordWrap = true;
name_txt.html = false;
name_txt.type = input;
name_txt.text = Enter Your Name;
name_txt.setTextFormat(txt_style1);
Selection.setFocus(name_txt);

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Blur background html with flash overlay

2006-08-17 Thread eric dolecki

I say darken yes, blur no. You don't have the HTML as a bitmap source to
blur, but you could overlay a large semi-transparent mc over the HTML (the
.swf would need to be large enough to accommodate this).

- e.d.

On 8/17/06, Nick Weekes [EMAIL PROTECTED] wrote:


Hi all,

Im playing with a flash menu that Id like to dynamically show/hide from an
html page.  The overlay is not a problem using DIV and Z depth, but is
there
anyway of controlling the parent (background) html in a way similar to the
Flex effect when showing dialog boxes etc, i.e. make the background blur?

Or Darken the background or anything really.  Just something that suggests
the menu is now foreground, and the parent html page is background.

Thanks,

Nick


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] How do I make a dynamically created input text box retain text formatting?

2006-08-17 Thread eric dolecki

I believe all you need to do is to add this line:
name_txt.setNewTextFormat( txt_style1 );

- e.d.

On 8/17/06, David Sharek [EMAIL PROTECTED] wrote:


What am I doing wrong here?

   1. Copy the code below into a new Flash file and test it.
   2. The text in teh box should be selected
   3. Try typing in your name
   4. Notice that the text format is lost
   5. How do I make a dynamically created input text box retain text
  formatting?

//create text style
var txt_style1:TextFormat = new TextFormat();
txt_style1.font = arial;
txt_style1.align = left;
txt_style1.bold = true;
txt_style1.size = 40;
txt_style1.color = 0x003366;
//create input text box
this.createTextField(name_txt, this.getNextHighestDepth(), 50, 50,
500, 100);
name_txt.multiline = false;
name_txt.wordWrap = true;
name_txt.html = false;
name_txt.type = input;
name_txt.text = Enter Your Name;
name_txt.setTextFormat(txt_style1);
Selection.setFocus(name_txt);

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] How do I make a dynamically created input text boxretain text formatting?

2006-08-17 Thread Zeh Fernando

  5. How do I make a dynamically created input text box retain text
 formatting?


Try using .setNewTextFormat(), as .setTextFormat() only sets the current 
(existing) text.



- Zeh 


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


RE: [Flashcoders] Blur background html with flash overlay

2006-08-17 Thread Nick Weekes
Ah yeah of course.  Nice idea Eric, thanks dude. 

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of eric dolecki
Sent: 17 August 2006 16:13
To: Flashcoders mailing list
Subject: Re: [Flashcoders] Blur background html with flash overlay

I say darken yes, blur no. You don't have the HTML as a bitmap source to
blur, but you could overlay a large semi-transparent mc over the HTML (the
.swf would need to be large enough to accommodate this).

- e.d.

On 8/17/06, Nick Weekes [EMAIL PROTECTED] wrote:

 Hi all,

 Im playing with a flash menu that Id like to dynamically show/hide 
 from an html page.  The overlay is not a problem using DIV and Z 
 depth, but is there anyway of controlling the parent (background) html 
 in a way similar to the Flex effect when showing dialog boxes etc, 
 i.e. make the background blur?

 Or Darken the background or anything really.  Just something that 
 suggests the menu is now foreground, and the parent html page is
background.

 Thanks,

 Nick


 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the archive:
 http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training 
 http://www.figleaf.com http://training.figleaf.com

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training http://www.figleaf.com
http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


[Flashcoders] Workaround for loadvars size limitation

2006-08-17 Thread Randy Tinfow
We wrote an app using the loadvars method to send data back and forth to
a database.  The app has been succesful, which means that we are pushing
up against the limitation in the length of an html query string...64KB.


We can't use Flash Remoting in this environment.  Any suggestions on how
to divide the data into multiple query strings so we don't have to
totally rewrite the app?

Thanks,

Randy Tinfow
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


[Flashcoders] Fonts in loaded movieclips

2006-08-17 Thread Michael Bedar
I know that shared fonts have been discussed to death, but I need a  
little clarification on  this:


I have a main movie, with Font symbols in the library, se to export.   
I am loading swf's into that movie.. should existing plain d- 
textfields in the subclips have access to the fonts in the parent  
movie, and if not, should tf's i create after loading?


Thanks
Mike
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


RE: [Flashcoders] Workaround for loadvars size limitation

2006-08-17 Thread Arva, Adrian
You have to write your own packet distribution system so that you can
load a sequence of packets and stitch them together to get your data.
Kind of messy but if you are limited not to use Flash Remoting...

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Randy
Tinfow
Sent: Thursday, August 17, 2006 11:29 AM
To: flashcoders@chattyfig.figleaf.com
Subject: [Flashcoders] Workaround for loadvars size limitation

We wrote an app using the loadvars method to send data back and forth to
a database.  The app has been succesful, which means that we are pushing
up against the limitation in the length of an html query string...64KB.


We can't use Flash Remoting in this environment.  Any suggestions on how
to divide the data into multiple query strings so we don't have to
totally rewrite the app?

Thanks,

Randy Tinfow
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Workaround for loadvars size limitation

2006-08-17 Thread Chris Hill
The limit on a querystring is not 64KB in browsers, its less than that 
in browsers:


http://www.aspfaq.com/show.asp?id=

Anyway, need more information:

Are you using GET or POST? Are you limited to one or the other?

I've found that you can overload the XML object within flash, and write 
arbitrary strings to raw POST data. So its possible that you could 
create a POST querystring using this method, and turn it into variables 
server side. AFAIK if there is a limit on POST in LoadVars, you could 
theoretically use this method to create as long of a querystring as you 
like?




Randy Tinfow wrote:


We wrote an app using the loadvars method to send data back and forth to
a database.  The app has been succesful, which means that we are pushing
up against the limitation in the length of an html query string...64KB.


We can't use Flash Remoting in this environment.  Any suggestions on how
to divide the data into multiple query strings so we don't have to
totally rewrite the app?

Thanks,

Randy Tinfow
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com
 


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


RE: [Flashcoders] MovieClip loader IE Caching bug

2006-08-17 Thread Ryan Potter
I ran into the same problem yesterday.  Just looked all over for an as2
version of qload and I am not coming up with it.  Would you mind posting
a link?

Thanks.

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Mike
Mountain
Sent: Thursday, August 17, 2006 2:29 AM
To: Flashcoders mailing list
Subject: RE: [Flashcoders] MovieClip loader IE Caching bug

OK I've narrowed it down to when IE is set to never check or
automatic for page update checking in the settings - I can't believe
there's so little information out there on such a serious bug. I had to
completely scrap using the MovieClip Loader, fortunately there's a few
AS2 conversions of qlod which slotted neatly in.

I wonder if flash 9 will have similar problems with its Loader events?

M

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED] On Behalf 
 Of Mike Mountain
 Sent: 16 August 2006 15:58
 To: Flashcoders mailing list
 Subject: [Flashcoders] MovieClip loader IE Caching bug
 
 I don't do too much online work to be honest so I've only 
 just found this out - but I cannot believe Adobe haven't 
 fixed this bug.
 http://livedocs.macromedia.com/flash/8/main/wwhelp/wwhimpl/com
 mon/html/w
 whelp.htm?context=LiveDocs_Partsfile=2538.html
 
 Using listeners for the movieclip loader, events only fire 
 the first time the swf is loaded, if it's cached in ie then 
 the listeners don't fire!
 
 How fundamentally flawed is this!?!
 
 Is their an elegant workaround or do I really have to use the 'old'
 onEnterFrame bytesLoaded v bytesTotal comparision?
 
 OMG Arrgh! Etc.
 
 M
 
 
 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the archive:
 http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
 
 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training 
 http://www.figleaf.com http://training.figleaf.com
 
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


[Flashcoders] FlashDevelop telling me Video has no _visible field

2006-08-17 Thread Andreas Rønning

type error Video have no field _visible

What gives?
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] MovieClip loader IE Caching bug

2006-08-17 Thread ben farrell
Does anyone know if this applies to Director hosted content as well?  I 
had a Flash game that was hosted in Director.  It used the movieclip 
loader to load external assets.  When run in flash alone on my desktop, 
it work great.  But then in Director, the events called when it finished 
loading were never firing.  I thought I might have been doing something 
wrong, but maybe it's a bug?


thanks!
ben

Ryan Potter wrote:

I ran into the same problem yesterday.  Just looked all over for an as2
version of qload and I am not coming up with it.  Would you mind posting
a link?

Thanks.

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Mike
Mountain
Sent: Thursday, August 17, 2006 2:29 AM
To: Flashcoders mailing list
Subject: RE: [Flashcoders] MovieClip loader IE Caching bug

OK I've narrowed it down to when IE is set to never check or
automatic for page update checking in the settings - I can't believe
there's so little information out there on such a serious bug. I had to
completely scrap using the MovieClip Loader, fortunately there's a few
AS2 conversions of qlod which slotted neatly in.

I wonder if flash 9 will have similar problems with its Loader events?

M

  

-Original Message-
From: [EMAIL PROTECTED] 
[mailto:[EMAIL PROTECTED] On Behalf 
Of Mike Mountain

Sent: 16 August 2006 15:58
To: Flashcoders mailing list
Subject: [Flashcoders] MovieClip loader IE Caching bug

I don't do too much online work to be honest so I've only 
just found this out - but I cannot believe Adobe haven't 
fixed this bug.

http://livedocs.macromedia.com/flash/8/main/wwhelp/wwhimpl/com
mon/html/w
whelp.htm?context=LiveDocs_Partsfile=2538.html

Using listeners for the movieclip loader, events only fire 
the first time the swf is loaded, if it's cached in ie then 
the listeners don't fire!


How fundamentally flawed is this!?!

Is their an elegant workaround or do I really have to use the 'old'
onEnterFrame bytesLoaded v bytesTotal comparision?

OMG Arrgh! Etc.

M


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training 
http://www.figleaf.com http://training.figleaf.com




___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

  

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Blur background html with flash overlay

2006-08-17 Thread Michel Scoz
or maybe use a javascript to change/replace the body style with another one, 
with a different background... using a preloaded image.


michel.

- Original Message - 
From: eric dolecki [EMAIL PROTECTED]

To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
Sent: Thursday, August 17, 2006 12:12 PM
Subject: Re: [Flashcoders] Blur background html with flash overlay



I say darken yes, blur no. You don't have the HTML as a bitmap source to
blur, but you could overlay a large semi-transparent mc over the HTML (the
.swf would need to be large enough to accommodate this).

- e.d.

On 8/17/06, Nick Weekes [EMAIL PROTECTED] wrote:


Hi all,

Im playing with a flash menu that Id like to dynamically show/hide from 
an

html page.  The overlay is not a problem using DIV and Z depth, but is
there
anyway of controlling the parent (background) html in a way similar to 
the

Flex effect when showing dialog boxes etc, i.e. make the background blur?

Or Darken the background or anything really.  Just something that 
suggests

the menu is now foreground, and the parent html page is background.

Thanks,

Nick


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com



___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


[Flashcoders] Question about __constructor__

2006-08-17 Thread Helmut Granda

Hello,

Could any soul out there help me understand why the __constructor__ and
__proto__ are used in the following code:

class Application {

   public static var instance:Application;

   private function Application(createdBy)
   {
   createdBy.__proto__ = this.__proto__;
   createdBy.__constructor__ = Application;
   this = createdBy;
   }

   public static function main(createdBy:MovieClip){
   if(instance == null)
   instance = new Application(createdBy);
   return instance;
   }
}


//then in the main file

Application.main(this);

For what I undertand this code is used to assign the whole application to
_root but i was looking for a better understanding of constructor and
proto here.

TIA!
...helmut
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Question about __constructor__

2006-08-17 Thread erixtekila

Could any soul out there help me understand why the __constructor__ and
__proto__ are used in the following code:

Check this out :
http://www.quantumwave.com/flash/inheritance.html

And join the rebel alliance :P
(very old private joke, ask others)
---
erixtekila
http://blog.v-i-a.net/

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


[Flashcoders] Help Getting Size of Text Dynamically

2006-08-17 Thread Aaron Roberson

I am creating a dynamic drop down menu using XML and I am having
trouble spacing out each menu item.

Is there a way of determing the size of the text in each xml node?

Thanks for your help,
Aaron

P.S. This menu is based on a tutorial at kirupa.com.

Here is the XML:

?xml version=1.0 encoding=iso-8859-1?
menu name=navigation
item name=Home link=http://whitehorsemedia.com; /
menu name=About Us link=http://whitehorsemedia.com/about/index.cfm;
item name=Our Name 
link=http://whitehorsemedia.com/about/name.cfm; /
item name=News link=http://whitehorsemedia.com/about/news.cfm; 
/
item name=We Believe 
link=http://whitehorsemedia.com/about/believe.cfm; /
item name=Staff 
link=http://whitehorsemedia.com/about/staff.cfm; /
item name=Projects 
link=http://whitehorsemedia.com/about/projects.cfm; /
/menu
/menu

Here is the ActionScript:


// generates a list of menu items (effectively one menu)
// given the inputted parameters.  This makes the main menu
// as well as any of the submenus
GenerateMenu = function(container, name, x, y, depth, node_xml) {
// variable declarations
var curr_node;
var curr_item;
var curr_menu = container.createEmptyMovieClip(name, depth);

// for all items or XML nodes (items and menus)
// within this node_xml passed for this menu
for (var i=0; inode_xml.childNodes.length; i++) {
// movieclip for each menu item
curr_item = curr_menu.attachMovie(menuitem,item+i+_mc, i);
curr_item._x = x + i*curr_item._width;
curr_item._y = y;
curr_item.trackAsMenu = true;

// item properties assigned from XML
curr_node = node_xml.childNodes[i];
curr_item.link = curr_node.attributes.link;
curr_item.name.text = curr_node.attributes.name;

// item submenu behavior for rollover event
if (node_xml.childNodes[i].nodeName == menu){
// open a submenu
curr_item.node_xml = curr_node;
curr_item.onRollOver = curr_item.onDragOver = 
function(){
var x = 200;
var y = this._y + this._height;
GenerateMenu(curr_menu, submenu_mc, x, y, 
1000, this.node_xml);
// show a hover color
var col = new Color(this.background);
col.setRGB(0xf4faff);
};
}else{ // nodeName == item
curr_item.arrow._visible = false;
// close existing submenu
curr_item.onRollOver = curr_item.onDragOver = 
function(){
curr_menu.submenu_mc.removeMovieClip();
// show a hover color
var col = new Color(this.background);
col.setRGB(0xf4faff);
};
}

curr_item.onRollOut = curr_item.onDragOut = function(){
// restore color
var col = new Color(this.background);
col.setTransform({ra:100,rb:0,ga:100,gb:0,ba:100,bb:0});
};

// any item, menu opening or not can have actions
curr_item.onRelease = function(){
Actions[goToURL](this.link);
CloseSubmenus();
};
} // end for loop
};

// create the main menu, this will be constantly visible
CreateMainMenu = function(x, y, depth, menu_xml){
// generate a menu list
GenerateMenu(this, mainmenu_mc, x, y, depth, menu_xml.firstChild);
// close only submenus if visible durring a mouseup
// this main menu (mainmenu_mc) will remain
mainmenu_mc.onMouseUp = function(){
if (mainmenu_mc.submenu_mc  
!mainmenu_mc.hitTest(_root._xmouse,
_root._ymouse, true)){
CloseSubmenus();
}
};
};

// closes all submenus by removing the submenu_mc
// in the main menu (if it exists)
CloseSubmenus = function(){
mainmenu_mc.submenu_mc.removeMovieClip();
};

// This actions object handles methods for actions
// defined by the XML called when a menu item is pressed
Actions = Object();
Actions.gotoURL = function(urlVar){
getURL(urlVar, _blank);
};

// load XML, when done, run CreateMainMenu to interpret it
menu_xml = new XML();
menu_xml.ignoreWhite = true;
menu_xml.onLoad = function(ok){
// create main menu after successful loading of XML
if (ok){
CreateMainMenu(200, 250, 0, 

RE: [Flashcoders] Help Getting Size of Text Dynamically

2006-08-17 Thread Merrill, Jason
XML is actually not relevant to the question here.  Only the text string
you get from it is.  Once the text string is in a TextField, you should
just be able to use the TextField.textWidth property.

Jason Merrill
Bank of America 
Learning  Organization Effectiveness - Technology Solutions 
 
 
 
 
 

-Original Message-
From: [EMAIL PROTECTED] [mailto:flashcoders-
[EMAIL PROTECTED] On Behalf Of Aaron Roberson
Sent: Thursday, August 17, 2006 4:55 PM
To: flashcoders@chattyfig.figleaf.com
Subject: [Flashcoders] Help Getting Size of Text Dynamically

I am creating a dynamic drop down menu using XML and I am having
trouble spacing out each menu item.

Is there a way of determing the size of the text in each xml node?

Thanks for your help,
Aaron

P.S. This menu is based on a tutorial at kirupa.com.

Here is the XML:

?xml version=1.0 encoding=iso-8859-1?
menu name=navigation
  item name=Home link=http://whitehorsemedia.com; /
  menu name=About Us
link=http://whitehorsemedia.com/about/index.cfm;
  item name=Our Name
link=http://whitehorsemedia.com/about/name.cfm; /
  item name=News
link=http://whitehorsemedia.com/about/news.cfm; /
  item name=We Believe
link=http://whitehorsemedia.com/about/believe.cfm; /
  item name=Staff
link=http://whitehorsemedia.com/about/staff.cfm; /
  item name=Projects
link=http://whitehorsemedia.com/about/projects.cfm; /
  /menu
/menu

Here is the ActionScript:


// generates a list of menu items (effectively one menu)
// given the inputted parameters.  This makes the main menu
// as well as any of the submenus
GenerateMenu = function(container, name, x, y, depth, node_xml) {
  // variable declarations
  var curr_node;
  var curr_item;
  var curr_menu = container.createEmptyMovieClip(name, depth);

  // for all items or XML nodes (items and menus)
  // within this node_xml passed for this menu
  for (var i=0; inode_xml.childNodes.length; i++) {
  // movieclip for each menu item
  curr_item =
curr_menu.attachMovie(menuitem,item+i+_mc,
i);
  curr_item._x = x + i*curr_item._width;
  curr_item._y = y;
  curr_item.trackAsMenu = true;

  // item properties assigned from XML
  curr_node = node_xml.childNodes[i];
  curr_item.link = curr_node.attributes.link;
  curr_item.name.text = curr_node.attributes.name;

  // item submenu behavior for rollover event
  if (node_xml.childNodes[i].nodeName == menu){
  // open a submenu
  curr_item.node_xml = curr_node;
  curr_item.onRollOver = curr_item.onDragOver =
function(){
  var x = 200;
  var y = this._y + this._height;
  GenerateMenu(curr_menu, submenu_mc, x,
y,
1000, this.node_xml);
  // show a hover color
  var col = new Color(this.background);
  col.setRGB(0xf4faff);
  };
  }else{ // nodeName == item
  curr_item.arrow._visible = false;
  // close existing submenu
  curr_item.onRollOver = curr_item.onDragOver =
function(){
  curr_menu.submenu_mc.removeMovieClip();
  // show a hover color
  var col = new Color(this.background);
  col.setRGB(0xf4faff);
  };
  }

  curr_item.onRollOut = curr_item.onDragOut = function(){
  // restore color
  var col = new Color(this.background);

col.setTransform({ra:100,rb:0,ga:100,gb:0,ba:100,bb:0});
  };

  // any item, menu opening or not can have actions
  curr_item.onRelease = function(){
  Actions[goToURL](this.link);
  CloseSubmenus();
  };
  } // end for loop
};

// create the main menu, this will be constantly visible
CreateMainMenu = function(x, y, depth, menu_xml){
  // generate a menu list
  GenerateMenu(this, mainmenu_mc, x, y, depth,
menu_xml.firstChild);
  // close only submenus if visible durring a mouseup
  // this main menu (mainmenu_mc) will remain
  mainmenu_mc.onMouseUp = function(){
  if (mainmenu_mc.submenu_mc 
!mainmenu_mc.hitTest(_root._xmouse,
_root._ymouse, true)){
  CloseSubmenus();
  }
  };
};

// closes all submenus by removing the submenu_mc
// in the main menu (if it exists)
CloseSubmenus = function(){
  mainmenu_mc.submenu_mc.removeMovieClip();
};

// This actions object handles methods for actions
// defined by the XML called when a menu item is pressed
Actions = Object();

Re: [Flashcoders] Help Getting Size of Text Dynamically

2006-08-17 Thread Aaron Roberson

I'm half way there...

I figured out how to resize the movie clip based on the length of the
text being loaded from the name attribute of the xml node. I added the
following line to my code:

curr_item.name.autoSize = left;

Now I need to figure out how to make the spacing between each menu
item 15px. Sounds simple, and is for others, but now that each movie
clip is a different size I'm not sure how to do that. Any help on that
would be appreciated!

-Aaron

On 8/17/06, Elena Blanco [EMAIL PROTECTED] wrote:

By size, are you referring to the length of the text (in this case the
name?)

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Aaron
Roberson
Sent: Thursday, August 17, 2006 1:55 PM
To: flashcoders@chattyfig.figleaf.com
Subject: [Flashcoders] Help Getting Size of Text Dynamically

I am creating a dynamic drop down menu using XML and I am having
trouble spacing out each menu item.

Is there a way of determing the size of the text in each xml node?

Thanks for your help,
Aaron

P.S. This menu is based on a tutorial at kirupa.com.

Here is the XML:

?xml version=1.0 encoding=iso-8859-1?
menu name=navigation
item name=Home link=http://whitehorsemedia.com; /
menu name=About Us
link=http://whitehorsemedia.com/about/index.cfm;
item name=Our Name
link=http://whitehorsemedia.com/about/name.cfm; /
item name=News
link=http://whitehorsemedia.com/about/news.cfm; /
item name=We Believe
link=http://whitehorsemedia.com/about/believe.cfm; /
item name=Staff
link=http://whitehorsemedia.com/about/staff.cfm; /
item name=Projects
link=http://whitehorsemedia.com/about/projects.cfm; /
/menu
/menu

Here is the ActionScript:


// generates a list of menu items (effectively one menu)
// given the inputted parameters.  This makes the main menu
// as well as any of the submenus
GenerateMenu = function(container, name, x, y, depth, node_xml) {
// variable declarations
var curr_node;
var curr_item;
var curr_menu = container.createEmptyMovieClip(name, depth);

// for all items or XML nodes (items and menus)
// within this node_xml passed for this menu
for (var i=0; inode_xml.childNodes.length; i++) {
// movieclip for each menu item
curr_item = curr_menu.attachMovie(menuitem,item+i+_mc,
i);
curr_item._x = x + i*curr_item._width;
curr_item._y = y;
curr_item.trackAsMenu = true;

// item properties assigned from XML
curr_node = node_xml.childNodes[i];
curr_item.link = curr_node.attributes.link;
curr_item.name.text = curr_node.attributes.name;

// item submenu behavior for rollover event
if (node_xml.childNodes[i].nodeName == menu){
// open a submenu
curr_item.node_xml = curr_node;
curr_item.onRollOver = curr_item.onDragOver =
function(){
var x = 200;
var y = this._y + this._height;
GenerateMenu(curr_menu, submenu_mc, x, y,
1000, this.node_xml);
// show a hover color
var col = new Color(this.background);
col.setRGB(0xf4faff);
};
}else{ // nodeName == item
curr_item.arrow._visible = false;
// close existing submenu
curr_item.onRollOver = curr_item.onDragOver =
function(){
curr_menu.submenu_mc.removeMovieClip();
// show a hover color
var col = new Color(this.background);
col.setRGB(0xf4faff);
};
}

curr_item.onRollOut = curr_item.onDragOut = function(){
// restore color
var col = new Color(this.background);

col.setTransform({ra:100,rb:0,ga:100,gb:0,ba:100,bb:0});
};

// any item, menu opening or not can have actions
curr_item.onRelease = function(){
Actions[goToURL](this.link);
CloseSubmenus();
};
} // end for loop
};

// create the main menu, this will be constantly visible
CreateMainMenu = function(x, y, depth, menu_xml){
// generate a menu list
GenerateMenu(this, mainmenu_mc, x, y, depth, menu_xml.firstChild);
// close only submenus if visible durring a mouseup
// this main menu (mainmenu_mc) will remain
mainmenu_mc.onMouseUp = function(){
if (mainmenu_mc.submenu_mc 

Re: [Flashcoders] Help Getting Size of Text Dynamically

2006-08-17 Thread Aaron Roberson

Jason,

I used textfield.autoSize = left which seems to fix half of my
problem. Maybe I can use textfield.textWidth to fix the other half -
which is to get the menu items to be evenly spaced from one another
and not spaced on a static value.

I post back...

Aaron

P.S. That textfield is name.

On 8/17/06, Merrill, Jason [EMAIL PROTECTED] wrote:

XML is actually not relevant to the question here.  Only the text string
you get from it is.  Once the text string is in a TextField, you should
just be able to use the TextField.textWidth property.

Jason Merrill
Bank of America
Learning  Organization Effectiveness - Technology Solutions






-Original Message-
From: [EMAIL PROTECTED] [mailto:flashcoders-
[EMAIL PROTECTED] On Behalf Of Aaron Roberson
Sent: Thursday, August 17, 2006 4:55 PM
To: flashcoders@chattyfig.figleaf.com
Subject: [Flashcoders] Help Getting Size of Text Dynamically

I am creating a dynamic drop down menu using XML and I am having
trouble spacing out each menu item.

Is there a way of determing the size of the text in each xml node?

Thanks for your help,
Aaron

P.S. This menu is based on a tutorial at kirupa.com.

Here is the XML:

?xml version=1.0 encoding=iso-8859-1?
menu name=navigation
  item name=Home link=http://whitehorsemedia.com; /
  menu name=About Us
link=http://whitehorsemedia.com/about/index.cfm;
  item name=Our Name
link=http://whitehorsemedia.com/about/name.cfm; /
  item name=News
link=http://whitehorsemedia.com/about/news.cfm; /
  item name=We Believe
link=http://whitehorsemedia.com/about/believe.cfm; /
  item name=Staff
link=http://whitehorsemedia.com/about/staff.cfm; /
  item name=Projects
link=http://whitehorsemedia.com/about/projects.cfm; /
  /menu
/menu

Here is the ActionScript:


// generates a list of menu items (effectively one menu)
// given the inputted parameters.  This makes the main menu
// as well as any of the submenus
GenerateMenu = function(container, name, x, y, depth, node_xml) {
  // variable declarations
  var curr_node;
  var curr_item;
  var curr_menu = container.createEmptyMovieClip(name, depth);

  // for all items or XML nodes (items and menus)
  // within this node_xml passed for this menu
  for (var i=0; inode_xml.childNodes.length; i++) {
  // movieclip for each menu item
  curr_item =
curr_menu.attachMovie(menuitem,item+i+_mc,
i);
  curr_item._x = x + i*curr_item._width;
  curr_item._y = y;
  curr_item.trackAsMenu = true;

  // item properties assigned from XML
  curr_node = node_xml.childNodes[i];
  curr_item.link = curr_node.attributes.link;
  curr_item.name.text = curr_node.attributes.name;

  // item submenu behavior for rollover event
  if (node_xml.childNodes[i].nodeName == menu){
  // open a submenu
  curr_item.node_xml = curr_node;
  curr_item.onRollOver = curr_item.onDragOver =
function(){
  var x = 200;
  var y = this._y + this._height;
  GenerateMenu(curr_menu, submenu_mc, x,
y,
1000, this.node_xml);
  // show a hover color
  var col = new Color(this.background);
  col.setRGB(0xf4faff);
  };
  }else{ // nodeName == item
  curr_item.arrow._visible = false;
  // close existing submenu
  curr_item.onRollOver = curr_item.onDragOver =
function(){
  curr_menu.submenu_mc.removeMovieClip();
  // show a hover color
  var col = new Color(this.background);
  col.setRGB(0xf4faff);
  };
  }

  curr_item.onRollOut = curr_item.onDragOut = function(){
  // restore color
  var col = new Color(this.background);

col.setTransform({ra:100,rb:0,ga:100,gb:0,ba:100,bb:0});
  };

  // any item, menu opening or not can have actions
  curr_item.onRelease = function(){
  Actions[goToURL](this.link);
  CloseSubmenus();
  };
  } // end for loop
};

// create the main menu, this will be constantly visible
CreateMainMenu = function(x, y, depth, menu_xml){
  // generate a menu list
  GenerateMenu(this, mainmenu_mc, x, y, depth,
menu_xml.firstChild);
  // close only submenus if visible durring a mouseup
  // this main menu (mainmenu_mc) will remain
  mainmenu_mc.onMouseUp = function(){
  if (mainmenu_mc.submenu_mc 
!mainmenu_mc.hitTest(_root._xmouse,
_root._ymouse, true)){
  

Re: [Flashcoders] Help Getting Size of Text Dynamically

2006-08-17 Thread Aaron Roberson

Elena,

Option 2 is exactly the track I am currently taking!

I am having a hard time adjusting the width of the movie clip based on
the length of the text after setting it to auto size. Can you help?

Here is my code:

for (var i=0; inode_xml.childNodes.length; i++) {
// movieclip for each menu item
curr_item = curr_menu.attachMovie(menuitem,item+i+_mc, i);
curr_item.name.autoSize = left;
curr_item._width = curr_item.name.textWidth;
curr_item._x = x + i*curr_item._width;
curr_item._y = y;
curr_item.trackAsMenu = true;
// truncated

Thanks,
Aaron

P.S. Option #2 is:

quoteYou could set autosize = true for the dynamic text field, then retrieve
the length of the text field once populated with the text, the adjust the
width of the movie clip based on it.. all on the fly./quote


On 8/17/06, Elena Blanco [EMAIL PROTECTED] wrote:

A couple of ideas that pop in my mind

1. You can store the name in a temporary string and get the length of it
with string.length - then change the width of the movie clip accordingly
2. You could set autosize = true for the dynamic text field, then retrieve
the length of the text field once populated with the text, the adjust the
width of the movie clip based on it.. all on the fly.

Let me know if any helps!

ELENA BLANCO
Blancomedia
WEB APPLICATION ARCHITECT
920 HULL STREET
HOOD RIVER, OR 97031
p: 541.490.4993
e: [EMAIL PROTECTED]
w: http://www.blancomedia.com


-Original Message-
From: Aaron Roberson [mailto:[EMAIL PROTECTED]
Sent: Thursday, August 17, 2006 2:13 PM
To: [EMAIL PROTECTED]
Subject: Re: [Flashcoders] Help Getting Size of Text Dynamically

Yes, I am referring to the length of the text in the name attribute of
the xml nodes.

The script is creating a new movie clip based on an existing movie
clip in the library. The movie clip in the library (menuitem) has an a
movie clip (arrow) and a dynamic text field (name). When the script
creates the new movie clips for each menu item, instead of making them
the width of the text, they are the width of the movie clip in the
library. The width of the movie clip in the library is based on the
text inside, which makes me think that I could change the width of the
generated movie clips based on the text loaded from xml.

I hope that makes sense!

On 8/17/06, Elena Blanco [EMAIL PROTECTED] wrote:
 By size, are you referring to the length of the text (in this case the
 name?)

 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED] On Behalf Of Aaron
 Roberson
 Sent: Thursday, August 17, 2006 1:55 PM
 To: flashcoders@chattyfig.figleaf.com
 Subject: [Flashcoders] Help Getting Size of Text Dynamically

 I am creating a dynamic drop down menu using XML and I am having
 trouble spacing out each menu item.

 Is there a way of determing the size of the text in each xml node?

 Thanks for your help,
 Aaron

 P.S. This menu is based on a tutorial at kirupa.com.

 Here is the XML:

 ?xml version=1.0 encoding=iso-8859-1?
 menu name=navigation
 item name=Home link=http://whitehorsemedia.com; /
 menu name=About Us
 link=http://whitehorsemedia.com/about/index.cfm;
 item name=Our Name
 link=http://whitehorsemedia.com/about/name.cfm; /
 item name=News
 link=http://whitehorsemedia.com/about/news.cfm; /
 item name=We Believe
 link=http://whitehorsemedia.com/about/believe.cfm; /
 item name=Staff
 link=http://whitehorsemedia.com/about/staff.cfm; /
 item name=Projects
 link=http://whitehorsemedia.com/about/projects.cfm; /
 /menu
 /menu

 Here is the ActionScript:


 // generates a list of menu items (effectively one menu)
 // given the inputted parameters.  This makes the main menu
 // as well as any of the submenus
 GenerateMenu = function(container, name, x, y, depth, node_xml) {
 // variable declarations
 var curr_node;
 var curr_item;
 var curr_menu = container.createEmptyMovieClip(name, depth);

 // for all items or XML nodes (items and menus)
 // within this node_xml passed for this menu
 for (var i=0; inode_xml.childNodes.length; i++) {
 // movieclip for each menu item
 curr_item =
curr_menu.attachMovie(menuitem,item+i+_mc,
 i);
 curr_item._x = x + i*curr_item._width;
 curr_item._y = y;
 curr_item.trackAsMenu = true;

 // item properties assigned from XML
 curr_node = node_xml.childNodes[i];
 curr_item.link = curr_node.attributes.link;
 curr_item.name.text = curr_node.attributes.name;

 // item submenu behavior for rollover event
 if (node_xml.childNodes[i].nodeName == menu){
 // open a submenu
 curr_item.node_xml = curr_node;
 curr_item.onRollOver = curr_item.onDragOver =
 function(){
  

Re: [Flashcoders] Help Getting Size of Text Dynamically

2006-08-17 Thread Aaron Roberson

Elena,

Option 2 is exactly the track I am currently taking!

I am having a hard time adjusting the width of the movie clip based on
the length of the text after setting it to auto size. Can you help?

Here is my code:

for (var i=0; inode_xml.childNodes.length; i++) {
// movieclip for each menu item
curr_item = curr_menu.attachMovie(menuitem,item+i+_mc, i);
curr_item.name.autoSize = left;
curr_item._width = curr_item.name.textWidth;
curr_item._x = x + i*curr_item._width;
curr_item._y = y;
curr_item.trackAsMenu = true;
// truncated

Thanks,
Aaron

P.S. Option #2 is:

quoteYou could set autosize = true for the dynamic text field, then retrieve
the length of the text field once populated with the text, the adjust the
width of the movie clip based on it.. all on the fly./quote

On 8/17/06, Elena Blanco [EMAIL PROTECTED] wrote:

A couple of ideas that pop in my mind

1. You can store the name in a temporary string and get the length of it
with string.length - then change the width of the movie clip accordingly
2. You could set autosize = true for the dynamic text field, then retrieve
the length of the text field once populated with the text, the adjust the
width of the movie clip based on it.. all on the fly.

Let me know if any helps!

ELENA BLANCO
Blancomedia
WEB APPLICATION ARCHITECT
920 HULL STREET
HOOD RIVER, OR 97031
p: 541.490.4993
e: [EMAIL PROTECTED]
w: http://www.blancomedia.com

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Blur background html with flash overlay

2006-08-17 Thread Maximilian Reuss

you could also implement a use of the lightbox Javascript.
http://www.huddletogether.com/projects/lightbox/
this places an layer above the content.

max



am Donnerstag, 17. August 2006 um 21:14 schrieben Sie:

 or maybe use a javascript to change/replace the body style with another one,
 with a different background... using a preloaded image.

 michel.

 - Original Message - 
 From: eric dolecki [EMAIL PROTECTED]
 To: Flashcoders mailing list flashcoders@chattyfig.figleaf.com
 Sent: Thursday, August 17, 2006 12:12 PM
 Subject: Re: [Flashcoders] Blur background html with flash overlay


I say darken yes, blur no. You don't have the HTML as a bitmap source to
 blur, but you could overlay a large semi-transparent mc over the HTML (the
 .swf would need to be large enough to accommodate this).

 - e.d.

 On 8/17/06, Nick Weekes [EMAIL PROTECTED] wrote:

 Hi all,

 Im playing with a flash menu that Id like to dynamically show/hide from
 an
 html page.  The overlay is not a problem using DIV and Z depth, but is
 there
 anyway of controlling the parent (background) html in a way similar to
 the
 Flex effect when showing dialog boxes etc, i.e. make the background blur?

 Or Darken the background or anything really.  Just something that 
 suggests
 the menu is now foreground, and the parent html page is background.

 Thanks,

 Nick


 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the archive:
 http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training
 http://www.figleaf.com
 http://training.figleaf.com

 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the archive:
 http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training
 http://www.figleaf.com
 http://training.figleaf.com
 

 ___
 Flashcoders@chattyfig.figleaf.com
 To change your subscription options or search the archive:
 http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

 Brought to you by Fig Leaf Software
 Premier Authorized Adobe Consulting and Training
 http://www.figleaf.com
 http://training.figleaf.com





___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Help Getting Size of Text Dynamically

2006-08-17 Thread John VanHorn

there are many ways to do the spacing. if your mc is sized after the width
of the textfield, just add the witdh of the mc to its _x plus the 15px for
spacing to get the _x of the next mc.

On 8/17/06, Aaron Roberson [EMAIL PROTECTED] wrote:


I'm half way there...

I figured out how to resize the movie clip based on the length of the
text being loaded from the name attribute of the xml node. I added the
following line to my code:

curr_item.name.autoSize = left;

Now I need to figure out how to make the spacing between each menu
item 15px. Sounds simple, and is for others, but now that each movie
clip is a different size I'm not sure how to do that. Any help on that
would be appreciated!

-Aaron

On 8/17/06, Elena Blanco [EMAIL PROTECTED] wrote:
 By size, are you referring to the length of the text (in this case the
 name?)

 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED] On Behalf Of Aaron
 Roberson
 Sent: Thursday, August 17, 2006 1:55 PM
 To: flashcoders@chattyfig.figleaf.com
 Subject: [Flashcoders] Help Getting Size of Text Dynamically

 I am creating a dynamic drop down menu using XML and I am having
 trouble spacing out each menu item.

 Is there a way of determing the size of the text in each xml node?

 Thanks for your help,
 Aaron

 P.S. This menu is based on a tutorial at kirupa.com.

 Here is the XML:

 ?xml version=1.0 encoding=iso-8859-1?
 menu name=navigation
 item name=Home link=http://whitehorsemedia.com; /
 menu name=About Us
 link=http://whitehorsemedia.com/about/index.cfm;
 item name=Our Name
 link=http://whitehorsemedia.com/about/name.cfm; /
 item name=News
 link=http://whitehorsemedia.com/about/news.cfm; /
 item name=We Believe
 link=http://whitehorsemedia.com/about/believe.cfm; /
 item name=Staff
 link=http://whitehorsemedia.com/about/staff.cfm; /
 item name=Projects
 link=http://whitehorsemedia.com/about/projects.cfm; /
 /menu
 /menu

 Here is the ActionScript:


 // generates a list of menu items (effectively one menu)
 // given the inputted parameters.  This makes the main menu
 // as well as any of the submenus
 GenerateMenu = function(container, name, x, y, depth, node_xml) {
 // variable declarations
 var curr_node;
 var curr_item;
 var curr_menu = container.createEmptyMovieClip(name, depth);

 // for all items or XML nodes (items and menus)
 // within this node_xml passed for this menu
 for (var i=0; inode_xml.childNodes.length; i++) {
 // movieclip for each menu item
 curr_item =
curr_menu.attachMovie(menuitem,item+i+_mc,
 i);
 curr_item._x = x + i*curr_item._width;
 curr_item._y = y;
 curr_item.trackAsMenu = true;

 // item properties assigned from XML
 curr_node = node_xml.childNodes[i];
 curr_item.link = curr_node.attributes.link;
 curr_item.name.text = curr_node.attributes.name;

 // item submenu behavior for rollover event
 if (node_xml.childNodes[i].nodeName == menu){
 // open a submenu
 curr_item.node_xml = curr_node;
 curr_item.onRollOver = curr_item.onDragOver =
 function(){
 var x = 200;
 var y = this._y + this._height;
 GenerateMenu(curr_menu, submenu_mc, x,
y,
 1000, this.node_xml);
 // show a hover color
 var col = new Color(this.background);
 col.setRGB(0xf4faff);
 };
 }else{ // nodeName == item
 curr_item.arrow._visible = false;
 // close existing submenu
 curr_item.onRollOver = curr_item.onDragOver =
 function(){
 curr_menu.submenu_mc.removeMovieClip();
 // show a hover color
 var col = new Color(this.background);
 col.setRGB(0xf4faff);
 };
 }

 curr_item.onRollOut = curr_item.onDragOut = function(){
 // restore color
 var col = new Color(this.background);

 col.setTransform({ra:100,rb:0,ga:100,gb:0,ba:100,bb:0});
 };

 // any item, menu opening or not can have actions
 curr_item.onRelease = function(){
 Actions[goToURL](this.link);
 CloseSubmenus();
 };
 } // end for loop
 };

 // create the main menu, this will be constantly visible
 CreateMainMenu = function(x, y, depth, menu_xml){

Re: [Flashcoders] Help Getting Size of Text Dynamically

2006-08-17 Thread Aaron Roberson

John,

That is what I am trying to do but it's not working for some reason.
Can you detect any problem or give me a suggestion with the following
code:

for (var i=0; inode_xml.childNodes.length; i++) {
  // movieclip for each menu item
  curr_item = curr_menu.attachMovie(menuitem,item+i+_mc, i);
  //set text field to auto size with left alignment
  curr_item.name.autoSize = left;
  curr_item.trackAsMenu = true;

  // item properties assigned from XML
  curr_node = node_xml.childNodes[i];
  curr_item.link = curr_node.attributes.link;
  curr_item.name.text = curr_node.attributes.name;

  // set movie clip width to the width of the text loaded from xml
  curr_item._width = curr_item.name.textWidth;
  // set x coordinate to the coordinate passed in times
the width of the movie clip
  curr_item._x = x + i*curr_item._width;
  curr_item._y = y;

Thanks,
Aaron

On 8/17/06, John VanHorn [EMAIL PROTECTED] wrote:

there are many ways to do the spacing. if your mc is sized after the width
of the textfield, just add the witdh of the mc to its _x plus the 15px for
spacing to get the _x of the next mc.

On 8/17/06, Aaron Roberson [EMAIL PROTECTED] wrote:

 I'm half way there...

 I figured out how to resize the movie clip based on the length of the
 text being loaded from the name attribute of the xml node. I added the
 following line to my code:

 curr_item.name.autoSize = left;

 Now I need to figure out how to make the spacing between each menu
 item 15px. Sounds simple, and is for others, but now that each movie
 clip is a different size I'm not sure how to do that. Any help on that
 would be appreciated!

 -Aaron

 On 8/17/06, Elena Blanco [EMAIL PROTECTED] wrote:
  By size, are you referring to the length of the text (in this case the
  name?)
 
  -Original Message-
  From: [EMAIL PROTECTED]
  [mailto:[EMAIL PROTECTED] On Behalf Of Aaron
  Roberson
  Sent: Thursday, August 17, 2006 1:55 PM
  To: flashcoders@chattyfig.figleaf.com
  Subject: [Flashcoders] Help Getting Size of Text Dynamically
 
  I am creating a dynamic drop down menu using XML and I am having
  trouble spacing out each menu item.
 
  Is there a way of determing the size of the text in each xml node?
 
  Thanks for your help,
  Aaron
 
  P.S. This menu is based on a tutorial at kirupa.com.
 
  Here is the XML:
 
  ?xml version=1.0 encoding=iso-8859-1?
  menu name=navigation
  item name=Home link=http://whitehorsemedia.com; /
  menu name=About Us
  link=http://whitehorsemedia.com/about/index.cfm;
  item name=Our Name
  link=http://whitehorsemedia.com/about/name.cfm; /
  item name=News
  link=http://whitehorsemedia.com/about/news.cfm; /
  item name=We Believe
  link=http://whitehorsemedia.com/about/believe.cfm; /
  item name=Staff
  link=http://whitehorsemedia.com/about/staff.cfm; /
  item name=Projects
  link=http://whitehorsemedia.com/about/projects.cfm; /
  /menu
  /menu
 
  Here is the ActionScript:
 
 
  // generates a list of menu items (effectively one menu)
  // given the inputted parameters.  This makes the main menu
  // as well as any of the submenus
  GenerateMenu = function(container, name, x, y, depth, node_xml) {
  // variable declarations
  var curr_node;
  var curr_item;
  var curr_menu = container.createEmptyMovieClip(name, depth);
 
  // for all items or XML nodes (items and menus)
  // within this node_xml passed for this menu
  for (var i=0; inode_xml.childNodes.length; i++) {
  // movieclip for each menu item
  curr_item =
 curr_menu.attachMovie(menuitem,item+i+_mc,
  i);
  curr_item._x = x + i*curr_item._width;
  curr_item._y = y;
  curr_item.trackAsMenu = true;
 
  // item properties assigned from XML
  curr_node = node_xml.childNodes[i];
  curr_item.link = curr_node.attributes.link;
  curr_item.name.text = curr_node.attributes.name;
 
  // item submenu behavior for rollover event
  if (node_xml.childNodes[i].nodeName == menu){
  // open a submenu
  curr_item.node_xml = curr_node;
  curr_item.onRollOver = curr_item.onDragOver =
  function(){
  var x = 200;
  var y = this._y + this._height;
  GenerateMenu(curr_menu, submenu_mc, x,
 y,
  1000, this.node_xml);
  // show a hover color
  var col = new Color(this.background);
  col.setRGB(0xf4faff);
  

RE: [Flashcoders] Help Getting Size of Text Dynamically

2006-08-17 Thread Ryan Potter
Hey Aaron.  The problem that I can see is that you are setting the x to
the x of the current item, hence you are setting it to its own width.
If you are trying to space them across the screen horizontally you need
to get the x and width of the last clip.  Another way to do it is to get
the width of the container clip and use that.  This only works if the
container only contains the nav items.  

Option 1:

// get the last clip (i-1)
last_item = curr_menu[item+i-1+_mc];
last_x = last_item._x;
last_width = ast_item._width;

// set the x to the last item x plus the last item width
curr_item._x = last_x + last_width;


Option 2:
// set the x to the width of the container
curr_item._x = curr_menu._width;


Option 3:

// Set a fixed width
curr_item._x = i*100;


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Aaron
Roberson
Sent: Thursday, August 17, 2006 4:23 PM
To: Flashcoders mailing list
Subject: Re: [Flashcoders] Help Getting Size of Text Dynamically

John,

That is what I am trying to do but it's not working for some reason.
Can you detect any problem or give me a suggestion with the following
code:

for (var i=0; inode_xml.childNodes.length; i++) {
   // movieclip for each menu item
   curr_item =
curr_menu.attachMovie(menuitem,item+i+_mc, i);
   //set text field to auto size with left alignment
   curr_item.name.autoSize = left;
   curr_item.trackAsMenu = true;

   // item properties assigned from XML
   curr_node = node_xml.childNodes[i];
   curr_item.link = curr_node.attributes.link;
   curr_item.name.text = curr_node.attributes.name;

   // set movie clip width to the width of the text loaded
from xml
   curr_item._width = curr_item.name.textWidth;
   // set x coordinate to the coordinate passed in times
the width of the movie clip
   curr_item._x = x + i*curr_item._width;
   curr_item._y = y;

Thanks,
Aaron

On 8/17/06, John VanHorn [EMAIL PROTECTED] wrote:
 there are many ways to do the spacing. if your mc is sized after the
width
 of the textfield, just add the witdh of the mc to its _x plus the 15px
for
 spacing to get the _x of the next mc.

 On 8/17/06, Aaron Roberson [EMAIL PROTECTED] wrote:
 
  I'm half way there...
 
  I figured out how to resize the movie clip based on the length of
the
  text being loaded from the name attribute of the xml node. I added
the
  following line to my code:
 
  curr_item.name.autoSize = left;
 
  Now I need to figure out how to make the spacing between each menu
  item 15px. Sounds simple, and is for others, but now that each movie
  clip is a different size I'm not sure how to do that. Any help on
that
  would be appreciated!
 
  -Aaron
 
  On 8/17/06, Elena Blanco [EMAIL PROTECTED] wrote:
   By size, are you referring to the length of the text (in this case
the
   name?)
  
   -Original Message-
   From: [EMAIL PROTECTED]
   [mailto:[EMAIL PROTECTED] On Behalf Of
Aaron
   Roberson
   Sent: Thursday, August 17, 2006 1:55 PM
   To: flashcoders@chattyfig.figleaf.com
   Subject: [Flashcoders] Help Getting Size of Text Dynamically
  
   I am creating a dynamic drop down menu using XML and I am having
   trouble spacing out each menu item.
  
   Is there a way of determing the size of the text in each xml node?
  
   Thanks for your help,
   Aaron
  
   P.S. This menu is based on a tutorial at kirupa.com.
  
   Here is the XML:
  
   ?xml version=1.0 encoding=iso-8859-1?
   menu name=navigation
   item name=Home link=http://whitehorsemedia.com; /
   menu name=About Us
   link=http://whitehorsemedia.com/about/index.cfm;
   item name=Our Name
   link=http://whitehorsemedia.com/about/name.cfm; /
   item name=News
   link=http://whitehorsemedia.com/about/news.cfm; /
   item name=We Believe
   link=http://whitehorsemedia.com/about/believe.cfm; /
   item name=Staff
   link=http://whitehorsemedia.com/about/staff.cfm; /
   item name=Projects
   link=http://whitehorsemedia.com/about/projects.cfm; /
   /menu
   /menu
  
   Here is the ActionScript:
  
  
   // generates a list of menu items (effectively one menu)
   // given the inputted parameters.  This makes the main menu
   // as well as any of the submenus
   GenerateMenu = function(container, name, x, y, depth, node_xml) {
   // variable declarations
   var curr_node;
   var curr_item;
   var curr_menu = container.createEmptyMovieClip(name,
depth);
  
   // for all items or XML nodes (items and menus)
   // within this node_xml passed for this menu
   for (var i=0; inode_xml.childNodes.length; i++) {
   // movieclip for each menu item
   curr_item =
  curr_menu.attachMovie(menuitem,item+i+_mc,
   i);
 

Re: [Flashcoders] Help Getting Size of Text Dynamically

2006-08-17 Thread Aaron Roberson

Ryan,

I went with option number 1 and it is working like a champ. I did
change one little thing:

last_item = curr_menu[item+i-1+_mc];

to

last_item = curr_menu[item+(i-1)+_mc];

But it works wonderfully now. Thank you all for your help!

-Aaron

On 8/17/06, Ryan Potter [EMAIL PROTECTED] wrote:

Hey Aaron.  The problem that I can see is that you are setting the x to
the x of the current item, hence you are setting it to its own width.
If you are trying to space them across the screen horizontally you need
to get the x and width of the last clip.  Another way to do it is to get
the width of the container clip and use that.  This only works if the
container only contains the nav items.

Option 1:

// get the last clip (i-1)
last_item = curr_menu[item+i-1+_mc];
last_x = last_item._x;
last_width = ast_item._width;

// set the x to the last item x plus the last item width
curr_item._x = last_x + last_width;


Option 2:
// set the x to the width of the container
curr_item._x = curr_menu._width;


Option 3:

// Set a fixed width
curr_item._x = i*100;


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Aaron
Roberson
Sent: Thursday, August 17, 2006 4:23 PM
To: Flashcoders mailing list
Subject: Re: [Flashcoders] Help Getting Size of Text Dynamically

John,

That is what I am trying to do but it's not working for some reason.
Can you detect any problem or give me a suggestion with the following
code:

for (var i=0; inode_xml.childNodes.length; i++) {
   // movieclip for each menu item
   curr_item =
curr_menu.attachMovie(menuitem,item+i+_mc, i);
   //set text field to auto size with left alignment
   curr_item.name.autoSize = left;
   curr_item.trackAsMenu = true;

   // item properties assigned from XML
   curr_node = node_xml.childNodes[i];
   curr_item.link = curr_node.attributes.link;
   curr_item.name.text = curr_node.attributes.name;

   // set movie clip width to the width of the text loaded
from xml
   curr_item._width = curr_item.name.textWidth;
   // set x coordinate to the coordinate passed in times
the width of the movie clip
   curr_item._x = x + i*curr_item._width;
   curr_item._y = y;

Thanks,
Aaron

On 8/17/06, John VanHorn [EMAIL PROTECTED] wrote:
 there are many ways to do the spacing. if your mc is sized after the
width
 of the textfield, just add the witdh of the mc to its _x plus the 15px
for
 spacing to get the _x of the next mc.

 On 8/17/06, Aaron Roberson [EMAIL PROTECTED] wrote:
 
  I'm half way there...
 
  I figured out how to resize the movie clip based on the length of
the
  text being loaded from the name attribute of the xml node. I added
the
  following line to my code:
 
  curr_item.name.autoSize = left;
 
  Now I need to figure out how to make the spacing between each menu
  item 15px. Sounds simple, and is for others, but now that each movie
  clip is a different size I'm not sure how to do that. Any help on
that
  would be appreciated!
 
  -Aaron
 
  On 8/17/06, Elena Blanco [EMAIL PROTECTED] wrote:
   By size, are you referring to the length of the text (in this case
the
   name?)
  
   -Original Message-
   From: [EMAIL PROTECTED]
   [mailto:[EMAIL PROTECTED] On Behalf Of
Aaron
   Roberson
   Sent: Thursday, August 17, 2006 1:55 PM
   To: flashcoders@chattyfig.figleaf.com
   Subject: [Flashcoders] Help Getting Size of Text Dynamically
  
   I am creating a dynamic drop down menu using XML and I am having
   trouble spacing out each menu item.
  
   Is there a way of determing the size of the text in each xml node?
  
   Thanks for your help,
   Aaron
  
   P.S. This menu is based on a tutorial at kirupa.com.
  
   Here is the XML:
  
   ?xml version=1.0 encoding=iso-8859-1?
   menu name=navigation
   item name=Home link=http://whitehorsemedia.com; /
   menu name=About Us
   link=http://whitehorsemedia.com/about/index.cfm;
   item name=Our Name
   link=http://whitehorsemedia.com/about/name.cfm; /
   item name=News
   link=http://whitehorsemedia.com/about/news.cfm; /
   item name=We Believe
   link=http://whitehorsemedia.com/about/believe.cfm; /
   item name=Staff
   link=http://whitehorsemedia.com/about/staff.cfm; /
   item name=Projects
   link=http://whitehorsemedia.com/about/projects.cfm; /
   /menu
   /menu
  
   Here is the ActionScript:
  
  
   // generates a list of menu items (effectively one menu)
   // given the inputted parameters.  This makes the main menu
   // as well as any of the submenus
   GenerateMenu = function(container, name, x, y, depth, node_xml) {
   // variable declarations
   var curr_node;
   var curr_item;
   var curr_menu = container.createEmptyMovieClip(name,
depth);
  
   // for all items 

[Flashcoders] Flash 7,8,9 , AS 2 and 3 - clarify the situation

2006-08-17 Thread GregoryN
Hello Flashcoders,

I'm a bit confused with waterfall of all these new terms :-).
Can't find all answers at the Adobe site so far...

As far as I can judge, current Flash version is 8, but
- on product and Version Penetration pages it's 8
- latest Flash Player offered is v.9
- you're discussing AS3 and even Flash 9 IDE here in the list

So, can anyone clarify the current situation with Flash versions?
What about expected in the nearest future (till the end of 2006)?

Please excuse me if this question seems dumb for you.


-- 
Best regards,
 GregoryN

http://GOusable.com
Flash components development.
Usability services.

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Flash 7,8,9 , AS 2 and 3 - clarify the situation

2006-08-17 Thread Claus Wahlers

Gregory,

The latest Flash IDE is the Flash 8 IDE.

The latest Flash Player is Flash Player 9.

The Flash 9 IDE is currently in public alpha test, and can be downloaded 
from http://labs.adobe.com/ (You need a valid Flash 8 IDE serial number 
to run it though). The new IDE is expected to be released early 2007 as 
far as i heard, and supports AS3 as well as AS1 and 2.


Then there is Flex Builder 2 and the Flex 2 SDK, which were released 
recently.


The Flex 2 SDK is free, you can download it from the Adobe site. It 
contains the Flex 2 framework, AS3 and MXML commandline compilers and a 
commandline debugger.


The Flex Builder 2 is an Eclipse based IDE that allows you to develop in 
AS3 and in MXML (or a combination thereof). Both can't be used to 
develop in AS1 and 2.


Flex Builder 2 and the Flex 2 SDK tend to target software developers, 
whereas the Flash 9 IDE tends to target designers (allthough the line is 
becoming blurry).


Cheers,
Claus.

ps: seems labs.adobe.com is down at the moment, or is it just me?


GregoryN wrote:


Hello Flashcoders,

I'm a bit confused with waterfall of all these new terms :-).
Can't find all answers at the Adobe site so far...

As far as I can judge, current Flash version is 8, but
- on product and Version Penetration pages it's 8
- latest Flash Player offered is v.9
- you're discussing AS3 and even Flash 9 IDE here in the list

So, can anyone clarify the current situation with Flash versions?
What about expected in the nearest future (till the end of 2006)?

Please excuse me if this question seems dumb for you.


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com