Project

General

Profile

Feature #69 » pdf.rb_r6129.patch

Jun NAITOH, 2011-06-29 16:43

View differences:

lib/redmine/export/pdf.rb (working copy)
Cell(w,h,fix_text_encoding(txt),border,ln,align,fill,link)
end
def RDMMultiCell(w,h=0,txt='',border=0,align='',fill=0)
MultiCell(w,h,fix_text_encoding(txt),border,align,fill)
def RDMMultiCell(w,h=0,txt='',border=0,align='',fill=0,ln=1)
MultiCell(w,h,fix_text_encoding(txt),border,align,fill,ln)
end
def RDMwriteHTMLCell(w, h, x, y, html='', border=0, ln=1, fill=0)
writeHTMLCell(w, h, x, y, fix_text_encoding(html), border, ln, fill)
end
def Footer
SetFont(@font_for_footer, 'I', 8)
SetY(-15)
......
"#{issue.project} - #{issue.tracker} # #{issue.id}: #{issue.subject}")
pdf.Ln
y0 = pdf.GetY
pdf.SetFontStyle('B',9)
pdf.RDMCell(35,5, l(:field_status) + ":","LT")
pdf.SetFontStyle('',9)
......
pdf.RDMMultiCell(155,5, (show_value custom_value),"R")
end
y0 = pdf.GetY;
pdf.SetFontStyle('B',9)
pdf.RDMCell(35,5, l(:field_subject) + ":","LT")
pdf.SetFontStyle('',9)
pdf.RDMMultiCell(155,5, issue.subject,"RT")
pdf.Line(pdf.GetX, y0, pdf.GetX, pdf.GetY)
pdf.SetFontStyle('B',9)
pdf.RDMCell(35,5, l(:field_description) + ":","LT")
pdf.RDMCell(35 + 155,5, l(:field_description),"LRT", 1)
pdf.SetFontStyle('',9)
pdf.RDMMultiCell(155,5, issue.description.to_s,"RT")
pdf.RDMwriteHTMLCell(35 + 155,5,0,0, Redmine::WikiFormatting.to_html(Setting.text_formatting, issue.description.to_s),"LRB")
pdf.Line(pdf.GetX, y0, pdf.GetX, pdf.GetY)
pdf.Line(pdf.GetX, pdf.GetY, pdf.GetX + 190, pdf.GetY)
pdf.Ln
if issue.changesets.any? &&
......
if journal.notes?
pdf.Ln unless journal.details.empty?
pdf.SetFontStyle('',8)
pdf.RDMMultiCell(190,5, journal.notes.to_s)
pdf.RDMwriteHTMLCell(190,5,0,0, Redmine::WikiFormatting.to_html(Setting.text_formatting, journal.notes.to_s), "")
end
pdf.Ln
end
(4-4/9)