Usando BITMAP no TAB
Enviado: 28 Nov 2020 22:19
Simoes teria como você postar a CLASS New( ) da HTAB, pois acho que a minha está diferente da sua estou meio perdido
Código: Selecionar todos
METHOD New( oWndParent, nId, nStyle, nLeft, nTop, nWidth, nHeight, ;
oFont, bInit, bSize, bPaint, aTabs, bChange, aImages, lResour, nBC, bClick, bGetFocus, bLostFocus ) CLASS HTab
LOCAL i, aBmpSize
nStyle := Hwg_BitOr( iif( nStyle == Nil,0,nStyle ), WS_CHILD + WS_VISIBLE + WS_TABSTOP )
::Super:New( oWndParent, nId, nStyle, nLeft, nTop, nWidth, nHeight, oFont, bInit, ;
bSize, bPaint )
::title := ""
::oFont := iif( oFont == Nil, ::oParent:oFont, oFont )
::aTabs := iif( aTabs == Nil, {}, aTabs )
::bChange := bChange
::bChange2 := bChange
::bGetFocus := iif( bGetFocus == Nil, Nil, bGetFocus )
::bLostFocus := iif( bLostFocus == Nil, Nil, bLostFocus )
::bAction := iif( bClick == Nil, Nil, bClick )
IF aImages != Nil
::aImages := {}
FOR i := 1 TO Len( aImages )
AAdd( ::aImages, Upper( aImages[i] ) )
aImages[i] := iif( lResour, hwg_Loadbitmap( aImages[i] ), hwg_Openbitmap( aImages[i] ) )
NEXT
aBmpSize := hwg_Getbitmapsize( aImages[1] )
::himl := hwg_Createimagelist( aImages, aBmpSize[1], aBmpSize[2], 12, nBC )
::Image1 := 0
IF Len( aImages ) > 1
::Image2 := 1
ENDIF
ENDIF
::Activate()
RETURN Self