@@ -109,6 +109,13 module Redmine | |||||
109 | RDMPdfEncoding::rdm_from_utf8(txt, l(:general_pdf_encoding)) |
|
109 | RDMPdfEncoding::rdm_from_utf8(txt, l(:general_pdf_encoding)) | |
110 | end |
|
110 | end | |
111 |
|
111 | |||
|
112 | def formatted_text(text) | |||
|
113 | html = Redmine::WikiFormatting.to_html(Setting.text_formatting, text) | |||
|
114 | # Strip {{toc}} tags | |||
|
115 | html.gsub!(/<p>\{\{([<>]?)toc\}\}<\/p>/i, '') | |||
|
116 | html | |||
|
117 | end | |||
|
118 | ||||
112 | def RDMCell(w ,h=0, txt='', border=0, ln=0, align='', fill=0, link='') |
|
119 | def RDMCell(w ,h=0, txt='', border=0, ln=0, align='', fill=0, link='') | |
113 | Cell(w, h, fix_text_encoding(txt), border, ln, align, fill, link) |
|
120 | Cell(w, h, fix_text_encoding(txt), border, ln, align, fill, link) | |
114 | end |
|
121 | end | |
@@ -120,8 +127,7 module Redmine | |||||
120 | def RDMwriteHTMLCell(w, h, x, y, txt='', attachments=[], border=0, ln=1, fill=0) |
|
127 | def RDMwriteHTMLCell(w, h, x, y, txt='', attachments=[], border=0, ln=1, fill=0) | |
121 | @attachments = attachments |
|
128 | @attachments = attachments | |
122 | writeHTMLCell(w, h, x, y, |
|
129 | writeHTMLCell(w, h, x, y, | |
123 | fix_text_encoding( |
|
130 | fix_text_encoding(formatted_text(txt)), | |
124 | Redmine::WikiFormatting.to_html(Setting.text_formatting, txt)), |
|
|||
125 | border, ln, fill) |
|
131 | border, ln, fill) | |
126 | end |
|
132 | end | |
127 |
|
133 |
General Comments 0
You need to be logged in to leave comments.
Login now