I use the following script to rate my iTunes tracks. As you can see, in addition to changing the track rating, it also displays a rather nice Growl notification diplaying the appropriate track info, using Unicode symbols for the rating stars. The problem: Ever since I upgraded to Tiger, (using 10.4.2 now), the unicode symbol for the “black_stars,” or the active stars representing the 1-5 star rating, have been much smaller than the “white_stars,” or the ones representing the null spaces (i.e. # of white_stars" = 5 - rating (“black_stars”)). So my question is, how can I increase the size of the “black_stars” so that they match the size of the “white_stars”?
Here’s the script for a 4-star rating, with 0-3- and 5-star rating scripts being similar:
(NOTE: These are not my scripts–I don’t remember where I got them, but they’re not mine!)
property black_star : «data utxt2605» as Unicode text
property white_star : «data utxt2606» as Unicode text
tell application "System Events" to set GrowlRunning to ¬
((application processes whose (name is equal to "GrowlHelperApp" ¬
)) count)
if GrowlRunning is greater than or equal to 1 then
set appName to "iTunes ratings"
set notificationName to "Ratings"
set notifs to {notificationName}
tell application "GrowlHelperApp"
register as application appName all notifications notifs default notifications notifs icon of application "iTunes"
end tell
tell application "iTunes"
if class of current track is in {track, file track, URL track, device track, shared track, audio CD} then
set aTrack to current track
tell aTrack to set rating to 80
set puppies to (name of aTrack)
set rate to (rating of aTrack)
set stars to (rate div 20)
if rate is greater than 0 and stars is equal to 0 then
set stars to 1 -- after all, a 10 rating isn't no stars
end if
set giraffes to "" as Unicode text
repeat with i from 1 to stars
set giraffes to giraffes & black_star
end repeat
repeat with i from stars to 4
set giraffes to giraffes & white_star
end repeat
if class of aTrack is URL track then
set kittens to current stream title
set chickens to (bit rate of aTrack)
tell application "GrowlHelperApp"
notify with name notificationName title "Streaming Radio (" & chickens & " kbps)" application name appName description puppies & return & kittens & return & giraffes
end tell
else
set chickens to (album of aTrack)
set kittens to (artist of aTrack)
if exists artworks of aTrack then
set aw to data of (artwork 1 of aTrack)
(*
tell application "GrowlHelperApp"
notify with name notificationName title puppies application name appName description kittens & return & chickens & return & giraffes pictImage aw
end tell
*)
tell application "Quicksilver"
show notification puppies ¬
text kittens & return & chickens & return & giraffes ¬
image data aw
end tell
else
tell application "GrowlHelperApp"
notify with name notificationName title puppies application name appName description kittens & return & chickens & return & giraffes
end tell
end if
end if
else
set puppies to "No current track"
tell application "GrowlHelperApp"
notify with name notificationName title puppies description puppies application name appName
end tell
end if
end tell
end if