<?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>PABLO GODEL &#187; flex</title>
	<atom:link href="http://pablogodel.com/category/flex/feed/" rel="self" type="application/rss+xml" />
	<link>http://pablogodel.com</link>
	<description>Software Development / Sailing / Photography / House Music</description>
	<lastBuildDate>Sun, 08 Nov 2009 03:42:41 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Embedding fonts in Adobe Flex</title>
		<link>http://pablogodel.com/2009/05/12/embedding-fonts-in-adobe-flex/</link>
		<comments>http://pablogodel.com/2009/05/12/embedding-fonts-in-adobe-flex/#comments</comments>
		<pubDate>Tue, 12 May 2009 20:48:45 +0000</pubDate>
		<dc:creator>Pablo</dc:creator>
				<category><![CDATA[flex]]></category>
		<category><![CDATA[tips]]></category>

		<guid isPermaLink="false">http://pablogodel.com/2009/05/12/embedding-fonts-in-adobe-flex/</guid>
		<description><![CDATA[I just solved a problem that I have been fighting for many hours and generated a lot of frustration. The solution was quite simple, but it proved difficult to identify the problem.
When you need to embed a font in Adobe Flex, you do so by adding something like this in the css:

@font-face {
   [...]]]></description>
			<content:encoded><![CDATA[<p>I just solved a problem that I have been fighting for many hours and generated a lot of frustration. The solution was quite simple, but it proved difficult to identify the problem.</p>
<p>When you need to embed a font in Adobe Flex, you do so by adding something like this in the css:</p>
<pre class="brush: css;">
@font-face {
        font-family: Gotham;
        src: url('assets/Gotham.otf');
}
.headerText
{
	font-family: Gotham;
	font-size: 18pt;
	color:#fbaf33;
}
</pre>
<p>The original problem was that some parts of the Flex application were using the font, but specific components did not. The problem got confusing when a co-worker was able to see the correct font in all components with the same code base.</p>
<p>After much research and trial and error, we found that the reason he was able to see the font in all components was that he had the font installed in his computer. So apparently, Flash and the browser displayed the correct font from the system when not being able to get it from the embed font.</p>
<p>So, after finding out that the font had to be installed locally to be displayed all across the Flex application, and after removing the font locally, the solution came quicker:</p>
<p>When embedding fonts in Flex, you need to embed each font style and weight separately. And this important: You cannot specify the weight in the css style names. You just specify which font family you want to use to use a different font weight.</p>
<p>This is how it would be done:</p>
<pre class="brush: css;">
@font-face {
        font-family: Gotham;
        src: url('assets/Gotham.otf');
}
@font-face {
        font-family: Gotham-Bold;
        src: url('assets/Gotham-Bold.otf');
}

.headerText
{
	font-family: Gotham;
	font-size: 18pt;
	color:#fbaf33;
}

.headerText2
{
	font-family: Gotham-Bold;
	font-size: 18pt;
	color:#fbaf33;
}
</pre>
<p>I am sure I will not make this mistake again!</p>
]]></content:encoded>
			<wfw:commentRss>http://pablogodel.com/2009/05/12/embedding-fonts-in-adobe-flex/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Regular expressions Flex explorer</title>
		<link>http://pablogodel.com/2009/05/06/regular-expressions-flex-explorer/</link>
		<comments>http://pablogodel.com/2009/05/06/regular-expressions-flex-explorer/#comments</comments>
		<pubDate>Thu, 07 May 2009 02:07:15 +0000</pubDate>
		<dc:creator>Pablo</dc:creator>
				<category><![CDATA[flex]]></category>

		<guid isPermaLink="false">http://pablogodel.com/?p=26</guid>
		<description><![CDATA[In my quest to get one of the regular expressions for RegExpValidator, I found this phenomenal explorer of regular expressions created by Ryan Swanson. Amazing work!
Thanks for sharing it!
]]></description>
			<content:encoded><![CDATA[<p>In my quest to get one of the regular expressions for RegExpValidator, I found <a href="http://ryanswanson.com/regexp/#start">this phenomenal explorer of regular expressions</a> created by <a href="http://blog.ryanswanson.com/">Ryan Swanson</a>. Amazing work!</p>
<p>Thanks for sharing it!</p>
]]></content:encoded>
			<wfw:commentRss>http://pablogodel.com/2009/05/06/regular-expressions-flex-explorer/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Validate hostname with RegExpValidator in Flex</title>
		<link>http://pablogodel.com/2009/05/06/validate-hostname-with-regexpvalidator-in-flex/</link>
		<comments>http://pablogodel.com/2009/05/06/validate-hostname-with-regexpvalidator-in-flex/#comments</comments>
		<pubDate>Thu, 07 May 2009 02:02:12 +0000</pubDate>
		<dc:creator>Pablo</dc:creator>
				<category><![CDATA[flex]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[propel]]></category>
		<category><![CDATA[tips]]></category>

		<guid isPermaLink="false">http://pablogodel.com/?p=21</guid>
		<description><![CDATA[I spent quite some time trying to get this working. The documentation available for RegExpValidator is not very extensive just to put it in a nice way.
All I needed to do is validate a string to verify if it follows the pattern of a hostname.
After much work and research I finally narrowed it down and [...]]]></description>
			<content:encoded><![CDATA[<p>I spent quite some time trying to get this working. The documentation available for RegExpValidator is not very extensive just to put it in a nice way.</p>
<p>All I needed to do is validate a string to verify if it follows the pattern of a hostname.</p>
<p>After much work and research I finally narrowed it down and here it is:</p>
<pre class="brush: js;">
&lt;mx:RegExpValidator id=&quot;regExpV&quot;
source=&quot;{tbDomainName}&quot; property=&quot;text&quot;
flags=&quot;i&quot; expression=&quot;^[a-zA-Z0-9\-\.]+\.[A-Za-z]\{2,6\}$&quot;
/&gt;
</pre>
<p>Notice the backslashes for escaping { and }  as these characters are used in Flex for data binding.</p>
]]></content:encoded>
			<wfw:commentRss>http://pablogodel.com/2009/05/06/validate-hostname-with-regexpvalidator-in-flex/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Flex binding tip when adding components dynamically</title>
		<link>http://pablogodel.com/2009/04/16/flex-binding-tip-when-adding-components-dynamically/</link>
		<comments>http://pablogodel.com/2009/04/16/flex-binding-tip-when-adding-components-dynamically/#comments</comments>
		<pubDate>Thu, 16 Apr 2009 15:44:30 +0000</pubDate>
		<dc:creator>Pablo</dc:creator>
				<category><![CDATA[flex]]></category>
		<category><![CDATA[tips]]></category>

		<guid isPermaLink="false">http://pablogodel.com/?p=3</guid>
		<description><![CDATA[Today I was developing this UI using Flex where a panel is added as a child dynamically. Inside the Panel there is a form with a series of input elements, and I use Binding to put back the changes of an Input component into the object that originally had the text.
A weird problem occured: The [...]]]></description>
			<content:encoded><![CDATA[<p>Today I was developing this UI using Flex where a panel is added as a child dynamically. Inside the Panel there is a form with a series of input elements, and I use Binding to put back the changes of an Input component into the object that originally had the text.</p>
<p>A weird problem occured: The input text was empty even though the property in the object has some text. I tested by removing the Binding and was able to see the text in the Input.  Weird&#8230; I&#8217;ve done this so many times before and never had a problem.</p>
<p>Well, it turns out that if you set the object where the Input grabs the text from before adding the component to the tree of UIComponents for some reason the Binding messes up. So the solution was adding the Panel to the parent and then setting this object where Input grabs the text from.</p>
]]></content:encoded>
			<wfw:commentRss>http://pablogodel.com/2009/04/16/flex-binding-tip-when-adding-components-dynamically/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
