[glade--]C++/glame-- basics..



sorry for the repost, now I'm subscribed...
Here comes the question:

>
> Hi there.
> (oh, please cc. to me, I not subscr.)
>
> I got over the first steps to run my own small program.
> So far so good, here comes a basic question:
>
> glame-- creates, say, one button and one label.
> I'd like to change the label-text when the but is pressed...
> so this is the code for the window-class
>
> class mwindow : public mwindow_glade
> {
>         friend class mwindow_glade;
>         void on_but_NewEvent_clicked();
> };
>
> and here for the mwindow_glade class:
> (snipped)
>
> mwindow_glade::mwindow_glade(
> ) : Gtk::Window(GTK_WINDOW_TOPLEVEL)
> {
>
>    Gtk::Window *mwindow = this;
>    Gtk::Button *but_NewEvent =
> Gtk::wrap((GtkButton*)gtk_toolbar_append_element(GTK_TOOLBAR(toolbar1->gtkobj()),
> GTK_TOOLBAR_CHILD_BUTTON, 0, "New Event", 0, 0, 0, 0, 0));
>
>    Gtk::Label *label_rfreq = manage(new class Gtk::Label("Radio
> Frequency:"));
> }
>
>
> how do I access the label_rfreq from the
> mwindow class in mwindow.cc ?
> I know this is basics, but I'm sure you can help me here.
> void mwindow::on_but_NewEvent_clicked()
> {
> ???????
> }
>
> thanks a million.
> Tobias.
>
>




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]