diff options
author | Brad King <brad.king@kitware.com> | 2003-02-16 16:57:20 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2003-02-16 16:57:20 (GMT) |
commit | 7d1ee1d4c82eb30cd52250e8f5c6b3ab73679bab (patch) | |
tree | cfea6085d422b9b08763a0a475b5d6fa948779c0 /Source/cmDocumentation.cxx | |
parent | caa074e8b57907d84977806f189d9d19c8b297df (diff) | |
download | CMake-7d1ee1d4c82eb30cd52250e8f5c6b3ab73679bab.zip CMake-7d1ee1d4c82eb30cd52250e8f5c6b3ab73679bab.tar.gz CMake-7d1ee1d4c82eb30cd52250e8f5c6b3ab73679bab.tar.bz2 |
ERR: Use of stream format flags is hard to make portable. Manually implementing justification.
Diffstat (limited to 'Source/cmDocumentation.cxx')
-rw-r--r-- | Source/cmDocumentation.cxx | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/Source/cmDocumentation.cxx b/Source/cmDocumentation.cxx index f88e170..9ebd738 100644 --- a/Source/cmDocumentation.cxx +++ b/Source/cmDocumentation.cxx @@ -229,15 +229,16 @@ void cmDocumentation::PrintUsageSection(std::ostream& os, const cmDocumentationEntry* section) { if(!section) { return; } - long flags = static_cast<long>(os.flags()); - os.setf(flags | std::ios::left); for(const cmDocumentationEntry* op = section; op->brief; ++op) { if(op->name) { - os << " "; - os.width(25); - os << op->name << "= " << op->brief << "\n"; + os << " " << op->name; + for(int i = static_cast<int>(strlen(op->name)); i < 25; ++i) + { + os << " "; + } + os << "= " << op->brief << "\n"; } else { @@ -246,7 +247,6 @@ void cmDocumentation::PrintUsageSection(std::ostream& os, os << "\n"; } } - os.setf(flags); } //---------------------------------------------------------------------------- |