Archive for January, 2009

Internet Explorer 8 still rendering on as 7 in Intranet (local) editing

In IE8, Tools > Compatibility View Settings > Uncheck “Display intranet sites in Compatibility View”.

Although this may come as a surprise for you, Microsoft does has a point doing that. In large organizations like governments, intranet applications that date back to IE 6’s omnipotency are very omnipresent. Thus, keeping backward compatibility by default on all Intranet websites is the safest choice to make. There’s probably more than a ten-fold difference between the amount of corporate intranet users and home intranet users.

CSS Tables – The Limitations

Oh, CSS, you’ll never give up do you. So, think again, float is not dead. How’s that? First off, take a CSS table for layout. Secondly, realize that, in a table, there is no way to seperate table blocks, except if you put something in-between.

What used to be this with floats:

<div class="table_table">
<div class="table_row">
<div class="table_cell"></div>
<div class="table_cell"></div>
<div class="table_cell"></div>
</div>
</div>

Is now this ugly thing with CSS tables:

<div class="table_table">
<div class="table_row">
<div class="table_cell"></div>
<div class="table_cell_spacer"></div>
<div class="table_cell"></div>
<div class="table_cell_spacer"></div>
<div class="table_cell"></div>
</div>
</div>

(Sorry for the lack of code indentation, WordPress is acting stupid)

Anyways… spacers! Oh god, no. Luckily, borders can aproximate spacing and most image-based design cuts won’t need those margins in-between blocks. Actually, the fortunate news is that about 90% of the time, the spaces between blocks is what you don’t want.

I don’t think CSS tables are going to make CSS logic that much easier. If you were using floats in a good way, chances are you won’t have to change much in your HTML structure. I didn’t say you won’t have to change anything! Yes, CSS tables eliminate the need for container blocks or float clears everywhere and yes, CSS tables will fix a lot of bugs and make possible a lot of cool things; like menues that expand with content and 100% height properties that base themselves on the browser window, not parent CSS block, oh god yes.

CSS Tables – The Next Best Thing Since Ice-Cream

If your a new web developer, you’ll be amazed at how logical today’s world of the web can be. Learning CSS tables firsthand in CSS would be dream-like; I envy future students.

But for modern web developers, for the few who truly master the trickery art of CSS design, CSS table is nothing short of amazing. While reading Everything You Know About CSS is Wrong from Sitepoint, you seriously have to buy this book, my jaw dropped. I couldn’t stop reading the basics of CSS tables with a constantly growing excitement to re-code all of my sites in CSS tables.

Really, the next best thing since the invention of ice-cream, or chocolate, or whatever godly desert basis you can think of, tasting CSS tables after having been proclamed CSS guru by your friends is heavenly. I know a lot in CSS. In my short life-span of web developement carreer, nothing has ever been so cool to learn.

To give you a good idea of my history, when I entered college (we call it Cégep here in the province of Québec in Canada, and it’s before University), I knew nothing about HTML and CSS and was learning to do everything via Dreamweaver’s WYSIWYG interface. Well, so long for those wasted hours, at least I know Dreamweaver’s interface by heart. I quickly realized how coding directly was superior. By the half of my first college year, I was coding without a WYSIWYG in all of CSS’s complex floating glory, learning mind-bending tricks I have yet to see in use by anyone else than some elites on other parts of the planet. So no, I haven’t met anyone better than me in CSS in person, yet. I am now in my third year of college.

Keep in mind though that layout is just half of CSS, the other accessibility part being largely ignored and unexciting, it’s always been something I could count on when it comes to showing off CSS skills. You don’t necessarily know what’s the difference between an <i> tag and an <em> tag if you know how to use float CSS.

But enough talk. Download the free chapters of Sitepoint’s book and learn ahead. (I thought about puting the information here directly, but Sitepoint deserves too much credit for publishing that book).

The Truth About Your Battery

OpenSUSE 11.1 is amazing.

I just installed it on my sister’s old laptop and it came up to me with this dialog;

Apparently, despite being 100% charged, by battery’s capacity was at only 42%, indicating a broken or aged battery. So, want to discover how sucky your battery is in comparison to when you bought it? Go get OpenSUSE.

Edit: Ubuntu 8.10 also has the same feature. This looks like a regular UI feature of GNome associated with Linux hardware probing capabilities, not a distro-speficic thing.

Anime: Changing Artist Halfway

I was listening to The Third and uppon listening to 13, it seemed to me the drawings were awkward, making the characters look fat. So, I did a comparison with past and future episodes, and to my delight, it’s the only episode that’s this way.

The change is stunning. It really is another artist.
Let’s take a look.


The second image is the original of course; I’ll keep it this way from now on. But, hey, if that isn’t obvious. Just look at the nose!


Although closer to the original, it’s far from it. The nose, the face’s roundness, the hair detail. Everything!


Honoka and Millie. This one’s most notable aspect is probably the lack of hair detail on Millie.


And for the final, fat face!

Really, I hope the artist of the filler never makes Anime or Manga. May you stay as a good in-between-animation frame artist.

Output Power is Everything

Besides Signal to Noise ratio, of which you can really only hear the differences when listening in extremely quiet environments, that is, perceiving more noise on a device than another (yes, this is no audiophile trip, you can really hear the difference from a player to another, and some players are good enough that you don’t hear any noise), the thing you might want to look out for on an MP3 player is its Output Power.

Now, because of battery, we measure MP3’s output power in mW instead of W. If MP3 players used output power measurable in W, their current battery would last 2 minutes. As such, the Sony NZW-A829, which sound awesome, only has 5mW of output power per channel. The average iPod is rated at 30mW per channel, a real step up, and my SimAudio amp is rated at roughly 100W per channel.

So, how does this make it sound different? It won’t reduce the noise or the sound artifacts produced by poor sound-cards like the Nintendo DS Lite’s (no idea about the other models) but it will produce stronger bass and obviously a louder output.

Technically however, it will only push your headphones or speakers at their maximum potential. We measure this “potential” in Ohms, a mesure of impendance. The higher the impedance, the more powerful your headphones or speakers can sound. But, the higher the impedance, the more ouput power you need to be able to drive the headphones or speakers to their maximum potential.

Impendance is like a resistance. Expensive headphones with really high impendance will sound like crap and will be really quiet on a device that can’t match it.

If you extrapolate the 100W per channel of my amp with the iPod’s 30mW per channel, you might be wondering what kind of crazy loud sound this gives in my headphones. Let me reassure you that it won’t blow your ears out. The amp’s headphone plug is toned down for headphones. Regular speakers need a much stronger output power to produce sound. Also, don’t forget we’re talking about non-pre-amplified speakers here, not the ones that you plug in a power outlet (ex: PC speakers), these have an integrated amp. In the same regard, powering large speakers with an iPod is an impossible task.

The typical cheap eardbuds are rated at 16 Ohms of impedance. This amount is roughly topped by an iPod. However, more expensive headphones like the Sennheiser HD650, rated at 300 Ohms of impedance will have a lot of difficulty sounding great on anything else than the most highend systems. You might be surprised when the smaller heapdhones of your friend sound better on your iPod than your HD650.

This is a good buying decision to make. Don’t consider the HD650 if you’re a road warrior, you’ll be disappointed. Mind you, they’re also very fragile peices of technology. In any cases, always try to find out the output power of an MP3 player before you buy one. Cowon has some really powerful players too.

There is a sad thruth about output power ratings though: the way they are rated. To measure output power, you have to run it against an impedance rating. Cowon’s S9 for example, has a 29mW of output power per channel rating on 16 Ohms headphones. While this may sound close to the iPod’s 30mW, the iPod’s rating is made against 32 Ohms headphones. This effectively means the iPod has a 60mW output power per channel rating against a 16 Ohms pair of headphones, much higher than Cowon’s MP3 players.

The Future of Smartphones – It’s computer history all over again

During the 177th TWiT, John gave out an analogy about the smart phone market I thought was just brilliant. It’s probably the best take on the Smartphone future I’ve ever heard, so I’ll explore on its contenders right now.

PC vs Mac

What does PC vs Mac has to do with it you ask? Probably everything. Take a look at the Smartphone’s evolution pattern. It started out by basically taking a PDA, more or less a boosted agenda, and a cell phone, and mashing them together.

The smartphone platform then spread all over the place. RIM’s Blackberry came in as an inovative contender against Windows Mobile and Palm had its own stuff. And then came the iPhone, which, much like the original Macintosh, spewed life into the smartphone market, bringing in contenders from Samsung, LG, etc. All immitating, more or less, the iPhone or the Blackberry.

The recent announcement of the Palm Pre raises the question whether Palm can buy back its success. However, the smartphone market has really become a computer market. These devices are increasingly sophisticated, and with the addition of the App Store from Apple, it’s now all about the apps you can get.

Although it’s been done before with Windows Mobile and Palm PDAs, nothing has reached the extent Apple has. And this is where Google comes in, with Android. Since Android is an open platform, what’s mostly likely to happen is manufacturers like Palm, Samsung and who else will just become handset manufacturers, much like companies manufacture PCs today.

And then, you’ve got the exact same scenario as the computer industry. Two big contenders; one integrated hardware and software solution and one software only; Apple’s iPhone and Google Android. So where does Blackberry and others fit in? They don’t. Blackberry has already lost the ability to garnish an application developer community like Apple’s and the only thing that may well be capable of doing that is an open platform, in which case, Android.

Now, it’s interesting to observe in specifics why this is so.

Apple iPhone

Apple’s iPhone is the pioneer. It has a huge userbase and developer community. Simply put, it’s far from over and is probably going to stay as a premium smartphone for ever, much like the Mac has always been a premium product that costs more than what you can get for a PC.

One thing’s for sure, if there is such a thing as repeating history, Apple’s going to be part of it, no matter what.

Microsoft Windows Mobile

When comparing Windows Mobile to the other contenders for that future rivalry, you can’t really compare it to the iPhone. If anything, it’s going to compete against the iPhone. But Apple already has the premium end of the branch. Microsoft cannot hope selling Windows Mobile to developers if it is also associated with licensing costs, like Apple.

Unlike Google, there is little chance for Microsoft and their current position to succeed at an open platform. The smartphone market is much focused on Internet access and PC-like features. Google has its search engine to pop up in its Android platform, Microsoft has Live Search… not much of a money maker. Also, you have to keep in mind the only reason Microsoft still has the PC market is because peolpe keep buying PCs. That makes a circle effect where the more PCs bought, the higher number of developers make software for the platform, the higher numbers of users want to buy that platform, and on and on.

This time, the smartphone arena is different and there is very little way for Microsoft to convince developers to make anything for their platform. If they were to immitate Google, a good solution to make their platform popular, it wouldn’t be profitable for them, unlike for Google.

Palm

The Palm Pre may be a brand new sexy and exciting phone, but its prospects are short. Palm did think ahead in the ways of applications and created a Web OS. Per say, it is possible to make applications very easily, but the smartphone isn’t the most performant platform on earth, and it’ll never be. Pushing developers to make web apps only for a platform maybe isn’t the best idea.

Think about it, the iPhone would already have Safari on it to run those web-like apps equally well, that doesn’t make Palm’s idea very compelling for developers.

Blackberry

Blackberry is even more done than Windows Mobile. Unless RIM jumps on the band wagon and produce handsets for Android, they’re gonna eat dirt. Blackberry can’t possibly keep up when it comes to applications, there’s no way developers are going to go for such a closed platform, and it’s virtually infeasable financially for RIM to do the same as Google.

RIM only sells phones, they don’t have that whole infratructur of stuff behind them. One’s thing for sure, if it comes down to Blackberry winning the Apple’s contender game, Microsoft would have won it 10 years before. In other words, it’s never gonna happen.

The Rest

Well, the rest, Samsung, LG and other iPhone puns, we don’t even need to talk about. These companies are handset makers and will jump on whoever’s band wagon they have to, no question. My guess is obviously Android, some like HTC already are, even though HTC can’t really been counted since they’ve always only been handset makers.

Google

The easy guess is Google. That’s not very surprising.

When you have the world’s most used website, the world’s most used search engine and a group of followers comprised of the most significant companies in its market (HTC, NTT DoCoMo, Sony Ericson, Intel, to name a few), you have a winner.

Android is no question, right now, the best contender to Apple. The easy guess is we’ll see history repeats itself, only this time, with Google instead of Microsoft. Take a good look at the names up there, NTT DoCoMo, rings a bell? Yeah, the biggest cell phone provider in Japan, the place where cell phones are so advanced, is in the Open Handset Alliance. This means that the future of mobile phones is Japan is, you guessed it, Android.

Taking a Look Back

I think that, taking a look back at all that text, the thing that’s actually the most accutely buzzing is the fact that Apple is the no question contender. We’re not talking about who’s going to stay, we’re really talking about who’s going to compete against Apple.

Much like the iPod and the Mac, although the later had a sadder fate, it’s kind of impressive. I would have said Apple was a doomed company, OS talking, since Microsoft had so much future-like incentives. But in reality, Apple has never been so well placed. We’re talking about terminal computing becoming more significant. What’s an iPhone? A terminal computer to your Mac! What’s an Android smartphone, a terminal computer to Google.

Powerful stuff.

Audible – Not DRM-Free but Excellent Customer Support

The other day I came about to a small surprise. I format computers a lot so a lot of my licenses have to be re-activated with a new OS counted as a new computer.

Unfortunatly, Audible only allows a maximum of three computers to be activated at the same time. If you don’t purposely disactivate your account, it’ll stay activated and when you have it on three systems, whether you can activate them or not, you’re done for it.

Fortunately this isn’t much of an issue as you can call Audible anytime and they will reset your activated devices. I called and I was immediatly serviced by someone who looked like this is something that happens a lot of time. But he still remained very pleasent and knew exactly what was my problem, I’m guessing this isn’t the first time it happens.

So even though Audible books are DRMed and you can’t play them on incompatible devices, Audible supports its fare amount of MP3 players and they have great support. iTunes and iPods are the best for Audilbe of course.

Thank you Audible!

DSD Applied to Video – Beyond the Pixel

DSD is somewhat Ironic (What is DSD) because its process is quite literaly immitating the analog signal. But in audio, much to the contrary of video and imaging, this is the best thing to do.

In imaging however, the saying goes digital is better since it can describe every pixel in a lossless matter, which is good because this is how monitors work.

However, digital imaging is stuck to pixels. You can’t get more than what the pixel gives you with a pixel. With traditional films, you could rescan a film tape and get a greater amount of detail in it. A very direct impact of that is that traditional film cameras (the very expensive ones) are expected to be around 120 Mega Pixels, in theory, much higher than today’s best Digital SLRs.

While this theory is largely eliminated by the fact digital imaging never loses quality because you can’t degrade a bit of numeric information, it’s either a 1 or 0 and that’s where it ends, I came to the conclusion DSD could be applied to imaging, digitally, much the same way as it was for audio.

Think of it, the technology already exists. NTSC is transported over analog as a modulated signal on a 4.2 MHz bandwidth. Since this signal is essentially composed of waveforms, it could be digitally encoded in the same way as DSD: on a 1 bit high frequency stream using algorithms to describe its content. This could essentially describe visual content in a way that goes beyond pixels because it’s mathematically scalable functions stringed together.

But, this is a very “in the air” theory. Fixed images cannot be described on a lenght of time, so an image would have to be a peice of video. Editing such data digitally could prove immensily complex, the very reason why the best SACD discs are mastered from a PCM-based recording instead of a DSD stream. And as I am not scientific, there is probably a dozen of other holes in my theory, but hey, we can dream and you have to admit the idea is technically cool.

Tags: , , ,

The confusing world of Newlines – Why your text file may have become a single line

If you’re in the web business, you’re bound to have come across the phenomenon of opening your text file and have it appear completely on one line or in some kind of giberish.

While a lot of it can be attributed to localization and the use of incorrect encodings for languages, we’re gonna talk more specifically about Newlines here.

In simple terms, each system has its own way of encoding new lines in text files with special invisible characters. Windows uses a CR+LF, UNIX a LF and Mac a CR.

Now, Mac OS X is based on UNIX so the CR-only format doesn’t apply to newer Macs, only to pre-OS-X systems. Mac OS X uses a single LF for a new line.

So, if somebody gives you a text file made on a Linux machine or a Mac, chances are Notepad will open it on a single line. Some uploading systems automatically convert the file to that system’s format, and since your web server probably runs Linux, you’re bound to download back your file and open it in a single line.

A very good example is opening Engadget’s RSS XML file in Notepad. It’s pretty ugly. Now this doesn’t mean Engadget is working on UNIX-based boxes, rather, that XML file was probably automatically generated by somekind of PHP script running on none-other than a very common Linux server.

Open it in a proper text editor, say, Notepad++, and you’ll see all of its glory (and the confirmation it uses LF by checking some stuff in Notepad++).

The solution?
There is none.
Yeah… unfortunatly nobody thought of making that a standard yet so instead you’ll need to use a software that supports all the formats. Luckily, about every raw-text capable software on earth, even FrontPage and Wordpad, can recognize all formats, just, not Notepad. With a bit more badluck however, UNIX-based servers aren’t so polivalent as those big software suites and could possibly read your the extra CR in Windows encoded files as crap, resulting in mysterious application errors and what not.

The morale of this story is to choose your software.

  • Linux Server = LF capable editor (Notepad++, Dreamweaver)
  • Windows Server = Anything really, your server’s not going to panick if the code is on one line, except if it’s Ruby. Try to use Windows stuff in this case, any Microsoft software fits the bill, as well as Notepad++ and Dreamweaver.
  • General Public = Windows-compatible. The big majority of users are still on Windows, don’t go publishing raw-text files with UNIX newlines in them if you don’t wish for 95% of the planet to not be able to read your files. (remember .txt files open in Notepad by default, not Wordpad, so you don’t really have a choice but to accomodate for Notepad)

Tags: , , ,