?? vt100.h
字號:
/*****************************************************************************
* *
* ********** *
* ************ *
* *** *** *
* *** +++ *** *
* *** + + *** *
* *** + CHIPCON CC1010 *
* *** + + *** CUL SIMPLE PACKET PROTOCOL (SPP) *
* *** +++ *** VT100 HEADER FILE *
* *** *** *
* *********** *
* ********* *
* *
*****************************************************************************
* Internal header file for the CUL simple packet protocol. *
*****************************************************************************
* Author: JOL *
*****************************************************************************
* Revision history: *
* *
* $Log: vt100.h,v $
* Revision 1.1 2002/10/14 11:49:09 tos
* Initial version in CVS.
*
* *
****************************************************************************/
// VT100 MACROS
#define ESC 27
// Deleting text
#define VT100_CLEAR_SCREEN() printf("%c[2J", ESC)
#define VT100_CLEAR_LINE_RIGHT() printf("%c[0K", ESC)
#define VT100_CLEAR_LINE() printf("%c[2K", ESC)
#define VT100_CLEAR_SCREEN_DOWN() printf("\n%c[0J", ESC)
#define VT100_INSERT_BLANK_LINE() printf("\n%c[0K", ESC)
// Scroll
#define VT100_SET_SCROLL_REGION(startRow, endRow) printf("%c[%d;%dr", ESC, (int) (startRow), (int) (endRow));
#define VT100_SET_SCROLL_ALL() printf("%c[r", ESC)
#define VT100_SET_BGCOLOR(color, brightness) printf("%c[%d;%dm", ESC, (int)((color) + 40), (int)(brightness))
#define VT100_SET_FGCOLOR(color, brightness) printf("%c[%d;%dm", ESC, (int)((color) + 30), (int)(brightness))
#define VT100_SCROLL_UP() printf("%cM", ESC)
#define VT100_SCROLL_DOWN() printf("%cD", ESC)
// Jump
#define VT100_GO_TOP_LEFT() printf("%c[H", ESC)
#define VT100_GO_TO_POS(row, col) printf("%c[%d;%dH", ESC, (int) (row), (int) (col));
#define BLACK 0
#define RED 1
#define GREEN 2
#define YELLOW 3
#define BLUE 4
#define MAGENTA 5
#define CYAN 6
#define WHITE 7
#define BRIGHT 1
#define DIM 2
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -