funtc97b.dat
来自「C++指令字典 一个方便的软件 用于C++指令的查询」· DAT 代码 · 共 29 行
DAT
29 行
#include <graphics.h>
#include <stdlib.h>
#include <stdio.h>
#include <conio.h>
int main(void)
{
int gdriver = DETECT, gmode, errorcode;
int midx, midy, i;
initgraph(&gdriver, &gmode, );
errorcode = graphresult();
if (errorcode != grOk)
{
printf("Graphics error: %s", grapherrormsg(errorcode));
printf("Press any key to halt:");
getch();
exit(1);
}
midx = getmaxx() / 2;
midy = getmaxy() / 2;
for (i=SOLID_FILL; i<USER_FILL; i++)
{
setfillstyle(i, getmaxcolor());
bar(midx-50, midy-50, midx+50,midy+50);
getch();
}
closegraph();
return 0;
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?