oBtn:lCancel := .T.
horacio wrote:Estuve mirando la clase btnbmp y lCancel no existe como data
// C:\FWH..\SAMPLES\HORACIO.PRG
#Include "FiveWin.ch"
FUNCTION Main()
LOCAL oDlg , oMenuPop, oBtn1, oBtn2, MENU, oFont, aGrad, cTitle
LOCAL nColor1 := CLR_BLACK
LOCAL nColor2 := CLR_WHITE
SET _3DLOOK ON
SetBalloon( .T. )
SkinButtons()
MENU oMenuPop POPUP 2007
MENUITEM "First " ACTION MsgInfo( "first" )
SEPARATOR
MENUITEM "Second " ACTION MsgInfo( "second" )
SEPARATOR
MENUITEM "Colores" ACTION( PicKColors( oBtn1, oDlg,, "gray" ) )
ENDMENU
aGrad := { { 0.30, CLR_WHITE, CLR_HCYAN },{ 0.50, CLR_WHITE, CLR_HCYAN } }
cTiTle := "Números de la paleta de colores: Horacio."
DEFINE FONT oFont NAME "Ms Sans Serif" SIZE 00, -16 BOLD
DEFINE DIALOG oDlg SIZE 500, 400 PIXEL TRUEPIXEL RESIZABLE ;
TITLE cTitle GRADIENT aGrad FONT oFont
oDlg:lhelpIcon := .F.
@ 50, 50 BTNBMP oBtn1 SIZE 60, 60 PIXEL OF oDlg FLAT NOBORDER ;
PROMPT "Color" FILENAME "..\bitmaps\16x16\floppy.bmp" BOTTOM ;
COLOR CLR_HBLUE, CLR_BLACK UPDATE ;
ACTION( PicKColors( oBtn1, oDlg,, "gray" ) ) ;
TOOLTIP { "Números de la paleta de colores", ;
"Números de la paleta de colores", 1, CLR_WHITE, CLR_GREEN }
oDlg:aControls[ 1 ]:oPopup := oMenuPop
oBtn1:bClrGrad = {| lInvert | If( ! lInvert, ;
{ { 0.25, RGB( 238, 236, 219 ), RGB( 238, 236, 219 ) }, ;
{ 0.75, RGB( 238, 236, 219 ), RGB( 238, 236, 219 ) } }, ;
{ { 0.25, RGB( 238, 236, 219 ), RGB( 238, 236, 219 ) }, ;
{ 0.75, RGB( 238, 236, 219 ), RGB( 238, 236, 219 ) } } ) }
WITH OBJECT oBtn1
:nClrBorder := CLR_HRED // border color
:bColorMap := { || { { CLR_YELLOW, CLR_HRED } } } // image color
END
@ 50, 120 BTNBMP oBtn2 SIZE 60, 60 PIXEL OF oDlg FLAT NOBORDER ;
PROMPT "Exit" FILENAME "..\bitmaps\16x16\Exit.bmp" BOTTOM ;
COLOR CLR_BLACK, CLR_HBLUE UPDATE ;
ACTION( oDlg:End() ) ;
TOOLTIP { "Salida-Exit-Cancelar", ;
"Salida-Exit-Cancelar", 1, CLR_WHITE, CLR_GREEN }
oBtn2:lCancel := .T.
ACTIVATE DIALOG oDlg CENTERED
oFont:End()
RETURN NIL
FUNCTION PicKColors( ocontrol, oParent, lHex, cColore )
LOCAL oDlgSel
DEFINE DIALOG oDlgSel SIZE 400, 200 PIXEL
oDlgSel:nStyle = nOR( WS_CHILD, WS_BORDER, WS_VISIBLE, WS_POPUP )
ACTIVATE DIALOG oDlgSel CENTERED
RETURN NIL
// FIN / END - kapiabafwh@gmail.com
Return to FiveWin para Harbour/xHarbour
Users browsing this forum: Google [Bot] and 30 guests