Row BackColor in inactive BROWSE control
Moderator: Rathinagiri
Re: Row BackColor in inactive BROWSE control
But grid is very slow with dbfs.
I'm only using virtual grid for arrays.
CellNavigAtionColor works only if you set CellNavigatio to .T.
I'm only using virtual grid for arrays.
CellNavigAtionColor works only if you set CellNavigatio to .T.
Re: Row BackColor in inactive BROWSE control
Andrés González López
Desde Guadalajara, Jalisco. México.
Desde Guadalajara, Jalisco. México.
- SALINETAS24
- Posts: 667
- Joined: Tue Feb 27, 2018 3:06 am
- DBs Used: DBF
- Contact:
Re: Row BackColor in inactive BROWSE control
Hola, mira este modelo. Yo utilizo tambien VIRTUAL GRID, y lo unico que tienes que ajustar es que cuando cargas
Code: Select all
Local i := Form_1.Grid_1.Value
Por lo demas.., queda bastante bien.
Una cervecita bien fresquita a todos los hombre de buena voluntad
- Attachments
-
- GRID_07.rar
- (1.21 MiB) Downloaded 105 times
Como dijo el gran pensador Hommer Simpson..., - En este mundo solo hay 3 tipos de personas, los que saben contar y los que no. 
Re: Row BackColor in inactive BROWSE control
Marku patrzyłeś na KSeF, który Ci przysłałem? Tam jest virtual grid dla dbf bez ładowania do pamięci/tablicy, querydata w locie nawiguje po dbf.
Re: Row BackColor in inactive BROWSE control
Dzięki Edward, byłem na feriach i nie miałem kiedy zajmować się tym.
Jutro popatrzę
Jutro popatrzę
Re: Row BackColor in inactive BROWSE control
Hi Edward!
Your solution is OK.
But, I want to find universal solution for BROWSE. I don't want to rebuild my whole old application changing every BROWSE to GRID.
Cześć Edwa, przepraszam, że po angielsku, ale może ktoś jeszcze śledzi ten temat.
Straciłem już trzy popołudnia, wydaje mi się, że jestem bardzo blisko, ale brak znajomości wewnętrznych zależności HMG nie pozwala mi osiągnąć efektu.
Myślę, że Claudio lub Grigorij mogliby o zrobić, ale nie chcą i już
Your solution is OK.
But, I want to find universal solution for BROWSE. I don't want to rebuild my whole old application changing every BROWSE to GRID.
Cześć Edwa, przepraszam, że po angielsku, ale może ktoś jeszcze śledzi ten temat.
Straciłem już trzy popołudnia, wydaje mi się, że jestem bardzo blisko, ale brak znajomości wewnętrznych zależności HMG nie pozwala mi osiągnąć efektu.
Myślę, że Claudio lub Grigorij mogliby o zrobić, ale nie chcą i już
Re: Row BackColor in inactive BROWSE control
Dobrze Cię rozumiem, nieraz wkurza mnie moja bezradność i niewiedza.
- AUGE_OHR
- Posts: 2117
- Joined: Sun Aug 25, 2019 3:12 pm
- DBs Used: DBF, PostgreSQL, MySQL, SQLite
- Location: Hamburg, Germany
Re: Row BackColor in inactive BROWSE control
hi Mol,
it is "by Design" of Windows that "active" Color switch when "lost Focus"
open 2 x Explorer Windows and use "Detail" for "Report" Design -> GRID / BROWSE
now switch Windows and note "hi-light" or "low-light" Row in Explorer
--- on left Side it is a HMG App and on right Side my Xbase++ App
left Side have Focus (see active Titlebar) but only 1 GRID are "active"
my Xbase++ App use "own" WC_LISTVIEW Control and "Owner Draw"
both GRID have "hilight" ROW even Window / Control are not active
so you need "Owner Draw" to get that "Look"
---
possible Workaroud
under
you will find actual Theme Color which are used
there are some "active/inactive" Color like
there are 2 API Function to Set/Get those Colors
https://docs.microsoft.com/en-us/window ... etsyscolor
! Note : Setsyscolors() will effect on ALL Windows App (but not "Permanent")
! Note : Setsyscolors() will NOT written into Registry
so after re-Login all Color are default like before
it is "by Design" of Windows that "active" Color switch when "lost Focus"
open 2 x Explorer Windows and use "Detail" for "Report" Design -> GRID / BROWSE
now switch Windows and note "hi-light" or "low-light" Row in Explorer
--- on left Side it is a HMG App and on right Side my Xbase++ App
left Side have Focus (see active Titlebar) but only 1 GRID are "active"
my Xbase++ App use "own" WC_LISTVIEW Control and "Owner Draw"
both GRID have "hilight" ROW even Window / Control are not active
so you need "Owner Draw" to get that "Look"
---
possible Workaroud
under
Code: Select all
Computer\HKEY_CURRENT_USER\Control Panel\Colorsthere are some "active/inactive" Color like
Code: Select all
#define COLOR_ACTIVECAPTION 2
#define COLOR_INACTIVECAPTION 3
#define COLOR_CAPTIONTEXT 9https://docs.microsoft.com/en-us/window ... etsyscolor
https://docs.microsoft.com/en-us/window ... tsyscolorsThe function returns the red, green, blue (RGB) color value of the given element.
using API Function "SetSysColor" you can set those 30 COLOR_* Constante in WinUser.H (see Attachment )An array of COLORREF values that contain the new red, green, blue (RGB) color values for the display elements in the array pointed to by the lpaElements parameter.
! Note : Setsyscolors() will effect on ALL Windows App (but not "Permanent")
! Note : Setsyscolors() will NOT written into Registry
so after re-Login all Color are default like before
have fun
Jimmy
Jimmy
Re: Row BackColor in inactive BROWSE control
It is possible to change color in inactive browse, I think. But I can't find solution 
I don't want to change windows schema.
I don't want to change windows schema.
- AUGE_OHR
- Posts: 2117
- Joined: Sun Aug 25, 2019 3:12 pm
- DBs Used: DBF, PostgreSQL, MySQL, SQLite
- Location: Hamburg, Germany
Re: Row BackColor in inactive BROWSE control
hi Mol,
you will find something like WINDOW_LOSTFOCUS ... so search for it
so i guess it is not possible without "Owner Draw" to "overule" draw "by System"
look into \SOURCE\h_windows.PRG and search for WM_ACTIVATE
you will find something like WINDOW_LOSTFOCUS ... so search for it
Code: Select all
IF _HMG_SYSDATA[ 232 ] == 'WINDOW_LOSTFOCUS'
MsgHMGError( "ACTIVATE WINDOW / Activate(): Not allowed in window's LOSTFOCUS event procedure. Program terminated" )
ENDIFhave fun
Jimmy
Jimmy