You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@flex.apache.org by Scott Matheson <sm...@intralinks.com> on 2013/04/12 17:10:08 UTC

Application Scale

Hi
    Not sure if this is the correct place, I will ask anyway

In my Main.mxml  I have a simple code

 this.scaleX  = this.scaleX – 0.1
 this.scaleY = this,scaleY –0.1

This works fine for the main container, but not the Application, so I end up with scroll bars

How do I scale the application not the first container

Scott


________________________________

Disclaimer: This electronic mail and any attachments are confidential and may be privileged. If you are not the intended recipient, please notify the sender immediately by replying to this email, and destroy all copies of this email and any attachments. Thank you.

Re: Application Scale

Posted by jude <fl...@gmail.com>.
We had a similar solution. We created a Group that is a child of the
application. This allows us to have different applications but thesame
main group. The reason is we can then use different CSS style sheets
for different application targets.

Then in the application resize we check for the minimum width:


	protected function application1_resizeHandler(event:ResizeEvent):void
	{
		resizeApplication();
	}

	protected function resizeApplication():void {
		if (!systemManager) return;
		
		var visibleWidth:Number = systemManager.getVisibleApplicationRect().width;
		var visibleHeight:Number = systemManager.getVisibleApplicationRect().height;
		
		// if the visible area is less than our content then scale down
		if (visibleHeight < ApplicationModel.APPLICATION_MIN_HEIGHT ||
			visibleWidth < ApplicationModel.APPLICATION_MIN_WIDTH) {
			var smallestScale:Number =
Math.min(visibleHeight/ApplicationModel.APPLICATION_MIN_HEIGHT,
visibleWidth/ApplicationModel.APPLICATION_MIN_WIDTH);
			parentGroup.scaleX = smallestScale;
			parentGroup.scaleY = smallestScale;
		}
		
		else {
			parentGroup.scaleY = 1;
			parentGroup.scaleX = 1;
		}
	}


On Fri, Apr 12, 2013 at 1:18 PM, atauri <da...@gmail.com> wrote:
> Hi, I am using the following function, and it works like a charm to me.
> First I designed the interface for 1280*800 (using phtoshop) and then
> positioned the elements in pixels (no anchors, or relative position). It
> scales great to any phone, tablet even desktop. Hope it helps.
>
>                 //escalar al dispositivo (se diseñó para 1280*800)
>                 xScaleFactor=this.width/1280;
>                 yScaleFactor=this.height/800;
>                 ScaleFactor=Math.min(xScaleFactor,yScaleFactor);
>
>                 trace("ancho del dispositivo:
> "+FlexGlobals.topLevelApplication.width);
>                 trace("dpi del dispositivo:
> "+FlexGlobals.topLevelApplication.applicationDPI);
>                 trace("scalar por "+ ScaleFactor);
>
>                 //scalar para el dispositivo
>                 FlexGlobals.topLevelApplication.scaleX=ScaleFactor
>                 FlexGlobals.topLevelApplication.scaleY=ScaleFactor;
>
>

Re: Application Scale

Posted by atauri <da...@gmail.com>.
Hi Angelo, the function goes in the app xml, the ini fuction.  import
mx.core.FlexGlobals;

<s:ViewNavigatorApplication xmlns:fx="http://ns.adobe.com/mxml/2009"
                            xmlns:s="library://ns.adobe.com/flex/spark"
                            firstView="views.videoView"

                            backgroundColor="#000000"
                            width="1280"
                            height="800"
                            xmlns:myClasses="myClasses.*"
                            initialize="ini()"
                            >
    then my interface (views.videoView") looks like

<s:VideoDisplay id="v" left="0" top="0" width="1280" height="800"
                    currentTimeChange="v_currentTimeChangeHandler(event)"
depth="0" enabled="true"
                    opaqueBackground="#000000"
touchBegin="activarSubNativo()"/>

    <s:HGroup id="hbNat" x="100" y="20" width="1080" height="208"
horizontalAlign="center">
        <s:RichText id="txSubNativo" left="25" right="25" top="15"
width="700" height="196"
                    color="#F7FC6E" depth="3" fontSize="20" paddingTop="10"
                    text="Subtitulo Nativo" textAlign="center"
verticalAlign="top" click="goFullScreen(event)"/>
    </s:HGroup>

all sizes in pixels.
I used photoshop to draw an d position elements and measure distances in
pixels.
Good luck


2013/4/12 Angelo Lazzari <la...@gmail.com>

> Hi all,
> david, one question, did you do a jpg? And where did you put the code you
> wrote?
>
> Thx?
>
> Sent from my 
>
> On Apr 12, 2013, at 20:18, atauri <da...@gmail.com> wrote:
>
> > Hi, I am using the following function, and it works like a charm to me.
> > First I designed the interface for 1280*800 (using phtoshop) and then
> > positioned the elements in pixels (no anchors, or relative position). It
> > scales great to any phone, tablet even desktop. Hope it helps.
> >
> >                //escalar al dispositivo (se diseñó para 1280*800)
> >                xScaleFactor=this.width/1280;
> >                yScaleFactor=this.height/800;
> >                ScaleFactor=Math.min(xScaleFactor,yScaleFactor);
> >
> >                trace("ancho del dispositivo:
> > "+FlexGlobals.topLevelApplication.width);
> >                trace("dpi del dispositivo:
> > "+FlexGlobals.topLevelApplication.applicationDPI);
> >                trace("scalar por "+ ScaleFactor);
> >
> >                //scalar para el dispositivo
> >                FlexGlobals.topLevelApplication.scaleX=ScaleFactor
> >                FlexGlobals.topLevelApplication.scaleY=ScaleFactor;
> >
> >
> > 2013/4/12 Alex Harui <ah...@adobe.com>
> >
> >>
> >>
> >>
> >> On 4/12/13 10:07 AM, "Scott Matheson" <sm...@intralinks.com> wrote:
> >>
> >>> Hi
> >>>   Some good points, we are developing for 1024 x 768,  as most screen
> >> are
> >>> larger than this, however with the browser URL etc on some devices you
> >> end
> >>> up with score bars, all graphics are vectors so we think these will
> scale
> >>> well, that¹s what our limited testing has shown, the screen are very
> >>> simple with lost of space, so we could scale the design down
> >> If you scale too far, fonts will get too small to read.  But in general,
> >> scaling causes lines/edges that were on pixel boundaries to no longer
> be on
> >> pixel boundaries and then anti-aliasing kicks in and the colors change
> or
> >> edges look fuzzy.  Quite frankly, I never notice unless told to look,
> but
> >> some folks have a sensitivity to this sort of thing.
> >>>
> >>> This was a v3 app we upgraded, to V4 I also implemented a Main and
> >> AppBase
> >>> class, looks like I may not have updated all mx: to S;
> >>>
> >>> Should is change the base imports ?
> >> I think Flex 4 has different scaling behavior than Flex 3, and Spark
> does
> >> not show scrollbars by default, so probably worth trying.
> >>
> ===========================================================================
> >>> =
> >>>
> >>> AppBase.AS
> >>>
> >>>
> >>> package baseclasses
> >>> {
> >>>        import com.peach.uofs.services.LoadCenters;
> >>>
> >>>
> >>>        import flash.events.IEventDispatcher;
> >>>
> >>>
> >>>        import mx.core.Application;
> >>>        import mx.core.FlexGlobals;
> >>>        import mx.events.FlexEvent;
> >>>        import mx.events.StyleEvent;
> >>>        import mx.styles.IStyleManager2;
> >>>
> >>>
> >>>
> >>>        public class AppBase extends Application
> >>
> ===========================================================================
> >>> ==
> >>>
> >>> Main.mxml
> >>> <?xml version="1.0" encoding="utf-8"?>
> >>> <baseclasses:AppBase
> >>>            layout="absolute"
> >>>                xmlns:fx="http://ns.adobe.com/mxml/2009"
> >>>                xmlns:mx="library://ns.adobe.com/flex/mx"
> >>>                xmlns:s="library://ns.adobe.com/flex/spark"
> >>>            xmlns:baseclasses="baseclasses.*"
> >>>            xmlns:components="com.peach.uofs.components.*"
> >>>                xmlns:skins="skins.*"
> >>>            creationComplete="init()"  >
> >>>
> >>>
> >>>        <fx:Style source="main.css"/>
> >>>
> >>>
> >>>
> >>>
> >>>
> >>>
> >>>
> >>>
> >>>
> >>> On 4/12/13 5:12 PM, "Alex Harui" <ah...@adobe.com> wrote:
> >>>
> >>>> Is this mx:Application or s:Application?
> >>>>
> >>>> Why are you trying to adjust the scale?  I would think that would make
> >>>> your
> >>>> app look a bit "fuzzy" as things won't be on pixel boundaries.  You
> >> might
> >>>> be
> >>>> better off with a main container offset within the application.
> >>>>
> >>>> If the main container isn't also "shrinkable", that might be what
> causes
> >>>> the
> >>>> scroll bars.
> >>>>
> >>>>
> >>>> On 4/12/13 8:10 AM, "Scott Matheson" <sm...@intralinks.com>
> wrote:
> >>>>
> >>>>> Hi
> >>>>>    Not sure if this is the correct place, I will ask anyway
> >>>>>
> >>>>> In my Main.mxml  I have a simple code
> >>>>>
> >>>>> this.scaleX  = this.scaleX ­ 0.1
> >>>>> this.scaleY = this,scaleY ­0.1
> >>>>>
> >>>>> This works fine for the main container, but not the Application, so I
> >>>>> end up
> >>>>> with scroll bars
> >>>>>
> >>>>> How do I scale the application not the first container
> >>>>>
> >>>>> Scott
> >>>>>
> >>>>>
> >>>>> ________________________________
> >>>>>
> >>>>> Disclaimer: This electronic mail and any attachments are confidential
> >>>>> and may
> >>>>> be privileged. If you are not the intended recipient, please notify
> the
> >>>>> sender
> >>>>> immediately by replying to this email, and destroy all copies of this
> >>>>> email
> >>>>> and any attachments. Thank you.
> >>>>
> >>>> --
> >>>> Alex Harui
> >>>> Flex SDK Team
> >>>> Adobe Systems, Inc.
> >>>> http://blogs.adobe.com/aharui
> >>>
> >>>
> >>> ________________________________
> >>>
> >>> Disclaimer: This electronic mail and any attachments are confidential
> >> and may
> >>> be privileged. If you are not the intended recipient, please notify the
> >> sender
> >>> immediately by replying to this email, and destroy all copies of this
> >> email
> >>> and any attachments. Thank you.
> >>
> >> --
> >> Alex Harui
> >> Flex SDK Team
> >> Adobe Systems, Inc.
> >> http://blogs.adobe.com/aharui
> >
> >
> > --
> > ¿ Te gustan las *Abejas* y la *Tecnología* ? Sígueme en
> > Twitter<http://twitter.com/apilink><http://twitter.com/apilink>
> >
> >  (\__/)
> >  (='.'=)   This is Bunny. Copy and paste bunny into your
> >  (")_(")   signature to help him gain world domination.
>



-- 
 ¿ Te gustan las *Abejas* y la *Tecnología* ? Sígueme en
Twitter<http://twitter.com/apilink><http://twitter.com/apilink>

  (\__/)
  (='.'=)   This is Bunny. Copy and paste bunny into your
  (")_(")   signature to help him gain world domination.

Re: Application Scale

Posted by Angelo Lazzari <la...@gmail.com>.
Hi all, 
david, one question, did you do a jpg? And where did you put the code you wrote?

Thx?

Sent from my 

On Apr 12, 2013, at 20:18, atauri <da...@gmail.com> wrote:

> Hi, I am using the following function, and it works like a charm to me.
> First I designed the interface for 1280*800 (using phtoshop) and then
> positioned the elements in pixels (no anchors, or relative position). It
> scales great to any phone, tablet even desktop. Hope it helps.
> 
>                //escalar al dispositivo (se diseñó para 1280*800)
>                xScaleFactor=this.width/1280;
>                yScaleFactor=this.height/800;
>                ScaleFactor=Math.min(xScaleFactor,yScaleFactor);
> 
>                trace("ancho del dispositivo:
> "+FlexGlobals.topLevelApplication.width);
>                trace("dpi del dispositivo:
> "+FlexGlobals.topLevelApplication.applicationDPI);
>                trace("scalar por "+ ScaleFactor);
> 
>                //scalar para el dispositivo
>                FlexGlobals.topLevelApplication.scaleX=ScaleFactor
>                FlexGlobals.topLevelApplication.scaleY=ScaleFactor;
> 
> 
> 2013/4/12 Alex Harui <ah...@adobe.com>
> 
>> 
>> 
>> 
>> On 4/12/13 10:07 AM, "Scott Matheson" <sm...@intralinks.com> wrote:
>> 
>>> Hi
>>>   Some good points, we are developing for 1024 x 768,  as most screen
>> are
>>> larger than this, however with the browser URL etc on some devices you
>> end
>>> up with score bars, all graphics are vectors so we think these will scale
>>> well, that¹s what our limited testing has shown, the screen are very
>>> simple with lost of space, so we could scale the design down
>> If you scale too far, fonts will get too small to read.  But in general,
>> scaling causes lines/edges that were on pixel boundaries to no longer be on
>> pixel boundaries and then anti-aliasing kicks in and the colors change or
>> edges look fuzzy.  Quite frankly, I never notice unless told to look, but
>> some folks have a sensitivity to this sort of thing.
>>> 
>>> This was a v3 app we upgraded, to V4 I also implemented a Main and
>> AppBase
>>> class, looks like I may not have updated all mx: to S;
>>> 
>>> Should is change the base imports ?
>> I think Flex 4 has different scaling behavior than Flex 3, and Spark does
>> not show scrollbars by default, so probably worth trying.
>> ===========================================================================
>>> =
>>> 
>>> AppBase.AS
>>> 
>>> 
>>> package baseclasses
>>> {
>>>        import com.peach.uofs.services.LoadCenters;
>>> 
>>> 
>>>        import flash.events.IEventDispatcher;
>>> 
>>> 
>>>        import mx.core.Application;
>>>        import mx.core.FlexGlobals;
>>>        import mx.events.FlexEvent;
>>>        import mx.events.StyleEvent;
>>>        import mx.styles.IStyleManager2;
>>> 
>>> 
>>> 
>>>        public class AppBase extends Application
>> ===========================================================================
>>> ==
>>> 
>>> Main.mxml
>>> <?xml version="1.0" encoding="utf-8"?>
>>> <baseclasses:AppBase
>>>            layout="absolute"
>>>                xmlns:fx="http://ns.adobe.com/mxml/2009"
>>>                xmlns:mx="library://ns.adobe.com/flex/mx"
>>>                xmlns:s="library://ns.adobe.com/flex/spark"
>>>            xmlns:baseclasses="baseclasses.*"
>>>            xmlns:components="com.peach.uofs.components.*"
>>>                xmlns:skins="skins.*"
>>>            creationComplete="init()"  >
>>> 
>>> 
>>>        <fx:Style source="main.css"/>
>>> 
>>> 
>>> 
>>> 
>>> 
>>> 
>>> 
>>> 
>>> 
>>> On 4/12/13 5:12 PM, "Alex Harui" <ah...@adobe.com> wrote:
>>> 
>>>> Is this mx:Application or s:Application?
>>>> 
>>>> Why are you trying to adjust the scale?  I would think that would make
>>>> your
>>>> app look a bit "fuzzy" as things won't be on pixel boundaries.  You
>> might
>>>> be
>>>> better off with a main container offset within the application.
>>>> 
>>>> If the main container isn't also "shrinkable", that might be what causes
>>>> the
>>>> scroll bars.
>>>> 
>>>> 
>>>> On 4/12/13 8:10 AM, "Scott Matheson" <sm...@intralinks.com> wrote:
>>>> 
>>>>> Hi
>>>>>    Not sure if this is the correct place, I will ask anyway
>>>>> 
>>>>> In my Main.mxml  I have a simple code
>>>>> 
>>>>> this.scaleX  = this.scaleX ­ 0.1
>>>>> this.scaleY = this,scaleY ­0.1
>>>>> 
>>>>> This works fine for the main container, but not the Application, so I
>>>>> end up
>>>>> with scroll bars
>>>>> 
>>>>> How do I scale the application not the first container
>>>>> 
>>>>> Scott
>>>>> 
>>>>> 
>>>>> ________________________________
>>>>> 
>>>>> Disclaimer: This electronic mail and any attachments are confidential
>>>>> and may
>>>>> be privileged. If you are not the intended recipient, please notify the
>>>>> sender
>>>>> immediately by replying to this email, and destroy all copies of this
>>>>> email
>>>>> and any attachments. Thank you.
>>>> 
>>>> --
>>>> Alex Harui
>>>> Flex SDK Team
>>>> Adobe Systems, Inc.
>>>> http://blogs.adobe.com/aharui
>>> 
>>> 
>>> ________________________________
>>> 
>>> Disclaimer: This electronic mail and any attachments are confidential
>> and may
>>> be privileged. If you are not the intended recipient, please notify the
>> sender
>>> immediately by replying to this email, and destroy all copies of this
>> email
>>> and any attachments. Thank you.
>> 
>> --
>> Alex Harui
>> Flex SDK Team
>> Adobe Systems, Inc.
>> http://blogs.adobe.com/aharui
> 
> 
> -- 
> ¿ Te gustan las *Abejas* y la *Tecnología* ? Sígueme en
> Twitter<http://twitter.com/apilink><http://twitter.com/apilink>
> 
>  (\__/)
>  (='.'=)   This is Bunny. Copy and paste bunny into your
>  (")_(")   signature to help him gain world domination.

Re: Application Scale

Posted by atauri <da...@gmail.com>.
Hi, I am using the following function, and it works like a charm to me.
First I designed the interface for 1280*800 (using phtoshop) and then
positioned the elements in pixels (no anchors, or relative position). It
scales great to any phone, tablet even desktop. Hope it helps.

                //escalar al dispositivo (se diseñó para 1280*800)
                xScaleFactor=this.width/1280;
                yScaleFactor=this.height/800;
                ScaleFactor=Math.min(xScaleFactor,yScaleFactor);

                trace("ancho del dispositivo:
"+FlexGlobals.topLevelApplication.width);
                trace("dpi del dispositivo:
"+FlexGlobals.topLevelApplication.applicationDPI);
                trace("scalar por "+ ScaleFactor);

                //scalar para el dispositivo
                FlexGlobals.topLevelApplication.scaleX=ScaleFactor
                FlexGlobals.topLevelApplication.scaleY=ScaleFactor;


2013/4/12 Alex Harui <ah...@adobe.com>

>
>
>
> On 4/12/13 10:07 AM, "Scott Matheson" <sm...@intralinks.com> wrote:
>
> > Hi
> >    Some good points, we are developing for 1024 x 768,  as most screen
> are
> > larger than this, however with the browser URL etc on some devices you
> end
> > up with score bars, all graphics are vectors so we think these will scale
> > well, that¹s what our limited testing has shown, the screen are very
> > simple with lost of space, so we could scale the design down
> If you scale too far, fonts will get too small to read.  But in general,
> scaling causes lines/edges that were on pixel boundaries to no longer be on
> pixel boundaries and then anti-aliasing kicks in and the colors change or
> edges look fuzzy.  Quite frankly, I never notice unless told to look, but
> some folks have a sensitivity to this sort of thing.
> >
> > This was a v3 app we upgraded, to V4 I also implemented a Main and
> AppBase
> > class, looks like I may not have updated all mx: to S;
> >
> > Should is change the base imports ?
> I think Flex 4 has different scaling behavior than Flex 3, and Spark does
> not show scrollbars by default, so probably worth trying.
> >
> >
> ===========================================================================
> > =
> >
> > AppBase.AS
> >
> >
> > package baseclasses
> > {
> >         import com.peach.uofs.services.LoadCenters;
> >
> >
> >         import flash.events.IEventDispatcher;
> >
> >
> >         import mx.core.Application;
> >         import mx.core.FlexGlobals;
> >         import mx.events.FlexEvent;
> >         import mx.events.StyleEvent;
> >         import mx.styles.IStyleManager2;
> >
> >
> >
> >         public class AppBase extends Application
> >
> >
> >
> >
> ===========================================================================
> > ==
> >
> > Main.mxml
> > <?xml version="1.0" encoding="utf-8"?>
> > <baseclasses:AppBase
> >             layout="absolute"
> >                 xmlns:fx="http://ns.adobe.com/mxml/2009"
> >                 xmlns:mx="library://ns.adobe.com/flex/mx"
> >                 xmlns:s="library://ns.adobe.com/flex/spark"
> >             xmlns:baseclasses="baseclasses.*"
> >             xmlns:components="com.peach.uofs.components.*"
> >                 xmlns:skins="skins.*"
> >             creationComplete="init()"  >
> >
> >
> >         <fx:Style source="main.css"/>
> >
> >
> >
> >
> >
> >
> >
> >
> >
> > On 4/12/13 5:12 PM, "Alex Harui" <ah...@adobe.com> wrote:
> >
> >> Is this mx:Application or s:Application?
> >>
> >> Why are you trying to adjust the scale?  I would think that would make
> >> your
> >> app look a bit "fuzzy" as things won't be on pixel boundaries.  You
> might
> >> be
> >> better off with a main container offset within the application.
> >>
> >> If the main container isn't also "shrinkable", that might be what causes
> >> the
> >> scroll bars.
> >>
> >>
> >> On 4/12/13 8:10 AM, "Scott Matheson" <sm...@intralinks.com> wrote:
> >>
> >>> Hi
> >>>     Not sure if this is the correct place, I will ask anyway
> >>>
> >>> In my Main.mxml  I have a simple code
> >>>
> >>>  this.scaleX  = this.scaleX ­ 0.1
> >>>  this.scaleY = this,scaleY ­0.1
> >>>
> >>> This works fine for the main container, but not the Application, so I
> >>> end up
> >>> with scroll bars
> >>>
> >>> How do I scale the application not the first container
> >>>
> >>> Scott
> >>>
> >>>
> >>> ________________________________
> >>>
> >>> Disclaimer: This electronic mail and any attachments are confidential
> >>> and may
> >>> be privileged. If you are not the intended recipient, please notify the
> >>> sender
> >>> immediately by replying to this email, and destroy all copies of this
> >>> email
> >>> and any attachments. Thank you.
> >>
> >> --
> >> Alex Harui
> >> Flex SDK Team
> >> Adobe Systems, Inc.
> >> http://blogs.adobe.com/aharui
> >>
> >
> >
> > ________________________________
> >
> > Disclaimer: This electronic mail and any attachments are confidential
> and may
> > be privileged. If you are not the intended recipient, please notify the
> sender
> > immediately by replying to this email, and destroy all copies of this
> email
> > and any attachments. Thank you.
>
> --
> Alex Harui
> Flex SDK Team
> Adobe Systems, Inc.
> http://blogs.adobe.com/aharui
>
>


-- 
 ¿ Te gustan las *Abejas* y la *Tecnología* ? Sígueme en
Twitter<http://twitter.com/apilink><http://twitter.com/apilink>

  (\__/)
  (='.'=)   This is Bunny. Copy and paste bunny into your
  (")_(")   signature to help him gain world domination.

Re: Application Scale

Posted by Alex Harui <ah...@adobe.com>.


On 4/12/13 10:07 AM, "Scott Matheson" <sm...@intralinks.com> wrote:

> Hi
>    Some good points, we are developing for 1024 x 768,  as most screen are
> larger than this, however with the browser URL etc on some devices you end
> up with score bars, all graphics are vectors so we think these will scale
> well, that¹s what our limited testing has shown, the screen are very
> simple with lost of space, so we could scale the design down
If you scale too far, fonts will get too small to read.  But in general,
scaling causes lines/edges that were on pixel boundaries to no longer be on
pixel boundaries and then anti-aliasing kicks in and the colors change or
edges look fuzzy.  Quite frankly, I never notice unless told to look, but
some folks have a sensitivity to this sort of thing.
> 
> This was a v3 app we upgraded, to V4 I also implemented a Main and AppBase
> class, looks like I may not have updated all mx: to S;
> 
> Should is change the base imports ?
I think Flex 4 has different scaling behavior than Flex 3, and Spark does
not show scrollbars by default, so probably worth trying.
> 
> ===========================================================================
> =
> 
> AppBase.AS
> 
> 
> package baseclasses
> {
>         import com.peach.uofs.services.LoadCenters;
> 
> 
>         import flash.events.IEventDispatcher;
> 
> 
>         import mx.core.Application;
>         import mx.core.FlexGlobals;
>         import mx.events.FlexEvent;
>         import mx.events.StyleEvent;
>         import mx.styles.IStyleManager2;
> 
> 
> 
>         public class AppBase extends Application
> 
> 
> 
> ===========================================================================
> ==
> 
> Main.mxml
> <?xml version="1.0" encoding="utf-8"?>
> <baseclasses:AppBase
>             layout="absolute"
>                 xmlns:fx="http://ns.adobe.com/mxml/2009"
>                 xmlns:mx="library://ns.adobe.com/flex/mx"
>                 xmlns:s="library://ns.adobe.com/flex/spark"
>             xmlns:baseclasses="baseclasses.*"
>             xmlns:components="com.peach.uofs.components.*"
>                 xmlns:skins="skins.*"
>             creationComplete="init()"  >
> 
> 
>         <fx:Style source="main.css"/>
> 
> 
> 
> 
> 
> 
> 
> 
> 
> On 4/12/13 5:12 PM, "Alex Harui" <ah...@adobe.com> wrote:
> 
>> Is this mx:Application or s:Application?
>> 
>> Why are you trying to adjust the scale?  I would think that would make
>> your
>> app look a bit "fuzzy" as things won't be on pixel boundaries.  You might
>> be
>> better off with a main container offset within the application.
>> 
>> If the main container isn't also "shrinkable", that might be what causes
>> the
>> scroll bars.
>> 
>> 
>> On 4/12/13 8:10 AM, "Scott Matheson" <sm...@intralinks.com> wrote:
>> 
>>> Hi
>>>     Not sure if this is the correct place, I will ask anyway
>>> 
>>> In my Main.mxml  I have a simple code
>>> 
>>>  this.scaleX  = this.scaleX ­ 0.1
>>>  this.scaleY = this,scaleY ­0.1
>>> 
>>> This works fine for the main container, but not the Application, so I
>>> end up
>>> with scroll bars
>>> 
>>> How do I scale the application not the first container
>>> 
>>> Scott
>>> 
>>> 
>>> ________________________________
>>> 
>>> Disclaimer: This electronic mail and any attachments are confidential
>>> and may
>>> be privileged. If you are not the intended recipient, please notify the
>>> sender
>>> immediately by replying to this email, and destroy all copies of this
>>> email
>>> and any attachments. Thank you.
>> 
>> --
>> Alex Harui
>> Flex SDK Team
>> Adobe Systems, Inc.
>> http://blogs.adobe.com/aharui
>> 
> 
> 
> ________________________________
> 
> Disclaimer: This electronic mail and any attachments are confidential and may
> be privileged. If you are not the intended recipient, please notify the sender
> immediately by replying to this email, and destroy all copies of this email
> and any attachments. Thank you.

-- 
Alex Harui
Flex SDK Team
Adobe Systems, Inc.
http://blogs.adobe.com/aharui


Re: Application Scale

Posted by Scott Matheson <sm...@intralinks.com>.
Hi
   Some good points, we are developing for 1024 x 768,  as most screen are
larger than this, however with the browser URL etc on some devices you end
up with score bars, all graphics are vectors so we think these will scale
well, that’s what our limited testing has shown, the screen are very
simple with lost of space, so we could scale the design down

This was a v3 app we upgraded, to V4 I also implemented a Main and AppBase
class, looks like I may not have updated all mx: to S;

Should is change the base imports ?

===========================================================================
=

AppBase.AS


package baseclasses
{
        import com.peach.uofs.services.LoadCenters;


        import flash.events.IEventDispatcher;


        import mx.core.Application;
        import mx.core.FlexGlobals;
        import mx.events.FlexEvent;
        import mx.events.StyleEvent;
        import mx.styles.IStyleManager2;



        public class AppBase extends Application



===========================================================================
==

Main.mxml
<?xml version="1.0" encoding="utf-8"?>
<baseclasses:AppBase
            layout="absolute"
                xmlns:fx="http://ns.adobe.com/mxml/2009"
                xmlns:mx="library://ns.adobe.com/flex/mx"
                xmlns:s="library://ns.adobe.com/flex/spark"
            xmlns:baseclasses="baseclasses.*"
            xmlns:components="com.peach.uofs.components.*"
                xmlns:skins="skins.*"
            creationComplete="init()"  >


        <fx:Style source="main.css"/>









On 4/12/13 5:12 PM, "Alex Harui" <ah...@adobe.com> wrote:

>Is this mx:Application or s:Application?
>
>Why are you trying to adjust the scale?  I would think that would make
>your
>app look a bit "fuzzy" as things won't be on pixel boundaries.  You might
>be
>better off with a main container offset within the application.
>
>If the main container isn't also "shrinkable", that might be what causes
>the
>scroll bars.
>
>
>On 4/12/13 8:10 AM, "Scott Matheson" <sm...@intralinks.com> wrote:
>
>> Hi
>>     Not sure if this is the correct place, I will ask anyway
>>
>> In my Main.mxml  I have a simple code
>>
>>  this.scaleX  = this.scaleX ­ 0.1
>>  this.scaleY = this,scaleY ­0.1
>>
>> This works fine for the main container, but not the Application, so I
>>end up
>> with scroll bars
>>
>> How do I scale the application not the first container
>>
>> Scott
>>
>>
>> ________________________________
>>
>> Disclaimer: This electronic mail and any attachments are confidential
>>and may
>> be privileged. If you are not the intended recipient, please notify the
>>sender
>> immediately by replying to this email, and destroy all copies of this
>>email
>> and any attachments. Thank you.
>
>--
>Alex Harui
>Flex SDK Team
>Adobe Systems, Inc.
>http://blogs.adobe.com/aharui
>


________________________________

Disclaimer: This electronic mail and any attachments are confidential and may be privileged. If you are not the intended recipient, please notify the sender immediately by replying to this email, and destroy all copies of this email and any attachments. Thank you.

Re: Application Scale

Posted by Alex Harui <ah...@adobe.com>.
Is this mx:Application or s:Application?

Why are you trying to adjust the scale?  I would think that would make your
app look a bit "fuzzy" as things won't be on pixel boundaries.  You might be
better off with a main container offset within the application.

If the main container isn't also "shrinkable", that might be what causes the
scroll bars.


On 4/12/13 8:10 AM, "Scott Matheson" <sm...@intralinks.com> wrote:

> Hi
>     Not sure if this is the correct place, I will ask anyway
> 
> In my Main.mxml  I have a simple code
> 
>  this.scaleX  = this.scaleX ­ 0.1
>  this.scaleY = this,scaleY ­0.1
> 
> This works fine for the main container, but not the Application, so I end up
> with scroll bars
> 
> How do I scale the application not the first container
> 
> Scott
> 
> 
> ________________________________
> 
> Disclaimer: This electronic mail and any attachments are confidential and may
> be privileged. If you are not the intended recipient, please notify the sender
> immediately by replying to this email, and destroy all copies of this email
> and any attachments. Thank you.

-- 
Alex Harui
Flex SDK Team
Adobe Systems, Inc.
http://blogs.adobe.com/aharui