RE: [gtkmm] Static lable in Static method ?
- From: Murray Cumming Comneon com
- To: sms 4-sms com, gtkmm-list gnome org
- Subject: RE: [gtkmm] Static lable in Static method ?
- Date: Tue, 9 Dec 2003 08:26:22 +0100
You need to initialize the static member, in your .cc file. Consult a good
C++ book:
http://www.gtkmm.org/books.shtml
Murray Cumming
www.murrayc.com
murrayc usa net
> -----Original Message-----
> From: gtkmm-list-admin gnome org
> [mailto:gtkmm-list-admin gnome org] On Behalf Of SMS WebMaster
> Sent: Dienstag, 9. Dezember 2003 03:58
> To: gtkmm list
> Subject: [gtkmm] Static lable in Static method ?
>
>
> Hi
>
> I have a static method and I want to change a text of a lable in it ,
> how can I do that ?
>
> [code]
>
> class MainWindow : public Gtk::Window
> {
> public:
> MainWindow();
> virtual ~MainWindow();
>
> protected:
> static void MainWindow::Set_Time_Mod(void);
> static Gtk::Label labTimes;
>
> }
>
> void MainWindow::Set_Time_Mod(void)
> {
> MainWindow::labTimes.set_text(_("Hello"));
> }
>
> [/code]
>
> When I compile this code I got this error :
>
> /mainwindow.h:206: undefined reference to `MainWindow::labTimes'
>
>
> --
> http://www.4-SMS.Com
> http://eShop.4-SMS.Com
> http://Mozilla.4-SMS.Com
> -*- If Linux doesn't have the solution, you have the wrong problem -*-
>
> _______________________________________________
> gtkmm-list mailing list
> gtkmm-list gnome org http://mail.gnome.org/mailman/listinfo/gtkmm-list
>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]