• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
My first modest attempt with image events
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

My first modest attempt with image events


  • Subject: My first modest attempt with image events
  • From: Michelle Steiner <email@hidden>
  • Date: Mon, 27 Oct 2003 17:58:19 -0700

set foo to choose file default location alias ((path to home folder as text) & "pictures")

set rotation_factor to (text returned of (display dialog "Rotate the picture how many degrees 0 to 360)?" default answer "")) as number

set {scale_factor, scale_type} to {text returned, button returned} of (display dialog "How much should it be scaled?" & return & <option-L>
"(Percent should be 1 to 100.)" default answer "" buttons {"Percent", "Pixels", "Cancel"} default button 1)

set scale_factor to (scale_factor as number) / 100

tell application "Image Events"
launch
set the _image to open foo
if scale_type is "percent" then
scale foo by factor scale_factor
else
scale foo to size scale_factor
end if
rotate the _image to angle rotation_factor
save the _image in (path to desktop)
end tell

--
"Beware the march of ideas." _______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.
  • Prev by Date: Re: OS 9 or Classic, that's the question :-)
  • Next by Date: Re: Need to change the subject about Quark
  • Previous by thread: Modify a object in a .nib file
  • Next by thread: Re: Need to change the subject about Quark
  • Index(es):
    • Date
    • Thread