> > 1 - How do you get the QDColors? > The piece of code below doesn't work correctly whether I use XREF or > XREF@: > LMGetQDColors returns a pointer, not a handle as documented. Try this: Toolbox Fn LMGetQDColors = ptr `0x2EB8, 0x08B0 #if ndef _appearanceRuntime begin record ColorSpec dim as short value dim as RGBColor rgb end record #endif begin record CSpecArray dim as ColorSpec cSpec[7] end record Window 1 Dim i As Long Dim s As Str15 Dim r As Rect dim theQDColors as ^CSpecArray theQDColors = Fn LMGetQDColors SetRect(r,10,10,30,30) For i = 0 To 7 Select i Case 0 : s = "Black" Case 1 : s = "Yellow" Case 2 : s = "Magenta" Case 3 : s = "Red" Case 4 : s = "Cyan" Case 5 : s = "Green" Case 6 : s = "Blue" Case 7 : s = "White" End Select RGBForeColor( theQDColors.cSpec[i].rgb ) : PaintRect( r ) RGBForeColor( theQDColors.cSpec[0].rgb ) : FrameRect( r ) MoveTo( r.left, r.bottom + 10 ) DrawString( s ) OffsetRect( r, 50, 0 ) Next Do Handleevents Until Fn Button