FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour Change text color and background of tRadio
Posts: 244
Joined: Mon Jun 05, 2006 09:39 PM
Change text color and background of tRadio
Posted: Wed Nov 20, 2019 02:38 PM
I do like this:

Code (fw): Select all Collapse
 聽Redefine RADIO ::oRad760_DadosCobranca ;
聽 聽 VAR ::oDs_ClientesEdit:COBRANCA ;
聽 聽 ID 761,762,763,764 聽OF ::oFldDetalhes:aDialogs[1] ;
聽 聽 Color G_COLOR_SYS(2),G_COLOR_SYS(1)


In this example, G_COLOR_SYS (2) is white and G_COLOR_SYS (1) is the background.
I can't change the colors of the text or the background of tRadio.
Already tried the Bj: nClrText: = also does not work. This also happens with CheckBox.
Would anyone know any method to make this possible?

Posts: 6755
Joined: Wed Feb 15, 2012 08:25 PM
Re: Change text color and background of tRadio
Posted: Wed Nov 20, 2019 02:49 PM
As far as I know it is a problem to have active themes (also for checkboxes).
This may work although for me it has never been a good solution.
Code (fw): Select all Collapse
      SetWindowTheme( ::oRad760_DadosCobranca:hWnd, "", "" )
Cristobal Navarro

Hay dos tipos de personas: las que te hacen perder el tiempo y las que te hacen perder la noci贸n del tiempo

El secreto de la felicidad no est谩 en hacer lo que te gusta, sino en que te guste lo que haces
Posts: 244
Joined: Mon Jun 05, 2006 09:39 PM
Re: Change text color and background of tRadio
Posted: Wed Nov 20, 2019 03:04 PM
When executing I get the message:
Code (fw): Select all Collapse
Error description: Error BASE/1004  Message not found: TRADMENU:HWND
Posts: 6755
Joined: Wed Feb 15, 2012 08:25 PM
Re: Change text color and background of tRadio
Posted: Wed Nov 20, 2019 03:12 PM
Sorry, try

Code (fw): Select all Collapse
SetWindowTheme( ::oRad760_DadosCobranca:aItems[ 3 ]:hWnd, "", "" )
Cristobal Navarro

Hay dos tipos de personas: las que te hacen perder el tiempo y las que te hacen perder la noci贸n del tiempo

El secreto de la felicidad no est谩 en hacer lo que te gusta, sino en que te guste lo que haces
Posts: 244
Joined: Mon Jun 05, 2006 09:39 PM
Re: Change text color and background of tRadio
Posted: Wed Nov 20, 2019 03:36 PM
Thanks, it worked.
I better change the tRadio class so I don't have to mess with the whole system.
I am creating a kind of Dark Theme, and if I could not change certain controls, it would not work.

Code (fw): Select all Collapse
 聽::oDlgCadastro:bInit := <||
聽 聽 AEval( lc_oSelf:oCliDetConta:oRad760_DadosCobranca:aItems,;
聽 聽 聽 聽 聽 聽{|_oRadSeq|SetWindowTheme( _oRadSeq:hWnd, "", "" )})
聽 Return nil
聽 > //cEnd


Posts: 6755
Joined: Wed Feb 15, 2012 08:25 PM
Re: Change text color and background of tRadio
Posted: Wed Nov 20, 2019 03:41 PM
Ok, but I don't like the 3dlook style
Try using also this and tell me if it works with redefined controls

Code (fw): Select all Collapse
Ctl3DLook( <yourobjectcontrol>:hWnd, .F. )
Cristobal Navarro

Hay dos tipos de personas: las que te hacen perder el tiempo y las que te hacen perder la noci贸n del tiempo

El secreto de la felicidad no est谩 en hacer lo que te gusta, sino en que te guste lo que haces
Posts: 6755
Joined: Wed Feb 15, 2012 08:25 PM
Re: Change text color and background of tRadio
Posted: Wed Nov 20, 2019 03:50 PM

Giovany, Your design is very good, congratulations

Cristobal Navarro

Hay dos tipos de personas: las que te hacen perder el tiempo y las que te hacen perder la noci贸n del tiempo

El secreto de la felicidad no est谩 en hacer lo que te gusta, sino en que te guste lo que haces
Posts: 244
Joined: Mon Jun 05, 2006 09:39 PM
Re: Change text color and background of tRadio
Posted: Wed Nov 20, 2019 03:56 PM
I thought the Set3DLook(.F.) function would solve this question
Posts: 244
Joined: Mon Jun 05, 2006 09:39 PM
Re: Change text color and background of tRadio
Posted: Wed Nov 20, 2019 04:11 PM
cnavarro wrote:Giovany, Your design is very good, congratulations

Thank you Navarro. We have to show that Fivewin is beyond what we think we can do.

Via Activex Integration


Other controls
Posts: 6755
Joined: Wed Feb 15, 2012 08:25 PM
Re: Change text color and background of tRadio
Posted: Wed Nov 20, 2019 04:39 PM
Giovany Vecchi wrote:
cnavarro wrote:Giovany, Your design is very good, congratulations

Thank you Navarro. We have to show that Fivewin is beyond what we think we can do.



The limit is our imagination, without any doubt

Giovany Vecchi wrote:
I thought the Set3DLook(.F.) function would solve this question


Have you managed to solve the 3D effect?
Cristobal Navarro

Hay dos tipos de personas: las que te hacen perder el tiempo y las que te hacen perder la noci贸n del tiempo

El secreto de la felicidad no est谩 en hacer lo que te gusta, sino en que te guste lo que haces
Posts: 244
Joined: Mon Jun 05, 2006 09:39 PM
Re: Change text color and background of tRadio
Posted: Wed Nov 20, 2019 04:59 PM
Have you managed to solve the 3D effect?


I did not make it.
I noticed that even putting at the beginning of the program the option Set3dLook (.F.) OR .T., Does not change anything.

Continue the discussion