Menu

#103 AV at QGraphics TPen SetStyle / SetWidth

open
nobody
None
5
2002-01-30
2002-01-30
No

TPen.SetStyle and SetWidth are first calling
GetStyle and GetWidth.
GetStyle is not checking if FHandle is assigned,
and when nil, QT api raises AV.

Can they check if not Assigned(FHandle) then
call ReleaseHandle ?

Or... implement GetHandle to defer Handle creation
until required (like VCL).

This prevents generic creation of TPen objects
using a base TPersistent, and then calling Assign.

Discussion


Log in to post a comment.