D
D
David It2022-03-25 08:26:27
Qt
David It, 2022-03-25 08:26:27

How to run a program in QT creator?

Hello. I installed the program according to this instruction https://redos.red-soft.ru/base/arm/ide/qt-creator/...
Now, firstly, I just try to run the first code through QML:
man.qml:

import QtQuick 2.12
import QtQuick.Window 2.12
Window {
    id: root
    width: 640
    height: 480
    visible: true
    title: qsTr("Hello World")
    Tile {
        width: root.width / 4
        height: root.height / 4
    }
}

Tile.qml:
import QtQuick 2.0
Rectangle {
    id: root
    color: "lightgreen"
    radius: 10
    border.color: "black"
    border.width: 1
    Text {
        id: _firstText
        anchors.centerIn: root
        text: "1"
        font {
            pointSize: Math.min(root.width, root.height) / 3
            bold: true
        }
    }
}

It gives the following error:
Project ERROR: Unknown module(s) in QT: quick
And the second code through the console application:
main.cpp:
#include <iostream>
using namespace std;
int main() {
    cout << "Hello wolrd" << endl;
    return 0;
}

Gives this error:
13:23:56: Starting /home/[email protected]/Desktop/Hello/git/Cpp/Test2/build-Test-Desktop-Debug/Test ...
13:23:56: An unknown error in the process occurred.
13:23:56: Cannot start the terminal emulator "xterm", change the setting in the Environment options.
13:23:56: /home/[email protected]/Desktop/Hello/git/Cpp/Test2/build-Test-Desktop-Debug/Test exited with code -1
What to do? Everything worked great on Windows.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexander Ananiev, 2022-03-25
@SaNNy32

https://stackoverflow.com/questions/39390824/error...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question