Uncategorized

RTF output from Flex

I created a new project, http://code.google.com/p/rtflex/. I got the idea from AlivePDF. Basically it exports RTF binary to a file. Nice tool for saving documents that need to be opened by Word.

I hate my website

I hate my website. I've never been satisfied with it. I'm going to completely rewrite the whole thing. I might use Drupal. Blogger sucks.

mouseChildren=false

if you're trying to make a label into a link in Flex 2 and want the hand cursor you might notice that just adding userHandCursor="true" and buttonMode="true" doesn't quite do the trick. A little searching on Google and I discovered that you'll also need to add mouseChildren="false" as well. I mentioned this to Simon Horwith and he was as puzzled as me. A label is non-selectable so why does it even have mouse children? Possibly something for Adobe to consider with Flex 3 :).

Are your scrollbars not working in Flex?

In the Flex 3 SDK flex framework I found a minor little bug. When you set the "maxScrollPosition" on a scrollbar object, it doesn't actually change the scrollbar! Why? Well let's look at the code. Found this in Program Files\Adobe\Flex Builder 3\sdks\3.0.0\frameworks\projects\framework\src\mx\controls\scrollClasses
    /**
     *  @private
     */
    public function set maxScrollPosition(value:Number):void
    {
        _maxScrollPosition = value;
    }
What's missing here? Just one line of code, invalidateDisplayList().

Interesting Discovery about Breakfast, Captain Crunch > Kashi Go Lean

So if you compare the nutritional facts of Peanut Butter Captain Crunch and Kashi Go Lean honey nut something or another... you'll notice that the Captain Crunch actually has fewer calories (138 per cup) and less fat (about 3 gs) than Kashi Go Lean. To be fair, I didn't compare the other nutritional benefits, and I'm sure Kashi wins at least some of those.

Anyway, at half the price and three times the nostalgic awesomeness, I went with Peanut Butter Captain Crunch. Nothing against Kashi, I'm sure they make a fine cereal... but it's no fun!

Submitted topics

I submitted two topics, one for CFUnited and one for the Fusebox & Frameworks Conference. For CFUnited I submitted a topic on object-oriented validation and for Fusebox I submitted a topic on practical use and examples of SAM. Hopefully I'll get chosen to do them both because I'd really like to improve my public speaking skills as well as teach people some of what I know. I've been doing a lot on CF and Java this week. I was helping tutor a friend for a Java test and was rather disgusted by the way it was being taught.

Useful Flex Tip: Use CallLater()

Have you ever tried to do something like this:
var someText:Text = new Text();
someText.text="testing";
addChild(someText);
trace(someText.measuredWidth);
and then scratched your head when Flex traces 0 for the width? That's because Flex hasn't drawn it yet. There's two ways to fix it, one you could just call someText.validateSize() but the better way to do it is to wait till Flex validates on its own to make these changes. How do you do that?

Topic for Frameworks selected!

Well my topic was chosen and I will be speaking at the frameworks conference. Thanks to everyone who voted for me (Scott). Registration is only $399 and last years frameworks conference was awesome.

quick tip, includeInLayout

includeInLayout is an often overlooked property of a UIComponent. Basically it's purpose is to make on object not considered when rendering layout.

A finished website

I recently helped a friend program a website in my spare time. It was not a CF job, all Javascript and CSS stuff. The designer gave me an impossible challenge of horizontal scrolling action. Designers never take into consideration what a programmer has to do... but rather than tell him it was impossible I decided to try and do it. I was at first trying to control the scroll bar to scroll the site but that just wouldn't work...
Syndicate content