$include_dir="/home/hyper-archives/boost-commit/include"; include("$include_dir/msg-header.inc") ?>
Subject: [Boost-commit] svn:boost r58112 - in trunk: boost/program_options libs/program_options/src
From: s.ochsenknecht_at_[hidden]
Date: 2009-12-03 06:11:34
Author: s_ochsenknecht
Date: 2009-12-03 06:11:34 EST (Thu, 03 Dec 2009)
New Revision: 58112
URL: http://svn.boost.org/trac/boost/changeset/58112
Log:
rename description_length to min_description_length for better semantic
Text files modified: 
   trunk/boost/program_options/options_description.hpp    |     6 +++---                                  
   trunk/libs/program_options/src/options_description.cpp |    14 +++++++-------                          
   2 files changed, 10 insertions(+), 10 deletions(-)
Modified: trunk/boost/program_options/options_description.hpp
==============================================================================
--- trunk/boost/program_options/options_description.hpp	(original)
+++ trunk/boost/program_options/options_description.hpp	2009-12-03 06:11:34 EST (Thu, 03 Dec 2009)
@@ -159,7 +159,7 @@
         
         /** Creates the instance. */
         options_description(unsigned line_length = m_default_line_length,
-                            unsigned description_length = m_default_line_length / 2);
+                            unsigned min_description_length = m_default_line_length / 2);
         /** Creates the instance. The 'caption' parameter gives the name of
             this 'options_description' instance. Primarily useful for output.
             The 'description_length' specifies the number of columns that
@@ -169,7 +169,7 @@
         */
         options_description(const std::string& caption,
                             unsigned line_length = m_default_line_length,
-                            unsigned description_length = m_default_line_length / 2);
+                            unsigned min_description_length = m_default_line_length / 2);
         /** Adds new variable description. Throws duplicate_variable_error if
             either short or long name matches that of already present one. 
         */
@@ -219,7 +219,7 @@
 
         std::string m_caption;
         const unsigned m_line_length;
-        const unsigned m_description_length;
+        const unsigned m_min_description_length;
         
         // Data organization is chosen because:
         // - there could be two names for one option
Modified: trunk/libs/program_options/src/options_description.cpp
==============================================================================
--- trunk/libs/program_options/src/options_description.cpp	(original)
+++ trunk/libs/program_options/src/options_description.cpp	2009-12-03 06:11:34 EST (Thu, 03 Dec 2009)
@@ -206,23 +206,23 @@
     const unsigned options_description::m_default_line_length = 80;
 
     options_description::options_description(unsigned line_length,
-                                             unsigned description_length)
+                                             unsigned min_description_length)
     : m_line_length(line_length)
-    , m_description_length(description_length)
+    , m_min_description_length(min_description_length)
     {
         // we require a space between the option and description parts, so add 1.
-        assert(m_description_length < m_line_length - 1);    
+        assert(m_min_description_length < m_line_length - 1);    
     }
 
     options_description::options_description(const std::string& caption,
                                              unsigned line_length,
-                                             unsigned description_length)
+                                             unsigned min_description_length)
     : m_caption(caption)
     , m_line_length(line_length)
-    , m_description_length(description_length)
+    , m_min_description_length(min_description_length)
     {
         // we require a space between the option and description parts, so add 1.
-        assert(m_description_length < m_line_length - 1);
+        assert(m_min_description_length < m_line_length - 1);
     }
     
     void
@@ -554,7 +554,7 @@
         }
         /* this is the column were description should start, if first
            column is longer, we go to a new line */
-        const unsigned start_of_description_column = m_line_length - m_description_length;
+        const unsigned start_of_description_column = m_line_length - m_min_description_length;
 
         width = (min)(width, start_of_description_column-1);