Themed TGet on windows (fixed)
-
- Posts: 116
- Joined: Thu Oct 13, 2005 5:14 pm
- Location: Italy
Themed TGet on windows (fixed)
I can't obtain themed edit box on windows.
See the code below:
#include "fivewin.ch"
procedure main()
local oDlg, cText := Space(30)
define window oDlg title "Test" from 10,10 to 300,300 pixel
@1,1 get cText of oDlg size 200,20
activate window oDlg
return
The edit box has a black border instead the theme blue border.
It only happens with window, if I change the "define/activate window" with "define/activate dialog" it looks fine.
Antonio, I post this problem the first time in July 2004, please make my app full xp themed
Regards,
Roberto Parisi
See the code below:
#include "fivewin.ch"
procedure main()
local oDlg, cText := Space(30)
define window oDlg title "Test" from 10,10 to 300,300 pixel
@1,1 get cText of oDlg size 200,20
activate window oDlg
return
The edit box has a black border instead the theme blue border.
It only happens with window, if I change the "define/activate window" with "define/activate dialog" it looks fine.
Antonio, I post this problem the first time in July 2004, please make my app full xp themed
Regards,
Roberto Parisi
- Antonio Linares
- Site Admin
- Posts: 37481
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Contact:
-
- Posts: 116
- Joined: Thu Oct 13, 2005 5:14 pm
- Location: Italy
- Antonio Linares
- Site Admin
- Posts: 37481
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Contact:
- Antonio Linares
- Site Admin
- Posts: 37481
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Contact:
-
- Posts: 116
- Joined: Thu Oct 13, 2005 5:14 pm
- Location: Italy
- Antonio Linares
- Site Admin
- Posts: 37481
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Contact:
-
- Posts: 116
- Joined: Thu Oct 13, 2005 5:14 pm
- Location: Italy
changes
Antonio,
I don't understand what are the fixes I need in classes/tget.prg.
WS_Border appears in the lines:
thanks
I don't understand what are the fixes I need in classes/tget.prg.
WS_Border appears in the lines:
Code: Select all
WS_Border appears in the lines:
::nStyle = nOR( WS_CHILD, WS_VISIBLE,;
ES_AUTOHSCROLL, WS_BORDER,;
If( ! lReadOnly, WS_TABSTOP, 0 ),;
If( lDesign, WS_CLIPSIBLINGS, 0 ),;
If( lSpinner, WS_VSCROLL, 0 ),;
If( lReadOnly, ES_READONLY, 0 ),;
If( lCenter, ES_CENTER, If( lRight, ES_RIGHT, ES_LEFT ) ) )
// If( lCenter .OR. lRight, ES_MULTILINE, 0 ),; Only needed for Win31
::nStyle = If( lNoBorder, nAnd( ::nStyle, nNot( WS_BORDER ) ), ::nStyle )
Riccardo
- Antonio Linares
- Site Admin
- Posts: 37481
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Contact:
- Antonio Linares
- Site Admin
- Posts: 37481
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Contact:
This fix for Class TGet Method New(...) seems to be a better one:
Code: Select all
...
::nStyle = nOR( WS_CHILD, WS_VISIBLE,;
ES_AUTOHSCROLL,;
If( ! lReadOnly, WS_TABSTOP, 0 ),;
If( lDesign, WS_CLIPSIBLINGS, 0 ),;
If( lSpinner, WS_VSCROLL, 0 ),;
If( lReadOnly, ES_READONLY, 0 ),;
If( lCenter, ES_CENTER, If( lRight, ES_RIGHT, ES_LEFT ) ) )
#ifdef __CLIPPER__
if ! lNoBorder
::nStyle = nOr( ::nStyle, WS_BORDER )
endif
#else
if ! IsAppThemed()
::nStyle = nOr( ::nStyle, WS_BORDER )
else
::nStyle = nOr( ::nStyle, If( oWnd:ChildLevel( TDialog() ) != 0, WS_BORDER, 0 ) )
endif
#endif
a clear patch!
Sorry Antonio, I continue not to understand.
In your Nov,7 message you said to update winapi\mgetcrea.c and classes\tget.prg.
Now you add another correction to mgetcrea.c and another to tget.prg.
How is the definitive patch?
could you please send me the 2 files by email?
regards
In your Nov,7 message you said to update winapi\mgetcrea.c and classes\tget.prg.
Now you add another correction to mgetcrea.c and another to tget.prg.
How is the definitive patch?
could you please send me the 2 files by email?
regards
Riccardo
- Antonio Linares
- Site Admin
- Posts: 37481
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Contact:
- Antonio Linares
- Site Admin
- Posts: 37481
- Joined: Thu Oct 06, 2005 5:47 pm
- Location: Spain
- Contact: