In the old TGET.PRG we allowed the cliente to choose general foreground and background colors and applied the choice with these two lines.
COLOR_S is a public containing the clientes choice DEFAULT value
COLOR_S:= 16777215
::bGotFocus := {|| ::SetColor(nClrFore,COLOR_S)}
::bLostFocus := {|| ::SetColor(nClrFore, RGB(255,255,255))}
How can I apply the same system in the new TGET.PRG for FWH
FORGROUND BACK GROUND COLORS GETS
- James Bott
- Posts: 4654
- Joined: Fri Nov 18, 2005 4:52 pm
- Location: San Diego, California, USA
- Contact:
Paul,
What do you mean by the "old" and the "new" -- can you provide us with versions?
I assume it isn't working in the "new" FWH? What exactly is happening? What happens if you replace the codeblocks with msgBeep(); do you hear the beep?
Can you provide us with a small example that shows the problem?
James
What do you mean by the "old" and the "new" -- can you provide us with versions?
I assume it isn't working in the "new" FWH? What exactly is happening? What happens if you replace the codeblocks with msgBeep(); do you hear the beep?
Can you provide us with a small example that shows the problem?
James
Re: FORGROUND BACK GROUND COLORS GETS
Paul,PAUL SIMM wrote:In the old TGET.PRG we allowed the cliente to choose general foreground and background colors and applied the choice with these two lines.
COLOR_S is a public containing the clientes choice DEFAULT value
COLOR_S:= 16777215
::bGotFocus := {|| ::SetColor(nClrFore,COLOR_S)}
::bLostFocus := {|| ::SetColor(nClrFore, RGB(255,255,255))}
How can I apply the same system in the new TGET.PRG for FWH
in tget.prg add this method:
Code: Select all
METHOD SetIniClr()
add at the end of define:
Code: Select all
...
endif
::SetIniClr()
return Self
Code: Select all
...
endif
::SetIniClr()
oWnd:DefControl( Self )
return Self
Code: Select all
METHOD SetIniClr() CLASS TGet
// This is my standard set:
::nClrFocusText := nRGB(0,0,0) // CLR_BLACK //
::nClrFocusPane := nRGB( 213, 230, 255 ) // nRGB(243,250,200) // CLR_HBLUE //
::nClrPFoText := ::nClrText
::nClrPFoPane := ::nClrPane
//
::bGotFocus := {|| ::SetColor( ::nClrFocusText, ::nClrFocusPane) }
::bLostFocus := {|| ::SetColor( ::nClrPFoText , ::nClrPFoPane ) }
Return Self
Ciao, best regards,
Ugo
Ugo
CHANGING FOCUSED COLORS GLOBALLT IN TGET
WITH THE CHANGES YOU SUGGESTED TO REDEFINE I GET THE FOLLOWING ERROR:
(CANNOT FIND THE METHOD DEFINE IN THE CLASS )
Heres the Class modified http://www.pes-systems.net/temp/tget32.prg
INFORMACION: Error BASE/1005 Message not found: TGET:_NCLRFOCUSTEXT
Stack Calls
===========
2.TGET:ERROR(175) 3.(b)HBOBJECT:HBOBJECT(105) 4.TGET:MSGNOTFOUND(0)
5.TGET:_NCLRFOCUSTEXT(167) 6.TGET:SETINICLR(1604) 7.TGET:REDEFINE(376)
8.BUS_CLIENTES(174) 9.(b)BUILDMENU(1732) 10.TMENU:COMMAND(0)
11.TWINDOW:COMMAND(0) 12.TWINDOW:HANDLEEVENT(0) 13._FWH(0)
14.WINRUN(0) 15.TWINDOW:ACTIVATE(0) 16.MAIN(424)
(CANNOT FIND THE METHOD DEFINE IN THE CLASS )
Heres the Class modified http://www.pes-systems.net/temp/tget32.prg
INFORMACION: Error BASE/1005 Message not found: TGET:_NCLRFOCUSTEXT
Stack Calls
===========
2.TGET:ERROR(175) 3.(b)HBOBJECT:HBOBJECT(105) 4.TGET:MSGNOTFOUND(0)
5.TGET:_NCLRFOCUSTEXT(167) 6.TGET:SETINICLR(1604) 7.TGET:REDEFINE(376)
8.BUS_CLIENTES(174) 9.(b)BUILDMENU(1732) 10.TMENU:COMMAND(0)
11.TWINDOW:COMMAND(0) 12.TWINDOW:HANDLEEVENT(0) 13._FWH(0)
14.WINRUN(0) 15.TWINDOW:ACTIVATE(0) 16.MAIN(424)
Re: CHANGING FOCUSED COLORS GLOBALLT IN TGET
Paul,PAUL SIMM wrote: INFORMACION: Error BASE/1005 Message not found: TGET:_NCLRFOCUSTEXT
insert this line into data section:
Code: Select all
DATA nClrFocusText, nClrFocusPane, nClrPFoText, nClrPFoPane
Ciao, best regards,
Ugo
Ugo
Re: BACLGROUND COLORS GET
Paul,PAUL SIMM wrote:THANKS UGO WORKS FINE NOW.
nothing!
Ciao, best regards,
Ugo
Ugo