Re: New signal for GtkNoteBook
| From: | Steph | Date: | Sat, 22 Mar 2003 11:34:41 +0000 |
| Subject: | Re: New signal for GtkNoteBook | ||
| References: | 1 2 3 4 5 | Groups: | php.gtk.general |
| Request: | Send a blank email to php-gtk-general+get-3144@lists.php.net to get a copy of this message | ||
and now I've finally got around to looking at GTK source too, there's no
such beast as 'select_page' in the GTK 1.3 source I have here either. I
don't actually know what you mean by 'GTK+ 1.3 documentation', I've only
come across the stable 1.2 docs (based on 1.2.10) and the GTK2 docs
(current). The first mention I find of a 'select_page' signal is in GTK
2.0.6, which isn't to say that it didn't ever get created before that,
just that it isn't in the 1.3 source Frank uses to build GTK for the
Windows binary.
In answer to your question, Ivan, Andrei's currently working on the ZE2
port of the existing GTK version. We're a way off a GTK+ upgrade just
yet, basically because both PHP and GTK are going through/have gone
through major changes recently and both need to work together.
----- Original Message -----
From: "Steph" <sfox@php.net>
To: "Ivan Rodriguez" <epplestun@alaplaya.com>; "James Cameron"
<quozl@us.netrek.org>
Cc: <php-gtk-general@lists.php.net>
Sent: Saturday, March 22, 2003 11:06 AM
Subject: Re: [PHP-GTK] New signal for GtkNoteBook
> 1.3 is the win32-only branch of GTK+ prior to GTK2. When you talk
about
> 1.2, which version of 1.2 are you talking about pliz?
>
> ----- Original Message -----
> From: "Ivan Rodriguez" <epplestun@alaplaya.com>
> To: "James Cameron" <quozl@us.netrek.org>
> Cc: <php-gtk-general@lists.php.net>
> Sent: Saturday, March 22, 2003 11:11 AM
> Subject: Re: [PHP-GTK] New signal for GtkNoteBook
>
>
> Thx James, i will like to add gtk2 to php, one cquestion, is some
> rpoject to port php-gtk to php-gtk2?¿ to apply new widget of gtk2 ....
> ?¿?
>
> regards
>
> El sáb, 22-03-2003 a las 05:42, James Cameron escribió:
> > Epplestun wrote:
> > > HI, the php-gtk version don?t have select-page signal for
> gtknotebook,
> > > why?? we can apply it.
> >
> > Good question. I confirm your diagnosis. select-page is a signal
> > documented in 1.3 of GTK+. Yet it is not recognised by PHP-GTK
> > built against 1.2 of GTK+.
> >
> > I took the test/gtk.php script, and added a signal:
> >
> > $sample_notebook->connect('select-page', 'page_select');
> >
> > ... the result was ...
> >
> > Gtk-WARNING **: gtk_signal_connect_full(): could not find signal
> > "select-page" in the `GtkNotebook' class ancestry
> >
> > I also tried select_page. The patch for my change to reproduce this
> is
> > attached.
> >
> > I agree that GTK+ has the signal documented, in 1.3.
> >
> > I've checked through the source of PHP-GTK and cannot find this
signal
> > or the switch_page signal mentioned. I presume signal names are
> defined
> > in GTK+ alone, and not in PHP-GTK.
> >
> > So I checked the GTK+ source. In file gtknotebook.c of version 1.2
of
> > GTK+ at around line 272, the switch_page signal is defined, but none
> > of the other signals.
> >
> > I presume therefore that it is a signal added in GTK+ 1.3, and that
> you
> > will need to use that version to get the signal.
> >
> > Perhaps you should downgrade your GTK+ documentation to 1.2? ;-)
> >
> > Steph wrote:
> > > signals are inherited directly from GTK+...
> >
> > Yep, so since it isn't there, it isn't here.
> >
> > --
> > James Cameron mailto:quozl@us.netrek.org
> http://quozl.netrek.org/
> > ----
> >
>
> > *** gtk.php Fri Dec 6 22:36:12 2002
> > --- gtk-notebook.php Sat Mar 22 14:03:19 2003
> > ***************
> > *** 2320,2325 ****
> > --- 2320,2330 ----
> > $book_closed_mask = null;
> > $sample_notebook = null;
> >
> > + function page_select($notebook, $page, $page_num)
> > + {
> > + echo "page_select $notebook $page $page_num\n";
> > + }
> > +
> > function page_switch($notebook, $page, $page_num)
> > {
> > global $book_open, $book_open_mask,
> > ***************
> > *** 2496,2501 ****
> > --- 2501,2507 ----
> > $sample_notebook = new GtkNotebook;
> > $sample_notebook->show();
> > $sample_notebook->connect('switch_page', 'page_switch');
> > + $sample_notebook->connect('select-page', 'page_select');
> > $sample_notebook->set_tab_pos(GTK_POS_TOP);
> > $box1->pack_start($sample_notebook, true, true, 0);
> > $sample_notebook->set_border_width(10);
> >
> > ----
> >
>
> > --
> > PHP-GTK General Mailing List (http://gtk.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
>
>
>
> --
> PHP-GTK General Mailing List (http://gtk.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
>
>
> --
> PHP-GTK General Mailing List (http://gtk.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>