Index: PVCanvas.mac.rou =================================================================== diff -u -r734 -r2415 --- PVCanvas.mac.rou (.../PVCanvas.mac.rou) (revision 734) +++ PVCanvas.mac.rou (.../PVCanvas.mac.rou) (revision 2415) @@ -5,17 +5,17 @@ #define VertPos(%Rect) $LI(%Rect,5) Set %Screen=##class(UI.TNT.TScreen).Create() - + Set BGRect(1)=$LB(2,7,20,70) ; Background Set FGRect(1)=$LB(5,10,10,20) ; Foreground Set Rect=$LB(6,10,6,100,1) ; Te controlerenRectangle Write "Background " Do DispRect(BGRect) Write "Forground " Do DispRect(FGRect) Write "Rectangle " Do DispRect(Rect) Quit - + #Include UI.TNT.System - + Test(Control) New aBGRects,aFGRects Do WL^vhDBG("") @@ -25,19 +25,19 @@ . Do DispRects(.Rects) Else Do . Do WL^vhDBG("Failed") - + Quit - - + + // Geef een control op en de background + foreground rectangles terug GetPaintRects(Control,aBGRects,aFGRects) Quit:(Control="") 0 Quit:('Control.Visible) 0 - + ;Background rects (eventuele frames en form onder control) New Nr,ParentForm,ParentNotVisible Set Nr=0, ParentForm="", AParentIsNotVisible=0 - + For Set Control=Control.Parent Quit:(Control="") Do Quit:(AParentIsNotVisible) . Set:(Control.HasControls) Nr=Nr+1, aBGRects(Nr)=Control.GetRect(0) . Set:('Control.Visible) AParentIsNotVisible=1 @@ -74,7 +74,7 @@ For Set VolgNr=$O(BGRects(VolgNr)) Quit:VolgNr="" Do . Do ClippingBackground(BGRects(VolgNr),.InitRect) Quit:InitRect="" ; De rectangle valt volledig buiten de background - + ; Hidden removal Set Rects=1 Set Rects(Rects)=InitRect @@ -158,7 +158,7 @@ IsHidden(FGRect,Rect) Quit ($$$Top(FGRect)'>$$$Top(Rect)) && ($$$Bottom(FGRect)'<$$$Bottom(Rect)) && ($$$Left(FGRect)'>$$$Left(Rect)) && ($$$Right(FGRect)'<$$$Right(Rect)) - + DispRects(Rects) For I=1:1:Rects Do . Do W^vhDBG("["_I_"] ")