From: Benny M. <ben...@gm...> - 2012-12-03 14:42:56
|
Probably you need to prepend gramps. also everywhere in the rst. So, instead of the gui module, the gramps.gui module. After all, only gramps will be a module, while gui is a submodule of gramps. This is a something we did not understand yet fully when originally wrting the rst Benny 2012/12/3 jerome <rom...@ya...> > Benny, > > > You could change the code to > from gramps.gui ... > > Oh, yes ! > > Note, it was never planned to do this change on SVN ! > It was only for tracking this down on my local configuration. ;) > > Currently, my problem is not on code itself, but rather on API generation > which is looking at SVN/docs/coregui/gui.rst file. > > ########################## > The :mod:`gui` Module > ########################## > > .. automodule:: gui > > ***************************** > Gramps > ***************************** > .. automodule:: gui.grampsgui > .. autoclass:: Gramps > :members: > :undoc-members: > :show-inheritance: > > ***************************** > About Dialog > ***************************** > .. automodule:: gui.aboutdialog > .. autoclass:: AuthorParser > :members: > :undoc-members: > :show-inheritance: > .. autoclass:: GrampsAboutDialog > :members: > :undoc-members: > :show-inheritance: > > etc... > > I suppose something need to be fixed on gui.rst file, but I do not know > what is wrong! > > If I do changes (local patch for API generation), there is no more > warnings and errors related to gui section (API), else I get RuntimeError > for ValidatedComboEntry, then some others RuntimeError for next called > widgets (not all!). > > I just commented widgets as comming on tests while there was no more > errors. > > I suppose I know where is the source of my problems, but I do not know how > to fix gui.rst or if need to modify import into gramps on > widgets.__init__.py. > > gramps.gui.widgets.shortlistcomboentry > gramps.gui.widgets.springseparator > gramps.gui.widgets.statusbar > gramps.gui.widgets.styledtextbuffer > gramps.gui.widgets.styledtexteditor > gramps.gui.widgets.toolcomboentry > gramps.gui.widgets.undoableentry > gramps.gui.widgets.undoablestyledbuffer > gramps.gui.widgets.validatedcomboentry > gramps.gui.widgets.validatedmaskedentry > gramps.gui.widgets.valueaction > gramps.gui.widgets.valuetoolitem > > > Otherwise, it is true that validatedcomboentry 'coloring' feature is > broken on trunk, but it is something else, maybe related to my Gtk theme. > > Thanks! > Jérôme > > > --- En date de : Lun 3.12.12, Benny Malengier <ben...@gm...> > a écrit : > > De: Benny Malengier <ben...@gm...> > Objet: Re: [Gramps-devel] Python and .devhelp documentations > À: "jerome" <rom...@ya...> > Cc: "Doug Blank" <dou...@gm...>, "Gramps Development List" < > gra...@li...> > Date: Lundi 3 décembre 2012, 14h48 > > Importing from gui is wrong, so don't apply that. > You could change the code to > from gramps.gui .... > and that would be fine, but better is to find why the error is not visible > on doing absolute import as opposed to relative as it is now. > > > What error are you actually talking about, you posted so much output :-). > do you mean > > RuntimeError: could not create new GType: ValidatedComboEntry (subclass of > GtkComboBox) > > Benny > > > > 2012/12/3 jerome <rom...@ya...> > > Devs, > > > > I can get rid of 'gi/gtk/widgets' errors with the attached patch! > > > > I cannot make any interpretation. > > What does it mean? > > > > > > Jérôme > > > > > > --- En date de : Dim 2.12.12, Doug Blank <dou...@gm...> a écrit : > > > > De: Doug Blank <dou...@gm...> > > Objet: Re: [Gramps-devel] Python and .devhelp documentations > > À: "jerome" <rom...@ya...> > > Cc: "Benny Malengier" <ben...@gm...>, "Gramps Development > List" <gra...@li...> > > > Date: Dimanche 2 décembre 2012, 19h34 > > > > On Sun, Dec 2, 2012 at 1:13 PM, jerome <rom...@ya...> wrote: > > > > > "you know that can put multiple directories in the PYTHONPATH, like so:" > > > > > > > > export > PYTHONPATH=/path/to/pygobject:/path/to/gramps:/path/to/other/stuff:$PYTHONPATH > > > > > > > > No, I did not know that. > > > > Thanks! > > > > > > > > Unfortunately, no real changes. :( > > > > > > > > > > > > Maybe there is rather something around gramps' custom widget (GtkBuilder)? > > > > > > > > > > > > File "/home/jerome/trunk/gramps/gui/widgets/validatedcomboentry.py", > line 49, in <module> > > > > class ValidatedComboEntry(Gtk.ComboBox): > > > > File "/usr/local/lib/python2.7/site-packages/gi/types.py", line 219, in > __init__ > > > > super(GObjectMeta, cls).__init__(name, bases, dict_) > > > > File "/usr/local/lib/python2.7/site-packages/gi/_gobject/__init__.py", > line 222, in __init__ > > > > cls._type_register(cls.__dict__) > > > > File "/usr/local/lib/python2.7/site-packages/gi/_gobject/__init__.py", > line 276, in _type_register > > > > type_register(cls, namespace.get('__gtype_name__')) > > > > RuntimeError: could not create new GType: ValidatedComboEntry (subclass of > GtkComboBox) > > > > > > > > > > > > That looks like some errors that I got when I had the package > python-gnome2 installed. Perhaps you are finding the wrong version of > pygobject when you set your PYTHONPATH? > > > > -Doug > > > > I know that GtkComboBox is deprecated (GtkComboText should be used). > > > > But here, maybe all my GUI warnings are rather related to this gramps > custom widget? > > > > > > > > > > > > Jérôme > > > > > > > > > > _______________________________________________ > > > > > > > > Gramps-devel mailing list > > > > > > > > Gra...@li... > > > > > > > > https://lists.sourceforge.net/lists/listinfo/gramps-devel > > > |