FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour Missing transp. controls using DiagonalGradient
Posts: 4043
Joined: Wed Dec 19, 2007 06:40 PM
Missing transp. controls using DiagonalGradient
Posted: Mon Nov 24, 2014 07:51 PM
Hello,

testing gradient-styles, using function DiagonalGradient,
the controls are NOT transparent.

horizontal / vertical ( OK )



Circle ( OK )



Diagonal ( WRONG )



any working sample ?

The used function from FWH-samples :
( I couldn't find function DiagonalGradient )

Code (fw): Select all Collapse
FUNCTION DGRADFILL( hDC, nTop, nLeft, nBottom, nRight, aGradInfo, lDirection )
LOCAL nClr := 1, nClrs := Len( aGradInfo )
LOCAL nSize, nStart, nEnd

default lDirection := .T.

IF Empty( aGradInfo )
   RETURN NIL
ENDIF

nSize    = ( nBottom - nTop ) + ( nRight - nLeft )
nStart   = 0
nEnd     = 0

FOR nClr := 1 to nClrs
   nStart = nEnd  
   nEnd   += ( nSize * ( aGradInfo[ nClr ][ 1 ] ) )

   DiagonalGradient( hDC, ;
      { nTop, nLeft, nBottom, nRight },;
        aGradInfo[ nClr ][ 2 ], ;
        aGradInfo[ nClr ][ 3 ], ;
        lDirection, ;
        nStart, ;
        nEnd )
NEXT

RETURN NIL


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.

Continue the discussion