Widerbug 1.3.0 for Firefox 3

The Firebug team has been hard at work squashing bugs and making Firefox 3 related improvements, culminating in the release of Firebug 1.3.0 yesterday. Some of the notable changes include:

  • Better debugging performance when dealing with large JavaScript files
  • More reliable ‘console’ object for logging
  • Alphabetized DOM properties
  • Added localizations
  • Over 50 bug fixes

After some minor modifications, Widerbug 1.3.0 is ready for use on your widescreen display in its signature 2-up layout, complete with all the changes from above. As usual, head over to the Widerbug page to grab the latest version (please leave comments and note any bugs on that page).

Widerbug 1.3.0 for Firefox 3

iPod Screen Scratch Removal Revisited

Several years ago, I recommended RadTech’s IceCreme as a great solution for cleaning up your iPod’s scratched-up screen. While I still stand by my results and recommendation, IceCreme isn’t the sort of thing you can find at a nearby store, and is also a little pricey. Removing scratches from iPods and other pocket-bound electronics remains a common problem, so I thought it would be worthwhile to test some of the other available options. Additionally, since nicks and scratches occur on more than just the screen, we’ll also test the solutions elsewhere on an iPod.

For this little experiment, I chose three solutions offering varying levels of abrasiveness: Colgate toothpaste, Brasso metal polish, and Easy-Off oven cleaner. All three promise to leave their intended surfaces shiny and clean, and in the case of the latter two, free of scratches. We’ll see how each fares when put to use on both the front plastic and back metal of an iPod. To keep things clear, each polish will be used in a masked-off area, hopefully leaving a clear division among the results.

The target iPod is an already well-used 4G 20GB iPod, with most of its still working inner parts removed and replaced with padding just to help sustain its form while being polished. Donated to the cause, this iPod will be beat up even further, with even layers of light scratches, heavy scratches, and deep cuts, simluating everything from normal wear to keychain induced destruction. It has surely seen better days, and is now destined for that great Apple Retail Store in the sky, all in the name of science.

I started with Brasso first, since it has been recommended many times since my last scratch removal post, both by commenters and firsthand accounts. If you’re attempting this yourself, be sure to work in a well ventilated area, as Brasso smells very strongly of ammonia, and might start to irritate your eyes after a short while!

scratch_ipod_brasso

 

After only five minutes of polishing, the results were quite good, with nearly all of the light and medium scratches completely removed from the screen area. Deeper cuts remained, though their rough edges were significantly smoother.

scratch_ipod_brasso_done

 

Toothpaste was next on the list, and while it left the iPod minty fresh with a sparkling shine, its scratch-reducing effects were barely noticeable. Due to its sticky consistency, it was also more difficult to polish with than the more liquid Brasso, yielding poorer results for double the effort — a total flop.

Oven cleaner was last, and I really had no idea what to expect with it. Claiming to leave glassy surfaces shiny and free of scratches, it sounded like a possible winner. As it turns out, it’s not much more than a repackaged kitchen cleaner, resulting in a streak-free but still heavily scratched iPod. I’ll end up cleaning my glass top oven with this one, and nothing else.

With the front of the iPod clearly showing Brasso as the top choice, it was time to see what worked best on the scratched metal backing of the iPod.

 

scratch_ipod_scratched_back

Again, after just a few minutes with each polish, Brasso came out on top, while the other two trailed woefully behind. The Brasso-polished back still had quite a few scratches, though far less pronounced than when I started. All of them, including the deep cuts, had a very slick feel, whereas the others still left the surface pretty rough.

scratch_back_comparison

Convinced that Brasso was the right choice, I went back and finished off the front, cleaning up all but the most severe marks on the screen.

scratch_ipod_front

 

Given the results of my tests, I can easily recommend Brasso as a great iPod polishing solution that can be had for under $3 at your local stores.

iPod Screen Scratch Removal Revisited

Learning Cocoa for the iPhone

These last few weeks, I’ve been teaching myself Cocoa to learn what makes Mac OS X and iPhone OS apps tick. While Objective-C is quite a departure from my usual web development world, Cocoa has quickly become one of my favorite languages, as it takes care of much of the drudgery of pure C and has plenty of useful frameworks to get your application up and running quickly. Here are some of the best resources I’ve found so far:

  • Cocoa Dev Central and Become an Xcoder are both excellent tutorials for beginners, written in a clear, straightforward manner. They also explain the ins and outs of memory management, which is critical on platforms like the iPhone and iPod touch.
  • Stanford’s CS193P lecture notes and examples have proven to be one of the best resources for learning Cocoa, particularly for the iPhone. These notes and tests offer Cocoa Touch in bite-size chunks, with a little bit of “on your own” work to ensure you know your stuff before moving on.
  • Google Code Search is a good last resort for examples of how others are using a small bit of code or a particular class. For more accurate results, append “lang:objectivec” to your search string to narrow results to only Objective-C code.
Learning Cocoa for the iPhone

Consolas Cursor Fix

If you’ve attempted to use Consolas as your choice programming font on the Mac, you may have noticed (as I did) an odd issue with the font, where your blinking cursor hangs much lower than the current line. Oddly enough, this little issue only seems to affect Mac OS X. Even the Consolas set that ships with Microsoft Office 2008 has the same problem! Yet, when the same exact font file is used under Windows, the cursor position is correct.

John Gruber mentioned that BBEdit 9.1 now ships with Consolas as its default font, so I decided to see if it had the same cursor problem I had experienced in the past. As it turns out, BBEdit’s version of Consolas works just fine, as seen in the image above. However, it doesn’t include the other styles like Consolas Bold, Italic, and Bold Italic.

Through one way or another, the copy of Consolas that ships with BBEdit 9.1 is different than the one that ships with Microsoft Office 2008. To make system-wide use of the working version, download BBEdit 9.1, mount and open the .dmg, and navigate to:

(Control-click BBEdit, and choose “Show Package Contents” to get inside the application bundle): BBEdit.app/Contents/Resources/Fonts/consola.ttf

Copy consola.ttf from BBEdit’s “Fonts” folder to your own Fonts folder at /Users/you/Library/Fonts, or /Library/Fonts if you want to make it available to everyone who has an account on your computer. Then, fire up your favorite editor, set Consolas as your preferred fixed-width font, and get coding!

Update: Bare Bones has apparently changed the version of Consolas that ships with BBEdit versions later than 9.1, and they now have the cursor problem as well…

Consolas Cursor Fix

iPhone NDA Dropped

After hearing the cries of thousands of upset iPhone app developers, Apple has lifted the non-disclosure agreement covering (released) iPhone software. Developers can now freely talk about the inner workings of their applications, write books, publish blog entries, etc. Communicating developers means solutions to common problems get solved and shared, resulting in better software, making the iPhone and iPod Touch platform better as a whole.

For some time I’ve been worried that the NDA was going to remain in place indefinitely, silencing those who Apple needs the most, but it appears Apple has finally taken a positive action to help their App Store environment grow further. If you thought there was some cool stuff on the App Store now, just give it time…

iPhone NDA Dropped

iPhone and iPod Touch Icon Template

While working on some iPhone and iPod Touch apps, I found that the iPhone OS automatically masks and overlays your application icon for quick and easy development. You supply a square 57×57 pixel image, and it rounds off the corners and overlays the Mac-like gloss to create a consistent look.

When developing an icon for a Touch-based application, it’s handy to be able to see what your rendered creation will look like without going through the hassle of exporting your icon, compiling your code, and running your software every time a change is made. To that end, I present a small Photoshop file which very closely mimics the iPhone-applied mask and gloss, which you can place over top of your in progress icon layers to approximate the final result. Also, if you dislike the gloss, or have something special in mind, you can set a certain flag in the application’s Info.plist to disable the gloss… I hope my Photoshop file will help others create great looking Touch app icons!

Update: By request, I’ve added a 512×512 version of the template as well, so you can get a good feel for what your icon will look like when displayed in iTunes. Both files are now combined in a zip archive, downloadable here.

iPhone and iPod Touch Icon Template

fmTuner: A Last.fm Plugin for WordPress

fmTuner is a WordPress plugin for retrieving song details from your Last.fm profile and publishing them anywhere in your WordPress theme. It provides options for choosing among your Recent, Loved, or Top tracks, as well as tools to adjust the update frequency and appearance.

Of particular note is the customizable Display Format option. Using simple tags like [::artist::] and [::image::] intermixed with regular HTML, you can tweak your Last.fm tracks exactly how you like, or however your WordPress theme requires. You have full control!

Download

Download the latest fmTuner from WordPress.org

Requirements

  • WordPress 2.7 or newer.
  • PHP 5 or newer
  • Basic knowledge of PHP, HTML, and WordPress.

Installation

  • Upload fmtuner.php to a directory inside /wp-content/plugins/ directory. For example: /wp-content/plugins/fmtuner/fmtuner.php
  • Ensure /wp-content/plugins/fmtuner/ is writable by your webserver.
  • Activate the plugin through the “Plugins” menu in WordPress.
  • Set up options in the “Settings” menu in WordPress.
  • Place the PHP code if(function_exists('fmtuner')) { fmtuner(); } in your templates, to call up fmTuner.

Release History

  • fmTuner 1.1
    Released on Feb. 1, 2010
    Added a placeholder image field to the fmTuner Settings page, which will be substituted when tracks have no artwork.
    Tested under WordPress 2.9.1.
  • fmTuner 1.0.8
    Released on Nov. 3, 2009
    Fixed a bug with the [::url::] fmTuner tag that caused Last.fm links to appear incorrectly.
  • fmTuner 1.0.7
    Released on Apr. 23, 2009
    Tracks with foreign character sets now display more accurately.
  • fmTuner 1.0.6
    Released on Mar. 29, 2009
    You can now display more than 10 Recent Tracks, and you should get fewer tracks without artwork.
  • fmTuner 1.0.5
    Released on Mar. 22, 2009
    Track information is now properly escaped to handle $ signs, quotes, and other non-alphanumeric characters.
  • fmTuner 1.0.4
    Released on Dec. 14, 2008
    Made minor tweaks for fmTuner Settings page under WordPress 2.7.
  • fmTuner 1.0.3
    Released on Nov. 15, 2008
    By request, a [::number::] fmTuner tag has been added, which emits a sequential number for each track (starting at 1). This is particularly useful for CSS and JavaScript display purposes.
  • fmTuner 1.0.2
    Released on Oct. 5, 2008
    Added a cURL-based alternative to file_get_contents to hopefully resolve “URL file-access is disabled” issues. If allow_url_fopen is disabled in the php.ini, cURL will be used to fetch the Last.fm feed instead.
  • fmTuner 1.0.1
    Released on Sept. 9, 2008
    Added better failure checking and informational messages, removed development code, and updated instructions.
  • fmTuner 1.0
    Released on Sept. 6, 2008
    Initial release.
fmTuner: A Last.fm Plugin for WordPress