[Rt-commit] rt branch, 4.4/wrap-column-count, created. rt-4.4.4-55-gea73b35a6

Blaine Motsinger blaine at bestpractical.com
Thu Mar 14 19:14:41 EDT 2019


The branch, 4.4/wrap-column-count has been created
        at  ea73b35a6fbd9b94bc68a4e670d3b22ddc144f6c (commit)

- Log -----------------------------------------------------------------
commit ea73b35a6fbd9b94bc68a4e670d3b22ddc144f6c
Author: Blaine Motsinger <blaine at bestpractical.com>
Date:   Thu Mar 14 14:41:52 2019 -0500

    Added configurable option for wrap column count
    
    This change moves the default of 70 for wrap column count from the
    RT::Transaction module to RT_Config.pm.

diff --git a/etc/RT_Config.pm.in b/etc/RT_Config.pm.in
index 36de13fe2..caa0fde58 100644
--- a/etc/RT_Config.pm.in
+++ b/etc/RT_Config.pm.in
@@ -2331,6 +2331,15 @@ It defaults to on.  Set this to 0 to disable it.
 
 Set($QuoteFolding, 1);
 
+=item C<$QuoteWrapWidth>
+
+C<$QuoteWrapWidth> controls the number of columns to use when wrapping
+quoted text within transactions.
+
+=cut
+
+Set($QuoteWrapWidth, 100); 
+
 =back
 
 
diff --git a/lib/RT/Transaction.pm b/lib/RT/Transaction.pm
index b027ef664..eac7e0d1e 100644
--- a/lib/RT/Transaction.pm
+++ b/lib/RT/Transaction.pm
@@ -333,7 +333,8 @@ textual part (as defined in RT::I18N::IsTextualContentType).  Otherwise,
 returns the message "This transaction appears to have no content".
 
 Takes a paramhash.  If the $args{'Quote'} parameter is set, wraps this message 
-at $args{'Wrap'}.  $args{'Wrap'} defaults to 70.
+at $args{'Wrap'}.  $args{'Wrap'} is configurable through the QuoteWrapWidth
+config setting and defaults to 100 characters.
 
 If $args{'Type'} is set to C<text/html>, this will return an HTML 
 part of the message, if available.  Otherwise it looks for a text/plain
@@ -348,7 +349,7 @@ sub Content {
     my %args = (
         Type => $PreferredContentType || '',
         Quote => 0,
-        Wrap  => 70,
+        Wrap  => RT->Config->Get('QuoteWrapWidth'),
         @_
     );
 

-----------------------------------------------------------------------


More information about the rt-commit mailing list