diff --git a/lib/libqof/qof/qoflog.h b/lib/libqof/qof/qoflog.h index 3d233c2c93..2dbfbc34e8 100644 --- a/lib/libqof/qof/qoflog.h +++ b/lib/libqof/qof/qoflog.h @@ -63,6 +63,21 @@ * Trailing newlines (e.g. PINFO("...\n", ...)) are removed; the logger * will newline separate output. * + * @section best Best Practices + * + * Code should: + * + * @li Define both static QofLogModule log_module and #define + * G_LOG_DOMAIN to the same value. + * @li Define a logical, specific path as the log domain; + * @c "gnc.gui.plugin-pages.sx-list" or + * @c "gnc.register.gnome.cell.quickfill" are + * good examples. + * @li Use glib-provided @c g_debug(...), @c g_message(...), + * @c g_warning(...), @c g_critical(...) and + * @c g_error(...) functions in preference to the historical qof/gnc @c + * PINFO, @c PERR (&c.) macros + * * @see qof_log_parse_log_config(const char*) **/