Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Datagrid expands when put in movieclip

Guest
May 04, 2013 May 04, 2013

Gidday

I wanted a drop shadow on my datagrid, so created a movieclip, put the datagrid inside.

The datagrid's dimension are now all screwy. The header and text is magnified about 5x, and the width of the clip is bizarre.

Shouldn't the DG maintain it's own dimensions when placed inside a clip?

Any idea how this can be fixed?

Thanks for your help.

TOPICS
ActionScript
466
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

LEGEND , May 05, 2013 May 05, 2013

The only reason I can see that happening is that the movieclip itself has been scaled.  You shouldn't need to place the datagrid inside a movieclip to get a drop shadow.  You can  apply it directly to the datagrid using AS3.

var dropShadow:DropShadowFilter = new DropShadowFilter();

dg.filters = new Array(dropShadow);

If you want to adjust the properties of the shadow, look up the DropShadowFilter class in the help documents.  The constructor for it is specified as...

DropShadowFilter(distance:Number

...
Translate
LEGEND ,
May 05, 2013 May 05, 2013

The only reason I can see that happening is that the movieclip itself has been scaled.  You shouldn't need to place the datagrid inside a movieclip to get a drop shadow.  You can  apply it directly to the datagrid using AS3.

var dropShadow:DropShadowFilter = new DropShadowFilter();

dg.filters = new Array(dropShadow);

If you want to adjust the properties of the shadow, look up the DropShadowFilter class in the help documents.  The constructor for it is specified as...

DropShadowFilter(distance:Number = 4.0, angle:Number = 45, color:uint = 0, alpha:Number = 1.0, blurX:Number = 4.0, blurY:Number = 4.0, strength:Number = 1.0, quality:int = 1, inner:Boolean = false, knockout:Boolean = false, hideObject:Boolean = false)

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
May 06, 2013 May 06, 2013
LATEST

Thank you Ned - I'll apply it directly to the DG as you have shown.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines