projects
/
supertux.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
pt.po updates from José JORGE <lists.jjorge@free.fr>
[supertux.git]
/
src
/
video
/
font.cpp
diff --git
a/src/video/font.cpp
b/src/video/font.cpp
index
e5b6bb1
..
7628f67
100644
(file)
--- a/
src/video/font.cpp
+++ b/
src/video/font.cpp
@@
-243,8
+243,10
@@
Font::wrap_to_chars(const std::string& s, int line_length, std::string* overflow
}
std::string
}
std::string
-Font::wrap_to_width(const std::string& s, float width, std::string* overflow)
+Font::wrap_to_width(const std::string& s
_
, float width, std::string* overflow)
{
{
+ std::string s = s_;
+
// if text is already smaller, return full text
if (get_text_width(s) <= width) {
if (overflow) *overflow = "";
// if text is already smaller, return full text
if (get_text_width(s) <= width) {
if (overflow) *overflow = "";