summaryrefslogtreecommitdiff
path: root/program/lib/Roundcube
diff options
context:
space:
mode:
authorThomas Bruederli <thomas@roundcube.net>2013-01-26 17:13:52 +0100
committerThomas Bruederli <thomas@roundcube.net>2013-01-26 17:13:52 +0100
commit2a6472b2c232f1eea09d0f337ecfc7c17f1ae86d (patch)
tree74e600b1796979c8f94bea92574ef778e88cbe73 /program/lib/Roundcube
parenta8fd895263d6c32bc1c97cba2d373def73d4e603 (diff)
Bring back lost text braking width adjustment when quoting blockquote parts
Diffstat (limited to 'program/lib/Roundcube')
-rw-r--r--program/lib/Roundcube/rcube_html2text.php7
1 files changed, 7 insertions, 0 deletions
diff --git a/program/lib/Roundcube/rcube_html2text.php b/program/lib/Roundcube/rcube_html2text.php
index 3d32fe766..9b248a3a8 100644
--- a/program/lib/Roundcube/rcube_html2text.php
+++ b/program/lib/Roundcube/rcube_html2text.php
@@ -597,9 +597,16 @@ class rcube_html2text
// get blockquote content
$body = trim(substr($text, $startpos, $end - $startpos));
+ // adjust text wrapping width
+ $p_width = $this->width;
+ if ($this->width > 0) $this->width -= 2;
+
// replace content with inner blockquotes
$this->_converter($body);
+ // resore text width
+ $this->width = $p_width;
+
// Add citation markers and create <pre> block
$body = preg_replace_callback('/((?:^|\n)>*)([^\n]*)/', array($this, 'blockquote_citation_ballback'), trim($body));
$body = '<pre>' . htmlspecialchars($body) . '</pre>';