Re: wxEuphoria wxBitmapButton Question
- Posted by Mannequin <mannslists at invigorated.org> Jul 25, 2005
- 523 views
Matt Lewis wrote: > > Mannequin wrote: > > > > Hi all! > > > > I'm new to Euphoria, but working to plunge right in! > > > > I have a question about wxBitmapButtons in wxEuphoria. Could anyone post a > > simple working > > example of a wxBitmapButton for me? I'm cannot get it to work, so I'm > > thinking I might > > have the wrong idea about it. > > Here's a really simple example: > }}} <eucode> > -- Created using wxIDE > include wxEuphoria.e > include wxButton.e > include wxGraphics.e > > global constant > bitmap = create( wxBitmap, {BM_FROM_FILE, "tiles.bmp", wxBITMAP_TYPE_BMP}), > new_wxFrame_3 = create( wxFrame, {0, -1, "new_wxFrame_3" }), > new_wxPanel_1 = create( wxPanel, {new_wxFrame_3, -1, 0, 0, 299, 199 }), > new_wxBitmapButton_1 = create( wxBitmapButton, {new_wxPanel_1, -1, bitmap, 39, > 34, 197, 79 }) > > wxMain( new_wxFrame_3 ) > <font color="#330033"></eucode> {{{ </font> > > Matt Lewis > That works great. Thanks! I don't know what I had different, though. I erased what I did in frustration last night. After going through both the wxEuphoria reference manual and the wxWidgets reference manual, I was at the end of my rope. :) One other question, if I wanted to change the bitmap of the button 'on the fly', so to speak, how would I go about doing that? (Again, some very simple code might do me some good.) Thanks again! -Mannequin.