Page 1 of 2
Rowcolor - only frame colored
Posted: Tue Jun 08, 2021 6:12 am
by Victorio
Hi everyone ,
In DCBROWSE when I have cursor on row, this is colored default with blue color. The whole area of row is colored with blue.
Is possible to coloring only part of this area, for example only frame around the cell, or row, or only smaller stip line of row ?
Or is possible change parameter for bgcolor of browse rowcolor ?
I have coloring rows with different colors by status every rows, and when user stay on row which is in some other color, he do not see on what status is this row.
It is not very important problem, only one of clients wants this design, so if anybody know simple solutions ... THX
Re: Rowcolor - only frame colored
Posted: Wed Jun 09, 2021 11:16 am
by rdonnay
You could look at the \exp20\samples\browse\ownerdraw.prg sample for some ideas.
Re: Rowcolor - only frame colored
Posted: Wed Jun 09, 2021 11:50 am
by Auge_Ohr
hi,
not sure about FRAME Color.
Victorio wrote: ↑Tue Jun 08, 2021 6:12 am
I have coloring rows with different colors by status every rows, and when user stay on row which is in some other color, he do not see on what status is this row.
you need a "Special" Column CLASS to "show" Color "under" ROW-Bar from J.A. Diego Kerejeta
Re: Rowcolor - only frame colored
Posted: Wed Jun 09, 2021 2:32 pm
by rdonnay
Tell me what color his STATUS field is, so I can experiment with this.
Re: Rowcolor - only frame colored
Posted: Wed Jun 09, 2021 11:21 pm
by Wolfgang Ciriack
You can use color defines with a 4 elements array, f. e.
#define BRW_CLR_MARKRED {GRA_CLR_RED, GRA_CLR_DARKGRAY, GRA_CLR_RED, nil}
so standard is red on darkgray, and on cursor row red on cursor color.
Re: Rowcolor - only frame colored
Posted: Thu Jun 10, 2021 12:40 am
by Victorio
Roger , rows in browse are coloring various color combinations, by his status when processing. Now I have color of row when stay with curson on as white text on blue background,
I need something as in attached picture, first row or bottom row. middle is existing colors.
Jimmy, attached file not found ...
Re: Rowcolor - only frame colored
Posted: Thu Jun 10, 2021 3:56 am
by Wolfgang Ciriack
Roger, problem, attached file is not viewable.
Victorio, see my sample with 4 colorarray.
Re: Rowcolor - only frame colored
Posted: Thu Jun 10, 2021 4:52 am
by Victorio
Worfgang, I test it, but I want cursor color apply only for part of surface row, not only change text FG color to see where on row am I.
As my attached picture some thick frabe around row where is cursor.
Or redesign browser to get frame around row, but this can be complicated.
I just got an idea , zoom row content when cursor on it, change font size. I must examine it, then I must disable change color when cursor on row with XBPBRW_CURSOR_NONE .
Re: Rowcolor - only frame colored
Posted: Thu Jun 10, 2021 5:44 am
by Auge_Ohr
Victorio wrote: ↑Thu Jun 10, 2021 12:40 am
Jimmy, attached file not found ...
and i can´t see you Picture ...
here is the CLASS
Code: Select all
CLASS XbpColumnLocal FROM XbpColumn
EXPORTED:
INLINE METHOD HiliteRow( nRowPos, lHilite, lFrame, lRepaint )
LOCAL aColor
LOCAL RETVAR
IF( lHilite ) // .AND. ( aColor:= Eval( ::colorBlock ) ) # nil
IF ::colorBlock # NIL
aColor := EVAL( ::colorBlock )
IF aColor = NIL
RETVAR := ::XbpColumn:HiliteRow( nRowPos, lHilite, lFrame, lRepaint )
ELSE
RETVAR := ::dataArea:setCellColor( nRowPos, aColor[ 1 ], aColor[ 2 ] )
ENDIF
ELSE
RETVAR := ::XbpColumn:HiliteRow( nRowPos, lHilite, lFrame, lRepaint )
ENDIF
ELSE
RETVAR := ::XbpColumn:HiliteRow( nRowPos, lHilite, lFrame, lRepaint )
ENDIF
RETURN RETVAR
ENDCLASS
Re: Rowcolor - only frame colored
Posted: Thu Jun 10, 2021 7:06 am
by rdonnay
I am able to view the GIF.
I am still trying to figure out why they become unviewable for some users, also for myself.
On the row with the blue cursor, please explain to me which colors you want to see. (Foreground, Background).
What is the row color when the blue cursor is not covering it?
Is it black on green, or black on yellow?