[pygtk] Debugging Applets and bonobo-activation
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Is there any way to trace or see what is happening with bonobo-activation? I have this Applet that ~ behave strangly when selecting Properties..., and I would like to see what is happening from the caller. I assume that the caller is bonobo-activation. Also, I could RTFC. Which piece of code actually calls the callback registered with setup_menu()? I use 2.0.0. Thanks! - -- == Martin Gadbois S/W Developper Colubris Networks Inc. -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.3 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQE/esJ+9Y3/iTTCEDkRAq5OAJ9xNxWGJM3zW8vl2gsXBIwX3FvHEQCfTtsy Epgtplram76a/M6y7xAAogc= =NWow -END PGP SIGNATURE- ___ pygtk mailing list [EMAIL PROTECTED] http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/
[Fwd: Re: [pygtk] Debugging Applets and bonobo-activation]
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Gustavo answered... :-) - Original Message Subject: Re: [pygtk] Debugging Applets and bonobo-activation Date: Wed, 01 Oct 2003 13:53:29 +0100 From: Gustavo J. A. M. Carneiro [EMAIL PROTECTED] Organization: INESC Porto To: Martin Gadbois [EMAIL PROTECTED] References: [EMAIL PROTECTED][EMAIL PROTECTED] [EMAIL PROTECTED] A Qua, 2003-10-01 às 13:42, Martin Gadbois escreveu: | Gustavo J. A. M. Carneiro wrote: | | A Qua, 2003-10-01 às 13:03, Martin Gadbois escreveu: | | | |-BEGIN PGP SIGNED MESSAGE- | |Hash: SHA1 | | | |Is there any way to trace or see what is happening with bonobo-activation? I have this Applet that | | | | | | You could try recompiling ORBit2 and libbonobo with --enable-debug, | | then set ORBIT2_DEBUG=all and BONOBO_DEBUG=all before running your | | program. You should then obtain a *lot* of debugging messages. :) | | | | | | Thanks!! Where is the output? in the syslog? | | stdout/stderr :) | You better redirect that to a log file. You can launch the server | from the command line, and bonobo-activation will wake it up when the | activation request (from the gnome panel) arrives. | | | Can I put your reply on the mailing list for everyone else to see? | | Sure. I did Reply instead of Reply to All only by accident :/ | But this is really nothing all that new, I think :) | | | -- | == | Martin Gadbois | S/W Developper | Colubris Networks Inc. | - -- Gustavo João Alves Marques Carneiro [EMAIL PROTECTED] [EMAIL PROTECTED] - -- == Martin Gadbois S/W Developper Colubris Networks Inc. -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.3 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQE/etC19Y3/iTTCEDkRAq9sAKCmrHveLKhjH63rtVbadWt6Qzq2jwCZAQ3n ZcMvr4TUrukNcC4Tg1D1QN4= =bG0t -END PGP SIGNATURE- ___ 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] delete selection
I've figured out how to delete multiple selections. If anyone runs into the same problem, here's what I have learned: pygtk does not allow treemodel.remove(iter) in the selected_foreach(...) function, so I had to store all the iterators for the selected rows and then go back to delete them. The iterator parameter of the function called by selected_foreach is not the actual treestore row iterator, so I had to get it by using treemodel.get_iter(path). Only then was I abe to use treemodel.remove(iter) to remove the row. Here's my code: # list that stores all the iterators of the selected rows selectList = [] # function to get iterator of selected row def GetSelectedIter(model,path,iter,rowList): selectIter = model.get_iter(path) rowList.append(selectIter) # get reference to each row selection = watchvar_treeview.get_selection() selection.selected_foreach(GetSelectedIter,selectList) # actual removal of rows for iter in selectList: watchvar_treestore.remove(iter) ~ Yang On Fri, 2003-09-26 at 15:35, Yang Zheng wrote: Sorry for such a late response, but I just had a chance to come back to the pygtk stuff. Thank you for your help. I tried using the following code and it worked. However, it is meant only delete one row at a time right? (since get_slected() does not work in SELECTION_MULTIPLE mode) If I would like to delete multiple rows that are selected, do you have any suggestions? Again, using selection.selected_foreach produced errors. #Here is the function attached to the delete button: def RemoveWatchVariables(button): # delete each variable def DeleteVar(model,path,iter,data=None): model.remove(iter) # get selection and iterate through selection = watchvars_view.get_selection() selection.selected_foreach(DeleteVar) On Tue, 2003-08-05 at 12:42, Grzegorz Adam Hankiewicz wrote: On 2003-08-05, Yang Zheng [EMAIL PROTECTED] wrote: Can I not delete iterator like this? Hmmm... can't say what you do wrong, but here's my deletion code, maybe it helps you: selection = self.list_view.get_selection() model, iter, = selection.get_selected() if iter: path = model.get_path(iter) model.remove(iter) selection.select_path(path) if not selection.path_is_selected(path): row = path[0]-1 if row = 0: selection.select_path((row,)) ___ 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 mailing list [EMAIL PROTECTED] http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/