[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
NSCell drawInterior... positioning bug?
From: |
Willem Rein Oudshoorn |
Subject: |
NSCell drawInterior... positioning bug? |
Date: |
17 Feb 2003 08:41:36 +0100 |
User-agent: |
Gnus/5.09 (Gnus v5.9.0) Emacs/21.2 |
I am investigation bug
#101846: Refresh progem of dragged image.
And found that the reason is in the the
-[NSCell drawInteriorWithFrame:inView:]
method. The problem is that XGDragView
uses this method to redraw the image in
-[XGDragView drawRect:]
Now XGDragView assumes that the drawInterior...
method will redraw the part specified in the
first argument.
However, in NSCell we do two things,
A - We draw a frame (if needed)
of size approximately the first argument.
B - We try to centre the image in the frame.
This goes wrong if XGDragView passes a rectangle
that is only a part of the image.
Question: Who is correct? is XGDragView
correct in assuming it can pass an arbitrary rect
and the NSCell class will make sure that rect is redraw.
Or is NSCell correct in assuming it will get passed
a rect that is not clipped?
Wim Oudshoorn.
- NSCell drawInterior... positioning bug?,
Willem Rein Oudshoorn <=