Possible to change gradient-directions in xBrowse ?

Possible to change gradient-directions in xBrowse ?

Postby ukoenig » Wed Oct 30, 2019 8:41 pm

Hello,

is it possible to use bColorstd of xBrowse to build a gradient of columns ( 3D-loook ) in different direction ?
The column < button > shows the normal painting.
It is a matter of taste, but I think it looks much better.

Image

best regards
Uwe :?:
Last edited by ukoenig on Thu Oct 31, 2019 10:41 am, edited 1 time in total.
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.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany

Re: Possible to change gradient-directions in xBrowse ?

Postby nageswaragunupudi » Wed Oct 30, 2019 10:47 pm

Yes
Please try this way:
Code: Select all  Expand view
oBrw:aCols[ n ]:bClrStd := { || { CLR_BLACK, {{ 0.5, nClr1,nClr2 },{0.5, nClr2,nClr1}, .F. } } }

If the last element of the gradient array is not an array but logical .T. is vertical and .F. is horizontal,
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10631
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: Possible to change gradient-directions in xBrowse ?

Postby ukoenig » Thu Oct 31, 2019 10:42 am

Thank You very much.
It works with the same syntax like the normal gradientdesign.
Is there maybe a solution to protect a cell from to be covered from the focused rowcolor
to keep the cellcolor / gradient visible like used for images ?

Image

or drawing a rowborder using :

:nMarqueeStyle := 0
:lRowBox := .T.
:nColorBox := 255
:nBoxPen := 5

( would be perfect with a defined pensize )

Image

I changed some lines in xBrowse line 2995

a new data := DATA nBoxpen INIT 1
I added a value of 3
Code: Select all  Expand view

DATA nBoxPen INIT 1

if ::lRowBox .and. nStyle != 7
     oCol := ::ColAtPos( nLast )
     nLast := Min( oCol:nDisplayCol + oCol:nWidth - 1, ::GridWidth() - 3 )
     RoundBox( hDC, If( ::lRecordSelector, ::nRecSelWidth, 1 ), nRow +1, ;
                     nLast, nRow + nDataHeight -1, 2, 2, ::nColorBox, ::nBoxPen )      
       
    //::Box( nRow, If( ::lRecordSelector, ::nRecSelWidth, 1 ), ;
    //  nRow + nDataHeight, nLast, ::nColorBox )
endif


Image

best regards
Uwe :?:
Last edited by ukoenig on Sat Nov 02, 2019 9:51 am, edited 4 times in total.
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.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany

Re: Possible to change gradient-directions in xBrowse ?

Postby nageswaragunupudi » Thu Oct 31, 2019 1:16 pm

s there maybe a solution to protect a cell from to be covered from the focused rowcolor
to keep the cellcolor / gradient visible like used for images ?


oCol:bClrSelFocus := oCol:bClrStd
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10631
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: Possible to change gradient-directions in xBrowse ?

Postby ukoenig » Fri Nov 01, 2019 3:45 pm

Thank You very much

that works fine and I could finish the tool

If You downloaded the tool and it slows down with empty gradients ( shown as black )
please download again
There is a problem with the gradient-position 0
I changed this value to 0.1 and it is working fine now

http://www.pflegeplus.com/DOWNLOADS/GrdPaint2.zip

complete new design
100 positions are defined
You can clear the fields and reset the counter

Image

with a small change in xBrowse the pensize can be defined :!:

Image

oCol:bClrSelFocus := oCol:bClrStd

protecting the gradient-field

Image

Best regards
Uwe :D
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.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 100 guests