all groups > flash (macromedia) > april 2007 >
You're in the

flash (macromedia)

group:

Anyone know how to...



Anyone know how to... patrick garner
4/23/2007 8:23:42 PM
flash (macromedia): I am trying to learn how to create a site ithat no matter the size of browser
window the bottom and or side navigation smoothly adjust its self to fit in the
window.
I'm sorry, If you do not understand what I'm saying. here is an example
http://www.sfc.org.sg/main.html When you open the site adjust your window size
and you will see what I mean.

If anyone knows where there is a good tutorial or thread, please let me know.
It will be much appreciated.
Re: Anyone know how to... playz123
4/23/2007 11:07:19 PM
In the Publish Settings dialogue, select the HTML tab, and in the Dimensions
box select Percent. Then set width and height to 100 x 100. Keep in mind though
that this type of scaling can sometimes cause problems with the clarity of
bitmap images. Vector images, of course, will always be okay............frank
Re: Anyone know how to... patrick garner
4/24/2007 3:51:00 AM
That's not exactly what I was asking. If you go to the link I posted earlier
you will see that none of the images scale differently they rather just adjust
their position to fit in the window. Check it out and get back to me.
Re: Anyone know how to... mikeapolis
4/24/2007 4:15:59 AM
I'd actually like to know how to do this too. In html to make a site adapt to
different window sizes you simply use tables with a percentage as their size.
You can then use background images for different cells that tile as the table
size changes.

Is there a way to make a flash movie tile (maintaining its original size) just
like a normal background image on an html page?
Re: Anyone know how to... scotparker
4/25/2007 10:32:13 PM
Try using the below code in the first frame of your movie. Make a MC
(scaleable_mc) and put it on the bottom layer. This movie clip will stretch and
fill the browser at 100%. Since it will scale, do not use bitmaps. Add a square
of a color of your choice in the clip. Your other clips will not scale and will
stay in the center of the browser no matter how the user resizes it. Make sure
your publishing settings are diminsions 100% and scale is set to no scale. You
might have to add the marginwidth="0" marginheight="0" topmargin="0"
leftmargin="0" to the body tag.


_root.onLoad = stageResize();
Stage.scaleMode = "noScale";

function stageResize() {
scaleable_mc._width = Stage.width;
scaleable_mc._height = Stage.height;
}

myListener = new Object();
myListener.onResize = function() {
stageResize();
}
Stage.addListener(myListener);
Re: Anyone know how to... patrick garner
4/26/2007 2:24:35 PM
Re: Anyone know how to... parkeast
4/26/2007 3:56:22 PM
Yes, the script that [b]scotparker[/b] posted out is how to do it. You can do
that with every movieclip you have on the stage though... so things can float
in the center...

movieclip._x = Stage.width / 2;
movieclip._y = Stage.height / 2;

...be locked to the bottom of the screen...

movieclip._y = Stage.height;

Or any number of other options.

If you visit our site and view some of our work you'll see we do this sort of
thing a lot... as well as the 100% by 100% stuff that [b]playz123[/b] suggested.
Re: Anyone know how to... jo29
8/30/2007 4:18:18 AM
My dilemma is when I want the background image, to be top left and when
resizing the browser window to resize but to the image size. Not show the
stage background. And any nav bars weather up, middle, down stay in it's
dimensions(no stretching or distortion)
Can someone help me please?
AddThis Social Bookmark Button