learn more...You want to control how a movie fits in the Player, including the scaling. Use the Stage.scaleMode property. The Flash Player defaults to a scale mode of "showAll" (except the test Player, which defaults to "noScale"). In "showAll" mode, the Flash movie scales to fit the Player while maintaining the movie's original aspect ratio. The result is that the movie can have borders on the sides if the Player aspect ratio does not match the movie aspect ratio. You can set a movie to "showAll" mode, as follows: Stage.scaleMode = "showAll"; The "noBorder" mode scales a movie to fit the Player while maintaining the original aspect ratio, but it forces the Player to display no borders around the Stage. If the aspect ratio of the Player does not match that of the movie, some of the movie will be cut off around the edges. You can set a movie to "noBorder" mode, as follows: Stage.scaleMode = "noBorder"; The "exactFit" mode scales a movie to fit the Player and alters the movie's aspect ratio, if necessary, to match that of the Player. The result is that the movie always exactly fills the Player, but the elements of the movie may be distorted. For example: Stage.scaleMode = "exactFit"; In "noScale" mode, the movie is not scaled, and it maintains its original size and aspect ratio regardless of the Stage's size. When you use the "noScale" mode, also set the movie's alignment. For example: Stage.scaleMode = "noScale"; The scaleMode property's value does not prevent the user from being able to scale the movie using the right-click/Ctrl-click menu. However, you can disable those options in the menu |
||||||
Disclaimer
1) E-articles is not responsible for the information contained by this article as well for any and all copyright infringements by authors and writers. E-articles is a free information resource. If you suspect this article for any copyright infringement, please read the terms of service and contact us to investigate the problem.
2) E-articles is not responsible for inaccuracies, falsehoods, or any other types of misinformation this article may contain and will not be liable for any loss or damage suffered by a user through the user's reliance on the information gained here. link to this article |