Re: QuickTime Text Track Rotation
Re: QuickTime Text Track Rotation
- Subject: Re: QuickTime Text Track Rotation
- From: Stan Cleveland <email@hidden>
- Date: Thu, 10 Jun 2010 18:22:15 -0700
- Thread-topic: QuickTime Text Track Rotation
Title: Re: QuickTime Text Track Rotation
On 6/10/10 4:55 PM, "(4) GMAIL 5278" wrote:
Hello. I'm trying to use AppleScript to manipulate a text track over QuickTime. If you open a movie (with a text track) with QuickTime Pro, its Visual Settings lets you rotate a track. But the Dictionary for QuickTime states nothing about track rotation under track. Does that simply mean AppleScript won't let you rotate a track?
In the meantime, it doesn't look like text frame's drop shadow offset and drop shadown tranparency works.
tell application "QuickTime Player"
set keyed of text frame of track 3 of document 1 to true
set drop shadow of text frame of track 3 of document 1 to true
set drop shadow offset of text frame of track 3 of document 1 to {20, 50}
set drop shadow transparency of text frame of track 3 of document 1 to 100
set foreground color of text frame of track 3 of document 1 to {65535, 150, 250}
set background color of text frame of track 3 of document 1 to {0, 65535, 65535}
set default font size of text frame of track 3 of document 1 to 50
end tell
Or am I doing anything wrong? Thank you for your advice.
Hi Jim,
Even though you’ve already answered your own question and I don’t even have QuickTime Pro, you might find these general ideas helpful anyway.
If there’s no command for a particular operation, like rotation, the next thing to check for is a rotation-related property of the track itself. If there IS one, you’d just change its value. It might look something like this:
set rotation angle of text frame of track 3 of document 1 to 90
One trick I use a lot when I’m starting to script a new application is to request an object’s properties. Something like this:
tell application "QuickTime Player"
return properties of text frame of track 3 of document 1
end tell
You’d then manually comb through the returned properties, looking for any that pertain to your goals. Bear in mind that some properties are read-only and can’t be changed. The AS dictionary should help you identify those.
Another thing to look for when inspecting the properties of an object is the class of the property’s value. You might guess that a certain property should be an integer, but it might actually need to be a real or even a string! What’s in the returned properties record should correctly show what’s expected.
Here’s one last tidbit. I don’t know about QuickTime Pro, but many other applications will “nest” properties one or more levels deep. For example, Adobe InDesign’s numbering policy property is buried inside two parent property records:
tell application "Adobe InDesign CS3"
return numbering policy of numbering restart policies of change text preferences
--> after specific level
end tell
In this case, you’d need to reference all parent levels to get to the child (or grandchild) property.
HTH,
Stan C.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden