[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

small bug in NSClipView.m

From: Benhur Stein
Subject: small bug in NSClipView.m
Date: Thu, 19 Oct 2000 21:36:22 GMT


The background around the view inside NSClipView
is not redrawn when the document view becomes 
smaller than the clipview.
The test in [NSClipView viewFrameChanged:] seems wrong.
A version of this method that seems to correct the problem follows.

- (void) viewFrameChanged: (NSNotification*)aNotification
  [self setBoundsOrigin: [self constrainScrollPoint: _bounds.origin]];

  /* If document frame does not completely cover _bounds */
  if (!NSContainsRect([_documentView frame], _bounds))
      /* then fill the area not covered by documentView with background
color */
      [self setNeedsDisplay: YES];

  [_super_view reflectScrolledClipView: self];

Benhur Stein

reply via email to

[Prev in Thread] Current Thread [Next in Thread]