📄 myhead.h
字号:
/* ****************** Common header file ****************** *//* Before include this file, you may define MYDEBUG */#ifndef _MYHEAD_H_#define _MYHEAD_H_/*ANSI headers */#include <assert.h>#include <ctype.h>#include <errno.h>#include <float.h>#include <limits.h>#include <locale.h>#include <math.h>#include <setjmp.h>#include <signal.h>#include <stdarg.h>#include <stddef.h>#include <stdio.h>#include <stdlib.h>#include <string.h>#include <time.h>/*Linux headers */#include <fcntl.h>#include <getopt.h>#include <signal.h>#include <sys/types.h>#include <sys/ioctl.h>#include <sys/ipc.h>#include <sys/msg.h>#include <sys/mman.h>#include <sys/stat.h>#include <unistd.h>extern char *optarg;extern int optind, opterr, optopt;extern int errno;/*application libraries headers*///#include <readline/readline.h>//#include <readline/history.h>//char * readline (const char *prompt);//#define MYDEBUG#if defined MYDEBUG//#define PDEBUG(fmt, args...) printf(fmt, ##args)#define PDEBUG(args...) fprintf(stderr,args)#define PFUNC() PDEBUG("<%s:%s:%d> enter\n", __FILE__, __FUNCTION__);#define PAUSE() do{fflush(stdin); fprintf(stderr,"<%s><%d>press any key to continue\n",__FUNCTION__, __LINE__); getchar();}while(0)#define PLINE fprintf(stderr,"<%s:%s:%d>\n", __FILE__, __FUNCTION__, __LINE__)#else#define PDEBUG(fmt, args...)#define PFUNC()#define PLINE#define PAUSE()#endif//void show_prog(int prog, int max, char *head);/* Typedefs for integer types */typedef unsigned char U8; /* unsigned 8 bit data */typedef unsigned short U16; /* unsigned 16 bit data */typedef unsigned int U32; /* unsigned 32 bit data */typedef char S8; /* signed 8 bit data */typedef short S16; /* signed 16 bit data */typedef long S32; /* signed 32 bit data */typedef U8 *P_U8; /* unsigned 8 bit data */typedef U16 *P_U16; /* unsigned 16 bit data */typedef U32 *P_U32; /* unsigned 32 bit data */typedef S8 *P_S8; /* signed 8 bit data */typedef S16 *P_S16; /* signed 16 bit data */typedef S32 *P_S32; /* signed 32 bit data */typedef U16 TEXT; /* 16-bit text data */typedef P_U16 P_TEXT; /* 16-bit text data */typedef U8 BOOL; /* Boolean, TRUE/FALSE */typedef void VOID; /* void */typedef void *P_VOID; /* pointer to void */typedef signed char BOOLEAN;typedef unsigned char UINT8;typedef signed char SINT8;typedef unsigned short UINT16;typedef signed short SINT16;typedef unsigned long UINT32;typedef signed long SINT32;typedef volatile BOOLEAN VBOOLEAN;typedef volatile UINT8 VUINT8;typedef volatile SINT8 VSINT8;typedef volatile UINT16 VUINT16;typedef volatile SINT16 VSINT16;typedef volatile UINT32 VUINT32;typedef volatile SINT32 VSINT32;#define PRINT_VERSION printf("Build time: %s, %s\n", __DATE__, __TIME__)#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -