* src/frontends/qt4/GuiFontMetrics.C

(GuiFontMetrics::signedWidth): Micropotimization: Avoid a temporary
	docstring


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15755 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Georg Baum 2006-11-05 18:27:50 +00:00
parent ac2057254f
commit 99d066de95

View File

@ -145,7 +145,7 @@ int GuiFontMetrics::width(QString const & ucs2) const
int GuiFontMetrics::signedWidth(docstring const & s) const
{
if (s[0] == '-')
return -FontMetrics::width(s.substr(1, s.length() - 1));
return -width(&(s[1]), s.length() - 1);
else
return FontMetrics::width(s);
}