?? 1.txt
字號:
/* gui.c: Graphics demos * * Programmed By Chen Yang (support@hhcn.com) * * * 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. */#include <stdio.h> /* Standard input/output definitions */#include <string.h> /* String function definitions */#include <unistd.h> /* UNIX standard function definitions */#include <fcntl.h> /* File control definitions */#include <errno.h> /* Error number definitions */#include <termios.h> /* POSIX terminal control definitions */#include<sys/types.h>#include<sys/stat.h>#include <stdlib.h>#include "gui.h"void delay(){int i,j; for(i=0;i<10000;i++) for(j=0;j<2000;j++) {} }main(int argc,char*argv[]){ short i,j,w,h; struct stat st; int color0,filelength; PatternIndex p1=BlackPattern; char buf[20]={0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19}; char buf1[700000]; short *o;int *p;long *q;char *c; FILE *fp; initgraph(); if((fp=fopen("test3.bmp","r"))==NULL) {printf("Can't find the file"); return 1; } stat("test3.bmp",&st); filelength=st.st_size; clearscreen(); fillrect(10,10,100,100); /* clearscreen(); textout(0,130,"中國計量學院學生\n00算(5)\nA Student"); delay(); clearscreen(); fread(buf1,1,filelength,fp); ShowBuf(buf1,0,0);*//*ShowBMP("13.bmp",0,0);delay();clearscreen();ShowBMP("7.bmp",0,0);delay();clearscreen();ShowBMP("test3.bmp",0,0);*/}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -