<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>aut0poietic</title>
	<atom:link href="http://aut0poietic.us/feed/" rel="self" type="application/rss+xml" />
	<link>http://aut0poietic.us</link>
	<description>Just another WordPress site</description>
	<lastBuildDate>Fri, 21 Oct 2011 20:19:13 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Post &amp; Site Migration</title>
		<link>http://aut0poietic.us/2011/10/12/post-site-migration/</link>
		<comments>http://aut0poietic.us/2011/10/12/post-site-migration/#comments</comments>
		<pubDate>Wed, 12 Oct 2011 13:54:54 +0000</pubDate>
		<dc:creator>Jer</dc:creator>
				<category><![CDATA[Site Development]]></category>

		<guid isPermaLink="false">http://aut0poietic.us/?p=624</guid>
		<description><![CDATA[I am currently neck deep in the Annual Migration of the Lesser American Blog Posts. Please be patient while they bounce around for a bit. ]]></description>
			<content:encoded><![CDATA[<p>So, if you&#8217;ve google&#8217;d your way here, you might find the post you were looking for completely un-readable. </p>
<p>Yeah, that&#8217;d be my fault. Sorry.</p>
<p>See, I&#8217;ve been resisting a major change on my site for years. I start on a design, moving a new direction and quickly back-peddle on it and go with what&#8217;s typical, expected. However, by refusing to move posts and move on to what I want, I&#8217;m quickly dissatisfied with my design and build a *new* one that&#8217;s the same old site with new graphics.</p>
<p>This design changes this. But in the mean time, lots of posts will be lost in the never-never until I get them moved to their new home, and some redirection-logic built &#8212; and I&#8217;m not sure how I&#8217;m going to handle that little bit of work.</p>
<p>So, in the meantime, some things might be missing while I figure out how to implement them. Again, I&#8217;m really sorry. If there is an article or piece you need, hit me up on twitter ( <a href="https://twitter.com/#!/aut0poietic" target="_blank">@aut0poietic</a> ). I&#8217;ll either make the article available elsewhere, send it to ya in email, or direct you to the materials you were looking for.</p>
<p>And, uh, let me know what you think of the design.</p>
]]></content:encoded>
			<wfw:commentRss>http://aut0poietic.us/2011/10/12/post-site-migration/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Dijkstra&#8217;s Algorithm</title>
		<link>http://aut0poietic.us/2011/10/01/dijkstras-algorithm-in-canvas-and-html/</link>
		<comments>http://aut0poietic.us/2011/10/01/dijkstras-algorithm-in-canvas-and-html/#comments</comments>
		<pubDate>Sat, 01 Oct 2011 16:27:43 +0000</pubDate>
		<dc:creator>Jer</dc:creator>
				<category><![CDATA[Experiments]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[canvas]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[gamedev]]></category>
		<category><![CDATA[html]]></category>
		<category><![CDATA[javascript]]></category>

		<guid isPermaLink="false">http://aut0poietic.us/?p=540</guid>
		<description><![CDATA[I&#8217;m beginning to really play with JavaScript + Canvas, implementing some of my old Flash experiments and algorithms just to get comfortable. In experimenting with this, I began to run across angry posts on using canvas for game development, stating using actual HTML elements ( divs and such ) were more effective / efficient. So I decided to [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m beginning to really play with JavaScript + Canvas, implementing some of my old Flash experiments and algorithms just to get comfortable. In experimenting with this, I began to run across angry posts on using canvas for game development, stating using actual HTML elements ( divs and such ) were more effective / efficient.</p>
<p>So I decided to try to implement one of my older demonstrations of Dijkstra&#8217;s Algorithm in JavaScript, but one demo using Canvas to render the interaction, and one demo using divs, and CSS. I personally like Dijkstra&#8217;s because of how useful it is and because it&#8217;s one of those algorithms I&#8217;d heard about over and over, but no one could show me the code in action. </p>
<p>Up front: I&#8217;d like to point out that the code is not 100% efficient. Clarity was the goal, and I have to admit that the canvas example could likely be optimized ( and, cleaned up in general ) quite a bit. Heck, If I were doing this in any other language I&#8217;d be using multi-dimensional arrays and skip the whole string indexes, but MDArrays make me nervous in JS ( fodder for a future experiment, maybe ). That said I won&#8217;t get my feelings hurt if you show me how it could be better &#8212; Just don&#8217;t get your feelings hurt if I say &#8220;but that&#8217;s not as clear as my example.&#8221;</p>
<p>For some background, Dijkstra&#8217;s Algorithm is a variant of the well-know A* ( a star ) algorithm. A* is used to find the most efficient path between two objects on a map and can be modified to consider things like terrain, enemy line of site, etc. </p>
<p>Dijkstra&#8217;s uses similar logic to find all <em>possible</em> paths from a current position given a movement-per-duration.  In plan english, if a person can move 10 feet in one &#8220;turn,&#8221; Dijkstra&#8217;s can tell you <em>everywhere</em> it&#8217;s possible for that person to move during that term. If you&#8217;ve played Disgaea, Fire Emblem or any other turn-based tactical game, you get the idea of how this works.</p>
<div style="-webkit-column-span:all; -moz-column-span:all;column-span:all;text-align:center;">
<h2 style="">Demo 1:  Dijkstra&#8217;s Algorithm in SPAN&#8217;s</h2>
<p>(click the blue tile in the center to run)</p>
<p><iframe id="html_demo" src="http://aut0poietic.us/experiments/dijkstra/tag-based.html" width="423" height="423" style="margin:auto;overflow:hidden;" ></iframe><br />
<button id="reset_html" onclick="document.getElementById('html_demo').contentWindow.location.reload(false);">Reset Demo</a>
</div>
<p>The above simulation creates 400 span tags styled to create a grid, with some tiles having a higher &#8220;Terrain&#8221; cost &#8212; they&#8217;re harder to walk over. If you click the blue square in the center &#8212; the character ( I was too lazy to create little stick-figure art ). The code will calculate the area the character can move over the terrain. If you pull up your JavaScript console, you can see the amount of time it took to perform the calculation and render the grid.</p>
<p>I rebuilt this demo twice before I was happy with the way it ran. The first time, I used jQuery to create and reference elements &#8212; and paid a high price: Render time of 72 &#8211; 86ms per map.  That&#8217;s astoundingly high, but fairly obvious. I removed jQuery and found another opportunity for optimizing: my implementation used the DOM to store the cost and terrain values in attributes of each span. </p>
<p>This final version uses an array for all grid data, divorcing the implementation from rendering and allowing us to use the same function (&#8220;showMovement( )&#8221;) in both the HTML and Canvas versions. So the only difference in performance will be the <em>rendering</em>.</p>
<div style="-webkit-column-span:all; -moz-column-span:all;column-span:all;text-align:center;">
<h2 style="">Demo 2:  Dijkstra&#8217;s Algorithm in Canvas</h2>
<p>(click the blue tile in the center to run)</p>
<p><iframe id="canvas_demo" src="http://aut0poietic.us/experiments/dijkstra/canvas-js.html" width="423" height="423" style="margin:auto;overflow:hidden;" ></iframe><br />
<button id="canvas_demo" onclick="document.getElementById('html_demo').contentWindow.location.reload(false);">Reset Demo</a>
</div>
<p>As stated above, I literally copied and pasted the showMovement( ) and getAdjcent methods and all the properties from the previous demo and pasted them into this second demo &#8211; the only additions were the X &#038; Y values in the data objects and the canvas rendering. Early on, I added a simple layered design to the demo by pre-rendering the map ( grid lines and terrain ) into a canvas stored in memory ( never added to the DOM ) so I wouldn&#8217;t have to re-render the grid every time &#8212; hey, HTML didn&#8217;t have to either, why should canvas be so hobbled.</p>
<p>The results were inconclusive. In my non-scientific testing, the canvas version ran about 1-3ms faster on average, but this is not nearly enough to write home about. Even worse, the terrain map is random, making accurate comparisons difficult ( if not impossible ). However, my guess is that the canvas buffering technique would quickly become significantly faster if we were using complex graphics &#8212; like a real terrain map with alpha&#8217;d overlays for movement as well as alpha&#8217;d characters. I believe the when it came to rendering multiple images and applying effects to those images to each span multiple times, the canvas&#8217; pre-rendered map would be a big boost in performance.</p>
<p>The irony ( to this old Actionscripter anyway ) is that my <strong>extremely </strong>inefficient ActionScript version of this same simulation runs in between 1-3ms in a larger field. And when I say inefficient, I mean &#8220;I used a Flex DataGrid Object and the display list for data storage.&#8221; Yeah, pathetic code, but really shows off Flash&#8217;s speed. JS, for all it&#8217;s openness, can&#8217;t touch it. </p>
<p>Like almost everything I do, <a href="http://aut0poietic.us/experiments/dijkstra/dijkstra-canvas-html.zip">the source is here for the playing with</a>. If you come up with some modifications you&#8217;re proud of, share em over on http://jsbin.com/ so we can all play. </p>
]]></content:encoded>
			<wfw:commentRss>http://aut0poietic.us/2011/10/01/dijkstras-algorithm-in-canvas-and-html/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Cardboard Construction: Update 1</title>
		<link>http://aut0poietic.us/2011/09/03/cardboard-construction-update-1/</link>
		<comments>http://aut0poietic.us/2011/09/03/cardboard-construction-update-1/#comments</comments>
		<pubDate>Sat, 03 Sep 2011 20:13:37 +0000</pubDate>
		<dc:creator>Jer</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://aut0poietic.us/?p=515</guid>
		<description><![CDATA[Working, and I&#8217;ve already learned a few lessons in this, like tape!! Tape your straight edge in place to the cardboard you&#8217;re cutting. Also, don&#8217;t skimp on the blades. Sharp blade cuts cardboard like there&#8217;s nothing there. A dull one cuts nothing, and leaves a ragged edge. I&#8217;ll probably put more money into blades soon. [...]]]></description>
			<content:encoded><![CDATA[<p>Working, and I&#8217;ve already learned a few lessons in this, like tape!! Tape your straight edge in place to the cardboard you&#8217;re cutting. Also, don&#8217;t skimp on the blades. Sharp blade cuts cardboard like there&#8217;s nothing there. A dull one cuts nothing, and leaves a ragged edge. I&#8217;ll probably put more money into blades soon.</p>
<p>I also learned that you need to embrace the corrugation on a project like this. Don&#8217;t half or miter cut the cardboard in any way to assist in folding. Instead, us one of your metal rulers and crease the cardboard along an existing channel in the corrugation and fold into that channel. This has become very important as I&#8217;ve made progress.</p>
<p><img class="alignright size-medium wp-image-517" style="border-style: initial; border-color: initial;" title="IMG_20110903_133101" src="http://aut0poietic.us/wp-content/uploads/2011/09/IMG_20110903_133101-300x225.jpg" alt="" width="300" height="225" /></p>
<p>But for now, I&#8217;ve got the first two U sections of the first shelf built. This is the true prototype and I&#8217;m going to spend a few minutes creating the charts for what I&#8217;m doing, no so much to show anyone reading ( though I want to do that too ) but to validate the plan I have in my head with some actual geometry, if only on the computer.</p>
<p>The idea is to create two interlocking &#8220;U&#8221; shapes, each out of two thinner, offset U Shapes. It&#8217;s hard to describe, but the geometry works a little something like this:<br />
<img class="alignleft size-full wp-image-518" title="box-interlocking" src="http://aut0poietic.us/wp-content/uploads/2011/09/box-interlocking.png" alt="" width="295" height="101" /></p>
<p>This structure forms the core of the shelf. It&#8217;s important to note that the corrugation runs AROUND the core structure &#8212; Not parallel.</p>
<p>The next piece will be four additional &#8220;U&#8221; shapes desgned to wrap around the base and top to provide a clean, continuous finish. Those should look something like this before they&#8217;re folded:</p>
<p><img class="alignleft size-full wp-image-519" title="box-base-fold" src="http://aut0poietic.us/wp-content/uploads/2011/09/box-base-fold.png" alt="" width="218" height="146" /></p>
<p>Now, if you&#8217;ve been paying attention at home, the corrugation in this piece is running horizontal ( because that&#8217;s where the folds are ). This will have it running <strong><em>perpendicular</em></strong> to the corrugation in the core. The plan is for the alternating corrugation to create a <em><strong>very</strong> strong</em> structure. It  <em>should</em> also create a very smooth edge. I&#8217;ll wrap two more of these around the sides ( but without the tabs ), to create a very tight seam.</p>
<p><img class="alignright size-medium wp-image-520" title="IMG_20110903_143434" src="http://aut0poietic.us/wp-content/uploads/2011/09/IMG_20110903_143434-300x225.jpg" alt="" width="300" height="225" /><br />
Once the entire structure has been built and secure, I&#8217;ll use some form of filler ( Wood, apoxy filler, bondo, drywall compound ) to hide the edges. Sand, then paint and it&#8217;ll be a finished shelf!</p>
<p>Here&#8217;s the plan. Hopefully it all works like I think it should. Feel free to poke holes in the idea.</p>
<p>Here&#8217;s the first two &#8220;U&#8221; shapes, drying.</p>
]]></content:encoded>
			<wfw:commentRss>http://aut0poietic.us/2011/09/03/cardboard-construction-update-1/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Cardboard Construction: Project Setup</title>
		<link>http://aut0poietic.us/2011/09/03/cardboard-construction-project-setup/</link>
		<comments>http://aut0poietic.us/2011/09/03/cardboard-construction-project-setup/#comments</comments>
		<pubDate>Sat, 03 Sep 2011 18:12:19 +0000</pubDate>
		<dc:creator>Jer</dc:creator>
				<category><![CDATA[Cardboard]]></category>
		<category><![CDATA[Projects]]></category>

		<guid isPermaLink="false">http://aut0poietic.us/?p=507</guid>
		<description><![CDATA[Yeah, another insane project. This time I'm making De Stijl floating shelves out of cardboard. ]]></description>
			<content:encoded><![CDATA[<p>Okay, so I have a really cool idea for bookshelves for my daughter&#8217;s room, but the price of creating those shelves is extremely high, and the construction techniques involved are extremely complex &#8211; maybe even beyond me.  I won&#8217;t get into the project yet, but it&#8217;s cool.</p>
<p>I&#8217;m woried about the weight of the final sculpture, and the cost to create &#8212; not to mention the cost of my mistakes, of which there will be many.</p>
<p>So the idea came to me that it was theoretically possible to build this project out of cardboard. I&#8217;d been looking at projects like this for months, and with the long weekend coming, I&#8217;m gonna give it a whirl.</p>
<p>Here&#8217;s what I&#8217;ve assembled for starters to do this:</p>
<p><img class="size-medium wp-image-509 alignright" title="Project Materials" src="http://aut0poietic.us/wp-content/uploads/2011/09/IMG_20110903_124515-300x225.jpg" alt="" width="300" height="225" /></p>
<ul>
<li>1 yard and 1 foot metal rulers</li>
<li>1 metal &#8216;L&#8217; square</li>
<li>blue painter&#8217;s tape</li>
<li>Gorilla wood glue</li>
<li>a backing &#8212; in this case an old pergo floor board</li>
<li>4 woodworking clamps</li>
<li>misc wood blocks/boards (prevent clamp impressions in the cardboard)</li>
<li>6 Cardboard Project boards</li>
</ul>
<p>I&#8217;m using the project board this time because I wanted &#8220;clean&#8221; cardboard for the first few experiments &#8212; I want to know what the basic problems will be before I introduce those involving cleaning and squaring the cardboard.</p>
<p>Now, the project for the final design is FAR too complex to experiment with. To begin this, I&#8217;m going to make a few floating box shelves ( <a title="Boxes, you hang them on walls..." href="http://www.amazon.com/Melannco-Black-Square-Shelves-Set/dp/B001J2UDC8/ref=sr_1_14?s=furniture&amp;ie=UTF8&amp;qid=1315072477&amp;sr=1-14" target="_blank">like these on Amazon</a> ) in various rectangluar shapes to produce floating <a title="Examples of De Stijl" href="http://www.google.com/search?hl=en&amp;nord=1&amp;biw=1525&amp;bih=839&amp;site=webhp&amp;tbm=isch&amp;sa=1&amp;q=de+stijl&amp;oq=de+stijl&amp;aq=f&amp;aqi=&amp;aql=&amp;gs_sm=s&amp;gs_upl=0l0l0l800316l0l0l0l0l0l0l0l0ll0l0" target="_blank">De Stijl</a> shelves, <a title="Cool De Stijl Tree Shelves" href="http://www.google.com/imgres?q=de+stijl&amp;hl=en&amp;sa=X&amp;nord=1&amp;tbm=isch&amp;prmd=ivnsb&amp;tbnid=j_egKpPibObR2M:&amp;imgrefurl=http://www.cribcandy.com/shelves/b2f54da7b02fff16b27bef165f2924af%26pageoffset%3D0&amp;docid=G9UIO0pT1hCOrM&amp;w=400&amp;h=400&amp;ei=-WliTrDCEpCqsALemOi0Cg&amp;zoom=1&amp;iact=hc&amp;vpx=1259&amp;vpy=166&amp;dur=226&amp;hovh=225&amp;hovw=225&amp;tx=162&amp;ty=84&amp;page=4&amp;tbnh=150&amp;tbnw=127&amp;start=89&amp;ndsp=32&amp;ved=1t:429,r:7,s:89&amp;biw=1525&amp;bih=839" target="_blank">much like these, but not inter-connected</a>.</p>
<p>I&#8217;m going to be trying multiple methods of construction and finishing, hopefully over the course of the weekend.</p>
<p>Wish me luck, and I&#8217;ll update both facebook and twitter when I have time. Those of you on G+ will see my pics appear as I take them.</p>
]]></content:encoded>
			<wfw:commentRss>http://aut0poietic.us/2011/09/03/cardboard-construction-project-setup/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>jQuery UI + Button + Checkbox = Broken?</title>
		<link>http://aut0poietic.us/2010/11/19/jquery-ui-button-checkbox/</link>
		<comments>http://aut0poietic.us/2010/11/19/jquery-ui-button-checkbox/#comments</comments>
		<pubDate>Fri, 19 Nov 2010 16:25:06 +0000</pubDate>
		<dc:creator>Jer</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[jquery jquery-ui checkbox accessibility]]></category>

		<guid isPermaLink="false">http://aut0poietic.us/?p=434</guid>
		<description><![CDATA[Tell me this is a mistake on my part, not the jQuery UI team's fault?]]></description>
			<content:encoded><![CDATA[<p>This post is more a &#8220;I have to be missing something so someone clue me in because there&#8217;s no way the jQuery UI folks missed a hole this huge&#8221; kinda post.</p>
<p>I&#8217;m building a canned Multiple-Choice question for courses we use here at OU. My prototype got dinged in QA because you couldn&#8217;t tab to the buttons nor select them with space. Pretty big bug that I couldn&#8217;t believe I missed. I just assumed that because jQuery UI made everything accessible nearly automatically, I didn&#8217;t have to handle it directly.</p>
<p>Yeah, they don&#8217;t, and I do.</p>
<p>Issue is, if you create a button out of a checkbox, you can still tab to the checkbox (thus set focus to it, thus making it accessible to screen readers) but there is no visual indication that the item is focused. <a href="http://jsbin.com/urupi3/3">Here&#8217;s an example &#8212; try tabbing to the buttons and see what happens.</a></p>
<p>Here&#8217;s how I&#8217;m solving the issue. It is not perfect, but it&#8217;s what I&#8217;m doing for the moment. If I come up with something better, I&#8217;ll update the post.</p>
<pre class="brush: jscript; title: ; notranslate">
var o = $(&quot;#myCheckbox&quot;).button() ;
if(o.attr(&quot;type&quot;) == &quot;checkbox&quot; || o.attr(&quot;type&quot;) == &quot;radio&quot;)
{
o.bind(
&quot;focus blur&quot;,
function( event )
{
$(&quot;label[for='&quot; + event.target.id + &quot;']&quot;).toggleClass(&quot;ui-state-hover&quot;) ;
}
) ;
}
</pre>
<p>Obviously I&#8217;m hoping for comments here, so if you know a better solution or a better direction, please, let your voice be heard.</p>
<p>I *think* I may take the time to turn this into a plugin if it turns out that I&#8217;m not missing the painfully obvious step to make all this work. Comment too if you want the plugin code.</p>
<p>Edit: okay, the plugin tool like 30 seconds. Here ya go: <a href="http://aut0poietic.us/wp-content/uploads/2010/11/jquery-ui.checkbox.button.focus_.js">jquery-ui.checkbox.button.focus</a>. Include this file after jquery-ui.*.js and use it like this:</p>
<pre class="brush: jscript; title: ; notranslate">
$(&quot;#myform input[type='checkbox']&quot;).button().checkboxButtonFocus( ) ;
</pre>
]]></content:encoded>
			<wfw:commentRss>http://aut0poietic.us/2010/11/19/jquery-ui-button-checkbox/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>TextArea Automatically Resize</title>
		<link>http://aut0poietic.us/2009/06/18/textarea-auto-resize/</link>
		<comments>http://aut0poietic.us/2009/06/18/textarea-auto-resize/#comments</comments>
		<pubDate>Fri, 19 Jun 2009 01:35:06 +0000</pubDate>
		<dc:creator>Jer</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[actionscript]]></category>
		<category><![CDATA[Flex]]></category>
		<category><![CDATA[TextArea]]></category>

		<guid isPermaLink="false">http://aut0poietic.us/?p=1</guid>
		<description><![CDATA[Your Flex TextArea controls getting clipped?  This little piece of code fixes that. Sample code and a class after the jump.]]></description>
			<content:encoded><![CDATA[<p>Posting this just on the off-chance someone else ran into the issue and the solutions on the net weren&#8217;t up to their needs.</p>
<p>In a project, I&#8217;m using a TextArea control because it&#8217;s better at displaying images inline using the htmlText property &#8212; the Text control completely failed. But once I did this, I kept finding the text getting clipped.</p>
<p>TextArea controls expect that they&#8217;ll have a fixed or percentage width and height. Most of the suggestions I&#8217;ve seen require the use of getTextMetrics() for the mx_internal textField control of the TextArea. This fails miserably if there is any font sizing or inlined images in the html.</p>
<p>This (placed in creationComplete) works nearly perfectly:</p>
<pre class="brush: php; title: ; notranslate">

protected function onCreationComplete(event:Event):void
{
	//textAreaControl is the id of the control you want to resize to contain it's text.
	textAreaControl.validateNow() ;
	textAreaControl.mx_internal::getTextField().autoSize = TextFieldAutoSize.LEFT ;
	textAreaControl.mx_internal::getTextField().validateNow();
	textAreaControl.height = textAreaControl.mx_internal::getTextField().height ;
}
</pre>
<p>It would be just as easy to subclass the TextArea control and apply this on set htmlText().</p>
<p>One minor error with this is that before creationComplete is run, the text is briefly visible in it&#8217;s unsized state. If you&#8217;re using this in a subclassing situation, no worries, but if you&#8217;re applying this from a parent-&gt;child situation, you&#8217;re going to have to handle the appearance changes (but that&#8217;s fairly obvious &#8212; just felt it needed qualifying).</p>
<p>Hope that helps someone out.</p>
<p><strong>Update:</strong></p>
<p>Created the class in the comments below, figured I&#8217;d update the article:</p>
<pre class="brush: as3; title: ; notranslate">

package us.aut0poietic.controls.text
{
	import flash.text.TextFieldAutoSize;
	import mx.core.mx_internal;
	import mx.controls.TextArea;
;

	public class AutoSizeTextArea extends TextArea
	{
		public function AutoSizeTextArea()
		{
			super();
		}
		override public function set text(value:String):void
		{
			super.text = value ;
			updateSize() ;
		}
		override public function set htmlText(value:String):void
		{
			super.data = value ;
			updateSize() ;
		}
		override protected function commitProperties():void
		{
			super.commitProperties() ;
			updateSize() ;
		}
		protected function updateSize():void
		{
			if(mx_internal::getTextField() != null)
			{
				validateNow() ;
				mx_internal::getTextField().autoSize = TextFieldAutoSize.LEFT ;
				mx_internal::getTextField().validateNow();
				this.height = mx_internal::getTextField().height ;
			}
		}
	}
}
</pre>
]]></content:encoded>
			<wfw:commentRss>http://aut0poietic.us/2009/06/18/textarea-auto-resize/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>

