From 758ab591d8791383df45e38a5165aa73ac342e6d Mon Sep 17 00:00:00 2001 From: "Mikhail S. Pobolovets" Date: Thu, 5 Feb 2009 20:28:18 +0200 Subject: [PATCH 1/4] Simple doxygen description for files in src directory. Mostly \file and \brief tag added. Signed-off-by: Mikhail S. Pobolovets --- src/achown.c | 4 ++++ src/achown.h | 5 +++++ src/background.c | 4 ++++ src/background.h | 5 +++++ src/boxes.c | 4 ++++ src/boxes.h | 5 +++++ src/charsets.c | 4 ++++ src/charsets.h | 5 +++++ src/chmod.c | 4 ++++ src/chmod.h | 5 +++++ src/chown.c | 4 ++++ src/chown.h | 5 +++++ src/cmd.c | 6 ++++++ src/cmd.h | 7 +++++++ src/color.c | 4 ++++ src/color.h | 5 +++++ src/command.c | 4 ++++ src/command.h | 5 +++++ src/complete.c | 4 ++++ src/cons.handler.c | 4 ++++ src/cons.saver.c | 11 +++++++++++ src/cons.saver.h | 12 ++++++++++++ src/dialog.c | 4 ++++ src/dialog.h | 4 ++++ src/dir.c | 4 ++++ src/dir.h | 5 +++++ src/ecs-test.c | 4 ++++ src/ecs.c | 4 ++++ src/ecs.h | 4 ++++ src/eregex.h | 4 ++++ src/execute.c | 4 ++++ src/execute.h | 5 +++++ src/ext.c | 4 ++++ src/ext.h | 5 +++++ src/file.c | 4 ++++ src/file.h | 5 +++++ src/filegui.c | 3 +++ src/filegui.h | 5 +++++ src/fileloc.h | 23 +++++++++++++---------- src/filenot.c | 7 +++++++ src/fileopctx.c | 17 ++++++++++++----- src/fileopctx.h | 10 ++++++++-- src/find.c | 4 ++++ src/find.h | 5 +++++ src/findme.c | 4 ++++ src/findme.h | 4 ++++ src/fs.h | 5 +++++ src/fsusage.c | 6 ++++++ src/fsusage.h | 7 +++++++ src/glibcompat.c | 8 +++++--- src/glibcompat.h | 7 +++++++ src/global.h | 9 ++++++--- src/help.c | 45 ++++++++++++++++++++++++--------------------- src/help.h | 30 ++++++++++++++++++++++++++++-- src/history.h | 5 +++++ src/hotlist.c | 4 ++++ src/hotlist.h | 5 +++++ src/info.c | 4 ++++ src/info.h | 5 +++++ src/key.c | 4 ++++ src/key.h | 5 +++++ src/keyxdef.c | 10 ++++++---- src/layout.c | 4 ++++ src/layout.h | 5 +++++ src/learn.c | 4 ++++ src/learn.h | 5 +++++ src/listmode.c | 4 ++++ src/listmode.h | 5 +++++ src/logging.c | 4 ++++ src/logging.h | 5 +++++ src/main-widgets.h | 5 +++++ src/main.c | 4 ++++ src/main.h | 5 +++++ src/man2hlp.c | 4 ++++ src/menu.c | 4 ++++ src/menu.h | 5 +++++ src/mfmt.c | 4 ++++ src/mountlist.c | 4 ++++ src/mountlist.h | 4 ++++ src/mouse.c | 7 +++++-- src/mouse.h | 7 +++++++ src/myslang.h | 5 +++++ src/option.c | 4 ++++ src/option.h | 5 +++++ src/panel.h | 5 +++++ src/panelize.c | 4 ++++ src/panelize.h | 5 +++++ src/pipethrough.c | 8 ++++++++ src/pipethrough.h | 8 ++++++++ src/popt.c | 4 ++++ src/popt.h | 4 ++++ src/poptalloca.h | 22 +++++++++++++--------- src/poptconfig.c | 4 ++++ src/popthelp.c | 4 ++++ src/poptint.h | 4 ++++ src/poptparse.c | 5 +++++ src/profile.c | 4 ++++ src/profile.h | 5 +++++ src/regex.c | 5 +++++ src/rxvt.c | 4 ++++ src/screen.c | 4 ++++ src/selcodepage.c | 4 ++++ src/selcodepage.h | 5 +++++ src/setup.c | 4 ++++ src/setup.h | 5 +++++ src/slint.c | 5 +++++ src/subshell.c | 4 ++++ src/subshell.h | 5 +++++ src/textconf.c | 4 ++++ src/textconf.h | 5 +++++ src/timefmt.h | 5 +++++ src/tree.c | 5 +++++ src/tree.h | 5 +++++ src/treestore.c | 6 ++++++ src/treestore.h | 7 +++++++ src/tty.c | 4 ++++ src/tty.h | 5 +++++ src/unixcompat.h | 20 +++++++++++--------- src/user.c | 4 ++++ src/user.h | 5 +++++ src/util.c | 4 ++++ src/util.h | 5 +++++ src/utilunix.c | 4 ++++ src/vfsdummy.h | 5 ++++- src/view.c | 4 ++++ src/view.h | 5 +++++ src/widget.c | 4 ++++ src/widget.h | 5 +++++ src/win.c | 4 ++++ src/win.h | 5 +++++ src/wtools.c | 4 ++++ src/wtools.h | 5 +++++ src/x11conn.c | 11 +++++------ src/x11conn.h | 7 +++++++ 134 files changed, 721 insertions(+), 77 deletions(-) diff --git a/src/achown.c b/src/achown.c index de2ae0783..c3651459a 100644 --- a/src/achown.c +++ b/src/achown.c @@ -17,6 +17,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file achown.c + * \brief Source: Contains functions for advanced chowning + */ + #include #include diff --git a/src/achown.h b/src/achown.h index 3f45a6f2a..a506f8221 100644 --- a/src/achown.h +++ b/src/achown.h @@ -1,3 +1,8 @@ + +/** \file achown.h + * \brief Header: Contains functions for advanced chowning + */ + #ifndef MC_ACHOWN_H #define MC_ACHOWN_H diff --git a/src/background.c b/src/background.c index fa828ddda..eda69ac6f 100644 --- a/src/background.c +++ b/src/background.c @@ -22,6 +22,10 @@ /* }}} */ +/** \file background.c + * \brief Source: Background support + */ + #include #ifdef WITH_BACKGROUND diff --git a/src/background.h b/src/background.h index a39b5acd0..c590ec155 100644 --- a/src/background.h +++ b/src/background.h @@ -1,3 +1,8 @@ + +/** \file background.h + * \brief Header: Background support + */ + #ifndef MC_BACKGROUND_H #define MC_BACKGROUND_H diff --git a/src/boxes.c b/src/boxes.c index f5eae405f..72b0cdbea 100644 --- a/src/boxes.c +++ b/src/boxes.c @@ -20,6 +20,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file boxes.c + * \brief Source: Some misc dialog boxes for the program + */ + #include #include diff --git a/src/boxes.h b/src/boxes.h index 4496c11f9..4c73ab176 100644 --- a/src/boxes.h +++ b/src/boxes.h @@ -1,3 +1,8 @@ + +/** \file boxes.h + * \brief Header: Some misc dialog boxes for the program + */ + #ifndef MC_BOXES_H #define MC_BOXES_H diff --git a/src/charsets.c b/src/charsets.c index 5666c23e3..ce8cce0dd 100644 --- a/src/charsets.c +++ b/src/charsets.c @@ -17,6 +17,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file charsets.c + * \brief Source: Text conversion from one charset to another + */ + #include #ifdef HAVE_CHARSET diff --git a/src/charsets.h b/src/charsets.h index b701d5aba..78277c0c7 100644 --- a/src/charsets.h +++ b/src/charsets.h @@ -1,3 +1,8 @@ + +/** \file charsets.h + * \brief Header: Text conversion from one charset to another + */ + #ifndef MC_CHARSETS_H #define MC_CHARSETS_H diff --git a/src/chmod.c b/src/chmod.c index 2671c6567..c6250cdc0 100644 --- a/src/chmod.c +++ b/src/chmod.c @@ -17,6 +17,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file chmod.c + * \brief Source: chmod command + */ + #include #include diff --git a/src/chmod.h b/src/chmod.h index 8954a99b9..e592f18dc 100644 --- a/src/chmod.h +++ b/src/chmod.h @@ -1,3 +1,8 @@ + +/** \file chmod.h + * \brief Header: chmod command + */ + #ifndef MC_CHMOD_H #define MC_CHMOD_H diff --git a/src/chown.c b/src/chown.c index 6598b43dd..fcbd2306a 100644 --- a/src/chown.c +++ b/src/chown.c @@ -17,6 +17,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file chown.c + * \brief Source: chown command + */ + #include #include diff --git a/src/chown.h b/src/chown.h index af504268e..e572f46b2 100644 --- a/src/chown.h +++ b/src/chown.h @@ -1,3 +1,8 @@ + +/** \file chown.h + * \brief Header: chown command + */ + #ifndef MC_CHOWN_H #define MC_CHOWN_H diff --git a/src/cmd.c b/src/cmd.c index 84f6e071a..7af96b3b6 100644 --- a/src/cmd.c +++ b/src/cmd.c @@ -18,6 +18,12 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file cmd.c + * \brief Source: routines invoked by a function key + * + * They normally operate on the current panel. + */ + #include #include diff --git a/src/cmd.h b/src/cmd.h index ace6c28c9..b2da7ba27 100644 --- a/src/cmd.h +++ b/src/cmd.h @@ -1,3 +1,10 @@ + +/** \file cmd.h + * \brief Header: routines invoked by a function key + * + * They normally operate on the current panel. + */ + #ifndef MC_CMD_H #define MC_CMD_H diff --git a/src/color.c b/src/color.c index 1ef19d704..63908cade 100644 --- a/src/color.c +++ b/src/color.c @@ -16,6 +16,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file color.c + * \brief Source: color setup + */ + #include #include diff --git a/src/color.h b/src/color.h index 0597870a1..9c62fb2ed 100644 --- a/src/color.h +++ b/src/color.h @@ -1,3 +1,8 @@ + +/** \file color.h + * \brief Header: color setup + */ + #ifndef MC_COLOR_H #define MC_COLOR_H diff --git a/src/command.c b/src/command.c index 137ce3958..4c1af9433 100644 --- a/src/command.c +++ b/src/command.c @@ -22,6 +22,10 @@ */ +/** \file command.c + * \brief Source: command line widget + */ + #include #include diff --git a/src/command.h b/src/command.h index 920b0b668..bee1c930c 100644 --- a/src/command.h +++ b/src/command.h @@ -1,3 +1,8 @@ + +/** \file command.h + * \brief Header: command line widget + */ + #ifndef MC_COMMAND_H #define MC_COMMAND_H diff --git a/src/complete.c b/src/complete.c index 694b602b6..b8fedb318 100644 --- a/src/complete.c +++ b/src/complete.c @@ -20,6 +20,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file complete.c + * \brief Source: Input line filename/username/hostname/variable/command completion + */ + #include #include diff --git a/src/cons.handler.c b/src/cons.handler.c index b08c2662d..da0cda9b4 100644 --- a/src/cons.handler.c +++ b/src/cons.handler.c @@ -16,6 +16,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file cons.handler.c + * \brief Source: client interface for General purpose Linux console save/restore server + */ + #include #include diff --git a/src/cons.saver.c b/src/cons.saver.c index ccd0647ec..8c2577802 100644 --- a/src/cons.saver.c +++ b/src/cons.saver.c @@ -32,6 +32,17 @@ Seeing other peoples consoles is bad thing, but believe me, full root is even worse. */ +/** \file cons.handler.c + * \brief Source: general purpose Linux console screen save/restore server + * + * This code does _not_ need to be setuid root. However, it needs + * read/write access to /dev/vcsa* (which is priviledged + * operation). You should create user vcsa, make cons.saver setuid + * user vcsa, and make all vcsa's owned by user vcsa. + * Seeing other peoples consoles is bad thing, but believe me, full + * root is even worse. + */ + #ifdef HAVE_CONFIG_H #include #endif diff --git a/src/cons.saver.h b/src/cons.saver.h index 4fd06f8e7..64e49d7b7 100644 --- a/src/cons.saver.h +++ b/src/cons.saver.h @@ -1,3 +1,15 @@ + +/** \file cons.saver.h + * \brief Header: general purpose Linux console screen save/restore server + * + * This code does _not_ need to be setuid root. However, it needs + * read/write access to /dev/vcsa* (which is priviledged + * operation). You should create user vcsa, make cons.saver setuid + * user vcsa, and make all vcsa's owned by user vcsa. + * Seeing other peoples consoles is bad thing, but believe me, full + * root is even worse. + */ + #ifndef MC_CONS_SAVER_H #define MC_CONS_SAVER_H diff --git a/src/dialog.c b/src/dialog.c index f8467b9d6..af71445ee 100644 --- a/src/dialog.c +++ b/src/dialog.c @@ -17,6 +17,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file dialog.c + * \brief Source: dialog box features module + */ + #include #include diff --git a/src/dialog.h b/src/dialog.h index d0f797beb..81c1ade97 100644 --- a/src/dialog.h +++ b/src/dialog.h @@ -16,6 +16,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file dialog.h + * \brief Header: dialog box features module + */ + #ifndef MC_DLG_H #define MC_DLG_H diff --git a/src/dir.c b/src/dir.c index b87cd7061..ac381bcc1 100644 --- a/src/dir.c +++ b/src/dir.c @@ -16,6 +16,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file dir.c + * \brief Source: directory routines + */ + #include #include diff --git a/src/dir.h b/src/dir.h index 90af8bbe5..8387837d0 100644 --- a/src/dir.h +++ b/src/dir.h @@ -1,3 +1,8 @@ + +/** \file dir.h + * \brief Header: directory routines + */ + #ifndef MC_DIR_H #define MC_DIR_H diff --git a/src/ecs-test.c b/src/ecs-test.c index a194280f1..b3e6b45ac 100644 --- a/src/ecs-test.c +++ b/src/ecs-test.c @@ -22,6 +22,10 @@ MA 02110-1301, USA. */ +/** \file ecs-test.c + * \brief Source: testsuite for basic support for extended character sets + */ + #include #undef NDEBUG diff --git a/src/ecs.c b/src/ecs.c index 8c7582761..b0cacc355 100644 --- a/src/ecs.c +++ b/src/ecs.c @@ -22,6 +22,10 @@ MA 02110-1301, USA. */ +/** \file ecs.c + * \brief Source: basic support for extended character sets + */ + #include #include diff --git a/src/ecs.h b/src/ecs.h index 571d93e07..66e3e6601 100644 --- a/src/ecs.h +++ b/src/ecs.h @@ -22,6 +22,10 @@ MA 02110-1301, USA. */ +/** \file ecs.h + * \brief Header: basic support for extended character sets + */ + #ifndef MC_ECS_H #define MC_ECS_H diff --git a/src/eregex.h b/src/eregex.h index 58dddb1a0..8ed3a78f1 100644 --- a/src/eregex.h +++ b/src/eregex.h @@ -19,6 +19,10 @@ Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ +/** \file eregex.h + * \brief Header: data structures and routines for the regular expression library + */ + #ifndef USE_INCLUDED_REGEX #include #else diff --git a/src/execute.c b/src/execute.c index 970a1772c..e09a80a50 100644 --- a/src/execute.c +++ b/src/execute.c @@ -15,6 +15,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file execute.c + * \brief Source: execution routines + */ + #include #include diff --git a/src/execute.h b/src/execute.h index f5e95180c..977961cc2 100644 --- a/src/execute.h +++ b/src/execute.h @@ -1,3 +1,8 @@ + +/** \file execute.h + * \brief Header: execution routines + */ + #ifndef MC_EXECUTE_H #define MC_EXECUTE_H diff --git a/src/ext.c b/src/ext.c index 27d290921..694750814 100644 --- a/src/ext.c +++ b/src/ext.c @@ -19,6 +19,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file ext.c + * \brief Source: extension dependent execution + */ + #include #include diff --git a/src/ext.h b/src/ext.h index c5d07f819..65ba6e0e3 100644 --- a/src/ext.h +++ b/src/ext.h @@ -1,3 +1,8 @@ + +/** \file ext.h + * \brief Header: extension dependent execution + */ + #ifndef MC_EXT_H #define MC_EXT_H diff --git a/src/file.c b/src/file.c index 9e0e8c2f4..1e23b9a96 100644 --- a/src/file.c +++ b/src/file.c @@ -37,6 +37,10 @@ * operations. */ +/** \file file.c + * \brief Source: file management + */ + /* {{{ Include files */ #include diff --git a/src/file.h b/src/file.h index 97c38cf1e..91a8e3d5f 100644 --- a/src/file.h +++ b/src/file.h @@ -1,3 +1,8 @@ + +/** \file file.h + * \brief Header: file management + */ + #ifndef MC_FILE_H #define MC_FILE_H diff --git a/src/filegui.c b/src/filegui.c index 343e22a28..d8ff8964f 100644 --- a/src/filegui.c +++ b/src/filegui.c @@ -39,6 +39,9 @@ * operations. */ +/** \file filegui.c + * \brief Source: file management GUI for the text mode edition + */ /* {{{ Include files */ diff --git a/src/filegui.h b/src/filegui.h index 51040279a..e8997683a 100644 --- a/src/filegui.h +++ b/src/filegui.h @@ -1,3 +1,8 @@ + +/** \file filegui.h + * \brief Header: file management GUI for the text mode edition + */ + #ifndef MC_FILEGUI_H #define MC_FILEGUI_H diff --git a/src/fileloc.h b/src/fileloc.h index 8606e4289..9ca023918 100644 --- a/src/fileloc.h +++ b/src/fileloc.h @@ -1,16 +1,19 @@ + +/** \file fileloc.h + * \brief Header: config files list + * + * This file defines the locations of the various user specific + * configuration files of the Midnight Commander. Historically the + * system wide and the user specific file names have not always been + * the same, so don't use these names for finding system wide + * configuration files. + * + * \todo This inconsistency should disappear in the one of the next versions (5.0?) + */ + #ifndef MC_FILELOC_H #define MC_FILELOC_H -/* - This file defines the locations of the various user specific - configuration files of the Midnight Commander. Historically the - system wide and the user specific file names have not always been - the same, so don't use these names for finding system wide - configuration files. - - TODO: This inconsistency should disappear in version 5.0. -*/ - #define MC_USERCONF_DIR ".mc" #define MC_BASHRC_FILE "bashrc" diff --git a/src/filenot.c b/src/filenot.c index f614ce1e6..bc91235d8 100644 --- a/src/filenot.c +++ b/src/filenot.c @@ -22,6 +22,13 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ + +/** \file filenot.c + * \brief Source: wrapper for routines to notify the + * tree about the changes made to the directory + * structure. + */ + #include #include diff --git a/src/fileopctx.c b/src/fileopctx.c index ad02cf4ae..19e6b1fd2 100644 --- a/src/fileopctx.c +++ b/src/fileopctx.c @@ -21,6 +21,13 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file fileopctx.c + * \brief Source: file operation contexts + * \date 1998-2007 + * \author Federico Mena + * \author Miguel de Icaza + */ + #include #include @@ -31,12 +38,12 @@ /** * file_op_context_new: - * + * * Creates a new file operation context with the default values. If you later want * to have a user interface for this, call #file_op_context_create_ui(). - * + * * Return value: The newly-created context, filled with the default file mask values. - **/ + */ FileOpContext * file_op_context_new (FileOperation op) { @@ -61,10 +68,10 @@ file_op_context_new (FileOperation op) /** * file_op_context_destroy: * @ctx: The file operation context to destroy. - * + * * Destroys the specified file operation context and its associated UI data, if * it exists. - **/ + */ void file_op_context_destroy (FileOpContext *ctx) { diff --git a/src/fileopctx.h b/src/fileopctx.h index d2de6a99c..65a62fd23 100644 --- a/src/fileopctx.h +++ b/src/fileopctx.h @@ -1,9 +1,15 @@ + +/** \file fileopctx.h + * \brief Header: file operation contexts + * \date 1998 + * \author Federico Mena + * \author Miguel de Icaza + */ + /* File operation contexts for the Midnight Commander * * Copyright (C) 1998 Free Software Foundation, Inc. * - * Authors: Federico Mena - * Miguel de Icaza */ #ifndef FILEOPCTX_H diff --git a/src/find.c b/src/find.c index cdd193b0e..73effacf7 100644 --- a/src/find.c +++ b/src/find.c @@ -19,6 +19,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file find.c + * \brief Source: Find file command + */ + #include #include diff --git a/src/find.h b/src/find.h index 3289350b2..623086bdb 100644 --- a/src/find.h +++ b/src/find.h @@ -1,3 +1,8 @@ + +/** \file find.h + * \brief Header: Find file command + */ + #ifndef MC_FIND_H #define MC_FIND_H diff --git a/src/findme.c b/src/findme.c index 7ab6dec9d..193deaca7 100644 --- a/src/findme.c +++ b/src/findme.c @@ -2,6 +2,10 @@ file accompanying popt source distributions, available from ftp://ftp.redhat.com/pub/code/popt */ +/** \file findme.c + * \brief Source: findProgramPath function + */ + #include #include "poptalloca.h" diff --git a/src/findme.h b/src/findme.h index adf14ccbc..52a9f89c6 100644 --- a/src/findme.h +++ b/src/findme.h @@ -2,6 +2,10 @@ file accompanying popt source distributions, available from ftp://ftp.redhat.com/pub/code/popt */ +/** \file findme.h + * \brief Header: findProgramPath function + */ + #ifndef MC_FINDME_H #define MC_FINDME_H diff --git a/src/fs.h b/src/fs.h index b4ebe7315..e7d25183f 100644 --- a/src/fs.h +++ b/src/fs.h @@ -1,3 +1,8 @@ + +/** \file fs.h + * \brief Header: fs compatibility definitions + */ + /* Include file to use opendir/closedir/readdir */ #ifndef MC_FS_H diff --git a/src/fsusage.c b/src/fsusage.c index a858d7412..e75b763ea 100644 --- a/src/fsusage.c +++ b/src/fsusage.c @@ -17,6 +17,12 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file fsusage.c + * \brief Source: return space usage of mounted file systems + * + * Space usage statistics for a file system. Blocks are 512-byte + */ + #ifdef HAVE_CONFIG_H #include #endif diff --git a/src/fsusage.h b/src/fsusage.h index c0cdf6fcd..bd580d6be 100644 --- a/src/fsusage.h +++ b/src/fsusage.h @@ -19,6 +19,13 @@ /* Space usage statistics for a file system. Blocks are 512-byte. */ +/** \file fsusage.h + * \brief Header: return space usage of mounted file systems + * + * Space usage statistics for a file system. Blocks are 512-byte + */ + + #if !defined MC_FSUSAGE_H # define MC_FSUSAGE_H diff --git a/src/glibcompat.c b/src/glibcompat.c index 9c1c5041a..4168281e5 100644 --- a/src/glibcompat.c +++ b/src/glibcompat.c @@ -17,9 +17,11 @@ * Boston, MA 02110-1301, USA. */ -/* - * Following code was copied from glib to GNU Midnight Commander to - * provide compatibility with older versions of glib. +/** \file glibcompat.c + * \brief Source: old glib compatibility + * + * Following code was copied from glib to GNU Midnight Commander to + * provide compatibility with older versions of glib. */ #include diff --git a/src/glibcompat.h b/src/glibcompat.h index c29c635e9..c88d6ea82 100644 --- a/src/glibcompat.h +++ b/src/glibcompat.h @@ -15,6 +15,13 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file glibcompat.h + * \brief Header: old glib compatibility + * + * Following code was copied from glib to GNU Midnight Commander to + * provide compatibility with older versions of glib. + */ + #ifndef MC_GLIBCOMPAT_H #define MC_GLIBCOMPAT_H diff --git a/src/global.h b/src/global.h index 04ba14aca..04e01954a 100644 --- a/src/global.h +++ b/src/global.h @@ -1,8 +1,11 @@ -/* - * This file should be included after all system includes and before - * all local includes. + +/** \file global.h + * \brief Header: global definitions for compatibility + * + * This file should be included after all system includes and before all local includes. */ + #ifndef MC_GLOBAL_H #define MC_GLOBAL_H diff --git a/src/help.c b/src/help.c index 49cf8a28c..3194592bf 100644 --- a/src/help.c +++ b/src/help.c @@ -17,29 +17,32 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/* - Implements the hypertext file viewer. - The hypertext file is a file that may have one or more nodes. Each - node ends with a ^D character and starts with a bracket, then the - name of the node and then a closing bracket. Right after the closing - bracket a newline is placed. This newline is not to be displayed by - the help viewer and must be skipped - its sole purpose is to faciliate - the work of the people managing the help file template (xnc.hlp) . - Links in the hypertext file are specified like this: the text that - will be highlighted should have a leading ^A, then it comes the - text, then a ^B indicating that highlighting is done, then the name - of the node you want to link to and then a ^C. +/** \file help.c + * \brief Source: hypertext file browser + * + * Implements the hypertext file viewer. + * The hypertext file is a file that may have one or more nodes. Each + * node ends with a ^D character and starts with a bracket, then the + * name of the node and then a closing bracket. Right after the closing + * bracket a newline is placed. This newline is not to be displayed by + * the help viewer and must be skipped - its sole purpose is to faciliate + * the work of the people managing the help file template (xnc.hlp) . + * + * Links in the hypertext file are specified like this: the text that + * will be highlighted should have a leading ^A, then it comes the + * text, then a ^B indicating that highlighting is done, then the name + * of the node you want to link to and then a ^C. + * + * The file must contain a ^D at the beginning and at the end of the + * file or the program will not be able to detect the end of file. + * + * Lazyness/widgeting attack: This file does use the dialog manager + * and uses mainly the dialog to achieve the help work. there is only + * one specialized widget and it's only used to forward the mouse messages + * to the appropiate routine. + */ - The file must contain a ^D at the beginning and at the end of the - file or the program will not be able to detect the end of file. - - Lazyness/widgeting attack: This file does use the dialog manager - and uses mainly the dialog to achieve the help work. there is only - one specialized widget and it's only used to forward the mouse messages - to the appropiate routine. - -*/ #include diff --git a/src/help.h b/src/help.h index 4eb3b8537..638bc5d57 100644 --- a/src/help.h +++ b/src/help.h @@ -1,8 +1,34 @@ + +/** \file help.h + * \brief Header: hypertext file browser + * + * Implements the hypertext file viewer. + * The hypertext file is a file that may have one or more nodes. Each + * node ends with a ^D character and starts with a bracket, then the + * name of the node and then a closing bracket. Right after the closing + * bracket a newline is placed. This newline is not to be displayed by + * the help viewer and must be skipped - its sole purpose is to faciliate + * the work of the people managing the help file template (xnc.hlp) . + * + * Links in the hypertext file are specified like this: the text that + * will be highlighted should have a leading ^A, then it comes the + * text, then a ^B indicating that highlighting is done, then the name + * of the node you want to link to and then a ^C. + * + * The file must contain a ^D at the beginning and at the end of the + * file or the program will not be able to detect the end of file. + * + * Lazyness/widgeting attack: This file does use the dialog manager + * and uses mainly the dialog to achieve the help work. there is only + * one specialized widget and it's only used to forward the mouse messages + * to the appropiate routine. + * + * This file is included by help.c and man2hlp.c + */ + #ifndef MC_HELP_H #define MC_HELP_H -/* This file is included by help.c and man2hlp.c */ - #define HELP_TEXT_WIDTH 58 /* Markers used in the help files */ diff --git a/src/history.h b/src/history.h index efd4e1676..96b31fa03 100644 --- a/src/history.h +++ b/src/history.h @@ -1,3 +1,8 @@ + +/** \file history.h + * \brief Header: defines history section names + */ + #ifndef __MC_HISTORY_H #define __MC_HISTORY_H diff --git a/src/hotlist.c b/src/hotlist.c index 1d6c4df9c..763ed4062 100644 --- a/src/hotlist.c +++ b/src/hotlist.c @@ -27,6 +27,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file hotlist.c + * \brief Source: directory hotlist + */ + #include #include diff --git a/src/hotlist.h b/src/hotlist.h index 1e6936b2b..c051519c6 100644 --- a/src/hotlist.h +++ b/src/hotlist.h @@ -1,3 +1,8 @@ + +/** \file hotlist.h + * \brief Header: directory hotlist + */ + #ifndef MC_HOTLIST_H #define MC_HOTLIST_H diff --git a/src/info.c b/src/info.c index 0a0d04aff..0071d781a 100644 --- a/src/info.c +++ b/src/info.c @@ -16,6 +16,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file info.c + * \brief Source: panel managing + */ + #include #include diff --git a/src/info.h b/src/info.h index 4a2599251..43626eb0d 100644 --- a/src/info.h +++ b/src/info.h @@ -1,3 +1,8 @@ + +/** \file info.h + * \brief Header: panel managing + */ + #ifndef MC_INFO_H #define MC_INFO_H diff --git a/src/key.c b/src/key.c index 6d3002612..b29d97b15 100644 --- a/src/key.c +++ b/src/key.c @@ -22,6 +22,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file key.c + * \brief Source: keyboard support routines + */ + #include #include diff --git a/src/key.h b/src/key.h index b1dbbe564..1e340488f 100644 --- a/src/key.h +++ b/src/key.h @@ -1,3 +1,8 @@ + +/** \file key.h + * \brief Header: keyboard support routines + */ + #ifndef MC_KEY_H #define MC_KEY_H diff --git a/src/keyxdef.c b/src/keyxdef.c index 9fd9af178..e9c4a31af 100644 --- a/src/keyxdef.c +++ b/src/keyxdef.c @@ -22,21 +22,23 @@ /* }}} */ -/* +/** \file keyxdef.c + * \brief Source: additional keyboard support routines + * * PURPOSE: - * * We would like to support the direct ALT-?/META-? and some other 'extra' * keyboard functionality provided by some terminals under some OSes (and * not supported by the 'learn keys...' facility of 'mc'. * (First target platform: QNX.) - * + * * REMARK: - * + * * Implementation strategy: we don't want to rely on a specific terminal * information database management API (termcap,terminfo,SLang,...), so we * try to define a superset of the possible key identifiers here. * */ + #include #include "global.h" diff --git a/src/layout.c b/src/layout.c index a77cb3a98..5ffa3428f 100644 --- a/src/layout.c +++ b/src/layout.c @@ -20,6 +20,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file layout.c + * \brief Source: panel layout module + */ + #include #include diff --git a/src/layout.h b/src/layout.h index 6593a6f77..d7874da16 100644 --- a/src/layout.h +++ b/src/layout.h @@ -1,3 +1,8 @@ + +/** \file layout.h + * \brief Header: panel layout module + */ + #ifndef MC_LAYOUT_H #define MC_LAYOUT_H diff --git a/src/learn.c b/src/learn.c index fb9803335..32ed0d45e 100644 --- a/src/learn.c +++ b/src/learn.c @@ -19,6 +19,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file learn.c + * \brief Source: learn keys module + */ + #include #include diff --git a/src/learn.h b/src/learn.h index f91bc70a4..0cc521201 100644 --- a/src/learn.h +++ b/src/learn.h @@ -1,3 +1,8 @@ + +/** \file learn.h + * \brief Header: learn keys module + */ + #ifndef MC_LEARN_H #define MC_LEARN_H diff --git a/src/listmode.c b/src/listmode.c index 69e499d70..7581a958a 100644 --- a/src/listmode.c +++ b/src/listmode.c @@ -20,6 +20,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file listmod.c + * \brief Source: directory panel listing format editor + */ + #include #ifdef LISTMODE_EDITOR diff --git a/src/listmode.h b/src/listmode.h index b640dd9e6..1405c42f0 100644 --- a/src/listmode.h +++ b/src/listmode.h @@ -1,3 +1,8 @@ + +/** \file listmod.h + * \brief Header: directory panel listing format editor + */ + #ifndef MC_LISTMODE_H #define MC_LISTMODE_H diff --git a/src/logging.c b/src/logging.c index bfd48e054..598b87c5f 100644 --- a/src/logging.c +++ b/src/logging.c @@ -21,6 +21,10 @@ MA 02110-1301, USA. */ +/** \file logging.c + * \brief Source: provides a log file to ease tracing the program + */ + #include #include diff --git a/src/logging.h b/src/logging.h index 6ab8f941d..a9d9dbdde 100644 --- a/src/logging.h +++ b/src/logging.h @@ -1,3 +1,8 @@ + +/** \file logging.h + * \brief Header: provides a log file to ease tracing the program + */ + #ifndef MC_LOGGING_H #define MC_LOGGING_H diff --git a/src/main-widgets.h b/src/main-widgets.h index 861e1837f..85ecca5ce 100644 --- a/src/main-widgets.h +++ b/src/main-widgets.h @@ -1,3 +1,8 @@ + +/** \file main-widgets.h + * \brief Header: provides definitions for some widgets + */ + #ifndef MC_MAIN_WIDGETS_H #define MC_MAIN_WIDGETS_H diff --git a/src/main.c b/src/main.c index 4dcee7c9c..a1bcbea43 100644 --- a/src/main.c +++ b/src/main.c @@ -20,6 +20,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file main.c + * \brief Source: this is a main module + */ + #include #include diff --git a/src/main.h b/src/main.h index 1500548be..1c532852f 100644 --- a/src/main.h +++ b/src/main.h @@ -1,3 +1,8 @@ + +/** \file main.h + * \brief Header: this is a main module header + */ + #ifndef MC_MAIN_H #define MC_MAIN_H diff --git a/src/man2hlp.c b/src/man2hlp.c index 6a922377a..baf79dc19 100644 --- a/src/man2hlp.c +++ b/src/man2hlp.c @@ -18,6 +18,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file man2hlp.c + * \brief Source: man page to help file converter + */ + #include #include diff --git a/src/menu.c b/src/menu.c index f6348d4c9..f6827ad11 100644 --- a/src/menu.c +++ b/src/menu.c @@ -16,6 +16,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file menu.c + * \brief Source: pulldown menu code + */ + #include #include diff --git a/src/menu.h b/src/menu.h index e3e043eac..6de69d45a 100644 --- a/src/menu.h +++ b/src/menu.h @@ -1,3 +1,8 @@ + +/** \file menu.h + * \brief Header: pulldown menu code + */ + #ifndef MC_MENU_H #define MC_MENU_H diff --git a/src/mfmt.c b/src/mfmt.c index ec29f6713..d79f00c93 100644 --- a/src/mfmt.c +++ b/src/mfmt.c @@ -16,6 +16,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file mfmt.c + * \brief Source: sets bold and underline for mail files + */ + #include enum states { diff --git a/src/mountlist.c b/src/mountlist.c index bd9e8d9e5..17ab446d3 100644 --- a/src/mountlist.c +++ b/src/mountlist.c @@ -15,6 +15,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file mountlist.c + * \brief Source: list of mounted filesystems + */ + #include #include diff --git a/src/mountlist.h b/src/mountlist.h index ee9afce4c..c57c4a7c0 100644 --- a/src/mountlist.h +++ b/src/mountlist.h @@ -15,6 +15,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file mountlist.h + * \brief Header: list of mounted filesystems + */ + #ifndef MC_MOUNTLIST_H #define MC_MOUNTLIST_H diff --git a/src/mouse.c b/src/mouse.c index 276caa06a..380a40dd2 100644 --- a/src/mouse.c +++ b/src/mouse.c @@ -16,8 +16,11 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/* Events received by clients of this library have their coordinates 0 */ -/* based */ +/** \file mouse.c + * \brief Source: mouse managing + * + * Events received by clients of this library have their coordinates 0 based + */ #include diff --git a/src/mouse.h b/src/mouse.h index 1ee85a17c..2a210145a 100644 --- a/src/mouse.h +++ b/src/mouse.h @@ -1,3 +1,10 @@ + +/** \file mouse.h + * \brief Header: mouse managing + * + * Events received by clients of this library have their coordinates 0 based + */ + #ifndef MC_MOUSE_H #define MC_MOUSE_H diff --git a/src/myslang.h b/src/myslang.h index a8c8b42b8..f4c8183c9 100644 --- a/src/myslang.h +++ b/src/myslang.h @@ -1,3 +1,8 @@ + +/** \file myslang.h + * \brief Header: slang wrapper module + */ + #ifndef MC_MYSLANG_H #define MC_MYSLANG_H diff --git a/src/option.c b/src/option.c index 1649b0537..0da2c3aa6 100644 --- a/src/option.c +++ b/src/option.c @@ -17,6 +17,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file option.c + * \brief Source: configure box module + */ + #include #include diff --git a/src/option.h b/src/option.h index 4f501ca9b..a8c181a60 100644 --- a/src/option.h +++ b/src/option.h @@ -1,3 +1,8 @@ + +/** \file option.h + * \brief Header: configure box module + */ + #ifndef MC_OPTION_H #define MC_OPTION_H diff --git a/src/panel.h b/src/panel.h index 844f3594b..a9d632f6b 100644 --- a/src/panel.h +++ b/src/panel.h @@ -1,3 +1,8 @@ + +/** \file panel.h + * \brief Header: defines WPanel structure + */ + #ifndef MC_PANEL_H #define MC_PANEL_H diff --git a/src/panelize.c b/src/panelize.c index 5bbf643f7..0cca32e57 100644 --- a/src/panelize.c +++ b/src/panelize.c @@ -20,6 +20,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file panelize.c + * \brief Source: External panelization module + */ + #include #include diff --git a/src/panelize.h b/src/panelize.h index af9e1cf19..72a5ba4a9 100644 --- a/src/panelize.h +++ b/src/panelize.h @@ -1,3 +1,8 @@ + +/** \file panelize.h + * \brief Header: External panelization module + */ + #ifndef MC_PANELIZE_H #define MC_PANELIZE_H diff --git a/src/pipethrough.c b/src/pipethrough.c index c2274a5ca..e31f81658 100644 --- a/src/pipethrough.c +++ b/src/pipethrough.c @@ -16,6 +16,14 @@ Roland Illig , 2004. */ + +/** \file pipethrough.c + * \brief Source: a module for piping + * + * Pipe a buffer through a child command and receive two containing + * the stdout and stderr output of the child process. + */ + #ifdef HAVE_CONFIG_H # include #endif diff --git a/src/pipethrough.h b/src/pipethrough.h index d8f845dea..5b7936fec 100644 --- a/src/pipethrough.h +++ b/src/pipethrough.h @@ -1,3 +1,11 @@ + +/** \file pipethrough.h + * \brief Header: a module for piping + * + * Pipe a buffer through a child command and receive two containing + * the stdout and stderr output of the child process. + */ + #ifndef PIPETHROUGH_H #define PIPETHROUGH_H diff --git a/src/popt.c b/src/popt.c index ba4328206..0d71d2061 100644 --- a/src/popt.c +++ b/src/popt.c @@ -2,6 +2,10 @@ file accompanying popt source distributions, available from ftp://ftp.redhat.com/pub/code/popt */ +/** \file popt.c + * \brief Source: a module for parsing command line options + */ + #ifdef HAVE_CONFIG_H #include "config.h" #endif diff --git a/src/popt.h b/src/popt.h index a7596d88e..fbfe3b048 100644 --- a/src/popt.h +++ b/src/popt.h @@ -2,6 +2,10 @@ file accompanying popt source distributions, available from ftp://ftp.redhat.com/pub/code/popt */ +/** \file popt.h + * \brief Header: a module for parsing command line options + */ + #ifndef MC_POPT_H #define MC_POPT_H diff --git a/src/poptalloca.h b/src/poptalloca.h index 0c6a5d039..fba570493 100644 --- a/src/poptalloca.h +++ b/src/poptalloca.h @@ -1,13 +1,17 @@ -/* Definitions for alloca (mostly extracted from AC_FUNC_ALLOCA). According - to the autoconf manual in dome versions of AIX the declaration of alloca - has to precede everything else execept comments and prepocessor directives, - i.e. including this file has to preceed anything else. - NOTE: alloca is redefined as malloc on systems which fail to support alloca. - Don't include this header if you frequently use alloca in order to avoid an - unlimited amount of memory leaks. - popt uses alloca only during program startup, i.e. the memory leaks caused - by this redefinition are limited. +/** \file poptalloca.h + * \brief Header: definitions for alloca for popt + * + * Definitions for alloca (mostly extracted from AC_FUNC_ALLOCA). According + * to the autoconf manual in dome versions of AIX the declaration of alloca + * has to precede everything else execept comments and prepocessor directives, + * i.e. including this file has to preceed anything else. + * + * NOTE: alloca is redefined as malloc on systems which fail to support alloca. + * Don't include this header if you frequently use alloca in order to avoid an + * unlimited amount of memory leaks. + * popt uses alloca only during program startup, i.e. the memory leaks caused + * by this redefinition are limited. */ #ifndef MC_POPTALLOCA_H diff --git a/src/poptconfig.c b/src/poptconfig.c index 5298e7295..ee54c9fd0 100644 --- a/src/poptconfig.c +++ b/src/poptconfig.c @@ -2,6 +2,10 @@ file accompanying popt source distributions, available from ftp://ftp.redhat.com/pub/code/popt */ +/** \file poptconfig.c + * \brief Source: a module for configuring popt + */ + #ifdef HAVE_CONFIG_H #include "config.h" #endif diff --git a/src/popthelp.c b/src/popthelp.c index 801acacb9..de8e5d1f4 100644 --- a/src/popthelp.c +++ b/src/popthelp.c @@ -4,6 +4,10 @@ file accompanying popt source distributions, available from ftp://ftp.redhat.com/pub/code/popt */ +/** \file popthelp.c + * \brief Source: popt helper module + */ + #ifdef HAVE_CONFIG_H #include "config.h" #endif diff --git a/src/poptint.h b/src/poptint.h index 8021861e5..65778f898 100644 --- a/src/poptint.h +++ b/src/poptint.h @@ -2,6 +2,10 @@ file accompanying popt source distributions, available from ftp://ftp.redhat.com/pub/code/popt */ +/** \file poptint.h + * \brief Header: a module (internal?) for popt + */ + #ifndef MC_POPTINT_H #define MC_POPTINT_H diff --git a/src/poptparse.c b/src/poptparse.c index c06a8d4a3..54cadf34a 100644 --- a/src/poptparse.c +++ b/src/poptparse.c @@ -2,6 +2,11 @@ file accompanying popt source distributions, available from ftp://ftp.redhat.com/pub/code/popt */ + +/** \file poptparse.c + * \brief Source: popt parser + */ + #ifdef HAVE_CONFIG_H #include "config.h" #endif diff --git a/src/profile.c b/src/profile.c index 88b566f3d..e23d98fc4 100644 --- a/src/profile.c +++ b/src/profile.c @@ -21,6 +21,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file profile.c + * \brief Source: Initialization-files(ini) functions. + */ + #include #include diff --git a/src/profile.h b/src/profile.h index 7600c20d0..2c10724f0 100644 --- a/src/profile.h +++ b/src/profile.h @@ -1,3 +1,8 @@ + +/** \file profile.h + * \brief Header: Initialization-files(ini) functions. + */ + #ifndef MC_PROFILE_H #define MC_PROFILE_H diff --git a/src/regex.c b/src/regex.c index c7e603cd2..672d1bce6 100644 --- a/src/regex.c +++ b/src/regex.c @@ -20,6 +20,11 @@ Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ +/** \file regex.c + * \brief Source: extended regular expression matching and search library + * \version 0.12 + */ + /* AIX requires this to be the first thing in the file. */ #if defined _AIX && !defined REGEX_MALLOC #pragma alloca diff --git a/src/rxvt.c b/src/rxvt.c index da658f2e5..90311af25 100644 --- a/src/rxvt.c +++ b/src/rxvt.c @@ -16,6 +16,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file rxvt.c + * \brief Source: gives output lines on rxvt with a special rxvt patch + */ + #include #include diff --git a/src/screen.c b/src/screen.c index 482b8b71b..ae9e3351b 100644 --- a/src/screen.c +++ b/src/screen.c @@ -19,6 +19,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file screen.c + * \brief Source: panel managin module + */ + #include #include diff --git a/src/selcodepage.c b/src/selcodepage.c index 4f7fa3e85..b44d313bf 100644 --- a/src/selcodepage.c +++ b/src/selcodepage.c @@ -17,6 +17,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file selcodepage.c + * \brief Source: user interface for charset selection + */ + #include #ifdef HAVE_CHARSET diff --git a/src/selcodepage.h b/src/selcodepage.h index 06fbd77bd..067f72d0d 100644 --- a/src/selcodepage.h +++ b/src/selcodepage.h @@ -1,3 +1,8 @@ + +/** \file selcodepage.h + * \brief Header: user interface for charset selection + */ + #ifndef MC_SELCODEPAGE_H #define MC_SELCODEPAGE_H diff --git a/src/setup.c b/src/setup.c index dee0ec07f..dbfdcad84 100644 --- a/src/setup.c +++ b/src/setup.c @@ -16,6 +16,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file setup.c + * \brief Source: setup loading/saving + */ + #include #include diff --git a/src/setup.h b/src/setup.h index c611e9366..855e0ba96 100644 --- a/src/setup.h +++ b/src/setup.h @@ -1,3 +1,8 @@ + +/** \file setup.h + * \brief Header: setup loading/saving + */ + #ifndef MC_SETUP_H #define MC_SETUP_H diff --git a/src/slint.c b/src/slint.c index 5945b428e..16763b037 100644 --- a/src/slint.c +++ b/src/slint.c @@ -21,6 +21,11 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file slint.c + * \brief Source: slang interface to the Midnight Commander + * \warning This module will be removed soon + */ + #include #include diff --git a/src/subshell.c b/src/subshell.c index 99cf28ce4..8e2154a50 100644 --- a/src/subshell.c +++ b/src/subshell.c @@ -16,6 +16,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file subshell.c + * \brief Source: concurrent shell support + */ + #include #ifdef HAVE_SUBSHELL_SUPPORT diff --git a/src/subshell.h b/src/subshell.h index 072871da9..6bb003a4a 100644 --- a/src/subshell.h +++ b/src/subshell.h @@ -1,3 +1,8 @@ + +/** \file subshell.h + * \brief Header: concurrent shell support + */ + #ifndef MC_SUBSHELL_H #define MC_SUBSHELL_H diff --git a/src/textconf.c b/src/textconf.c index fa7cb0e4d..046477b28 100644 --- a/src/textconf.c +++ b/src/textconf.c @@ -18,6 +18,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file textconf.c + * \brief Source: prints features specific for this build + */ + #include #include diff --git a/src/textconf.h b/src/textconf.h index b5834805d..be87bc81f 100644 --- a/src/textconf.h +++ b/src/textconf.h @@ -1,3 +1,8 @@ + +/** \file textconf.h + * \brief Header: prints features specific for this build + */ + #ifndef MC_TEXTCONF_H #define MC_TEXTCONF_H diff --git a/src/timefmt.h b/src/timefmt.h index 2b8d52fd8..b93a13585 100644 --- a/src/timefmt.h +++ b/src/timefmt.h @@ -1,3 +1,8 @@ + +/** \file timefmt.h + * \brief Header: time formating macroses + */ + #ifndef __UTIL_TIMEFMT_H #define __UTIL_TIMEFMT_H diff --git a/src/tree.c b/src/tree.c index f4e7ceeca..0a908090f 100644 --- a/src/tree.c +++ b/src/tree.c @@ -27,6 +27,11 @@ it will be possible to have tree views over virtual file systems. */ + +/** \file tree.c + * \brief Source: directory tree browser + */ + #include #include diff --git a/src/tree.h b/src/tree.h index fa6e06db1..d0aee811a 100644 --- a/src/tree.h +++ b/src/tree.h @@ -1,3 +1,8 @@ + +/** \file tree.h + * \brief Header: directory tree browser + */ + #ifndef MC_TREE_H #define MC_TREE_H diff --git a/src/treestore.c b/src/treestore.c index 915ae421e..702010808 100644 --- a/src/treestore.c +++ b/src/treestore.c @@ -31,6 +31,12 @@ it will be possible to have tree views over virtual file systems. */ +/** \file treestore.c + * \brief Source: tree store + * + * Contains a storage of the file system tree representation. + */ + #include #include diff --git a/src/treestore.h b/src/treestore.h index f6249288f..93b4b1a5c 100644 --- a/src/treestore.h +++ b/src/treestore.h @@ -1,3 +1,10 @@ + +/** \file treestore.h + * \brief Header: tree store + * + * Contains a storage of the file system tree representation. + */ + #ifndef MC_TREE_STORE_H #define MC_TREE_STORE_H diff --git a/src/tty.c b/src/tty.c index a71c6cc8e..4dcd182bb 100644 --- a/src/tty.c +++ b/src/tty.c @@ -24,6 +24,10 @@ MA 02110-1301, USA. */ +/** \file tty.c + * \brief Source: interface to the terminal controlling library + */ + #include #include diff --git a/src/tty.h b/src/tty.h index 85d286b72..f6579c28b 100644 --- a/src/tty.h +++ b/src/tty.h @@ -1,3 +1,8 @@ + +/** \file tty.h + * \brief Header: interface to the terminal controlling library + */ + #ifndef MC_TTY_H #define MC_TTY_H diff --git a/src/unixcompat.h b/src/unixcompat.h index b4d030569..e71332f69 100644 --- a/src/unixcompat.h +++ b/src/unixcompat.h @@ -1,15 +1,17 @@ + +/** \file unixcompat.h + * \brief Header: collects differences between the various Unix + * + * This header file collects differences between the various Unix + * variants that are supported by the Midnight Commander and provides + * replacement routines if they are not natively available. + * The major/minor macros are not specified in SUSv3, so we can only hope + * they are provided by the operating system or emulate it. + */ + #ifndef MC_UNIXCOMPAT_H #define MC_UNIXCOMPAT_H -/* This header file collects differences between the various Unix - * variants that are supported by the Midnight Commander and provides - * replacement routines if they are not natively available. - */ - -/* The major/minor macros are not specified in SUSv3, so we can only hope - * they are provided by the operating system or emulate it. - */ - #include /* BSD */ #ifdef HAVE_SYS_MKDEV_H # include /* Solaris 9 */ diff --git a/src/user.c b/src/user.c index e47b84235..6ffa96f5b 100644 --- a/src/user.c +++ b/src/user.c @@ -16,6 +16,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file user.c + * \brief Source: user menu implementation + */ + #include #include diff --git a/src/user.h b/src/user.h index 72997dcd6..de44b1f36 100644 --- a/src/user.h +++ b/src/user.h @@ -1,3 +1,8 @@ + +/** \file user.h + * \brief Header: user menu implementation + */ + #ifndef MC_USER_H #define MC_USER_H diff --git a/src/util.c b/src/util.c index e47b6dccb..4b69be5f1 100644 --- a/src/util.c +++ b/src/util.c @@ -22,6 +22,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file util.c + * \brief Source: various utilities + */ + #include #include diff --git a/src/util.h b/src/util.h index e108424ed..3d72e2e9d 100644 --- a/src/util.h +++ b/src/util.h @@ -1,3 +1,8 @@ + +/** \file util.h + * \brief Header: various utilities + */ + #ifndef MC_UTIL_H #define MC_UTIL_H diff --git a/src/utilunix.c b/src/utilunix.c index 8837a4735..d95ffa27a 100644 --- a/src/utilunix.c +++ b/src/utilunix.c @@ -22,6 +22,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file utilunix.c + * \brief Source: various utilities - Unix variant + */ + #include #include diff --git a/src/vfsdummy.h b/src/vfsdummy.h index 06d39c229..b7bd7f058 100644 --- a/src/vfsdummy.h +++ b/src/vfsdummy.h @@ -1,4 +1,7 @@ -/* Replacement for vfs.h if VFS support is disabled */ + +/** \file vfsdummy.h + * \brief Header: replacement for vfs.h if VFS support is disabled + */ #ifndef MC_VFSDUMMY_H #define MC_VFSDYMMY_H diff --git a/src/view.c b/src/view.c index b86ca99ef..8778dc17a 100644 --- a/src/view.c +++ b/src/view.c @@ -28,6 +28,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file view.c + * \brief Source: internal file viewer + */ + #ifdef HAVE_CONFIG_H # include #endif diff --git a/src/view.h b/src/view.h index 2b2a6cf0e..dfe65bc89 100644 --- a/src/view.h +++ b/src/view.h @@ -1,3 +1,8 @@ + +/** \file view.h + * \brief Header: internal file viewer + */ + #ifndef MC_VIEW_H #define MC_VIEW_H diff --git a/src/widget.c b/src/widget.c index f0eb95bbe..58131c3de 100644 --- a/src/widget.c +++ b/src/widget.c @@ -25,6 +25,10 @@ */ +/** \file widget.c + * \brief Source: widgets + */ + #include #include diff --git a/src/widget.h b/src/widget.h index 8c6f78170..8cbc80a16 100644 --- a/src/widget.h +++ b/src/widget.h @@ -1,3 +1,8 @@ + +/** \file widget.h + * \brief Header: widgets + */ + #ifndef MC_WIDGET_H #define MC_WIDGET_H diff --git a/src/win.c b/src/win.c index 86cf05f96..576ca7c09 100644 --- a/src/win.c +++ b/src/win.c @@ -16,6 +16,10 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file win.c + * \brief Source: curses utilities + */ + #include #include diff --git a/src/win.h b/src/win.h index 3dfc3d4cf..682a8f136 100644 --- a/src/win.h +++ b/src/win.h @@ -1,3 +1,8 @@ + +/** \file win.h + * \brief Header: curses utilities + */ + #ifndef MC_WIN_H #define MC_WIN_H diff --git a/src/wtools.c b/src/wtools.c index ba317e9cf..4e479471b 100644 --- a/src/wtools.c +++ b/src/wtools.c @@ -23,6 +23,10 @@ */ +/** \file wtools.c + * \brief Source: widget based utility functions + */ + #include #include diff --git a/src/wtools.h b/src/wtools.h index e6e0e163e..2cbe92b7f 100644 --- a/src/wtools.h +++ b/src/wtools.h @@ -1,3 +1,8 @@ + +/** \file wtools.h + * \brief Header: widget based utility functions + */ + #ifndef MC_WTOOLS_H #define MC_WTOOLS_H diff --git a/src/x11conn.c b/src/x11conn.c index fd2aadd7f..c5f98a1b1 100644 --- a/src/x11conn.c +++ b/src/x11conn.c @@ -21,12 +21,11 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/* - !!! WARNING !!! - - This code uses setjmp() and longjmp(). Before you modify _anything_ - here, please read the relevant sections of the C standard. -*/ +/** \file x11conn.c + * \brief Source: X11 support + * \warning This code uses setjmp() and longjmp(). Before you modify _anything_ here, + * please read the relevant sections of the C standard. + */ #include diff --git a/src/x11conn.h b/src/x11conn.h index 01be52925..a9e20eb1c 100644 --- a/src/x11conn.h +++ b/src/x11conn.h @@ -1,3 +1,10 @@ + +/** \file x11conn.h + * \brief Header: X11 support + * \warning This code uses setjmp() and longjmp(). Before you modify _anything_ here, + * please read the relevant sections of the C standard. + */ + #ifndef MC_X11CONN_H #define MC_X11CONN_H From 08469a001e944573a07a06db05a26cd4a857fe37 Mon Sep 17 00:00:00 2001 From: "Mikhail S. Pobolovets" Date: Fri, 6 Feb 2009 16:46:15 +0200 Subject: [PATCH 2/4] Some fixups with wrongly highlighted words Signed-off-by: Mikhail S. Pobolovets --- src/cons.handler.c | 2 +- src/cons.saver.c | 2 +- src/global.h | 2 +- src/listmode.c | 2 +- src/listmode.h | 2 +- src/selcodepage.c | 2 +- src/selcodepage.h | 2 +- src/slint.c | 2 +- src/tty.c | 2 +- src/tty.h | 13 ++++++------- src/util.c | 2 +- 11 files changed, 16 insertions(+), 17 deletions(-) diff --git a/src/cons.handler.c b/src/cons.handler.c index da0cda9b4..1574e7e0c 100644 --- a/src/cons.handler.c +++ b/src/cons.handler.c @@ -17,7 +17,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ /** \file cons.handler.c - * \brief Source: client interface for General purpose Linux console save/restore server + * \brief Source: client %interface for General purpose Linux console save/restore server */ #include diff --git a/src/cons.saver.c b/src/cons.saver.c index 8c2577802..72bb3eeff 100644 --- a/src/cons.saver.c +++ b/src/cons.saver.c @@ -32,7 +32,7 @@ Seeing other peoples consoles is bad thing, but believe me, full root is even worse. */ -/** \file cons.handler.c +/** \file cons.saver.c * \brief Source: general purpose Linux console screen save/restore server * * This code does _not_ need to be setuid root. However, it needs diff --git a/src/global.h b/src/global.h index 04e01954a..a4fd4d28e 100644 --- a/src/global.h +++ b/src/global.h @@ -1,6 +1,6 @@ /** \file global.h - * \brief Header: global definitions for compatibility + * \brief Header: %global definitions for compatibility * * This file should be included after all system includes and before all local includes. */ diff --git a/src/listmode.c b/src/listmode.c index 7581a958a..dff24845b 100644 --- a/src/listmode.c +++ b/src/listmode.c @@ -20,7 +20,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/** \file listmod.c +/** \file listmode.c * \brief Source: directory panel listing format editor */ diff --git a/src/listmode.h b/src/listmode.h index 1405c42f0..d6b5e9df7 100644 --- a/src/listmode.h +++ b/src/listmode.h @@ -1,5 +1,5 @@ -/** \file listmod.h +/** \file listmode.h * \brief Header: directory panel listing format editor */ diff --git a/src/selcodepage.c b/src/selcodepage.c index b44d313bf..753c9c19a 100644 --- a/src/selcodepage.c +++ b/src/selcodepage.c @@ -18,7 +18,7 @@ */ /** \file selcodepage.c - * \brief Source: user interface for charset selection + * \brief Source: user %interface for charset %selection */ #include diff --git a/src/selcodepage.h b/src/selcodepage.h index 067f72d0d..f36aefad7 100644 --- a/src/selcodepage.h +++ b/src/selcodepage.h @@ -1,6 +1,6 @@ /** \file selcodepage.h - * \brief Header: user interface for charset selection + * \brief Header: user %interface for charset %selection */ #ifndef MC_SELCODEPAGE_H diff --git a/src/slint.c b/src/slint.c index 16763b037..c296164a9 100644 --- a/src/slint.c +++ b/src/slint.c @@ -22,7 +22,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ /** \file slint.c - * \brief Source: slang interface to the Midnight Commander + * \brief Source: slang %interface to the Midnight Commander * \warning This module will be removed soon */ diff --git a/src/tty.c b/src/tty.c index 4dcd182bb..0ac09ecf9 100644 --- a/src/tty.c +++ b/src/tty.c @@ -25,7 +25,7 @@ */ /** \file tty.c - * \brief Source: interface to the terminal controlling library + * \brief Source: %interface to the terminal controlling library */ #include diff --git a/src/tty.h b/src/tty.h index f6579c28b..6bd3aec00 100644 --- a/src/tty.h +++ b/src/tty.h @@ -1,17 +1,16 @@ /** \file tty.h - * \brief Header: interface to the terminal controlling library + * \brief Header: %interface to the terminal controlling library + * + * This file is the %interface to the terminal controlling library: + * ncurses, slang or the built-in slang. It provides an additional + * layer of abstraction above the "real" libraries to keep the number + * of ifdefs in the other files small. */ #ifndef MC_TTY_H #define MC_TTY_H -/* - This file is the interface to the terminal controlling library--- - ncurses, slang or the built-in slang. It provides an additional - layer of abstraction above the "real" libraries to keep the number - of ifdefs in the other files small. - */ #ifdef HAVE_SLANG # include "myslang.h" diff --git a/src/util.c b/src/util.c index 4b69be5f1..cb3068ab1 100644 --- a/src/util.c +++ b/src/util.c @@ -22,7 +22,7 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/** \file util.c +/** \file * \brief Source: various utilities */ From 6a209bdb598f29bae8b742f87811e36c53d7f603 Mon Sep 17 00:00:00 2001 From: "Mikhail S. Pobolovets" Date: Fri, 6 Feb 2009 23:09:50 +0200 Subject: [PATCH 3/4] Simple doxygen description for files in edit directory. Mostly \file and \brief tag added. Some fixes for warnings with existing comments. Signed-off-by: Mikhail S. Pobolovets --- edit/bookmark.c | 6 ++++++ edit/choosesyntax.c | 6 ++++++ edit/edit-widget.h | 5 +++++ edit/edit.c | 6 ++++++ edit/edit.h | 7 +++++++ edit/editcmd.c | 6 ++++++ edit/editcmddef.h | 10 ++++++++-- edit/editdraw.c | 6 ++++++ edit/editkeys.c | 4 ++++ edit/editlock.c | 36 ++++++++++++++++++++++-------------- edit/editlock.h | 8 ++++++++ edit/editmenu.c | 6 ++++++ edit/editoptions.c | 6 ++++++ edit/editwidget.c | 6 ++++++ edit/syntax.c | 21 +++++++++++++-------- edit/usermap.c | 6 ++++++ edit/usermap.h | 7 +++++++ edit/wordproc.c | 6 ++++++ maint/template.c | 9 +++++++++ src/fileopctx.c | 14 +++++++------- src/treestore.c | 22 ++++++++-------------- 21 files changed, 158 insertions(+), 45 deletions(-) diff --git a/edit/bookmark.c b/edit/bookmark.c index 403b93c33..0cfd52093 100644 --- a/edit/bookmark.c +++ b/edit/bookmark.c @@ -20,6 +20,12 @@ 02110-1301, USA. */ +/** \file + * \brief Source: editor book mark handling + * \author Paul Sheer + * \date 1996, 1997 + */ + #include #include diff --git a/edit/choosesyntax.c b/edit/choosesyntax.c index 78a7718c0..4d8cf702e 100644 --- a/edit/choosesyntax.c +++ b/edit/choosesyntax.c @@ -16,6 +16,12 @@ Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file + * \brief Source: user %interface for syntax %selection + * \author Leonard den Ottolander + * \date 2005, 2006 + */ + #include #include "edit.h" diff --git a/edit/edit-widget.h b/edit/edit-widget.h index ab55764af..d69a6d37c 100644 --- a/edit/edit-widget.h +++ b/edit/edit-widget.h @@ -1,3 +1,8 @@ + +/** \file + * \brief Header: editor widget WEdit + */ + #ifndef MC_EDIT_WIDGET_H #define MC_EDIT_WIDGET_H diff --git a/edit/edit.c b/edit/edit.c index 3697bb5c4..79f8266c1 100644 --- a/edit/edit.c +++ b/edit/edit.c @@ -21,6 +21,12 @@ 02110-1301, USA. */ +/** \file + * \brief Source: editor low level data handling and cursor fundamentals + * \author Paul Sheer + * \date 1996, 1997 + */ + #include #include #include diff --git a/edit/edit.h b/edit/edit.h index 3e5f5637e..ee313ca74 100644 --- a/edit/edit.h +++ b/edit/edit.h @@ -20,6 +20,13 @@ 02110-1301, USA. */ +/** \file + * \brief Source: editor low level data handling and cursor fundamentals + * edit.h - main include file + * \author Paul Sheer + * \date 1996, 1997 + */ + #ifndef MC_EDIT_H #define MC_EDIT_H diff --git a/edit/editcmd.c b/edit/editcmd.c index 257ab6efe..58da80903 100644 --- a/edit/editcmd.c +++ b/edit/editcmd.c @@ -22,6 +22,12 @@ */ +/** \file + * \brief Source: editor high level editing commands + * \author Paul Sheer + * \date 1996, 1997 + */ + /* #define PIPE_BLOCKS_SO_READ_BYTE_BY_BYTE */ #include diff --git a/edit/editcmddef.h b/edit/editcmddef.h index 213537619..66273f3e4 100644 --- a/edit/editcmddef.h +++ b/edit/editcmddef.h @@ -1,8 +1,14 @@ + +/** \file + * \brief Header: editor constants + */ + #ifndef MC_EDIT_CMD_DEF_H #define MC_EDIT_CMD_DEF_H -/* in the distant future, keyboards will be invented with a - separate key for each one of these commands *sigh* */ +/** \todo In the distant future, keyboards will be invented with a + * separate key for each one of these commands *sigh* + */ /* special commands */ #define CK_Insert_Char -1 diff --git a/edit/editdraw.c b/edit/editdraw.c index 86ea3f9c7..9c7c763d5 100644 --- a/edit/editdraw.c +++ b/edit/editdraw.c @@ -21,6 +21,12 @@ 02110-1301, USA. */ +/** \file + * \brief Source: editor text drawing + * \author Paul Sheer + * \date 1996, 1997 + */ + #include #include #include diff --git a/edit/editkeys.c b/edit/editkeys.c index 2cc6add83..2c3ac84fb 100644 --- a/edit/editkeys.c +++ b/edit/editkeys.c @@ -21,6 +21,10 @@ 02110-1301, USA. */ +/** \file + * \brief Source: editor key translation + */ + #include #include diff --git a/edit/editlock.c b/edit/editlock.c index c9434a252..59e9b0d01 100644 --- a/edit/editlock.c +++ b/edit/editlock.c @@ -21,6 +21,23 @@ */ +/** \file + * \brief Source: editor file locking + * \author Adam Byrtek + * \date 2003 + * + * Locking scheme used in mcedit is based on a documentation found + * in JED editor sources. Abstract from lock.c file (by John E. Davis): + * + * The basic idea here is quite simple. Whenever a buffer is attached to + * a file, and that buffer is modified, then attempt to lock the + * file. Moreover, before writing to a file for any reason, lock the + * file. The lock is really a protocol respected and not a real lock. + * The protocol is this: If in the directory of the file is a + * symbolic link with name ".#FILE", the FILE is considered to be locked + * by the process specified by the link. + */ + #include #include /* kill() */ @@ -51,19 +68,10 @@ struct lock_s { pid_t pid; }; -/* Locking scheme used in mcedit is based on a documentation found - in JED editor sources. Abstract from lock.c file (by John E. Davis): - - The basic idea here is quite simple. Whenever a buffer is attached to - a file, and that buffer is modified, then attempt to lock the - file. Moreover, before writing to a file for any reason, lock the - file. The lock is really a protocol respected and not a real lock. - The protocol is this: If in the directory of the file is a - symbolic link with name ".#FILE", the FILE is considered to be locked - by the process specified by the link. -*/ - -/* Build user@host.domain.pid string (need to be freed) */ +/** \fn static char * lock_build_name (void) + * \brief builds user@host.domain.pid string (need to be freed) + * \return a pointer to lock filename + */ static char * lock_build_name (void) { @@ -78,7 +86,7 @@ lock_build_name (void) if (!user) user = getenv ("LOGNAME"); if (!user) user = ""; - /* TODO: Use FQDN, no clean interface, so requires lot of code */ + /** \todo Use FQDN, no clean interface, so requires lot of code */ if (gethostname (host, BUF_SIZE - 1) == -1) *host = '\0'; diff --git a/edit/editlock.h b/edit/editlock.h index a6443f881..5ddeeefd4 100644 --- a/edit/editlock.h +++ b/edit/editlock.h @@ -1,3 +1,11 @@ + +/** \file + * \brief Header: editor file locking + * \author Adam Byrtek + * \date 2003 + * Look at editlock.c for more details + */ + #ifndef MC_EDIT_LOCK_H #define MC_EDIT_LOCK_H diff --git a/edit/editmenu.c b/edit/editmenu.c index 596b32fa0..ba7b8cad1 100644 --- a/edit/editmenu.c +++ b/edit/editmenu.c @@ -21,6 +21,12 @@ 02110-1301, USA. */ +/** \file + * \brief Source: editor menu definitions and initialisation + * \author Paul Sheer + * \date 1996, 1997 + */ + #include #include diff --git a/edit/editoptions.c b/edit/editoptions.c index 9011ded63..735d5e102 100644 --- a/edit/editoptions.c +++ b/edit/editoptions.c @@ -21,6 +21,12 @@ 02110-1301, USA. */ +/** \file + * \brief Source: editor options dialog box + * \author Paul Sheer + * \date 1996, 1997 + */ + #include #include diff --git a/edit/editwidget.c b/edit/editwidget.c index e23f0978b..61cef95b2 100644 --- a/edit/editwidget.c +++ b/edit/editwidget.c @@ -21,6 +21,12 @@ 02110-1301, USA. */ +/** \file + * \brief Source: editor initialisation and callback handler + * \author Paul Sheer + * \date 1996, 1997 + */ + #include #include diff --git a/edit/syntax.c b/edit/syntax.c index b517b4a0a..009e25a60 100644 --- a/edit/syntax.c +++ b/edit/syntax.c @@ -21,6 +21,19 @@ 02110-1301, USA. */ +/** \file + * \brief Source: editor syntax highlighting + * \author Paul Sheer + * \date 1996, 1997 + * + * Mispelled words are flushed from the syntax highlighting rules + * when they have been around longer than + * TRANSIENT_WORD_TIME_OUT seconds. At a cursor rate of 30 + * chars per second and say 3 chars + a space per word, we can + * accumulate 450 words absolute max with a value of 60. This is + * below this limit of 1024 words in a context. + */ + #include #include #include @@ -43,14 +56,6 @@ /* bytes */ #define SYNTAX_MARKER_DENSITY 512 -/* - Mispelled words are flushed from the syntax highlighting rules - when they have been around longer than - TRANSIENT_WORD_TIME_OUT seconds. At a cursor rate of 30 - chars per second and say 3 chars + a space per word, we can - accumulate 450 words absolute max with a value of 60. This is - below this limit of 1024 words in a context. - */ #define TRANSIENT_WORD_TIME_OUT 60 #define UNKNOWN_FORMAT "unknown" diff --git a/edit/usermap.c b/edit/usermap.c index 1f5a8b7d5..caf8f4a2c 100644 --- a/edit/usermap.c +++ b/edit/usermap.c @@ -18,6 +18,12 @@ 02111-1307, USA. */ +/** \file + * \brief Source: cooledit.bindings file parser + * \author Vitja Makarov + * \date 2005 + */ + #include #include diff --git a/edit/usermap.h b/edit/usermap.h index fecf03b08..6ea286990 100644 --- a/edit/usermap.h +++ b/edit/usermap.h @@ -1,3 +1,10 @@ + +/** \file + * \brief Header: cooledit.bindings file parser + * \author Vitja Makarov + * \date 2005 + */ + #ifndef MC_USERMAP_H #define MC_USERMAP_H diff --git a/edit/wordproc.c b/edit/wordproc.c index fc16136b1..6021349fc 100644 --- a/edit/wordproc.c +++ b/edit/wordproc.c @@ -18,6 +18,12 @@ 02110-1301, USA. */ +/** \file + * \brief Source: word-processor mode for the editor: does dynamic paragraph formatting + * \author Paul Sheer + * \date 1996 + */ + #include #include diff --git a/maint/template.c b/maint/template.c index 721bb1863..7f2ba8ff5 100644 --- a/maint/template.c +++ b/maint/template.c @@ -24,6 +24,15 @@ MA 02110-1301, USA. */ +/** \file + * \brief This is a template file (here goes brief description). + * \author Author1 + * \author Author2 + * \date 20xx + * + * Detailed description. + */ + #include #include /* see maint/headers.txt for details */ diff --git a/src/fileopctx.c b/src/fileopctx.c index 19e6b1fd2..3c1b5adc9 100644 --- a/src/fileopctx.c +++ b/src/fileopctx.c @@ -37,12 +37,12 @@ /** - * file_op_context_new: + * \fn FileOpContext * file_op_context_new (FileOperation op) + * \param op file operation struct + * \return The newly-created context, filled with the default file mask values. * * Creates a new file operation context with the default values. If you later want - * to have a user interface for this, call #file_op_context_create_ui(). - * - * Return value: The newly-created context, filled with the default file mask values. + * to have a user interface for this, call file_op_context_create_ui(). */ FileOpContext * file_op_context_new (FileOperation op) @@ -66,8 +66,8 @@ file_op_context_new (FileOperation op) /** - * file_op_context_destroy: - * @ctx: The file operation context to destroy. + * \fn void file_op_context_destroy (FileOpContext *ctx) + * \param ctx The file operation context to destroy. * * Destroys the specified file operation context and its associated UI data, if * it exists. @@ -82,7 +82,7 @@ file_op_context_destroy (FileOpContext *ctx) regfree (&ctx->rx); - /* FIXME: do we need to free ctx->dest_mask? */ + /** \todo FIXME: do we need to free ctx->dest_mask? */ g_free (ctx); } diff --git a/src/treestore.c b/src/treestore.c index 702010808..e31a0a02b 100644 --- a/src/treestore.c +++ b/src/treestore.c @@ -257,13 +257,10 @@ tree_store_load_from(char *name) } /** - * tree_store_load: - * @void: - * - * Loads the tree from the default location. - * - * Return value: TRUE if success, FALSE otherwise. - **/ + * \fn int tree_store_load(void) + * \brief Loads the tree from the default location + * \return 1 if success (true), 0 otherwise (false) + */ int tree_store_load(void) { @@ -362,13 +359,10 @@ tree_store_save_to(char *name) } /** - * tree_store_save: - * @void: - * - * Saves the tree to the default file in an atomic fashion. - * - * Return value: 0 if success, errno on error. - **/ + * \fn int tree_store_save(void) + * \brief Saves the tree to the default file in an atomic fashion + * \return 0 if success, errno on error + */ int tree_store_save(void) { From 0a7899709b36c7604e08a0d641edb37acf3fffc2 Mon Sep 17 00:00:00 2001 From: "Mikhail S. Pobolovets" Date: Sat, 7 Feb 2009 14:54:58 +0200 Subject: [PATCH 4/4] Simple doxygen description for files in vfs (not subdirs) directory. Mostly \file and \brief tag added. Signed-off-by: Mikhail S. Pobolovets --- vfs/cpio.c | 6 ++++++ vfs/direntry.c | 45 ++++++++++++++++++++++------------------ vfs/extfs.c | 9 ++++++++ vfs/fish.c | 14 ++++++++++--- vfs/fish.h | 8 +++++++ vfs/ftpfs.c | 17 +++++++++++---- vfs/ftpfs.h | 6 ++++++ vfs/gc.c | 11 ++++++++++ vfs/gc.h | 6 ++++++ vfs/local.c | 13 +++++++++--- vfs/local.h | 6 ++++++ vfs/mcfs.c | 10 ++++++++- vfs/mcfs.h | 6 ++++++ vfs/mcfsutil.c | 7 +++++++ vfs/mcfsutil.h | 17 +++++++++------ vfs/mcserv.c | 20 +++++++++++------- vfs/sfs.c | 10 +++++++-- vfs/smbfs.c | 11 +++++++++- vfs/smbfs.h | 6 ++++++ vfs/tar.c | 10 ++++++++- vfs/tcputil.c | 5 +++++ vfs/tcputil.h | 6 ++++++ vfs/undelfs.c | 8 +++++-- vfs/utilvfs.c | 7 +++++++ vfs/utilvfs.h | 8 +++++++ vfs/vfs-impl.h | 6 ++++++ vfs/vfs.c | 55 ++++++++++++++++++++++++++++--------------------- vfs/vfs.h | 6 ++++++ vfs/xdirentry.h | 7 +++++++ 29 files changed, 272 insertions(+), 74 deletions(-) diff --git a/vfs/cpio.c b/vfs/cpio.c index 26f81a42d..14e7ed1eb 100644 --- a/vfs/cpio.c +++ b/vfs/cpio.c @@ -18,6 +18,12 @@ License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** \file + * \brief Source: Virtual File System: GNU Tar file system. + * \author Jan Hudec + * \date 2000 + */ + #include #include diff --git a/vfs/direntry.c b/vfs/direntry.c index c2fff869c..c93d9b90a 100644 --- a/vfs/direntry.c +++ b/vfs/direntry.c @@ -1,28 +1,33 @@ -/* Directory cache support -- so that you do not have copy of this in - * each and every filesystem. + +/** \file + * \brief Source: directory cache support * - * Written at 1998 by Pavel Machek , distribute under LGPL. + * So that you do not have copy of this in each and every filesystem. * - * Very loosely based on tar.c from midnight and archives.[ch] from - * avfs by Miklos Szeredi (mszeredi@inf.bme.hu) + * Very loosely based on tar.c from midnight and archives.[ch] from + * avfs by Miklos Szeredi (mszeredi@inf.bme.hu) * - * Unfortunately, I was unable to keep all filesystems - * uniform. tar-like filesystems use tree structure where each - * directory has pointers to its subdirectories. We can do this - * because we have full information about our archive. + * Unfortunately, I was unable to keep all filesystems + * uniform. tar-like filesystems use tree structure where each + * directory has pointers to its subdirectories. We can do this + * because we have full information about our archive. * - * At ftp-like filesystems, situation is a little bit different. When - * you cd /usr/src/linux/drivers/char, you do _not_ want /usr, - * /usr/src, /usr/src/linux and /usr/src/linux/drivers to be - * listed. That means that we do not have complete information, and if - * /usr is symlink to /4, we will not know. Also we have to time out - * entries and things would get messy with tree-like approach. So we - * do different trick: root directory is completely special and - * completely fake, it contains entries such as 'usr', 'usr/src', ..., - * and we'll try to use custom find_entry function. + * At ftp-like filesystems, situation is a little bit different. When + * you cd /usr/src/linux/drivers/char, you do _not_ want /usr, + * /usr/src, /usr/src/linux and /usr/src/linux/drivers to be + * listed. That means that we do not have complete information, and if + * /usr is symlink to /4, we will not know. Also we have to time out + * entries and things would get messy with tree-like approach. So we + * do different trick: root directory is completely special and + * completely fake, it contains entries such as 'usr', 'usr/src', ..., + * and we'll try to use custom find_entry function. * - * Paths here do _not_ begin with '/', so root directory of - * archive/site is simply "". Beware. */ + * \author Pavel Machek , distribute under LGPL. + * \date 1998 + * + * \warning Paths here do _not_ begin with '/', so root directory of + * archive/site is simply "". + */ #include diff --git a/vfs/extfs.c b/vfs/extfs.c index e4a36d568..b3650360b 100644 --- a/vfs/extfs.c +++ b/vfs/extfs.c @@ -20,6 +20,15 @@ License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** + * \file + * \brief Source: Virtual File System: External file system + * \author Jakub Jelinek + * \author Pavel Machek + * \author Andrew T. Veliath + * \date 1995, 1998, 1999 + */ + /* Namespace: init_extfs */ #include diff --git a/vfs/fish.c b/vfs/fish.c index e4a6b9d13..510d6028c 100644 --- a/vfs/fish.c +++ b/vfs/fish.c @@ -23,12 +23,20 @@ License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/* +/** + * \file + * \brief Source: Virtual File System: FISH implementation for transfering files over + * shell connections + * \author Pavel Machek + * \author Michal Svec + * \date 1998, 2000 + * + * Derived from ftpfs.c * Read README.fish for protocol specification. * * Syntax of path is: /#sh:user@host[:Cr]/path - * where C means you want compressed connection, - * and r means you want to use rsh + * where C means you want compressed connection, + * and r means you want to use rsh * * Namespace: fish_vfs_ops exported. */ diff --git a/vfs/fish.h b/vfs/fish.h index 3876d8552..bae43ca04 100644 --- a/vfs/fish.h +++ b/vfs/fish.h @@ -1,3 +1,11 @@ + +/** + * \file + * \brief Header: Virtual File System: FISH implementation for transfering files over + * shell connections + */ + + #ifndef MC_VFS_FISH_H #define MC_VFS_FISH_H diff --git a/vfs/ftpfs.c b/vfs/ftpfs.c index 7737e93e2..eb65f4750 100644 --- a/vfs/ftpfs.c +++ b/vfs/ftpfs.c @@ -21,14 +21,23 @@ You should have received a copy of the GNU Library General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ - -/* FTPfs TODO: +/** + * \file + * \brief Source: Virtual File System: FTP file system + * \author Ching Hui + * \author Jakub Jelinek + * \author Miguel de Icaza + * \author Norbert Warmuth + * \author Pavel Machek + * \date 1995, 1997, 1998 + * + * \todo - make it more robust - all the connects etc. should handle EADDRINUSE and ERETRY (have I spelled these names correctly?) - make the user able to flush a connection - all the caches will get empty etc., (tarfs as well), we should give there a user selectable timeout - and assign a key sequence. + and assign a key sequence. - use hash table instead of linklist to cache ftpfs directory. What to do with this? @@ -53,7 +62,7 @@ What to do with this? */ -/* Namespace pollution: horrible */ +/* \todo Fix: Namespace pollution: horrible */ #include #include /* POSIX-required by sys/socket.h and netdb.h */ diff --git a/vfs/ftpfs.h b/vfs/ftpfs.h index 640a41c86..b2003db00 100644 --- a/vfs/ftpfs.h +++ b/vfs/ftpfs.h @@ -1,3 +1,9 @@ + +/** + * \file + * \brief Header: Virtual File System: FTP file system + */ + #ifndef MC_VFS_FTPFS_H #define MC_VFS_FTPFS_H diff --git a/vfs/gc.c b/vfs/gc.c index a0376d8fe..45af3fcb5 100644 --- a/vfs/gc.c +++ b/vfs/gc.c @@ -20,6 +20,17 @@ License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** + * \file + * \brief Source: Virtual File System: garbage collection code + * \author Miguel de Icaza + * \author Jakub Jelinek + * \author Pavel Machek + * \author Pavel Roskin + * \date 1995, 1998, 2003 + */ + + #include #include diff --git a/vfs/gc.h b/vfs/gc.h index e1ef7235b..f4f994664 100644 --- a/vfs/gc.h +++ b/vfs/gc.h @@ -1,3 +1,9 @@ + +/** + * \file + * \brief Header: Virtual File System: garbage collection code + */ + #ifndef MC_VFS_GC_H #define MC_VFS_GC_H diff --git a/vfs/local.c b/vfs/local.c index 4c56f6bca..26731ac12 100644 --- a/vfs/local.c +++ b/vfs/local.c @@ -1,3 +1,9 @@ + +/** + * \file + * \brief Source: local FS + */ + #include #include #include @@ -13,11 +19,12 @@ #include "vfs.h" #include "local.h" -/* Note: Some of this functions are not static. This has rather good +/** + * Note: Some of this functions are not static. This has rather good * reason: exactly same functions would have to appear in sfs.c. This * saves both computer's memory and my work. - * */ - + */ + static struct vfs_class vfs_local_ops; static void * diff --git a/vfs/local.h b/vfs/local.h index 03d5ce29a..176279b8b 100644 --- a/vfs/local.h +++ b/vfs/local.h @@ -1,3 +1,9 @@ + +/** + * \file + * \brief Header: local FS + */ + #ifndef MC_VFS_LOCAL_H #define MC_VFS_LOCAL_H diff --git a/vfs/mcfs.c b/vfs/mcfs.c index 9f5ace24d..42511666e 100644 --- a/vfs/mcfs.c +++ b/vfs/mcfs.c @@ -21,7 +21,15 @@ License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/* Namespace: exports mcfs_vfs_ops, tcp_invalidate_socket */ +/** + * \file + * \brief Source: Midnight Commander file system + * \author Miguel de Icaza + * \author Andrej Borsenkow + * \author Norbert Warmuth + * + * Namespace: exports mcfs_vfs_ops, tcp_invalidate_socket + */ #include diff --git a/vfs/mcfs.h b/vfs/mcfs.h index 6a4a557e3..6b864d6ed 100644 --- a/vfs/mcfs.h +++ b/vfs/mcfs.h @@ -1,3 +1,9 @@ + +/** + * \file + * \brief Header: Midnight Commander file system + */ + #ifndef MC_VFS_MCFS_H #define MC_VFS_MCFS_H diff --git a/vfs/mcfsutil.c b/vfs/mcfsutil.c index dd753f7cb..64416fddf 100644 --- a/vfs/mcfsutil.c +++ b/vfs/mcfsutil.c @@ -16,6 +16,13 @@ License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** + * \file + * \brief Source: Low-level protocol for MCFS + * \author Miguel de Icaza + * \date 1995, 1996 + */ + #include #ifdef WITH_MCFS diff --git a/vfs/mcfsutil.h b/vfs/mcfsutil.h index dc0ece656..9e1d89902 100644 --- a/vfs/mcfsutil.h +++ b/vfs/mcfsutil.h @@ -1,12 +1,17 @@ + +/** + * \file + * \brief Header: Low-level protocol for MCFS + * + * \todo FIXME: This protocol uses 32-bit integers for the communication. + * It is a problem on systems with large file support, which is now + * default. This means that lseek is broken unless --disable-largefile + * is used. 64-bit systems are probably broken even more. + */ + #ifndef MC_VFS_MCFSUTIL_H #define MC_VFS_MCFSUTIL_H -/* - * FIXME: This protocol uses 32-bit integers for the communication. - * It is a problem on systems with large file support, which is now - * default. This means that lseek is broken unless --disable-largefile - * is used. 64-bit systems are probably broken even more. - */ enum { RPC_END, /* End of RPC commands */ diff --git a/vfs/mcserv.c b/vfs/mcserv.c index d79c6f355..25b00464a 100644 --- a/vfs/mcserv.c +++ b/vfs/mcserv.c @@ -20,15 +20,19 @@ You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +*/ - TODO: - opendir instead of keeping its table of file handles could return - the pointer and expect the client to send a proper value back each - time :-) - - We should use syslog to register login/logout. - - */ +/** + * \file + * \brief Source: server for the Midnight Commander Virtual File System + * \author Miguel de Icaza + * \author Andrej Borsenkow + * \date 1995, 1996, 1997 + * + * \todo opendir instead of keeping its table of file handles could return + * the pointer and expect the client to send a proper value back each + * time :-) We should use syslog to register login/logout. + */ /* {{{ Includes and global variables */ diff --git a/vfs/sfs.c b/vfs/sfs.c index 077048211..9d94efcc7 100644 --- a/vfs/sfs.c +++ b/vfs/sfs.c @@ -17,15 +17,21 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ + +/** + * \file + * \brief Source: Single File fileSystem * * This defines whole class of filesystems which contain single file * inside. It is somehow similar to extfs, except that extfs makes - * whole virtual trees and we do only single virtual files. + * whole virtual trees and we do only single virtual files. * * If you want to gunzip something, you should open it with #ugz * suffix, DON'T try to gunzip it yourself. * - * Namespace: exports vfs_sfs_ops */ + * Namespace: exports vfs_sfs_ops + */ #include #include diff --git a/vfs/smbfs.c b/vfs/smbfs.c index 2f15ebf1f..814db8158 100644 --- a/vfs/smbfs.c +++ b/vfs/smbfs.c @@ -20,7 +20,16 @@ License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/* Namespace: exports init_smbfs, smbfs_set_debug(), smbfs_set_debugf() */ +/** + * \file + * \brief Source: Virtual File System: smb file system + * \author Wayne Roberts + * \author Andrew V. Samoilov + * \date 1997, 2002, 2003 + * + * Namespace: exports init_smbfs, smbfs_set_debug(), smbfs_set_debugf() + */ + #include #include diff --git a/vfs/smbfs.h b/vfs/smbfs.h index 3d63f79a3..07483e981 100644 --- a/vfs/smbfs.h +++ b/vfs/smbfs.h @@ -1,3 +1,9 @@ + +/** + * \file + * \brief Header: Virtual File System: smb file system + */ + #ifndef MC_VFS_SMBFS_H #define MC_VFS_SMBFS_H diff --git a/vfs/tar.c b/vfs/tar.c index 5a65d55f0..3e1c3a45b 100644 --- a/vfs/tar.c +++ b/vfs/tar.c @@ -19,7 +19,15 @@ License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/* Namespace: init_tarfs */ +/** + * \file + * \brief Source: Virtual File System: GNU Tar file system + * \author Jakub Jelinek + * \author Pavel Machek + * \date 1995, 1998 + * + * Namespace: init_tarfs + */ #include #include diff --git a/vfs/tcputil.c b/vfs/tcputil.c index 34c6263ba..08d62d46d 100644 --- a/vfs/tcputil.c +++ b/vfs/tcputil.c @@ -17,6 +17,11 @@ License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** + * \file + * \brief Source: Virtual File System: Network utilities + */ + #include #include #include diff --git a/vfs/tcputil.h b/vfs/tcputil.h index 51c19c85c..31afc0ffa 100644 --- a/vfs/tcputil.h +++ b/vfs/tcputil.h @@ -1,3 +1,9 @@ + +/** + * \file + * \brief Header: Virtual File System: Network utilities + */ + #ifndef MC_VFS_TCPUTIL_H #define MC_VFS_TCPUTIL_H diff --git a/vfs/undelfs.c b/vfs/undelfs.c index 010e7d563..a9e686a3f 100644 --- a/vfs/undelfs.c +++ b/vfs/undelfs.c @@ -26,12 +26,16 @@ License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/* Assumptions: +/** + * \file + * \brief Source: UnDel File System + * + * Assumptions: * * 1. We don't handle directories (thus undelfs_get_path is easy to write). * 2. Files are on the local file system (we do not support vfs files * because we would have to provide an io_manager for the ext2fs tools, - * and I don't think it would be too useful to undelete files + * and I don't think it would be too useful to undelete files */ #include diff --git a/vfs/utilvfs.c b/vfs/utilvfs.c index b2c45a1ee..82e6d2ff1 100644 --- a/vfs/utilvfs.c +++ b/vfs/utilvfs.c @@ -18,6 +18,13 @@ License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ +/** + * \file + * \brief Source: Utilities for VFS modules + * \author Miguel de Icaza + * \date 1995, 1996 + */ + #include #include diff --git a/vfs/utilvfs.h b/vfs/utilvfs.h index d0255036e..5747ee32a 100644 --- a/vfs/utilvfs.h +++ b/vfs/utilvfs.h @@ -1,3 +1,11 @@ + +/** + * \file + * \brief Header: Utilities for VFS modules + * \author Miguel de Icaza + * \date 1995, 1996 + */ + #ifndef MC_VFS_UTILVFS_H #define MC_VFS_UTILVFS_H diff --git a/vfs/vfs-impl.h b/vfs/vfs-impl.h index 1039abc54..484191d7c 100644 --- a/vfs/vfs-impl.h +++ b/vfs/vfs-impl.h @@ -1,3 +1,9 @@ + +/** + * \file + * \brief Header: VFS implemntation (?) + */ + #ifndef MC_VFS_IMPL_H #define MC_VFS_IMPL_H diff --git a/vfs/vfs.c b/vfs/vfs.c index 8ea71f77d..61daf3e1d 100644 --- a/vfs/vfs.c +++ b/vfs/vfs.c @@ -20,12 +20,20 @@ License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -/* Warning: funtions like extfs_lstat() have right to destroy any +/** + * \file + * \brief Source: Virtual File System switch code + * \author Miguel de Icaza + * \author Jakub Jelinek + * \author Pavel Machek + * \date 1995, 1998 + * \warning funtions like extfs_lstat() have right to destroy any * strings you pass to them. This is acutally ok as you g_strdup what - * you are passing to them, anyway; still, beware. */ - -/* Namespace: exports *many* functions with vfs_ prefix; exports - parse_ls_lga and friends which do not have that prefix. */ + * you are passing to them, anyway; still, beware. + * + * Namespace: exports *many* functions with vfs_ prefix; exports + * parse_ls_lga and friends which do not have that prefix. + */ #include @@ -54,7 +62,7 @@ #include "smbfs.h" #include "local.h" -/* They keep track of the current directory */ +/** They keep track of the current directory */ static struct vfs_class *current_vfs; static char *current_dir; @@ -69,7 +77,7 @@ static GSList *vfs_openfiles; static struct vfs_class *localfs_class; -/* Create new VFS handle and put it to the list */ +/** Create new VFS handle and put it to the list */ static int vfs_new_handle (struct vfs_class *vclass, void *fsinfo) { @@ -84,7 +92,7 @@ vfs_new_handle (struct vfs_class *vclass, void *fsinfo) return h->handle; } -/* Function to match handle, passed to g_slist_find_custom() */ +/** Function to match handle, passed to g_slist_find_custom() */ static gint vfs_cmp_handle (gconstpointer a, gconstpointer b) { @@ -93,7 +101,7 @@ vfs_cmp_handle (gconstpointer a, gconstpointer b) return ((struct vfs_openfile *) a)->handle != (long) b; } -/* Find VFS class by file handle */ +/** Find VFS class by file handle */ static inline struct vfs_class * vfs_op (int handle) { @@ -110,7 +118,7 @@ vfs_op (int handle) return h->vclass; } -/* Find private file data by file handle */ +/** Find private file data by file handle */ static inline void * vfs_info (int handle) { @@ -127,7 +135,7 @@ vfs_info (int handle) return h->fsinfo; } -/* Free open file data for given file handle */ +/** Free open file data for given file handle */ static inline void vfs_free_handle (int handle) { @@ -153,7 +161,7 @@ vfs_register_class (struct vfs_class *vfs) return 1; } -/* Return VFS class for the given prefix */ +/** Return VFS class for the given prefix */ static struct vfs_class * vfs_prefix_to_class (char *prefix) { @@ -173,9 +181,10 @@ vfs_prefix_to_class (char *prefix) return NULL; } -/* Strip known vfs suffixes from a filename (possible improvement: strip - suffix from last path component). - Returns a malloced string which has to be freed. */ +/** Strip known vfs suffixes from a filename (possible improvement: strip + * suffix from last path component). + * \return a malloced string which has to be freed. + */ char * vfs_strip_suffix_from_filename (const char *filename) { @@ -218,7 +227,7 @@ path_magic (const char *path) return 1; } -/* +/** * Splits path '/p1#op/inpath' into inpath,op; returns which vfs it is. * What is left in path is p1. You still want to g_free(path), you DON'T * want to free neither *inpath nor *op @@ -562,7 +571,7 @@ int mc_fstat (int handle, struct stat *buf) { return result; } -/* +/** * Return current directory. If it's local, reread the current directory * from the OS. You must g_strdup() whatever this function returns. */ @@ -603,9 +612,9 @@ vfs_setup_wd (void) current_vfs = vfs_get_class (current_dir); } -/* - * Return current directory. If it's local, reread the current directory - * from the OS. Put directory to the provided buffer. +/** + * Return current directory. If it's local, reread the current directory + * from the OS. Put directory to the provided buffer. */ char * mc_get_current_wd (char *buffer, int size) @@ -616,7 +625,7 @@ mc_get_current_wd (char *buffer, int size) return buffer; } -/* +/** * Return current directory without any OS calls. */ char * @@ -640,7 +649,7 @@ off_t mc_lseek (int fd, off_t offset, int whence) return result; } -/* +/** * remove //, /./ and /../ */ @@ -674,7 +683,7 @@ vfs_canon (const char *path) } } -/* +/** * VFS chdir. * Return 0 on success, -1 on failure. */ diff --git a/vfs/vfs.h b/vfs/vfs.h index d79c706f4..e90c298df 100644 --- a/vfs/vfs.h +++ b/vfs/vfs.h @@ -1,3 +1,9 @@ + +/** + * \file + * \brief Header: Virtual File System switch code + */ + #ifndef MC_VFS_VFS_H #define MC_VFS_VFS_H diff --git a/vfs/xdirentry.h b/vfs/xdirentry.h index c58a2f95c..c8da1c9a8 100644 --- a/vfs/xdirentry.h +++ b/vfs/xdirentry.h @@ -1,3 +1,10 @@ + +/** + * \file + * \brief Header: Virtual File System directory structure + */ + + #ifndef MC_VFS_XDIRENTRY_H #define MC_VFS_XDIRENTRY_H