⑴ 用c语言ege制作菜单,求代码
#include#include#include#includeusingnamespacestd;voidxuanzepaixu()//选择排序函数{printf("待添加,请按任意键继续");getchar();}voiderfenpaixu()//二分查找函数{printf("待添加,请按任意键继续");getchar();}voidmenu()//主菜单{system("cls");//清屏printf("\n\t\t\t菜单\n");printf("\t\t\t#***********************#\n");printf("\t\t\t#1选择排序#\n");printf("\t\t\t#2二分查找#\n");printf("\t\t\t#3返回#\n");printf("\t\t\t#4---关闭#\n");printf("\t\t\t#***********************#\n");printf("\t\t\t请选择(1-4)=:");}voidmain(){charselect;while(1){menu();system("COLOR9f");scanf("%c",&select);if(select=='3')break;//返回上级菜单else{getchar();//读入回车符if(!isdigit(select))//如果不是数字字符{printf("\n\7Yourselectmaybewrong,mustenterthedigit!\n");_getch();}else{switch(select){case'1':xuanzepaixu();break;case'2':erfenpaixu();break;case'4':exit(0);//直接退出default:{printf("\n\7\7Yourselecteddigitmaybewrong,selectagain!\n");_getch();break;}}}}}}
⑵ c语言ege输入函数
ege仅有那一个输入函数 inputbox_getline
⑶ 关于C语言的EGE字体问题
你把想要设置的字体放到winodws系统目录下的字体库就行了。
有哪些。。你打开word 字体格式选择那块就能看到了
⑷ C语言 用devc++编写一个模拟时钟,最简单那种就行,但要能在devc++上运行。
#include<iostream>
#include<windows.h>
usingnamespacestd;
classClock{
public:
Clock(shorth=0,shortm=0,shorts=0):h(h),m(m),s(s){
}
voiddisplayTime();
private:
shorth;
shortm;
shorts;
};voidClock::displayTime(){
while(true){
cout<<h<<':'<<m<<':'<<s<<"";
Sleep(1000);//一秒更新一次
cout<<' ';
if(!(s=++s%60))
if(!(m=++m%60))
h=++h%24;
}
}intmain()
{
ClockA(12,20,30);//初始时间
A.displayTime();//更新函数
return0;
}
/*
12:20:30
*/
⑸ 如何使用ege做c程序中计算器界面
setbkcolor(WHITE);
setfillcolor(BLUE);
bar(50,20,400,400);
setfillcolor(WHITE);
bar(100,25,240,50);//复数 ai
bar(260,25,370,50);//复数b
bar(100,60,370,90);//其他运算结果框
setfillcolor(RED);
bar(100,100,154,160);//建造键盘框(二进制,八进制,十六进制是无效键!!!
bar(154,100,208,160);
bar(208,100,262,160);
bar(262,100,316,160);
bar(316,100,370,160);
bar(100,160,154,220);
bar(154,154,208,220);
bar(208,154,262,220);
bar(262,154,316,220);
bar(316,154,370,220);
bar(100,220,154,280);
bar(154,220,208,280);
bar(208,220,262,280);
bar(262,220,316,280);
bar(316,220,370,280);
bar(100,280,154,340);
bar(154,280,208,340);
bar(208,280,262,340);
bar(262,280,316,340);
bar(316,280,370,340);
bar(100,340,154,400);
bar(154,340,154,400);
bar(208,340,262,400);
bar(262,340,316,400);
bar(316,340,370,400);
bar(154,340,208,400);
setcolor(RED);
line(100,100,100,400);
line(100,100,370,100);
line(100,160,370,160);
line(100,220,370,220);
line(100,280,370,280);
line(100,340,370,340);
line(100,400,370,400);
line(100,60,370,60);
line(100,90,370,90);
line(100,60,100,90);
line(370,60,370,90);
line(156,100,156,400);
line(212,100,212,400);
line(268,100,268,400);
line(324,100,324,400);
line(370,100,370,400);
setcolor(BLACK);
setfont(32, 0,"宋体");
outtextxy(105,105,"sin");
outtextxy(161,105,"cos");
outtextxy(217,105,"tan");
setfont(35,7,"楷体");
outtextxy(273,105,"八进制");
outtextxy(273,165,"二进制");
outtextxy(273,225,"16进制");
outtextxy(273,285,"复数");
outtextxy(273,345,"开方");
setfont(55,0,"楷体");
outtextxy(329,105,"+");
outtextxy(329,165,"-");
outtextxy(329,225,"*");
outtextxy(329,285,"/");
outtextxy(329,345,"=");
setcolor(BLACK);
setfont(50,0,"楷体");
outtextxy(105,165,"1");
outtextxy(105,225,"4");
outtextxy(105,285,"7");
outtextxy(105,345,"#");
outtextxy(161,165,"2");
outtextxy(161,225,"5");
outtextxy(161,285,"8");
outtextxy(161,345,"0");
outtextxy(217,165,"3");
outtextxy(217,225,"6");
outtextxy(217,285,"9");
outtextxy(217,345,"!");
}
getch();
cleardevice();
getch();
closegraph();
return 0;
}
}
⑹ c语言使用ege库如何实现两个图像的交换
应该是可以的。
getimage是从文件等类型中获取图像,不能从PIMAGE类型中获取图像的
⑺ c语言怎么用EGE 图形库
1、EGE(Easy Graphics Engine),是windows下的简易绘图库,是一个类似BGI(graphics.h)的面向C/C++语言新手的图形库,它的目标也是为了替代TC的BGI库而存在。
2、它的使用方法与TC中的graphics.h相当接近,对新手来说,简单,友好,容易上手,免费开源,而且因为接口意义直观,即使是之前完全没有接触过图形编程的,也能迅速学会基本的绘图。 目前,EGE图形库已经完美支持VC6, VC2008, VC2010, C-Free, DevCpp, Code::Blocks, wxDev, Eclipse for C/C++等IDE,即支持使用MinGW为编译环境的IDE。如果你需要在VC下使用graphics.h,那么ege将会是很好的替代品。
⑻ 关于C语言、EGE图形界面的问题
图形界面是无法使用printf、cls以及其他命令行模式下的系统调用的,所以除非全用图形界面的方式实现,否则没有办法⋯⋯
⑼ c语言ege图形库
链接器工具警告 LNK4098默认库“msvcrt.lib”与其他库的使用冲。意味着您在应用程序中,试图链接不同类型的运行库,例如混用了单线程运行库和多线程运行库。所以,请确认所有的项目以及文件都链接同一个运行库。你可以通过右键项目节点,并在C/C++->代码生成->运行库选项中设置您的运行库。
此外你还可以通过设置/NODEFAULTLIB选项来忽略此警告,你可以通过以下步骤来设置:
1.打开该项目的“属性页”对话框。。
2.单击“链接器”文件夹。
3.单击“输入”属性页。
4.选择“忽略所有默认库”属性或在“忽略指定库”属性中指定要忽略的库列表。“命令行”属性页将显示对这些属性所做的更改的效果
参考资料:http://social.msdn.microsoft.com/Forums/en-US/ccc0c160-5812-4e36-9fe9-12627849b10a/vs2008sdlsdl