- Code: Select all Expand view
#include "Fivewin.ch"
FUNCTION MAIN()
LOCAL oWnd, oBar
DEFINE WINDOW oWnd
DEFINE BUTTONBAR oBar OF oWnd //2007
DEFINE BUTTON OF oBar;
FILE "C:\FWH\BITMAPS\CLIENT.BMP"
ACTIVATE WINDOW oWnd
RETURN NIL
EMG
#include "Fivewin.ch"
FUNCTION MAIN()
LOCAL oWnd, oBar
DEFINE WINDOW oWnd
DEFINE BUTTONBAR oBar OF oWnd //2007
DEFINE BUTTON OF oBar;
FILE "C:\FWH\BITMAPS\CLIENT.BMP"
ACTIVATE WINDOW oWnd
RETURN NIL
TransBmp( ::hBitmap1, nBmpWidth( ::hBitmap1 ), nBmpHeight( ::hBitmap1 ), nZeroZeroClr, ::hDC,;
( ::nWidth / 2 ) - ( nBmpWidth( ::hBitmap1 ) / 2 ) + If( ::lPressed, 2, 1 ),;
Max( 0, ( ::nHeight / 3 ) - ( nBmpHeight( ::hBitmap1 ) / 2 ) ) + If( ::lPressed, 2, 1 ),;
nBmpWidth( ::hBitmap1 ), nBmpHeight( ::hBitmap1 ) )
#include "Fivewin.ch"
FUNCTION MAIN()
LOCAL oWnd, oBar
DEFINE WINDOW oWnd
DEFINE BUTTONBAR oBar OF oWnd
DEFINE BUTTON OF oBar;
TOOLTIP "Test"
SET MESSAGE OF oWnd TO "This is a test" 2007
ACTIVATE WINDOW oWnd
RETURN NIL
::Say( ::nHeight / 4,;
If( ::lCentered, ( ::nWidth / 2 ) - ( GetTextWidth( ::hDC,;
If( Empty( ::cMsg ), ::cMsgDef, ::cMsg ),;
::oWnd:oFont:hFont ) / 2 ), 10 ), If( Empty( ::cMsg ), ::cMsgDef, ::cMsg ),;
::nClrText,,, .T., .T. )
EnricoMaria wrote:Another problem: it seems that the height of the buttons is shorter with 2007 clause.
#include "Fivewin.ch"
FUNCTION MAIN()
LOCAL oWnd, oBar
DEFINE WINDOW oWnd
DEFINE BUTTONBAR oBar OF oWnd SIZE 40, 40 // 2007
DEFINE BUTTON OF oBar ;
TOOLTIP "Test" ACTION MsgInfo( oBar:aControls[ 1 ]:nHeight )
SET MESSAGE OF oWnd TO "This is a test" 2007
ACTIVATE WINDOW oWnd
RETURN NIL
DEFINE BUTTONBAR oBar OF oWnd SIZE 40, 40 2007 3D
::Say( ::nHeight / 4 - 2,;
If( ::lCentered, ( ::nWidth / 2 ) - ( GetTextWidth( ::hDC,;
If( Empty( ::cMsg ), ::cMsgDef, ::cMsg ),;
::oWnd:oFont:hFont ) / 2 ), 4 ), If( Empty( ::cMsg ), ::cMsgDef, ::cMsg ),;
::nClrText,,, .T., .T. )
#include "Fivewin.ch"
FUNCTION MAIN()
LOCAL oWnd, oBar
DEFINE WINDOW oWnd
DEFINE BUTTONBAR oBar OF oWnd SIZE 40, 40 2007
DEFINE BUTTON OF oBar;
FILE "C:\FWH\BITMAPS\CLIENT.BMP"
ACTIVATE WINDOW oWnd
RETURN NIL
Antonio Linares wrote:Enrico,
> Ok, but try with 3D clause:
Yes, you are right, 3D clause should not be used with 2007 clause together, or buttons will not cover all the bar height
Return to FiveWin for Harbour/xHarbour
Users browsing this forum: No registered users and 84 guests