GNOME Bugzilla – Bug 753935
Update example namespace and class names in GObject tutorial
Last modified: 2017-10-05 14:37:03 UTC
Maman is a very dated and unhelpful example namespace to use in the GObject tutorial. The reader can’t really relate to it at all. How about changing it to something concrete like specialised file types? Perhaps a running example of a file previewer program called ‘Viewer’, which has a File class and subclasses for specialised file types it supports, like AudioFile or ImageFile. That would give examples like: VIEWER_TYPE_FILE VIEWER_TYPE_AUDIO_FILE etc. (Thanks to ebassi for this suggestion.)
I think that is a good example.
Created attachment 313672 [details] [review] docs: Replace Maman in the tutorial with a more meaningful example Change it to a running example of a file viewer application with a file class and various derived classes and related interfaces. Hopefully the reader can relate to this a little better than to their maman.
Review of attachment 313672 [details] [review]: Yes, please. ::: docs/reference/gobject/tut_gobject.xml @@ +69,3 @@ +/* will create viewer_file_get_type and set viewer_file_parent_class */ +G_DEFINE_TYPE (ViewerFile, viewer_file, G_TYPE_OBJECT); Coding style consistency: drop the trailing semi-colon.
Pushed with the suggested change. Thanks for the review! Attachment 313672 [details] pushed as bf33f1d - docs: Replace Maman in the tutorial with a more meaningful example
*** Bug 705056 has been marked as a duplicate of this bug. ***