I just whipped up a little program to take care of a little detail that's been bothering me... It goes something like this.
I've got a nifty color sign that I've printed up for my room party at the convention I'm going to. I left a place blank to write in the room number as soon as I learn what it is.
But wouldn't it be nice if I could have the room number printed there too?
I could bring along a portable printer; I'll start doing that for the Fan Gallery one of these days. If I had a printer with me I could print my signs on-site.
But that's a risky chance to take -- what if something goes wrong with the printer setup? I don't want to be stuck with some blank paper instead of signs that I could finish with a black Sharpie marker.
I could bring along the ones with the space for the number, and use the printer to fill in the number. But how will I get the number to print in exactly the right place?
So what I've done -- using the immensely handy C library GD and a little tool I whipped up myself -- is create a grid to determine where to locate the number, then tell my little program to print the number in exactly that spot on the page.
It's pretty slick -- it scales the point size up or down to neatly fit the space, it can use a font I specify (or defaults to Arial Black). And the really cool thing, in my book, is that I don't need to measure carefully with a ruler and then hope that my printout faithfully goes to the right place. All I have to do is print the reference grid with the same print setup I'd use to overprint the number, and it'll always line up where it should...
Well, I thought it was cool, anyhow. I'm considering making it a CGI program on my server that'll let you generate the overlay number output -- would any of you have a use for that kind of thing?
I've got a nifty color sign that I've printed up for my room party at the convention I'm going to. I left a place blank to write in the room number as soon as I learn what it is.
But wouldn't it be nice if I could have the room number printed there too?
I could bring along a portable printer; I'll start doing that for the Fan Gallery one of these days. If I had a printer with me I could print my signs on-site.
But that's a risky chance to take -- what if something goes wrong with the printer setup? I don't want to be stuck with some blank paper instead of signs that I could finish with a black Sharpie marker.
I could bring along the ones with the space for the number, and use the printer to fill in the number. But how will I get the number to print in exactly the right place?
So what I've done -- using the immensely handy C library GD and a little tool I whipped up myself -- is create a grid to determine where to locate the number, then tell my little program to print the number in exactly that spot on the page.
It's pretty slick -- it scales the point size up or down to neatly fit the space, it can use a font I specify (or defaults to Arial Black). And the really cool thing, in my book, is that I don't need to measure carefully with a ruler and then hope that my printout faithfully goes to the right place. All I have to do is print the reference grid with the same print setup I'd use to overprint the number, and it'll always line up where it should...
Well, I thought it was cool, anyhow. I'm considering making it a CGI program on my server that'll let you generate the overlay number output -- would any of you have a use for that kind of thing?
no subject
Date: 2005-12-09 05:11 pm (UTC)I then cut and paste those fields onto all pages in the file (and it asks me if I want them to all be the same value, and I say yes.)
When we get there, I set up the laptop and printer, open the PDF, type in what I need for the party info, and print the pages I want to use that day. Voila!
(It's also spiffy because the font I want to use is, of course, imbedded in the PDF file, so I can give the file to someone else if they are going to print for me)
no subject
Date: 2005-12-10 03:38 pm (UTC)