Work in progress... improvements on font stuff, reverted to using Painter to get the string width. Since it actually uses glyph caching, it is about 20 times faster than the implementation in ServerFont (and a about twice the time as R5). I added a StringWidth method to Painter and AGGTextRenderer which works as correct as ServerFont::StringWidth, which btw was broken, because I mixed up glyph count and byte count...
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12745 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -213,6 +213,9 @@ class Painter {
|
||||
uint32 length,
|
||||
const BPoint& baseLine) const;
|
||||
|
||||
float StringWidth( const char* utf8String,
|
||||
uint32 length) const;
|
||||
|
||||
inline BRect ClipRect(const BRect& rect) const
|
||||
{ return _Clipped(rect); }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user