Re: [pygtk] gtk+vtk again
John, why don't you post this project somewhere on the Web, or see if James isn't interested in integrating your code? I can't put it inside the FAQ, and it's a shame to only have a pointer to it in a mailist list archive. Take care, -- Christian Reis | http://async.com.br/~kiko/ | [+55 16] 261 2331 ___ pygtk mailing list [EMAIL PROTECTED] http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/
Re: [pygtk] Unsetting the cursor in a gtk.TreeView
A Sex, 2003-09-19 às 16:26, Gary Herron escreveu: > I sent this question to the list just as I was becoming a member of > the list, so perhaps I missed an answer, or perhaps there really were > no responses. In either case I'd like to politely plead again for > some help in this matter. I'm not sure, but maybe you can try this: treeview.get_selection.unselect_all() > > Thanks, > Gary Herron > > On Tuesday 16 September 2003 02:23 pm, Gary Herron wrote: > > On a gtk.TreeView, I can highlight a line with a call to > > > > set_cursor(path, ...) > > > > but I can't find a way to turn the highlight off. I don't see > > > > unset_cursor() > > > > and I've tried every form of null path I can thing of > > > > set_cursor(None, ...) > > set_cursor(0, ...) > > set_cursor((0,), ...) > > set_cursor('', ...) > > set_cursor((), ...) > > > > all with no joy. > > > > > > ___ > pygtk mailing list [EMAIL PROTECTED] > http://www.daa.com.au/mailman/listinfo/pygtk > Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/ -- Gustavo João Alves Marques Carneiro <[EMAIL PROTECTED]> <[EMAIL PROTECTED]> ___ pygtk mailing list [EMAIL PROTECTED] http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/
Re: [pygtk] Unsetting the cursor in a gtk.TreeView
I sent this question to the list just as I was becoming a member of the list, so perhaps I missed an answer, or perhaps there really were no responses. In either case I'd like to politely plead again for some help in this matter. Thanks, Gary Herron On Tuesday 16 September 2003 02:23 pm, Gary Herron wrote: > On a gtk.TreeView, I can highlight a line with a call to > > set_cursor(path, ...) > > but I can't find a way to turn the highlight off. I don't see > > unset_cursor() > > and I've tried every form of null path I can thing of > > set_cursor(None, ...) > set_cursor(0, ...) > set_cursor((0,), ...) > set_cursor('', ...) > set_cursor((), ...) > > all with no joy. ___ pygtk mailing list [EMAIL PROTECTED] http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/
Re: [pygtk] gtk.Window.get_position()
On Fri, Sep 19, 2003 at 05:13:47PM +0200, [EMAIL PROTECTED] wrote: > Hi James and Christian, > > >The position of the window is relative to the parent window. If you > >want the position relative to the root window, you can use the > >get_root_origin() method. > > >James. > > > I'm a bit confused: get_root_origin() reqires a gdk.Window but I've a > gtk.Window, so how can I obtain the gdk.Window from a gtk.Window? That's a FAQ! Take care, -- Christian Reis | http://async.com.br/~kiko/ | [+55 16] 261 2331 ___ pygtk mailing list [EMAIL PROTECTED] http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/
Re:[pygtk] gtk.Window.get_position()
Hi James and Christian, >The position of the window is relative to the parent window. If you >want the position relative to the root window, you can use the >get_root_origin() method. >James. I'm a bit confused: get_root_origin() reqires a gdk.Window but I've a gtk.Window, so how can I obtain the gdk.Window from a gtk.Window? Christian thanks for your suggestion but I don't have a button to use :-( Thank you! Best regards! Pier Carteri - This mail sent through IMP: http://horde.org/imp/ ___ pygtk mailing list [EMAIL PROTECTED] http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/
Re: [pygtk] gtk.Window.get_position()
On 19/09/03 16:37, [EMAIL PROTECTED] wrote: Hi to all, I've a Window with a TextView, and I want to display another window (a popup winow) near the cursor position of the TextView. So I've calculate the cursor position with the buffer_to_window_coords() method and then I try to use the method get_position() of the Window to obtain the window position on the screen. The problem is that get_position() alwais return (0,0) to me, why? The following piece of code is what I'm using buffer=self.text_view.get_buffer() iter=buffer.get_iter_at_mark(buffer.get_insert()) rectangle=self.text_view.get_iter_location(iter) absX, absY=self.text_view.buffer_to_window_coords(gtk.TEXT_WINDOW_TEXT, rectangle.x ,rectangle.y) print absX, absY self.window.show_all() winX, winY=self.popup.get_position() print winX, winY and it prints 43 32 #of course theese values can be different 0 0 Any ideas or suggestions? The position of the window is relative to the parent window. If you want the position relative to the root window, you can use the get_root_origin() method. James. -- Email: [EMAIL PROTECTED] WWW: http://www.daa.com.au/~james/ ___ pygtk mailing list [EMAIL PROTECTED] http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/
Re: [pygtk] gtk.Window.get_position()
On Fri, Sep 19, 2003 at 10:37:05AM +0200, [EMAIL PROTECTED] wrote: > I've a Window with a TextView, and I want to display another window (a popup > winow) near the cursor position of the TextView. So I've calculate the cursor > position with the buffer_to_window_coords() method and then I try to use the > method get_position() of the Window to obtain the window position on > the screen. Just as a sanity check, is there a reason why you can't use button_press_event and then the event.x and event.y coordinates the GdkEvent object provides? (Hmm, maybe you're not expecting a button click?) Take care, -- Christian Reis | http://async.com.br/~kiko/ | [+55 16] 261 2331 ___ pygtk mailing list [EMAIL PROTECTED] http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/
[pygtk] gtk.Window.get_position()
Hi to all, I've a Window with a TextView, and I want to display another window (a popup winow) near the cursor position of the TextView. So I've calculate the cursor position with the buffer_to_window_coords() method and then I try to use the method get_position() of the Window to obtain the window position on the screen. The problem is that get_position() alwais return (0,0) to me, why? The following piece of code is what I'm using buffer=self.text_view.get_buffer() iter=buffer.get_iter_at_mark(buffer.get_insert()) rectangle=self.text_view.get_iter_location(iter) absX, absY=self.text_view.buffer_to_window_coords(gtk.TEXT_WINDOW_TEXT, rectangle.x ,rectangle.y) print absX, absY self.window.show_all() winX, winY=self.popup.get_position() print winX, winY and it prints 43 32 #of course theese values can be different 0 0 Any ideas or suggestions? Thank you! Best regards Pier Carteri - This mail sent through IMP: http://horde.org/imp/ ___ pygtk mailing list [EMAIL PROTECTED] http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/