CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Join Date
    Jan 2004
    Posts
    116

    Invalidate Scrollbar

    Hi,

    I have a tracking tooltip in a CView that has vertical and horz scrollbars.

    If the window is small and both scrolls are visible, the tooltip sometimes hovers over the small area of the window where the two scrollbars meet (bottom-right corner).

    This little area is then polluted with garbage until the entire window is painted or the scroll bar is used, etc...

    I've tried to invalidate the view in OnToolTipNeedText - but that's no good as it's pretty much the same as OnMouseMove, and creates too much flicker. I also use CheckScrollBars to limit the re-drawing, but its still too much.

    Any way to only invalidate the scroll bar regions?

    Thx.

  2. #2
    Join Date
    Apr 2009
    Posts
    598

    Re: Invalidate Scrollbar

    Maybe with SetWindowPos(SWP_FRAMECHANGED) instead of InvalidateRect().

  3. #3
    Join Date
    Jan 2004
    Posts
    116

    Re: Invalidate Scrollbar

    thx! that works nicely.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured