Solved

make a child use stage (_root) coordinates

Posted on 2002-04-10
2
132 Views
Last Modified: 2010-05-18
I'm working on  a quiz interface at: http://dev.ttstrain.com/comp/quiz.swf

After answering a given question a reply is presented with text that explains why the answer is right or wrong. The 'reply' clip holds two children, one for the text itself and one for the brownish color block behind it. (note...3 of the questions there have a sample graphic inside the question...these questions don't have a reply block...ignore 'em);

I'm dynamically controling the background's _height property depending on the number of lines in the text block. But the _y property flucuates depending on the _height value. ... even though I have the reg point at teh top of the clip.

I wanna know how to use the globalToLocal/localToGlobal method(s) to create a stable position for the background. Or I wanna know why I'm too dense to understand why those methods aren't for this sort of situation. I can figure out how to control _y by reversing the calculation that gives me the _height property but I do this sort of thing often enough and it seems like it's time to learn to do it right.

...i'm only starting at 50 in case the answer is 'don't try to use localToGlobal... I've read and tried to reproduce what AS Definitive Guide says...I don't get errors...i just don't get results.

thankx
--steve...

0
Comment
Question by:juststeve
2 Comments
 
LVL 5

Accepted Solution

by:
stef4s earned 50 total points
ID: 6936271
try mc.getBounds this allows you to get absolute positions
0
 
LVL 7

Expert Comment

by:ssdesign
ID: 6976207
have you placed your backgroud graphics, which changes height and width dynamically, at absolute locations?

That means, are the x and y round figures?

if not try by placing the registration point of the clip at rounded X and Y co-ordinates.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

There are times in your Flash CS4 application when you want more than a simple pointer or a hand, and it's hard to find an ideal walk-through to tell you what to do.  I spent a few days recently learning my way around making custom cursors in Flash,…
The last time I worked with Flash and Socket connections was in AS1. A recent project required flash connecting to a Socket, and sending receiving information - we figured it would be easy enough - we all know about the socket policy documents and c…
In this tutorial viewers will learn how to create a basic motion tween animation in Flash Open a new document in Flash: Draw/import an image: Press CTRL + F8 to convert it into a graphic symbol: Select a frame (how long you want the tween to last): …
In this tutorial viewers will learn how to create a basic shape tween animation in Flash including shape hints for smooth animation Open a new document in Flash: Draw a shape: Select another frame (how long you want the tween to be): Right click and…

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

27 Experts available now in Live!

Get 1:1 Help Now