[aseprite] 42/134: Fix formatted output of ProgramOptions when one option has multilines

Tobias Hansen thansen at moszumanska.debian.org
Sat Mar 14 17:10:01 UTC 2015


This is an automated email from the git hooks/post-receive script.

thansen pushed a commit to branch master
in repository aseprite.

commit 9d2fd2498b347388688c7ca1f55c6faeab3522b0
Author: David Capello <davidcapello at gmail.com>
Date:   Fri Nov 7 01:10:51 2014 -0300

    Fix formatted output of ProgramOptions when one option has multilines
---
 src/base/program_options.cpp | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/base/program_options.cpp b/src/base/program_options.cpp
index addc4d7..eab174d 100644
--- a/src/base/program_options.cpp
+++ b/src/base/program_options.cpp
@@ -217,7 +217,8 @@ std::ostream& operator<<(std::ostream& os, const base::ProgramOptions& po)
       bool multilines = (option->description().find('\n') != std::string::npos);
 
       if (!multilines) {
-        os << std::setw(maxOptionWidth - optionWidth + 1) << ' ' << option->description();
+        os << std::setw(maxOptionWidth - optionWidth + 1) << ' ' << option->description()
+           << "\n";
       }
       else {
         std::istringstream s(option->description());
@@ -230,7 +231,8 @@ std::ostream& operator<<(std::ostream& os, const base::ProgramOptions& po)
         }
       }
     }
-    os << "\n";
+    else
+      os << "\n";
   }
 
   return os;

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/aseprite.git



More information about the Pkg-games-commits mailing list