• 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
Smile PDF Drawing dpi question
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Smile PDF Drawing dpi question


  • Subject: Smile PDF Drawing dpi question
  • From: ilsa <email@hidden>
  • Date: Wed, 07 Mar 2012 13:43:10 -0800

Hi:

My goal is to create a lot of jpg (or gif) files of different
specified pixel dimensions. I'm trying to use Smile because I can
easily create variable messages and control the colors and
transparencies.

The below script gives me the pdf, which I then need to convert to jpg
or gif (to display in web browsers). I figure the easiest way to do
that is with a do shell script call to sips. However, sips thinks the
pdf is 150dpi instead of 72dpi, which I thought I had specified with
Smile, and so the jpg is about 2x as big as it should be. Opening the
pdf with Preview also shows it to be 150dpi.

Question: How can I get my pdf file to stay at the 72dpi dimensions I
gave it in Smile? Any insights appreciated, or even a different way to
generate these jpg files!

Thanks,

ilsa

set my_dest to "hd:test.pdf"
tell application "Finder"
	if exists file my_dest then
		move file my_dest to trash
	end if
end tell
tell application "Smile"
	set w to make new graphic window
	set pageheight of w to 125 -- default unit is always pixels
	set pagewidth of w to 600
	set resolution of w to 72
	set background color of w to {0.5, 0.5, 0.5, 0.5} -- percentages of
r,g,b,transp
	--return properties of w
	BeginFrontFigure(w)
	SetTextFont("Arial Black")
	SetTextSize(72)
	SetFillColor({0, 0, 0, 0.3})
	SetPenColor({0, 0, 0, 0.3})
	TextMoveTo({5, 5})
	DrawString("Test Text")
	EndFrontFigure()


	save w in file my_dest
	close every graphic window
	close every window

end tell
 _______________________________________________
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


  • Prev by Date: codesigning
  • Next by Date: Please Test ยป Safari Save Problem
  • Previous by thread: Re: codesigning
  • Next by thread: Smile PDF Drawing dpi question
  • Index(es):
    • Date
    • Thread