Images and printing....
Chipp Walters
chipp at chipp.com
Sat May 10 16:35:00 EDT 2003
David,
>
> Also is there any way to get the size / resolution information stored with
> images so that they can be resized when placing them in MC - MC
> imports them
> all at a size corresponding to 72dpi which can make pretty large images if
> they were stored at 300 dpi or above.>
You can check the cookbook of the lastest RR candidate for
"Recipe for getting the dimensions of a picture file"
which states:
function imageFileDimensions theFilePath
lock screen -- so user doesn't see the following shenanigans
lock error dialogs -- prevent error window if import fails
import paint from file theFilePath -- creates a new image
unlock error dialogs
put the width of last image into myWidth
put the height of last image into myHeight
delete last image -- get rid of image we created
unlock screen
return myWidth,myHeight
end imageFileDimensions
on errorDialog -- executed if the import causes a script error
beep
answer "There was a problem accessing the file data."\
& return & return & \
"Picture files must be in one of the following formats:"
& return & \
"PNG, JPEG, GIF, PICT, BMP, XWD/XBM/XPM, or PBM/PGM/PPM."
end errorDialog
best,
Chipp
More information about the metacard
mailing list