Re: [PHP-GTK] How to grab focus to the first entry field into a notebook page

[email protected] (kksou) Mon, 8 Sep 2008 19:23:35 -0700 (PDT)
Newsgroups php.gtk.general
Message-ID <[email protected]>

AngeloP wrote:
> 
> I have a 
>     GtkNotebook with 3 pages 
>         into every page there is a Gtkalignment
>                into Gtkalignment there is GtkEntry or an Object that
> contains GtkEntry
> 
> I would know how to grab_focus on the first GtkEntry of one page when the
> page becomes
> current page
> 

Hi,

- Store the pointer to the GtkEntry associated with each of the page in an
array.

- When the user clicks a new tab, just use $entry[$tab]->grab_focus()

Here's a complete sample code:

http://www.kksou.com/php-gtk2/articles/grab-focus-on-GtkEntry-in-a-GtkNotebook-page---Part-1---highlight-all-text-on-focus.php

Regards.
/kksou


-- 
View this message in context: http://www.nabble.com/How-to-grab-focus-to-the-first-entry-field-into-a-notebook-page-tp19361211p19384848.html
Sent from the Php - GTK - General mailing list archive at Nabble.com.