图形显示在dev c ++中的不同窗口bgi中 [英] graphics is displayed in different window bgi in dev c++

查看:65
本文介绍了图形显示在dev c ++中的不同窗口bgi中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用dev c ++,所以当我处理图形时,它会在不同的窗口中显示为bgi窗口,而正常输出窗口中的输入和输出功能我想要的是它们都在一个窗口中。我该怎么做?

i am using dev c++ ,so while i am working on graphics it gets diplayed in different window that is bgi window while input and output functions in normal output window what i want is both of them in one window . how do i do this ?

推荐答案

你不能。通过正常的输入输出我假设你的意思是通过scanf和printf(或类似的函数)使用stdin和stdout。


stdin,stdout和stderr必须被读/写到控制台窗口。大多数带有GUI的程序都没有控制台,因此无法显示标准输出或输入标准输入。

You can''t. By normal input output I assume you mean using stdin and stdout via scanf and printf (or similar functions).

stdin, stdout and stderr have to be read/written to a console window. Most programs with a GUI have no console and therefore can not display stdout or take stdin input.

Dev-C++, like most IDEs, takes extra steps to capture stdin/stdout/stderr and write them out to a Window in the IDE to provide extra information.


谢谢你的banfa ...但是我该怎么做?我正在进行一个测验游戏项目,需要输入以及图形背景和声音在同一个屏幕上..我将这样做...如果它不可能在开发c ++,我也尝试过turbo c ++但声音功能无法添加,因为无法打开windows.h时发生错误。否则graphis和输入操作只在一个窗口中进行。在turbo c ++ ..请帮我解决这个问题..如果我需要下载它请告诉我从哪里以及我需要执行哪些软件

是c ++项目
thank u banfa ...but then how do i do this? i am working on a quiz game project where input is required as well as graphics background and sound on the same screen ..how will i do this ...if it isnt possible in dev c++, i have tried turbo c++ also but sound function couldnt be added as error occured saying windows.h could not be opened. otherwise graphis and input operations are taking place in one window only .in turbo c++..please help me regarding this ..if i need to download it kindly tell me from where and which software will i need for carrying out th
is c++ project


不要打印你的输出字符串,使用WIN32 API调用将它们绘制到你的窗口,例如TextOut
Don''t printf your output strings, draw them to your window using WIN32 API calls such as TextOut


这篇关于图形显示在dev c ++中的不同窗口bgi中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆