I have been searching forum, tutorials and under tables for weeks on this one but still no joy, perhaps someone out there can help, or perhaps there is some sort of conspiricy to keep it from me.
I wish to dynamically resize my movie to fit the entire browser window. This in itself is of coarse no problem, but I do not want the contents of my movie to scale with it. I have found one Javascript resource for this but it causes the Flash content to centre when I require it to align where I choose.
This style of resizing is becoming more and more popular, expecially with the advent of interesting math interactivity, yet there seems to be no information floating arounf the net about how its done.
Does anyone have a suggestion, tutorial or some sourcecode on this???
// Set the scaling behavior of the movie
Stage.scaleMode = “noScale”;
Stage.align = “LT”;
// Create the first text field
this.createTextField(“title_txt”, 1, 0, 0, 180, 20);
title_txt.text = “Welcome to my website.”;
title_txt.border = true;
// Assign its listener callback function
title_txt.onResize = function ( ) {
this._x = Stage.width/2 - this._width/2;
this._y = Stage.height/2 - this._height/2;
}
// Create the second text field
this.createTextField(“subtitle_txt”, 2, 0, 0, 180, 20);
subtitle_txt.text = “Thanks for visiting.”;
subtitle_txt.border = true;
// Assign its listener callback function
subtitle_txt.onResize = function ( ) {
this._x = Stage.width/2 - this._width/2;
this._y = (Stage.height/2) + (title_txt._height/2) + 10;
}
// Register the text fields as Stage listeners
Stage.addListener(subtitle_txt);
Stage.addListener(title_txt);
from Colin Mook’s book
make a new movie , put this code on the first frame and the under publish settings make the move ocupy 100% height and 100% width
the result will be two textbars centered on the movie when you resize it
i have a problem (off topic)… when i want to modify the width of a line that is 1px thick , the thickness seemes to be modifing two , WHY ??