Re: bells and whistle in Gtkmm
- From: Chris Vine <chris cvine freeserve co uk>
- To: Jamiil <jalqadir gmail com>
- Cc: gtkmm-list gnome org
- Subject: Re: bells and whistle in Gtkmm
- Date: Sun, 7 Dec 2008 14:21:23 +0000
On Sun, 07 Dec 2008 07:19:01 -0500
Jamiil <jalqadir gmail com> wrote:
>
> Thanks Mohamed for the help!
> I read the documentation and it is exactly what I am looking for and
> more. However, the compiler complains saying that Display() is
> protected and in Gdk::Display::Display *is a 'protected' method (?)
> What can I do to fix this problem?
>
> Thanks
> -------
> #include <gdkmm/display.h>
> class SomeClass{
> ...
> public:
> ...Gdk::Display display;
> void someMethod();
> };
> ---------\
> void SomeClass::someMethod(){
> display.beep();
> }
You should get the default display with Gdk::Display::get_default(),
which is a static funcion.
Alternatively you can just call gdk_beep(), defined in gdk/gdk.h. It is
a wrapper for gdk_display_beep(gdk_display_get_default()), or it's
gdkmm equivalent Gdk::Display::get_default()->beep().
Chris
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]