Commit Graph

50 Commits

Author SHA1 Message Date
james
ea58b4b6a8 Add a "setDefaultFontSize" function to lpdf, and set it to something reasonable for backwards compatability
Update lpdf's table functions to honour the default font size setting.

(this works great, except for the column widths -  if you choose a font-size too big, its not oging to fit in the pre-defined column widths.)
2010-03-23 16:42:59 +00:00
james
9bad26096d Tweak the avery 5162 template a bit, lines up perfectly now 2009-11-30 18:46:48 +00:00
dave
3a921ba3bf - Add another arg to newPage to allow overriding the page number. Want to
create a single pdf with multiple forms for students, each form should start
  on page 1.
- Add a prevLine() function to go back a line.
- Switch the output mechanism to output to an array (and then print that
  array).  For remote transport to downstream SFIABs, we dont' want to output
  the PDF, we want to bundle up the data and return it via. json.  we do NOT
  want downstream fairs communicating directly with our PDF generator, nor do we
  want users of downstream fairs authenticating themselves, from their home browser, as 
  a fair.  The user talks to their SFIAB, that SFIAB goes through the
  remote.php authentication mechanism, and a PDF gets returned.
2009-09-25 19:13:29 +00:00
dave
52e7a6500a - Add a convenience stringwidth funciton 2008-03-24 18:45:51 +00:00
james
ec66217a2b Split label_box into two separate options: label_box and field_box. label_box draws a border around the entire label, field_box draws a boarder around each field of text on the label 2008-03-20 20:07:13 +00:00
james
a7da608982 Switch heading() to use addText() so it implements line-wrapping for super-long headings 2008-03-04 21:57:49 +00:00
dave
8ffc278286 - Put the "..." in the proper cell 2008-01-30 07:54:13 +00:00
dave
8b38f44501 - Move the start/end table logic into functions
- If a multi-line table row spills off the bottom of the page, start a new page
				/
  and then print that row.
2008-01-26 20:41:33 +00:00
dave
58df28ba9a - Fix drawing label boxes around text items
- Add the ability to draw a static label box (without text)
- Add "self nominated award" 1 through 5 to the student reports
- Add a new report demonstrating how to use the above (this is of the format
  Sudbury sent us).
2008-01-23 18:32:31 +00:00
dave
e24bbb0bbc - Add a filter to the last commit, to not show the none tshirts.
- Add a 'total' option to the report generator, to signal that this column
  should be added up.
- If total is != zero, it shows the total at the bottom of each table, else, it
  shows the number of rows (changed the text to Total: for a total, and Rows:
  to show rows, if the total is 0)
2007-12-30 22:16:34 +00:00
dave
7b7c6c0db2 - Use pdf_fit_image instead of pdf_place_image.
- The docs say pdf_place_image is deprecated (and so is
	  pdf_open_image_file.. apparently)
	- By using pdf_fit_image we can define a box where we would like the
	  image to fit, then use the highest quality image (logo.gif) and tell
	  pdflib to scale and center the image within that box.
2007-12-22 03:31:02 +00:00
dave
aa2f8883e3 - Fix the overlapping text in table layout when trying to fit it in multiple lines
- Fix an infinite loop if the text will never fit in the width provided.
2007-12-20 00:56:57 +00:00
james
2aeaf7bea9 unbreak the broken addText() that was introduced in r977 2007-12-12 20:35:03 +00:00
james
d4e6b63c2e Dont get stuck in an infinite loop if the text doesnt fit, just break out and forgetaboutit 2007-12-11 18:21:27 +00:00
dave
03d5e23496 - Use the new bold font instead of the old hack. 2007-12-10 21:29:53 +00:00
dave
a62a8bbbfb - Add a bold font option to pdf generation 2007-12-10 21:28:17 +00:00
james
f39178585b This should make PDF's work in the broken IE/PDF/SSL implementation 2007-11-14 20:53:35 +00:00
james
1c0c51c7fc Update all Avery templates, add new avery template for 1 1/3" x 4"
Fix a register_globals reliance
2007-10-09 17:42:00 +00:00
dave
f922adb9af - Implement vertical alignment for labels
- Implement boxes around text for testing (and maybe for a purpose?)
2007-10-05 20:12:19 +00:00
james
4a3aaac8af Properly address french mailing labels to schools 2007-09-27 15:29:48 +00:00
james
7cb46d5aee Use mb_strtoupper instead of strtoupper to properly uppercase accented french characters 2007-09-27 14:08:46 +00:00
james
55fcc1cf06 Guess i never committed my multi-line table lpdf fix. here it is. 2007-05-09 17:18:01 +00:00
dave
8c044c8309 - Remove unused nametag stuff. It's not referenced anywhere in the code base
anymore
2007-04-03 20:09:19 +00:00
james
72afcf583c Get the logo to fit on the label 2007-03-26 17:04:42 +00:00
dave
a67e8b8fb5 - Fix the position of the image on the label
- Change the fair title font to 13pt (from 14pt), it was spilling over onto the
  second line for many fairs  (Waterloo-Wellington, Greater Vancouver, Quinte,
  Fraser Valley)  Actually, the size of that should probably be proportinal to
  the size of the label.. that'll come later...
2007-03-20 06:27:04 +00:00
dave
4e2d7d77aa - Fix up the pdf generation of our nametags
- This also changes the newlabel function, so just thinking about it, I think
  there's a 0.15 missing in the alignment that was moved inside a conditional
  for labels... All labels will be replaced soon anyway.  :p
2007-03-19 06:56:38 +00:00
dave
7c96874571 - Add page numbers to lpdf generated reports
- Allow the addTable array to contain an 'option' array, with one supported
  option 'allow_multiline' => if true, it allows cell data to spill into
  mutliple rows, instead of just printing ... if the text doesn't fit.
  
- Ignore the addText2 function, it is for label generation and isn't finished
  yet.
2007-03-18 05:02:14 +00:00
james
db600b5eb4 Properly wrap signature lines when they reach a page break
Fix the signature page to only display once ALL the sections are complete
2007-03-04 16:26:04 +00:00
james
952a4d3c29 Fix a bug where if no $table is passed to addTable it will now return gracefully instead of spitting out error messages
Add email field to the judge list, and the judge manager list
2007-02-09 14:57:07 +00:00
james
7143e9e01a Delete old school mailing labels and replace with a mailing label generator
that allows you to customize the size of the labels to suit _ANY_ label
stock paper.

Add to label generator the option to get judge mailing labels, and award
sponsor mailing labels, and make it easy to add more mailing labels
down the road (students? committee? etc?)

Add two default label stocks (Avery 1"x4" and Avery 2"x4")
2006-10-16 15:42:29 +00:00
james
e6ed1c35b0 Account for spacing between labels when generating mailing labels for the schools
Also shrink the c/o line to better accomodate long names
2006-09-12 18:03:46 +00:00
james
a8d31a3603 Add report generation support for mailing labels
Add School Mailing Address Labels for Avery #05163 (4"x2" or 10.2 x 5.1 cm)
2006-09-11 18:05:35 +00:00
james
668d410207 Update LPDF to handle tables without a header row
Update LPDF to add a "..." to a table field if all of the text didnt fit in the table field
2005-12-08 18:01:30 +00:00
james
c171fe752d enter winning projects
new database files
update PDF addText to go to next page when necessary
awards ceremony script
2005-05-04 21:23:00 +00:00
james
795ea89ae0 whoops properly name the file on output 2005-04-22 19:33:56 +00:00
james
53e8ca4f93 make the nametag fair name height be big enough for two rows 2005-04-22 19:28:47 +00:00
james
fe1217ba6b Whew! LPDF Nametag support & nametags for students... that took 5 hours! 2005-04-22 17:37:19 +00:00
james
ccb38c5aa7 whoops fix a few bugs 2005-04-22 14:09:13 +00:00
james
13bc47708a Update PDF to handle any size page (default 8.5x11) to use a different size, simply call
newPage(width,height) in inches.
2005-04-22 14:04:47 +00:00
james
db6b2dad28 LPDF: fix bug when one line of text is added with addtext
LCSV: add addtext, newpage functions

Create new report containing judging team project assignments, one team per page.
2005-04-21 20:29:08 +00:00
james
2f8921a7a0 Fix things running over the bottom of the footer in PDF's
Also, if a heading is going to be the last thing on the page, move it to the top of the next page.
2005-04-15 16:44:26 +00:00
james
324433ef23 Add GPL headers to ALL PHP files 2005-01-24 18:00:03 +00:00
james
f4bc5ad4c3 only close the image if was opened to begin with 2005-01-21 17:01:43 +00:00
james
dfa1d438e7 only put the fair logo on the pdf if the logo file is valid 2005-01-21 17:00:28 +00:00
james
421e7f43d9 fix some alignment issues with the table, make sure it moves down the appropriate amounts at the appropriate times! 2005-01-18 17:45:26 +00:00
james
162475b62c Port participant signature page to use lpdf.php
Add required functions to lpdf.php to support the signature page
2005-01-18 03:33:37 +00:00
james
c03aaf07a3 add logo to pdf's 2005-01-14 20:42:03 +00:00
james
d3b1223e92 Make registration list sortable
Make links in summarytable header be white
(something in pdf?)
2005-01-14 17:00:24 +00:00
james
2c3f6e745f add a script to populate the db with some fake data
update divisions to accept 'shortform'
some updates to PDF
2005-01-13 23:59:22 +00:00
james
0e10fcda45 factor out PDF code into a separate PDF class
implement new PDF class in reports_checkin
2005-01-13 22:00:34 +00:00