Re: gdiplus: font.c: ensure to release resources

2008-06-26 Thread Joris Huizer
--- On Thu, 6/26/08, Huw Davies <[EMAIL PROTECTED]> wrote: > > You need to select out the hfont before deleting it. > > So the SelectObject should look like > hfont_old = SelectObject(hdc, hfont); > then after the > GetTextMetrics > do > DeleteObject(SelectObject(hdc, hfont_old)) > > (then you

Re: gdiplus: font.c: ensure to release resources

2008-06-26 Thread Huw Davies
Joris Huizer wrote: > A modified patch, taking hints into account from Huw Davies > You need to select out the hfont before deleting it. So the SelectObject should look like hfont_old = SelectObject(hdc, hfont); then after the GetTextMetrics do DeleteObject(SelectObject(hdc, hfont_old)) (then y