File tree Expand file tree Collapse file tree 1 file changed +64
-0
lines changed
Qt.Widgets/Controls/Widget Expand file tree Collapse file tree 1 file changed +64
-0
lines changed Original file line number Diff line number Diff line change
1
+ # Widget
2
+
3
+ Shows how to create a widget with QWidget.
4
+
5
+ ## Sources
6
+
7
+ [ src/Widget.h] ( src/Widget.h )
8
+
9
+ [ src/Widget.cpp] ( src/Widget.cpp )
10
+
11
+ [ CMakeLists.txt] ( CMakeLists.txt )
12
+
13
+ ## Output
14
+
15
+ ![ Screenshot] ( ../../../docs/Pictures/Widget.png )
16
+
17
+ ## Generate and build
18
+
19
+ ### Qt Creator
20
+
21
+ To build these projects, open ` Widget.pro ` file with Qt Creator.
22
+
23
+ ### CMake
24
+
25
+ To build this project, open "Terminal" and type following lines:
26
+
27
+ Set ` CMAKE_PREFIX_PATH ` with Qt6 install path.
28
+
29
+ #### Windows :
30
+
31
+ ``` cmake
32
+ mkdir build
33
+ cd build
34
+ cmake ..
35
+ start ./Widget.sln
36
+ ```
37
+
38
+ #### macOS :
39
+
40
+ ``` cmake
41
+ mkdir build
42
+ cd build
43
+ cmake .. -G "Xcode"
44
+ open ./Widget.xcodeproj
45
+ ```
46
+
47
+ #### Linux with Code::Blocks :
48
+
49
+ ``` cmake
50
+ mkdir build
51
+ cd build
52
+ cmake .. -G "CodeBlocks - Unix Makefiles"
53
+ xdg-open ./Widget.cbp > /dev/null 2>&1
54
+ ```
55
+
56
+ #### Linux :
57
+
58
+ ``` cmake
59
+ mkdir build
60
+ cd build
61
+ cmake ..
62
+ cmake --build . --config Debug
63
+ ./Widget
64
+ ```
You can’t perform that action at this time.
0 commit comments