Re: Documenting properties and signals with gtk-doc
On 12/20/2014 01:39 PM, Wouter Verhelst wrote: Hi list, I've been pouring over the (fairly scarce) documentation https://developer.gnome.org/gtk-doc-manual/unstable/ if anything is unclear, let me know. ... and FYI there also is a gtk-doc mailing list and irc channel. Stefan and trying to fix things for several hours last night (until the wee hours of the morning, in fact), but so far haven't been able to figure this out: I wrote a library to deal with joysticks in a GObject/GTK-like way. It works (including a GTK-based tester tool, although the UI could use some improvement), and I now want to do the API documentation and also make sure that glib-introspection works. However, I do not seem to be able to get the documentation that I wrote for the few signals and properties to actually show up in the gtk-doc output. It just isn't there. I'm sure this must be something obvious to someone more experienced with gtk-doc than me, but I don't see it. Help? The code is at https://github.com/yoe/libjoy Thanks, ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
Re: Documenting properties and signals with gtk-doc
I believe (I think) signals and properties are found at build time by starting up your library and walking the classes you define. You need to add a bit more machinery to your Makefile.am to help it run g-ir-scanner for you. There's a page on the wiki about this: https://wiki.gnome.org/action/show/Projects/GObjectIntrospection/AutotoolsIntegration?action=show I couldn't see most of that stuff in your project, perhaps I missed it. John On 20 December 2014 at 12:39, Wouter Verhelst w...@uter.be wrote: Hi list, I've been pouring over the (fairly scarce) documentation and trying to fix things for several hours last night (until the wee hours of the morning, in fact), but so far haven't been able to figure this out: I wrote a library to deal with joysticks in a GObject/GTK-like way. It works (including a GTK-based tester tool, although the UI could use some improvement), and I now want to do the API documentation and also make sure that glib-introspection works. However, I do not seem to be able to get the documentation that I wrote for the few signals and properties to actually show up in the gtk-doc output. It just isn't there. I'm sure this must be something obvious to someone more experienced with gtk-doc than me, but I don't see it. Help? The code is at https://github.com/yoe/libjoy Thanks, -- It is easy to love a country that is famous for chocolate and beer -- Barack Obama, speaking in Brussels, Belgium, 2014-03-26 ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
Re: Documenting properties and signals with gtk-doc
Oh dear, I'm sorry, I've been fiddling with gobject-introspection too much recently. Of course you don't need introspection to generate gtk-doc output. I don't know why your signal documentation is not being generated. On 20 December 2014 at 13:10, jcup...@gmail.com wrote: I believe (I think) signals and properties are found at build time by starting up your library and walking the classes you define. You need to add a bit more machinery to your Makefile.am to help it run g-ir-scanner for you. There's a page on the wiki about this: https://wiki.gnome.org/action/show/Projects/GObjectIntrospection/AutotoolsIntegration?action=show I couldn't see most of that stuff in your project, perhaps I missed it. John On 20 December 2014 at 12:39, Wouter Verhelst w...@uter.be wrote: Hi list, I've been pouring over the (fairly scarce) documentation and trying to fix things for several hours last night (until the wee hours of the morning, in fact), but so far haven't been able to figure this out: I wrote a library to deal with joysticks in a GObject/GTK-like way. It works (including a GTK-based tester tool, although the UI could use some improvement), and I now want to do the API documentation and also make sure that glib-introspection works. However, I do not seem to be able to get the documentation that I wrote for the few signals and properties to actually show up in the gtk-doc output. It just isn't there. I'm sure this must be something obvious to someone more experienced with gtk-doc than me, but I don't see it. Help? The code is at https://github.com/yoe/libjoy Thanks, -- It is easy to love a country that is famous for chocolate and beer -- Barack Obama, speaking in Brussels, Belgium, 2014-03-26 ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
Re: Documenting properties and signals with gtk-doc
On Sat, Dec 20, 2014 at 01:14:06PM +, jcup...@gmail.com wrote: Oh dear, I'm sorry, I've been fiddling with gobject-introspection too much recently. Of course you don't need introspection to generate gtk-doc output. Well, I do want introspection eventually, and I had already looked at that wiki page, which told me to look at gtk-doc first... so yeah, I'll have to do that eventually, but I want to get the documentation to work before I step it up and look at introspection. I must say that so far Doxygen looks a lot more easy to get to work. But maybe that's just my inexperience showing ;-) I don't know why your signal documentation is not being generated. Bummer. Thanks anyway. -- It is easy to love a country that is famous for chocolate and beer -- Barack Obama, speaking in Brussels, Belgium, 2014-03-26 ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
Re: Documenting properties and signals with gtk-doc
Hi, Le 20/12/2014 13:39, Wouter Verhelst a écrit : [...] I wrote a library to deal with joysticks in a GObject/GTK-like way. It works (including a GTK-based tester tool, although the UI could use some improvement), and I now want to do the API documentation and also make sure that glib-introspection works. However, I do not seem to be able to get the documentation that I wrote for the few signals and properties to actually show up in the gtk-doc output. It just isn't there. I'm sure this must be something obvious to someone more experienced with gtk-doc than me, but I don't see it. The problem you have is that your GType type names don't match your class names. You have JoyStickType and JoyModelType, but your classes are name JoyStick and JoyModel. As the properties and signals are detected by introspecting the types (via gtkdoc-scangobj), the GType type name has to match the one of your actual class, otherwise gtk-doc won't know they belong to it. What you actually need to do is rename your GTypes to the real structure name. This will fix the type hierarchy (as you miss it), and the properties and signals. Regards, Colomban PS: your build system has issues, like the generated files (joy-marchallers.[ch], joy-iface.h) aren't generated automatically, and you lack a dependency on libjoy.la and UDEV_LIBS on your libjoy-gtk library (this breaks building with LDFLAGS=-Wl,-z,defs) ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
Re: Documenting properties and signals with gtk-doc
On Sat, Dec 20, 2014 at 03:04:17PM +0100, Colomban Wendling wrote: Hi, Le 20/12/2014 13:39, Wouter Verhelst a écrit : [...] I wrote a library to deal with joysticks in a GObject/GTK-like way. It works (including a GTK-based tester tool, although the UI could use some improvement), and I now want to do the API documentation and also make sure that glib-introspection works. However, I do not seem to be able to get the documentation that I wrote for the few signals and properties to actually show up in the gtk-doc output. It just isn't there. I'm sure this must be something obvious to someone more experienced with gtk-doc than me, but I don't see it. The problem you have is that your GType type names don't match your class names. Thanks! That fixed it, indeed. In hindsight it's obvious that this can't work; but then, I suppose that's true for all bugs. [...] PS: your build system has issues, like the generated files (joy-marchallers.[ch], joy-iface.h) aren't generated automatically, and you lack a dependency on libjoy.la and UDEV_LIBS on your libjoy-gtk library (this breaks building with LDFLAGS=-Wl,-z,defs) I know. That's part of why it's not released yet :-) I'll need to fix that up before it's ready, and I will, but obviously I can't do everything at once. Still, thanks for pointing that out. -- It is easy to love a country that is famous for chocolate and beer -- Barack Obama, speaking in Brussels, Belgium, 2014-03-26 ___ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list