📄 cursor.c
字号:
/* Compiled by DJGPP */#include <stdio.h>#include <pc.h>void update_cursor(int row, int col){ USHORT position=(row*80) + col; /* cursor LOW port to VGA INDEX register */ outb(0x3D4, 0x0F); outb(0x3D5, (UCHAR)(position&0xFF)); /* cursor HIGH port to vga INDEX register */ outb(0x3D4, 0x0E); outb(0x3D5, (UCHAR)((position>>8)&0xFF));}void main(){ clrscr(); update_cursor(10, 10);}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -