⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 mfm.h

📁 a graphic tools for MTools
💻 H
字号:
/* MToolsFM - A graphical Frontend to mtools                                   *//* earlier versions under the name mfm                                         *//* Copyright (c) 1999 Christian Ospelkaus <christian@core-coutainville.org>    *//* This program is free software; you can redistribute it and/or               *//* modify it under the terms of the GNU General Public License                 *//* as published by the Free Software Foundation; either version 2              *//* of the License, or (at your option) any later version.                      *//* This program is distributed in the hope that it will be useful,             *//* but WITHOUT ANY WARRANTY; without even the implied warranty of              *//* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the               *//* GNU General Public License for more details.                                *//* 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., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA. *//* The location of the system-wide configuration file. *//* This should be fine on most systems. *//* The directory can be adjusted with ./configure --with-etcdir=... *//* Uncomment the following line if you use GTK+ 1.1 *//* #define OLDGTK */                                                                    /* Do not change anything below ;-) */#define ABOUTMFM "MToolsFM version " VERSION "\n\n\MToolsFM is a graphical frontend for mtools\n\n\Copyright (c) 1999 Christian Ospelkaus\n\<christian@core-coutainville.org>\n\n\For the newest version, see the MToolsFM-homepage at\n\n\http://www.core-coutainville.org/MToolsFM/\n\n\MToolsFM comes with ABSOLUTELY NO WARRANTY;\n\for details see file COPYING. This is free software,\n\and you are welcome to redistribute it under certain\n\conditions; again, see file COPYING for details.\n"#ifdef DEFAULT_NOSAVE#define MFMOPTIONS "Options:\n\n\--nosysconf\n\      Don磘 attempt to read system-wide\n\      configuration in " CONFFILE "\n\--nouserconf\n\      Don磘 read user config file in ~/.mtoolsfm\n\--save\n\      Save configuration in ~/.mtoolsfm when\n\      terminating\n\--nosave\n\      Don磘 save configuration in ~/.mtoolsfm when\n\      terminating (default)\n\--debug or -v\n\      Output debugging messages to stdout--help\n\      Display help\n"#else#define MFMOPTIONS "Options:\n\n\--nosysconf\n\      Don磘 attempt to read system-wide\n\      configuration in " CONFFILE "\n\--nouserconf\n\      Don磘 read user config file in ~/.mtoolsfm\n\--save\n\      Save configuration in ~/.mtoolsfm when\n\      terminating (default)\n\--nosave\n\      Don磘 save configuration in ~/.mtoolsfm when\n\      terminating\n\--debug or -v\n\      Output debugging messages to stdout--help\n\      Display help\n"#endif#define CONFDRIVES "This sets allowed driveletters for MToolsFM. Setting this helps you\n\not to select non-existing drives. If your sysadmin has set\n\up a system-wide configuration in \n\n" CONFFILE "\n\n\you do not need to set this. The configuration is saved in \n\n\~/.mtoolsfm \n\n\Give all drives available on your system. If you have drives\n\a: and b: available, you should enter ab, for example."#define CONFPATH "This sets the path for mtools-commands. If you do not fill this out, \n\n" MTOOLSDIR "\n\n\will be assumed for default. "#define MFMUSE "MToolsFM allows you to easily access dos-floppies using mtools.\n\The main window is split into two parts, each showing the contents of the\n\drive selected in the combobox. \"Harddisk\" means your UNIX filesystem.\n\You can select files with the mouse and copy them to the directory listed\n\in the other part of the window by right-clicking on the list and selecting\n\the copy command from the context-menu. You can also print files, make new\n\directories and delete files or directories. If you choose \"Text mode for copying\"\n\from the \"Options\" menu, files will be copied to / from floppy using appropriate\n\CR-LF translation for DOS text files. This is achieved using mcopy磗 -t flag.\n\n\Each of the two window halfs has got its own menu. If you have changed the\n\floppy in the drive, you can choose \"View -> Refresh\" to refresh the directory\n\listing. By clicking onto the column titles in the directory listing, you can\n\set the order in which MToolsFM displays files.\n"#define DIR_DEPTH 20struct _side{  GtkWidget *list;  GtkWidget *box;  GtkWidget *status;  char drive;  char *path[DIR_DEPTH];  int length;  guint context;  struct _side *other;  GdkColor *dircolor;  GdkColor *linkcolor;  GtkWidget *combo;  GList *comboglist;  long totsize;  GtkWidget *contextmenu;};typedef struct _dentry{  char name[256];  int dir;  long size;}dentry;typedef struct _side side;typedef struct _msgenv{  int *mvar;  int msg;}msgenv;#ifndef NOPIXMAPSstatic const char *xpm_dir[]={"20 16 5 1","c c #ffa858","# c #000000","b c #303030",". c None","a c #c00000","...........########.","....########aaaaaaa#","...#aaaaaaaaaaaaaaa#","..bbbbbbbbbbbbbbbaa#",".bcccccccccccccccba#",".bcccccccccccccccba#",".bcccccccccccccccba#",".bcccccccccccccccba#",".bcccccccccccccccba#",".bcccccccccccccccba#",".bcccccccccccccccba#",".bcccccccccccccccba#",".bcccccccccccccccb#.",".bcccccccccccccccb..","..bbbbbbbbbbbbbbb...","...................."};const char *xpm_file[]={"20 16 5 1","a c #808080","c c #000080","# c #000000",". c None","b c #ffffff","........##..........",".......#aa#.........","......#aaaa#........",".....#aaa##a#.......","....#aaa#bb#a#......","...#aaa#bbbb##......","..#aaa#bbcbbb#......","..#aa#bcbbcbbb#.....","...##bbbcbbcbb#.....","...#bbcbbcbbb#......","...#bbbcbbbb#.......","....#bbbcbb#........",".....#bbbb#.........","......#bb#..........",".......##...........","...................."};    static const char *xpm_mfm[]={"16 16 3 1","# c #000080","a c #800000",". c None","................","................","................","...#............","...##.##..##....","...#####.#####..","...###.###..##..","...###.##...##..","..###..##...##..","..##...##...##..","..##..##...##...",".###..##...##...",".##...##...##...","................","....aaaaaaaaa...",".aaaaaaaaa......"}; /* XPM */static const char*xpm_linkdir[]={"20 16 6 1","c c #ffa858","# c #000000","b c #303030","d c #0000ff",". c None","a c #c00000","...........########.","....########aaaaaaa#","...#aaaaaaaaaaaaaaa#","..bbbbbbbbbbbbbbbaa#",".bcccccccccccccccba#",".bccdddddddccccccba#",".bcccddddddccccccba#",".bccccdddddccccccba#",".bccccdddddccccccba#",".bcccddddddccccccba#",".bccddddcddccccccba#",".bcddddcccdccccccba#",".bddddcccccccccccb#.",".ddddccccccccccccb..","ddddbbbbbbbbbbbbb...","ddd................."};/* XPM */static const char*xpm_linkfile[]={"20 16 6 1","b c #808080","d c #000080","# c #000000","a c #ff8000",". c None","c c #ffffff","........##aaaaa.....",".......#bbaaaaaa....","......#bbaaaaaaaa...",".....#bbbaab#..aaa..","....#bbb#cc#b#.aaa..","...#bbb#cccc##.aaa..","..#bbb#ccdccc#.aaa..","..#bb#cdccdccc#aaa..","...##cccdccdcc#aaa..","...#ccdccdccc#.aaa..","...#cccdcccc#.aaaa..","....#cccdcc#..aaa...",".....#cccc#aaaaaaaaa","......#cc#..aaaaaaa.",".......##....aaaaa..","..............aaa..."};#endifGtkWidget *showdots,*textmode,*outtext,*dirfirst,*middlebox;GtkCListCompareFunc default_compare_func=0;#ifndef NOPIXMAPSGdkPixmap *dirpix;GdkBitmap *dirmask;GdkPixmap *filepix;GdkBitmap *filemask;GdkPixmap *linkdirpix;GdkBitmap *linkdirmask;GdkPixmap *linkfilepix;GdkBitmap *linkfilemask;GdkPixmap *mfmpix;GdkBitmap *mfmmask;#endifchar drives[27]="";char mpath[256]="";char mtoolscommand[256]="";char *homedir;int debug=0;/* should a configuration file ~/.mtoolsfm be written in user's homedir ? */#ifdef DEFAULT_NOSAVE    int nosave=1;#else    int nosave=0;#endif   int shallwecontinue(const char *,const char *);

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -