nonopolarity
nonopolarity

Reputation: 150996

How to scale any Flash object using HTML or flashvars?

I tried many Flash .swf before and they all can be scaled freely -- by using a width and height in the HTML, and sometimes in the URL params or flashvars. But is it true that all Flash object can be scaled? For example, can some Flash objects using absolute coordinates to plot graph so that every 10 pixels it marks 1, 2, 3, 4, 5, and no matter what is done at the HTML or any where else, it just won't scale and the browser can't do anything about it either? Is there a way to scale it to half the size for that graph? (that is, 1, 2, 3, 4, 5 is separated by 5 pixels instead of 10 pixels)

Upvotes: 0

Views: 3766

Answers (1)

longstaff
longstaff

Reputation: 2051

have a look at the scaleMode property here:livedocs

NO_SCALE is to keep the proportions (eg it will always be 10px) SHOW_ALL shows everything with scaling while keeping ratio, NO_BORDER crops to size with ratio EXACT_FIT disregards the ratio and stretches it.

this can be assigned either in the actionscript itself (stage.scaleMode) or through the html flashvars

might be worth having a look at the align property while you are at it.

Upvotes: 1

Related Questions