Dear All,
I need to change TFOLDEREX UI as FLAT style. How can I do it?
Thanks in advance,
Antonio Linares wrote:Dear Dutch,
Please provide a screenshot with the folderex look that you wish
oTab := TFolderEx() :New( .. )
// disable visual Style
SetWindowTheme( oTab:hWnd, "", "" )
@ 0, 0 FOLDEREX oFld1 PIXEL PROMPTS "Pendientes", "Despachados" OF oP SIZE oP:nWidth, oP:nHeight TAB HEIGHT 40 ON CHANGE EVAL(cbRecibe) NOBORDER
WITH OBJECT oFld1
:aGradSel := { { 1, CLR_WHITE, CLR_WHITE } }
:aGradUnSel := { { 1, CLR_WHITE, CLR_WHITE } }
:aGradOver := { { 1, Rgb( 237, 237, 237 ), Rgb( 237, 237, 237 ) } } //
:aGradOverUnSel := :aGradOver
END
Antonio Linares wrote:Dear Dutch,
We need to modify METHOD PaintTB() so tabs are painted in different styles. Looking for a way to do it
dutch wrote:Can I DISABLE TAB (disable color) for TFOLDER?
METHOD DisableTab( nOption ) CLASS TFolderEx
DEFAULT nOption := ::nOption
IF ::aEnable[ nOption ]
::aEnable[ nOption ] = .F.
::aDialogs[ nOption ]:Disable()
::Refresh()
ENDIF
RETURN NIL
bClrTabs := {| o, n | ::SetFldColors( o, n ) },;
METHOD SetFldColors( oThis, n ) CLASS TFolderEx
...
IF ! ::aEnable[ n ]
hBrush = GradientBrush( ::hDC, 0, 0, nWidth, nHeight, ::aGradDis, lHor )
RETURN hBrush
ENDIF
function TestFolderex()
local oDlg, oFld
DEFINE DIALOG oDlg SIZE 400,300 PIXEL TRUEPIXEL ;
TITLE "FOLDEREX FLAT STYLE by Leandro"
@ 10,10 FOLDEREX oFld ADJUST OF oDlg SIZE 380,280 PIXEL ;
PROMPT "Monday", "Tuesday", "WednesDay", "Thursday"
WITH OBJECT oFld
:aGradSel := { { 1, CLR_WHITE, CLR_WHITE } }
:aGradUnSel := { { 1, CLR_WHITE, CLR_WHITE } }
:aGradOver := { { 1, Rgb( 237, 237, 237 ), Rgb( 237, 237, 237 ) } } //
:aGradOverUnSel := :aGradOver
//
:DisableTab( 3 )
END
ACTIVATE DIALOG oDlg CENTERED
return nil
Return to FiveWin for Harbour/xHarbour
Users browsing this forum: Google [Bot] and 59 guests