summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/menu.cc
diff options
context:
space:
mode:
authorharanp <haranp@c06c8d41-db1a-0410-9941-cceddc491573>2009-02-04 20:47:43 +0000
committerharanp <haranp@c06c8d41-db1a-0410-9941-cceddc491573>2009-02-04 20:47:43 +0000
commit22e8777cd20d3bf9a9bce64901c4838f99fe9326 (patch)
tree70880152136ee9d5d0156c5df0555912ad73a449 /crawl-ref/source/menu.cc
parent013e0c0e9f3d7f35d9a9f8565622f4d7f3d17dee (diff)
downloadcrawl-ref-22e8777cd20d3bf9a9bce64901c4838f99fe9326.tar.gz
crawl-ref-22e8777cd20d3bf9a9bce64901c4838f99fe9326.zip
Don't pass number of columns to print_formatted_paragraph(), since it always
uses the width of the screen anyway. Have print_formatted_paragraph() respect delay_message_clear. Fixes [2492045]. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@8894 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/menu.cc')
-rw-r--r--crawl-ref/source/menu.cc7
1 files changed, 5 insertions, 2 deletions
diff --git a/crawl-ref/source/menu.cc b/crawl-ref/source/menu.cc
index 727948aadd..88e1238cd2 100644
--- a/crawl-ref/source/menu.cc
+++ b/crawl-ref/source/menu.cc
@@ -1566,9 +1566,12 @@ std::string get_linebreak_string(const std::string& s, int maxcol)
// Takes a (possibly tagged) string, breaks it into lines and
// prints it into the given message channel.
-void print_formatted_paragraph(std::string &s, int maxcol,
- msg_channel_type channel)
+void print_formatted_paragraph(std::string &s, msg_channel_type channel)
{
+ int maxcol = get_number_of_cols();
+ if (Options.delay_message_clear)
+ --maxcol;
+
linebreak_string2(s,maxcol);
std::string text;