flex

Flex. Images aligning in htmlText

I set htmlText property of a TextArea to the following value: <img src="img.gif" />Some text<br><img src="img.gif" />Some text The top edge of "Some text" is aligned to the top edge of the corresponging image. How to align it by bottom edges (the bottom of the text to the bottom of the image)? Is it possible? Remark: image's height ...

Flex: ListItem pulling data from other items in the list?

I have a TileList with a custom ItemRenderer, and each item shows an image which it extgracts from the data it receives from the dataProvider. The wierd thing is, and I have no clue why is some items are show images that are not in their data-bock but in another items data. If I am extracting the image url from its own data I have no clu...

Flex: Reuse classes for multiple projects without copy+paste?

OK I have a few classes I have made or found on the web that I plan to use in multiple projects, I would rather store these classes in a central location instead of copy+pasting them into each project. my Flex projects have their own workspaces inside the path Flex/WorkSpaces/< workSpaceName > If I wanted to put another folder inside t...

AdvancedDataGrid LockedRowCount not working

I am trying to lock the 1st row in my ADG. This 1st row is the SummaryRow. When I set the lockedRowCount property to 1, it still does not freeze the 1st row. I have tried with different numbers, but it is still not working. In fact, when I try to trace the value for lockedRowCount, it traces it as 0. Can anyone provide suggestion on how...

Flex, Ant and TeamCity

Is anyone using TeamCity for building their Flex apps? We're using .Net for our main site code and backend flex data calls and we use flex for our application. I have a working Ant build script, but I can't get it to run with the TeamCity Ant Runner. I'm curious if anyone has gotten this working and if they have, could I potentitially se...

Adding LegendItems in Flex places horizontally not vertically (as it's supposed to)

I'm dynamically inserting LegendItems into a Legend using the following code: signalLegend.removeAllChildren(); signalLegend.direction = "vertical"; for (var i:int = 0; i < numItems - 1; i++) { signalLegend.addChild(new LegendItem()); legendItem = signalLegend.getChildAt(i) as LegendItem; legendItem.label = "Title here"; ...

Handling client-side domain object state in a presentation model.

I'm currently building the client side of a Flex/PHP project using the Presentation Model pattern. What I'm trying to achieve: I currently have a view displaying non-editable information about a domain object called Node. Depending on if the Node is editable and the user has the right privileges, an additional view becomes available whe...

removing an item from a filtered ArrayCollection

Hi all, I'm having some issues when calling getItemIndex on an ArrayCollection with a filterFunction set. I do something like myAC.removeItemAt(myAC.getItemIndex(myObject)), which works fine when the filtering hasn't been applied. As soon as filtering is applied, getItemIndex seems to return -1 in every case. Has anyone come across...

Flex Bipmapdata and Scrolled Canvas

Hello, I have a canvas wich is a drawing area. This canvas can be scrolled horizontally and vertically. I am trying to make a screenshot of the whole canvas, this include visible and scrolled parts. var bmd:BitmapData = new BitmapData(board.width, board.height, false, 0xffffff); bmd.draw(board); This would only show me the visible ...

Flex collapsible field group control

Hi! I am trying to make a side panel in a Flex application that would hold a bunch of properties of a selected object. The number of properties may become huge, but they all fall into some certain categories. For that, I am looking for a flex control that would be like a collapsible field group. Or like an accordion that can have multi...

Flex Child Canvas insise a Canvas and resizing question

Hi, I have a Canvas A with scrollpolicy on, A has one unique Child canvas B which has no scrolling. A is the container of B which is a whiteboard like tool. If i dont set width and height of B, he will resize accordingly to A size, up to a certain point where A has scrollbars which is the good Behavior. However since B canvas seems t...

How can I send date object from Adobe Flex to RESTful rails?

Hello, I'm working on an Adobe AIR project that use the Ruby on Rails as RESTful web service as the back end. I have found a lot of examples that show how can I send the data to operated by Rails. but I stuck at date object, which will be very useful if I can send Actionscript's date object to Rails via XML or whatever and Rails can und...

Flex Type Coercion, it's gone mental I think...

I have a class essentially: public class WindowEvent extends Event { public static const WARNEVENT:String = "warnEvent"; public static const TASKREQEVENT:String = "taskRequestEvent"; public static const TASKANNOUNCE:String = "taskAnnounce"; public static const WINDOWCHANGE:String = "windowChange"; public static const...

AS3 RegExp to match words with boundry type characters in them

I'm wanting to match a list of words which is easy enough when those words are truly words. For example /\b (pop|push) \b/gsx when ran against the string pop gave the door a push but it popped back will match the words pop and push but not popped. I need similar functionality for words that contain characters that would normally q...

Flex3: Canvas over TextArea

There are two issues with TextArea htmlText that I posted as single questions: embeded images and images aligning. It's just impossible to solve this problem using only TextArea component. One of the solutions is to use images layer over TextArea. <mx:Canvas> <mx:TextArea id="content" width="100%" height="100%" /> <mx:Canvas i...

Adobe Flex image scaling quality

I have an image viewer I wrote in Flex that scales the size of the image you're currently viewing based on the size of the browser. This is what the tag looks like: <mx:Image id="img" maintainAspectRatio="true" source="{horizontalList.selectedItem.image}-large.jpg" height="100%" horizontalCenter="0" horizontalAlign=...

How to make a Flash PreLoader in AS3 Only?

I want to incorporate a Flash Pre-loader in my application, but I am using only Flex SDK/AS3/Notepad to code this beast. I don't have access to the Flash IDE. There are many tutorials and helpfiles online for how to do it within CS4, but not in the code itself. Can anyone give me direction here? Most examples seem to pivot around placi...

Flex slow first Http request

Hi, When i use loader.load(request); for the first time, my flex freeze for 10 secondes before posting the data (i can see the web server result in real time). However if redo a similar POST with other data but same request.url, it's instantaneous. // Multi form encoded data variables = new URLVariables(); variables.user = "aaa"; variab...

Styling UITextField

I've been playing around with different methods of determining at runtime the width of a "label" so that I can resize the "label" because I don't want it to truncate. I've finally found an easy solution through UITextField which allows me to set the .autoSize which is great! However, now I'm trying to "style" (simply adjust font and fo...

Why is 'textField' not instantiated when I subclass TextArea in Flex?

I'm experimenting with TextArea and inheritance to implement some additional functionality on the protected textField property. Unfortunately, when I create a new instance of the subclass, this property is set to null. I'm probably misunderstanding the way super() works, but I thought it would have been instantiated after the construct...