Follow-up Comment #6, bug #40776 (project gnustep):

Indeed, -documentVisibleRect is in the document view's coordinate system, I
failed to notice that when I replaced [self setNeedsDisplay: YES] with it, and
it still /seemed to/ work correctly, so I left it alone.

If you want to only redraw the whole clip view when the document view shrinks,
then one could do

:
:
NSRect oldBounds = [self bounds];
[super setBounds: b];
if (NSContainsRect(b, oldBounds))
  {
    [_documentView setNeedsDisplayInRect: [self documentVisibleRect]];
  }
else
  {
    [self setNeedsDisplay: YES];
  }
:
:

but that may be overkill, and just easier to always redraw when the bounds
change.


    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?40776>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/


_______________________________________________
Bug-gnustep mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/bug-gnustep

Reply via email to