Upon construction, the font is not locked by the drawing engine, so we better lock it ourselves.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14781 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -95,7 +95,12 @@ Painter::Painter()
|
|||||||
fPatternHandler(new PatternHandler()),
|
fPatternHandler(new PatternHandler()),
|
||||||
fTextRenderer(new AGGTextRenderer())
|
fTextRenderer(new AGGTextRenderer())
|
||||||
{
|
{
|
||||||
|
// Usually, the drawing engine will lock the font for us when
|
||||||
|
// needed - unfortunately, it can't know we need it here
|
||||||
|
fFont.Lock();
|
||||||
_UpdateFont();
|
_UpdateFont();
|
||||||
|
fFont.Unlock();
|
||||||
|
|
||||||
_UpdateLineWidth();
|
_UpdateLineWidth();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -960,7 +965,6 @@ Painter::DrawString(const char* utf8String, uint32 length,
|
|||||||
SetPattern(B_SOLID_HIGH);
|
SetPattern(B_SOLID_HIGH);
|
||||||
|
|
||||||
if (fBuffer) {
|
if (fBuffer) {
|
||||||
|
|
||||||
bounds = fTextRenderer->RenderString(utf8String,
|
bounds = fTextRenderer->RenderString(utf8String,
|
||||||
length,
|
length,
|
||||||
fFontRendererSolid,
|
fFontRendererSolid,
|
||||||
|
|||||||
Reference in New Issue
Block a user