From 07581f469c65a08158c4addfe310ed4470555016 Mon Sep 17 00:00:00 2001 From: gouldtj Date: Wed, 29 Mar 2006 05:42:00 +0000 Subject: [PATCH] r10985@tres: ted | 2006-02-25 21:56:46 -0800 Adding in documentation --- src/extension/prefdialog.cpp | 18 ++++++++++++++++++ src/extension/prefdialog.h | 1 + 2 files changed, 19 insertions(+) diff --git a/src/extension/prefdialog.cpp b/src/extension/prefdialog.cpp index 0006874f1..c9d32c7e2 100644 --- a/src/extension/prefdialog.cpp +++ b/src/extension/prefdialog.cpp @@ -18,6 +18,15 @@ namespace Inkscape { namespace Extension { +/** \brief Creates a new preference dialog for extension preferences + \param name Name of the Extension who's dialog this is + \param help The help string for the extension (NULL if none) + \param controls The extension specific widgets in the dialog + + This function initializes the dialog with the name of the extension + in the title. It adds a few buttons and sets up handlers for + them. It also places the passed in widgets into the dialog. +*/ PrefDialog::PrefDialog (Glib::ustring name, gchar const * help, Gtk::Widget * controls) : Gtk::Dialog::Dialog(name + _(" Preferences"), true, true), _help(help), _name(name) { @@ -41,6 +50,15 @@ PrefDialog::PrefDialog (Glib::ustring name, gchar const * help, Gtk::Widget * co return; } +/** \brief Runs the dialog + \return The response to the dialog + + This function overrides the run function in the GTKmm dialog + class, but basically it only calls it. This function only + handles the \c Gtk::RESPONSE_HELP return, and in that case it + brings up the help window. All other return values are returned + to the calling function. +*/ int PrefDialog::run (void) { int resp = Gtk::RESPONSE_HELP; diff --git a/src/extension/prefdialog.h b/src/extension/prefdialog.h index 371f06376..8092a83d9 100644 --- a/src/extension/prefdialog.h +++ b/src/extension/prefdialog.h @@ -20,6 +20,7 @@ namespace Inkscape { namespace Extension { +/** \brief A class to represent the preferences for an extension */ class PrefDialog : public Gtk::Dialog { /** \brief Help string if it exists */ gchar const * _help; -- 2.30.2