• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 847
  • Last Modified:

Background "exact fit" while parent contents "noscale"

I want to use a background that scales to "exact fit" but then I have a text block centered on the screen that I do not want to scale at all, akin to the HTML embed property "noscale".  The end result should be a background that behaves as if it was given the parameter "exactfit" while the primary contents never scale.

Help please!
0
instill
Asked:
instill
  • 3
  • 3
1 Solution
 
pietertje1983Commented:
you can set the width and height to the stage properties with:
img_mc._height = Stage.height;
img_mc._width = Stage.width;
0
 
instillAuthor Commented:
Thanks for the help pietertje1983, but that doesn't seem to be it.  That or I misunderstood.
0
 
instillAuthor Commented:
This is some non-working actionscript that may better illustrate what I am trying to do:

// LOAD BACKGROUND
var container = createEmptyMovieClip("background", 0);
var loadListener:Object = new Object();
loadListener.onLoadComplete = function(target_mc:MovieClip) {
};
var mcl:MovieClipLoader = new MovieClipLoader();
mc1.scaleMode = "exactfit";
mc1.loadClip("background.swf", container);

// LOAD TEXTBLOCK
var container = createEmptyMovieClip("textblock", 1);
var loadListener:Object = new Object();
loadListener.onLoadComplete = function(target_mc:MovieClip) {
};
var mc2:MovieClipLoader = new MovieClipLoader();
mc2.scaleMode = "showall";
mc2.loadClip("textblock.swf", container);

**THE ABOVE DOES NOT WORK

Help greatly appreciated.  Thanks!!!
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
MontoyaProcess Improvement MgrCommented:
Interesting.

I cannot think of a way to keep contents contained within an mc to not scale while the mc that contains them scales. (I think that is what you're asking).

Clearly, you could try to "cheat" and basically grow/shrink  the inside_mc proportionately to the size of the mc, but that will only take you so far. There would clearly come a point in resizing when that simply would not work right, but its the closest I can think of to your solution.

The only other thing would be loading swf's stacked on each other in html, but you're just asking for trouble there. Is there an effect or functionality you're trying to achieve? I'll send you a link to liquid layout for Flash, but I dont know how much that will be.

It could also be that its too early for me to think straight, because that is how I feel right now. :)

Montoya
0
 
MontoyaProcess Improvement MgrCommented:
0
 
instillAuthor Commented:
Thanks for your help Montoya.  Stacking SWFs just might give me the effect I desire.  I assume I would have to wmode/transparent the textblock content and display it above my background image?  HTML/DHTML for stacking SWFs would be very helpful.  Thanks again.
0
 
MontoyaProcess Improvement MgrCommented:
Glad to be of assistance.

:)


Cheers,
Montoya

0

Featured Post

[Webinar] Cloud and Mobile-First Strategy

Maybe you’ve fully adopted the cloud since the beginning. Or maybe you started with on-prem resources but are pursuing a “cloud and mobile first” strategy. Getting to that end state has its challenges. Discover how to build out a 100% cloud and mobile IT strategy in this webinar.

  • 3
  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now