[wx-dev] Question regarding how to create an apply
buttonusingwxWiggets
Cai, Xin
Xin.Cai at viasat.com
Tue Jun 3 17:58:45 PDT 2008
Hi
I am completely new to wxWiggets, I just started looking at it today and
I thought of that too but I couldn't figure out how to properly put the
button in the dialog. But I'll look into it some more. Thanks
Xin Cai
________________________________
From: wx-dev-bounces at lists.wxwidgets.org
[mailto:wx-dev-bounces at lists.wxwidgets.org] On Behalf Of Edgar Omar
Sent: Tuesday, June 03, 2008 5:26 PM
To: wx-dev at lists.wxwidgets.org
Subject: Re: [wx-dev] Question regarding how to create an apply
buttonusingwxWiggets
I havent used recently the wxPropertySheetDialog, but it actually
extends wxDialog, so I assume you can create your own button and append
it, not sure if you have tried that.
it would be something like
wxButton *button1;
button1 = new wxButton(this, ID_WXBUTTON1, wxT("Apply"), wxPoint(0 ,
120), wxDefaultSize, 0, wxDefaultValidator, "name");
just try to place it near the bottom and see if it works, if not I would
have to check some old code to see how I solved some issues.
On Tue, Jun 3, 2008 at 7:15 PM, Cai, Xin <Xin.Cai at viasat.com> wrote:
Basically I created my own class derived from wxPropertySheetDialog
class. And right now here is my constructor for my own class
MY_GUI::MY_GUI( const wxString & title )
: wxPropertySheetDialog(NULL, wxID_ANY, title, wxDefaultPosition,
wxSize(250,150))
{
CreateButtons(wxYES_NO);
// Add page
wxPanel* panel = new wxPanel(GetBookCtrl());
GetBookCtrl()->AddPage(panel, wxT("General"));
GetBookCtrl()->AddPage(panel, wxT("TEST"));
LayoutDialog();
}
Inside my OnInit function in main.c I simply create an instance of
MY_GUI class and call the show function. The ultimate goal is to be able
to
display a dialog similar to the "Display properties" dialog in windows.
Thanks
Xin Cai
________________________________
From: wx-dev-bounces at lists.wxwidgets.org
[mailto:wx-dev-bounces at lists.wxwidgets.org] On Behalf Of Edgar Omar
Sent: Tuesday, June 03, 2008 5:06 PM
To: wx-dev at lists.wxwidgets.org
Subject: Re: [wx-dev] Question regarding how to create an apply button
usingwxWiggets
I need more info than that, like are you in a wxDialog?, if so, you can
add your own buttons like in a normal wxFrame, with wxButton and a
connect event, the trick would be to make them look cool in a wxDialog,
I have some issues trying to fit a wxtextctrl and a label on it
On Tue, Jun 3, 2008 at 7:03 PM, Cai, Xin <Xin.Cai at viasat.com> wrote:
Hi guys
I am trying to create a program that shows a propertysheet and I need to
add an Apply button in addition to OK and cancel, and then I notice that
wxApply is no longer supported. In that case I would like to know how
can I add an apply button manually to my program? Thank you very much
Sincerely
Xin Cai
_______________________________________________
wx-dev mailing list
wx-dev at lists.wxwidgets.org
http://lists.wxwidgets.org/mailman/listinfo/wx-dev
_______________________________________________
wx-dev mailing list
wx-dev at lists.wxwidgets.org
http://lists.wxwidgets.org/mailman/listinfo/wx-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.wxwidgets.org/pipermail/wx-dev/attachments/20080603/f061930b/attachment-0001.htm
More information about the wx-dev
mailing list