Hello,
because including the new Circle-Gradient-Function in my Tools,
here is the exact Calculation of the Circle-Position for any Dialog-Size.
I'm working on a Update, to include this Calculation in the SkinTools.
How it works :
I devided the Screen in 20 Horizontal- and 20 Vertical-parts ( 5 Parts are 1 Screen-Quarter ).
Using Values of 10, 10 centeres the Circle.
Direction Left = minus ( Values 1-9 ), Right = plus ( Values 11-20 )
Up = minus ( Values 1-9 ), Down = plus ( Values 11-20 ).

The Function :
The new Function will be included in the next SkinTool-Update :

Best Regards
Uwe
because including the new Circle-Gradient-Function in my Tools,
here is the exact Calculation of the Circle-Position for any Dialog-Size.
I'm working on a Update, to include this Calculation in the SkinTools.
How it works :
I devided the Screen in 20 Horizontal- and 20 Vertical-parts ( 5 Parts are 1 Screen-Quarter ).
Using Values of 10, 10 centeres the Circle.
Direction Left = minus ( Values 1-9 ), Right = plus ( Values 11-20 )
Up = minus ( Values 1-9 ), Down = plus ( Values 11-20 ).

The Function :
//------------- DLG CIRCLE -----------
// How to use it :
// Step 1-9 for up and left, 11 - 20 for right and down. 10 = Centered
// ------------------------------------------------------------------------------------
// 1. Sample : Circle centered
// ------------------------------------
// ACTIVATE DIALOG oDlg CENTERED ;
// ON PAINT ( Â DLG_CIRCL( oDlg, COLOR1, COLOR2, 10, 10 )Â Â
//
// 2. Sample : Circle on left  / upper
// -------------------------------------------
// ACTIVATE DIALOG oDlg CENTERED ;
// ON PAINT ( Â DLG_CIRCL( oDlg, COLOR1, COLOR2, 5, 5 )Â
//
// -------------------------------------------------------------------------------
// 3. Sample : Circle on right / bottom
// --------------------------------------------------
// ACTIVATE DIALOG oDlg CENTERED ;
// ON PAINT ( Â DLG_CIRCL( oDlg, COLOR1, COLOR2, 20, 20 )Â Â
// -------------------------------------------------------------------------------
//
// hDC
// { nTop, nLeft, nBottom, nRight },
// startColor, endColor
// nOffserX, nOffserY
// lBrush --> hBitmap / hBrush ( GDI OBJECT )
FUNCTION DLG_CIRCL( oDlg, nVColor, nBColor, W_Hoffset, W_Voffset )
LOCAL oBrushBmp := TBrush():New()
LOCAL hDC := oDlg:GETDC()
LOCAL aRect := GETCLIENTRECT( oDlg:hWnd )
LOCAL nXa := aRect[3] / 20, nYa := aRect[4] / 20
LOCAL nX := 0, nY := 0 // Value 10
IF W_HOFFSET > 10
  // position : right from center dialog to middle Circle
  nX := W_HOFFSET * nXa
ENDIF
IF W_HOFFSET < 10
  // position : left from center dialog to middle Circle
  nX := - ( ( 10 - W_HOFFSET ) * nXa )
ENDIF
IF W_VOFFSET > 10
  // position : down from center Dialog to middle Circle
  nY := ( W_VOFFSET - 10 ) * nYa
ENDIF
IF W_VOFFSET < 10
  // position : up from middle dialog to middle Circle
  nY := - ( ( 10 - W_VOFFSET ) * nYa ) Â
ENDIF
DeleteObject( oBrushBmp:hBrush )
oBrushBmp:hBrush = CircleGradient( 0, { 0, 0, aRect[3], aRect[4] } , ;
nVColor, nBColor, nX, nY, 3 ) Â
FillRect( hDC, aRect, oBrushBMP:hBrush )
oDlg:ReleaseDC()
RELEASE BRUSH oBrushBMP
RETURN NILThe new Function will be included in the next SkinTool-Update :

Best Regards
Uwe
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
i work with FW.
If you have any questions about special functions, maybe i can help.