flex-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Silvio Liria (JIRA)" <j...@apache.org>
Subject [jira] [Created] (FLEX-34816) BitmapUtil.getSnapshot not working
Date Tue, 31 Mar 2015 19:33:52 GMT
Silvio Liria created FLEX-34816:
-----------------------------------

             Summary: BitmapUtil.getSnapshot not working
                 Key: FLEX-34816
                 URL: https://issues.apache.org/jira/browse/FLEX-34816
             Project: Apache Flex
          Issue Type: Bug
    Affects Versions: Apache Flex 4.13.0
         Environment: OSX Yosemite.
Adobe Air project
            Reporter: Silvio Liria


The getSnapshotWithPadding method does not work. 
It doesn't show any error but the image is never drawn,

I have this problem also with ImageSnapshot.captureBitmapData(lbl)

	<fx:Script>
		<![CDATA[
			import mx.core.IVisualElement;
			import mx.core.UIComponent;
			import mx.events.FlexEvent;
			import mx.graphics.ImageSnapshot;
			
			import spark.components.Application;
			import spark.components.Button;
			import spark.components.Group;
			import spark.components.Image;
			import spark.components.Label;
			import spark.utils.BitmapUtil;
			
			import models.Colors;
			import models.Icons;
			import models.TrailbackMapaIcons;
			
			private var pi:positionIcon
		
			
			protected function container_creationCompleteHandler(event:FlexEvent):void
			{
				var lbl:Label = new Label()
				lbl.text = 'testing...'; 
				lbl.width = 200
				lbl.height = 25

			var bmData:BitmapData;

			bmData =  BitmapUtil.getSnapshotWithPadding(lbw,6,false,new Rectangle(0,0,250,50))  


			var b:Bitmap = new Bitmap(bmData)
			var img:Image = new Image()
			img.source = b
			img.width = img.height = 25
	
			container.source =  img.source;	
			}
		]]>
	</fx:Script>

	<s:Image id="container" width="100%" height="100%" creationComplete="container_creationCompleteHandler(event)"/>




--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message