FightSkillz.com - Life, Code, & Idiocy
It's really irritating when you're searching for OGG Vorbis support in the iOS 4 version of WebKit and a tech reporter's last name is Ogg. 2 days ago

June, 2008

Blank Screen + Blinking Cursor

Monday, June 30th, 2008

While I've been Mac based for more than a year now (and how fantastic it is), I still have an old Windows box that I use as a local media server. I know from experience not to put anything valuable on it, and as an added layer of security for this still-paranoid-former-Windows-user I have a dual boot setup with the latest Kubuntu as a just-in-case. At least I'll be able to get online and troubleshoot. Despite my best practices I've just had to go through an all to familiar process with a family member's laptop. A majorly corrupt memory module caused a Windows XP re-installation to fail midway. The only option was to erase the hard drive, from something called Doctor Dos. Regardless after several hours of erasing everything, turning on the machine seemed pointless. First something called Intel Boot Agent kept declaring there was no operating system on any storage devices. After playing around with the BIOS settings changing the boot order and putting copies of Linux onto everything from thumb-drives to cds without any luck, I eventually went back into the BIOS and disabled network boot. This solved one problem and caused another.

It was no longer declaring "no operating system found" after long stints of doing nothing but was now just a blank screen and a blinking cursor. Now finally something I recognized, I had done this to my computers plenty of times, I knew there was an easy way out, but just couldn't remember what it was. Naturally I spent the next 4 hours trying everything and anything, but then Google proved it couldn't solve every problem and as I went into that dark place of accepting I'd lost and reached for a hammer, the familiarity of the rooms emotion accessed that one piece of information I needed.

All I had to do was tap shift a bunch of times while it was starting up with [any] bootable operating system disk in the cd tray and installation would start, it would all be resolved... but by the time that thought was complete the laptop was in 12 pieces on the desk in front of me, strangely all the vowel keys must have seen it coming and were way on the other side of the room, and one fluid motion to the next I snapped the biggest remaining pieces over my knee, and will likely have a serious limp for the rest of my life.

So to anyone in the future, just hit shift a bunch of times.

Why Web Standards?

Tuesday, June 24th, 2008

When it comes to the web there are a hundred different ways to accomplish any one thing. The key disciplines in internet programming are structure, style, client-side logic, server-side logic, and storage. There are plenty of languages out there to satisfy each discipline, but they can become obsolete/unused and as the nature of the technologies running the code change, the languages themselves must adapt and change.

New innovations and concepts start to pile up as they are discovered in a given language and each developer having to hand code themselves a suite of special functions and method's to take advantage is a massive waste of resources--enter the framework. Frameworks are an incredibly important time saving tool for web developers. Aside from exploiting a given language from every possible angle and putting all that power into the hands of the developer. They make it easy for us to write neater more efficient code, often in more legible and fluent syntax than the original language offered. Frameworks allow the developer to bypass issues like those caused by cross-browser rendering engines, security, and high level language exploits as the necessary work-arounds and hacks are built into the framework. Frameworks are developed by communities, individuals, organizations, and private companies. The luxury of having a team of people working the kinks out of a language and the way it's interpreted is a great one, but it comes at a price. Each framework is developed at a different pace, in a different order, often with a different purpose in mind.

So what is the best approach to web development? What is the most effective suite of languages and practices? In the democracy of the web it's important to understand that any given approach is only as good as the support it gets; from the creators, developers, and end users. These are the main factors: which languages, frameworks, and practices are supported and innovated upon by it's creators the most; to the finest degree, which are contributed to and used and documented by the most developers, and which are the most amount of end users capable of viewing. Most end users don't have the experience to question the browser or plugins with which they view the web. They don't care or think about how they get to a virtual destination, they just want to get there and they want everything to work when they do.

Due to the politics and business deals of the major players the long standing state of the web has been one of division. End users stuck with browsers that came with their computers, and those who went in search of more functionality (bookmarks, tabs, etc.), or neglect to update, creates a situation where everyone's using different browsers and versions with different interpreters for the code on any given web site. A system where one line of code can be interpreted in 10 different ways depending on the end users who don't have the know-how or control to deal with it, is an immature one.

Even in the early growth of the internet these problems were apparent and so the Web Standards movement was born. An increasing amount of web communities, organizations, developers, and private companies are adopting web standards, even the biggest violator of these standards Internet Explorer--infamous for deliberately misinterpreting standards based code in favour of it's own proprietary code, is in development to finally be standards complient. Microsoft claims IE 8 is finally going to adopt many, if not all web standards, but is still in the beginning stages of development, even when they do everyone who uses IE6 and IE7 will not upgrade and so for a very long time it will likely be yet another cross-browser concern. It's important to note that even between the current standards compliant browsers, there is still some wiggle room of how they interpret the standards, some of which can affect user experience and site functionality to a relatively large degree.

Until web standards are refined to a point where one line of code has one universal interpretation and the democracy of the web is ruled by those standards and viewed by standards compliant browsers we are stuck having to hack away at code to make our sites and applications usable by as many people as possible. I believe to move towards a culture where our beliefs and values are reality and commonplace, we each have to practice those beliefs and values, regardless of whether they are accepted by our current culture, the norm, or the majority. So anyone reading this visit [http://w3c.org], get a standards compliant browser, I love Firefox 3 [http://firefox.com], and write standards compliant code.

Embedding fonts in Flex 3

Friday, June 20th, 2008

Fonts are the creative content of the font designer or foundry, so if you don't have a collection of fonts you've paid for, and aren't planning on purchasing some, you should stick to free fonts. A good place to start is Google, you'll find plenty of foundries who make a few free fonts, and several sites like [http://www.fonts.com/]. You may choose to embed a particular font that came with your operating system for the sake of cross-platform uniformity as well, however you still need to make sure that it is either an OTF (Open Type Font) or TTF (True Type Font), as Flex works with these file types. There are ways to convert postscript and other font formats to OTF/TTF but it's tedious and you're better off finding a different compatible font

You can also load fonts as an external resource in your apps similar to just calling a system font, however embedding them is the way to go. Embedded fonts can be anti-aliased, take part in effects, and are handled as a true asset and thus with a higher regard in your application.

There are a number of ways to embed fonts in your Flex applications. If you're embedding a font that's active in your system you can specify the system name as in the following example:

@font-face {
src: local("Arial");
fontFamily: MyFont;
}

Likely however you'll not want to keep a whole bunch of fonts active or have to think about activating your project fonts every time you compile, in which case you can copy the font file to your project directory. In the example below the Arial font is in a 'fonts' sub-directory of my project:

@font-face {
src: url("/fonts/Arial.ttf");
fontFamily: MyFont;
}

Note: If you use spaces in the font family as in "My Font" you'll run into an issue where the font appears in Design View but isn't compiled with the app.

There are other options that can be specified to customize your font-face:

fontStyle: normal | italic | oblique;
fontWeight: normal | bold | heavy;
advancedAntiAliasing: true | false;

These style declarations are placed within the mxml <mx:Style> tag. The above code uses CSS, which is best for styling and skinning your application, but if you prefer you can do the same thing in actionscript.

For more information on how to, and why you should/shouldn't embed a font in your applications refer to [http://livedocs.adobe.com...fonts_09.html]

Keep in mind that font files can be quite large, in the 5-12MB+ range and that size will be added to the weight of your application. It's best to use lighter fonts when creating online apps, in which case try to find one's under 200KB.

Firefox 3

Wednesday, June 18th, 2008

Firefox 3 has finally been released. The Mozilla Foundation set to break a world record with the largest number of downloads within a 24 hour period. It started Tuesday at 1:00PM Eastern, with the Firefox blog reporting consistently about 14,000 downloads/minute. What's even more incredible is the report on their web traffic which is said to have been pushed "well over 2 Gigabits a second of just pure HTTP traffic...in addition to 13 Gigabits a second or so of download traffic."[http://developer.mozilla.org/devnews/]

Download day is over and the world is waiting for Guinness to validate the more than 8 million recorded downloads within 24 hours. Web developers everywhere are looking forward to having a secure standards compliant cross-platform browser with majority market share. With this massive boost of downloads, and the Colbert Bump, there's no doubt in my mind that we will finally be able to build standards compliant sites and applications before having to deal with or even think about hacks and proprietary code to satisfy a diminishing IE crowd.

It's just another example of a community overthrowing a corporate monopoly, and one more step toward a global community where knowledge and information is free and abundant, corruption and success cannot exist together, and everyone is on an equal plane with equal opportunity regardless of [anything].

Now that download day is over Firefox 3 will soon be pushed through as an update for previous versions of Firefox.

Download Day 2008