AppleScripts for iTunes

November 11, 2007

AppleScript is the hidden “glue” language that binds software on the Mac together and allows for unparalleled interaction between apps. When built into a program, it allows anyone with the right tools to automate nearly any function of the appication. In fact, it’s what Apple’s Automator is built upon, making AppleScript more accessible to end users who don’t want to know or care about things like variables and loops. Where Automator is as easy as drag-and-drop, programming AppleScript can be complicated (perhaps more so for seasoned programmers).

Doug Adams, however, is an AppleScript wizard, and his huge library of scripts covers all kinds of Mac applications. Of particular interest are his iTunes scripts. He offers dozens upon dozens of cool and useful ready-to-run code samples that do all kinds of tricks with iTunes, including managing playlists, embedding and exporting album artwork, finding and replacing text in track names, and tons more. For getting more out of your Mac and iTunes, check out Doug’s AppleScripts library.

Leopard Compatibility Notes

October 28, 2007

Leopard is finally in the hands of thousands of Mac owners who are now getting their “new Mac” set up the way they prefer. While some found frustration with the Upgrade install, I backed up my important stuff and performed a full Erase and Install, resulting in a fresh system with no lingering apps or tweaks from the previous system. So far, my experience with Leopard has been a great one, with only a few software updates required to make things run like new. Here’s a run-down of some of the notes I made while getting software working:

  • Backup

    Apple’s .Mac-bundled “Backup” application received a small update bringing it up to Leopard standards, meaning many users can now successfully retrieve backups created before installing the system. Since I erased my previous OS install, being able to bring forth my backups stored on my networked G4 fileserver was one of the first things I needed to accomplish – something I’ll hopefully only need to do once with the advent of Time Machine. (Thanks for the tip, Jaron!)

  • Adobe CS3 Compatibility

    I had read a number of reports concerning CS3 compatibility with Leopard, and was wary of even installing them again, but I was glad to find that Adobe CS3 seems to work just fine in Leopard. I’ve run Photoshop, Illustrator, and Bridge for a few hours now without issue!

  • VMware Fusion

    I’m a big fan of using VMware on Windows to try out software before actually installing it on the host PC, and couldn’t be happier with the implementation on the Mac side of things, as well. VMware Fusion for Mac just hit 1.1 RC, and is nearing the final 1.1 release. The update brings, among other things, Leopard compatibility which works great.

  • Transmit & Unison

    My two must-have utilities from Panic, Transmit and Unison, are now Leopard ready and run with nary a hitch. Way to go, guys!

  • Font icons

    Images, PDFs, and Keynote presentations aren’t the only icons branded with the actual content they contain. Font files’ icons are updated to show the actual typeface on right on the icon. How cool is that?

I’m sure there’s a mountain of other cool things in Leopard just waiting to be discovered, and software developers will be publishing Leopard compatibility updates for the next few weeks at least. Keep an eye on MacOSXHints.com, one of the best places to check for the latest Leopard tweaks and tips!

10 Photoshop Selection Tips

October 8, 2007

Select a Layer Outline

Command-Click a layer thumbnail in the Layers palette to load a selection of its outline, including any anti-aliased (non-jaggy) edges. If your layer has an inherent opacity set (for example, if you opened a partially transparent PNG image), the opacity difference is included in the selection. Normal opacities set in the Layers palette, however, do not affect the selection.

Use Multiple Selections

Once a selection is made, there are a number of operations you can perform to modify your selection. Holding Shift and making an additional selection will add to your current selection, and Option will remove from it. Holding both Shift and Option will do something unique: wherever your two selections intersect will become the new selection.

Combine Layer Outlines

Using the first Command-click thumbnail hint with Shift, Option, or Shift+Option modifier keys, you can add, remove, or intersect selections using outlines of other layers. Your cursor will show +, -, or x to indicate which type of operation will be performed, respectively.

Move Selection While Dragging

While in the middle of dragging a selection, you can hold down the spacebar to move around the origin of the selection. This is extremely useful if you find that your selection is a bit off – Instead of re-making a new selection from scratch, you can make adjustments “on the fly.” When the spacebar is released, the selection seamlessly drops back into the default “grow” mode, using the new origin as the starting point.

Start at the Center

Hold down Option after starting a selection to expand from the middle, causing the outline to grow symmetrically in each cardinal direction. Add the Shift key into the mix Shift to maintain a square shaped ratio.

Fixed Ratios and Sizes

Using the selection tool options, you can set a fixed ratio or specific size, both of which are great for slicing out content with a pre-determined size, like that of a computer wallpaper. Using the ratio, you can select a portion of an image that would fit on your desktop. Once you have the portion selected, you can scale it down to the native resolution of your display, being sure that it will scale proportionally to the correct size.

Quick Mask Mode

By flipping into Quick Mask Mode, you can use paintbrush tools to “paint” the beginnings of a selection. When you leave Quick Mask Mode, the painted area becomes a selection which you can use right away or modify further.

Transform!

Use the Select, Transform Selection command to distort the current selection. Note that this applies to just the selection outline, not the content within it. (To change the content, do Edit, Transform, pick a type).

Selection Paste Target

By making a selection and then pasting content into it, you can target exactly where the pasted content will land. Without a selection, pasted content simply gets dumped in the middle of the document.

Save Selections with the PSD File

Once you have your beautiful selection made and ready to use, you might consider saving for future use if it was particularly complicated to make, or if it’s a handy, reusable shape. Photoshop provides two simple commands for saving and loading selections. Choose Select, Save Selection to commit your selection to a given name. Retrieving it is as simple as picking the Select, Load Selection command, and choosing the name you saved the selection under earlier. Best of all, these named selections are included in the file, meaning you can save and re-open the document, and reload selections at a later date.

How To: Put Together an Affordable Laptop Repair Kit

September 25, 2007

Having your prized laptop unexpectedly bite the dust is a real drag, but with an affordable set of tools ready, you can ensure your machine lives a long, healthy life with minimum downtime. Here are my personal picks that won’t break the bank:

Presented with a failing laptop, the first step on the road to recovery is figuring out where the problem lies. Even if you can’t yet narrow down the issue to a single component, identifying the essential parts and ordering them by “most likely” to “least likely to fail” will offer a prioritized checklist to run down while working. If you’re unsure of what may be causing a problem, a good rule of thumb is to start with the obvious and work your way back to the motherboard – often the source of problems is the least expensive part in the chain, as computer parts are generally purchased from the lowest bidder. If your laptop can’t find it’s operating system, the hard drive might be dead. No video on the LCD? Something screwy with the display assembly. CD won’t eject? Probably the optical drive. In most cases, replacing the motherboard on the computer is the most complicated and most expensive, so it’s worth your time and money to start at the cheap end and work your way back.

Researching problems on web forums is a prudent starting place, as are manufacturer service manuals. If you can clearly explain the problem you’re having and show that you’ve attempted to do some of your own research, most forum members (like those on MacNN) will gladly assist. As far as manufacturer-offered support goes, most manuals are free, however Apple in particular is picky about who gets this information. iFixit, MacFixIt, and xlr8YourMac are a few trustworthy and respected sites which help make up for Apple’s stinginess with documentation. If you look hard enough, though, Apple’s official repair guides can be found on the net, despite their best efforts (and, really, the iFixit guides are more detailed).

Screwdrivers

With knowledge in hand – or in PDF form – and the courage to crack open the case of your laptop, you can start with the basics: a screwdriver set. Many will make promises of years of durability and offer second-to-none craftsmanship, however I find that a cheap little set will do just fine for most projects. Stanley offers a $5 6-piece screwdriver set, with Phillips and flat screwdrivers of a couple sizes (also at Amazon. And if you’re not put off by Wal-Mart, you can pick one up there, as well.). Just one little set has served me well for years of computer repair, especially on laptops.

If you care to get a little fancier, you can find a more expansive $15 set on eBay. I also have one of these sets, and am unable to find a manufacturer on any of the parts, however identical looking screwdrivers can be found at RadioShack, made by Kronus. It includes a wide assortment of changeable bits, including hard to find ones like Torx T4 (for iPod logic boards and cell phones) and a number of Phillips sizes. Search eBay for ‘torx’ and look for the black and red handle and white bit case. This kit is, as advertised on eBay auctions, of surprisingly good quality, despite the curious absence of a manufacturer imprint on the tool or casing.

Nylon Pry Tool

An absolute must for performing professional-looking laptop repair is the ability to remove plastic bezels without chewing up the edges with a rigid metal tool. As noted in my earlier post, Apple recommends a nylon pry tool for accomplishing this, and I can vouch for its extreme utility on any brand laptop. Computer manufacturers often affix plastic covers with slightly flexible clips, and this $2 tool will effectively and cleanly undo them, allowing for future re-assembly.

Straightened Paper Clip

The standard computer fixing tool for many a geek, a straightened paperclip can be had for free, but offers the ability to exert pressure in the most narrow of spaces. It’s also no coincidence that nearly all tray-loading computer optical drives can be safely forced open using the tiny paperclip hole built into their front covers. Keep a few on hand.

Ice Cube Tray

Once you start getting deep into a laptop repair, keeping the screws of various sizes in order can be a monumental task of its own. By keeping a simple $1 ice cube tray nearby to hold loose screws (preferably labeled in a fashion you can understand hours or days from now), you’ll be able to remember how it all fits together. Keeping screws and parts organized takes time away from getting the job done, but if you’re interrupted or happen to bump the table, you won’t be utterly lost when it comes time to put everything back in place.

Hemostats

A pair of hemostats are outstanding tools for extracting otherwise impossible to reach connectors, as well as plugging them back in. The occasional runaway screw can also be retrieved with ease, possibly avoiding unnecessary disassembly. Prices range from $3 at RadioShack to upwards of $10, depending where you search. Both curved and straight nose hemostats are of nearly unlimited use.

Multi-meter

Last, but not required, is a small, decent multi-meter. Problems can often be traced to a lack of power or electrical connection, and even the cheapest of meters will indicate both. When set to measure voltage, you can check that a component has the necessary power, and when set to measure resistance, you can assert the continuity of a circuit just by touching a probe to either end of the wire and watching for a huge drop in resistance. Unconnected wires will show infinite resistance, while a good wire should have extremely low resistance. A self-contained, pocket-sized meter can be had for $20 at RadioShack, and is well worth the cost.

So there you have it: a complete kit for about $30, all of which will easily zip up into your laptop bag, ready to break out and make repairs on the go. Print out your specific laptop’s service guide for quick reference, and you’ll be poised to tackle problems whenever they may crop up. If you were expecting a “priceless” item on the list, then here you go: confidence. Work slowly, think before you pull on a connector or wire, and take pictures if you have to.

Hiding Your "Untitled" Boot Camp Drive

September 21, 2007

After getting back to Boot Camp from a dual-boot Mac OS X system, I remembered how disappointing it was that I couldn’t rename the Windows NTFS volume from “Untitled” to something more appropriate. The Garbage In Garbage Out blog has a tip that will accomplish the next best thing: Hide the Boot Camp volume from your Desktop.

Using the SetFile utility from the Developer Tools package that came with your Mac (on the second disc), you can effectively remove the volume from view in the Finder, while not affecting its normal operation or visibility anywhere else in the system. Great tip!

Mastodon