Just installed Qt 6.8 and no terminal window when running program
-
Hi guys
Debian Bookworm
I installed Qt 6.8 and am now trying to run a simple console program
#include <QCoreApplication> #include <iostream> #include <string> void do_cpp(){ std::string name; std::cout << "Enter your name: "; std::cin >> name; std::cout << "Hello " << name << "\n"; } int main(int argc, char *argv[]) { QCoreApplication a(argc, argv); // something somethin do_cpp(); return a.exec(); } ```. The program builds but there is no console window. There is output from the first cout in the application output window but no other output after entering a name. I have unchecked 'use internal terminal' and also tried the different terminal options under 'Preferences->Environment->System' all to no avail. any help would be greatly appreciated
-
Hi and welcome to devnet,
Which OS are you on ?
Which version of Qt Creator are you using ?
Are you using qmake or cmake ? -
I have 'Preferences->Terminal->Use internal terminal' unchecked. I have tried both checked and unchecked with the same result.
for 'Preferences->Environment->System', i am using /usr/bin/xterm -e. I have tried the us/bin/x-terminal-emulator and /usr/bin/konsole options as well. -
@Madzi
Neither of those is my question or what it says in the first sentence of that link.When you select the Run in Terminal check box and run an application or the Open Terminal button to open a terminal, it opens as an output view.
The two things you refer to are options. You need to be running a terminal before they are relevant.
-