Commit 232f80348d8349fc5a36a8c86c9822d1c7f86a74
1 parent
5fb07bda
Initial setup
Showing
5 changed files
with
128 additions
and
1 deletions
.gitignore
0 → 100644
CMakeLists.txt
| ... | ... | @@ -18,11 +18,17 @@ include(compiler) |
| 18 | 18 | |
| 19 | 19 | set(SRC_LIST |
| 20 | 20 | ${CMAKE_CURRENT_SOURCE_DIR}/main.cpp |
| 21 | + ${CMAKE_CURRENT_SOURCE_DIR}/CalcPi.cpp | |
| 22 | +) | |
| 23 | + | |
| 24 | +include(qtuic) | |
| 25 | +create_ui(SRC_LIST UIC_LIST | |
| 26 | + ${CMAKE_CURRENT_SOURCE_DIR}/CalcPiForm.ui | |
| 21 | 27 | ) |
| 22 | 28 | |
| 23 | 29 | include(qtmoc) |
| 24 | 30 | create_mocs( SRC_LIST MOC_LIST |
| 25 | - | |
| 31 | + ${CMAKE_CURRENT_SOURCE_DIR}/CalcPi.h | |
| 26 | 32 | ) |
| 27 | 33 | |
| 28 | 34 | add_executable( ${PROJECT_NAME} | ... | ... |
CalcPi.h
CalcPiForm.ui
0 → 100644
| 1 | +<?xml version="1.0" encoding="UTF-8"?> | |
| 2 | +<ui version="4.0"> | |
| 3 | + <class>Form</class> | |
| 4 | + <widget class="QWidget" name="Form"> | |
| 5 | + <property name="geometry"> | |
| 6 | + <rect> | |
| 7 | + <x>0</x> | |
| 8 | + <y>0</y> | |
| 9 | + <width>786</width> | |
| 10 | + <height>481</height> | |
| 11 | + </rect> | |
| 12 | + </property> | |
| 13 | + <property name="windowTitle"> | |
| 14 | + <string>Form</string> | |
| 15 | + </property> | |
| 16 | + <layout class="QGridLayout" name="gridLayout"> | |
| 17 | + <item row="0" column="0"> | |
| 18 | + <layout class="QVBoxLayout" name="verticalLayout"> | |
| 19 | + <item> | |
| 20 | + <widget class="QLabel" name="label"> | |
| 21 | + <property name="text"> | |
| 22 | + <string>Run</string> | |
| 23 | + </property> | |
| 24 | + <property name="alignment"> | |
| 25 | + <set>Qt::AlignBottom|Qt::AlignHCenter</set> | |
| 26 | + </property> | |
| 27 | + </widget> | |
| 28 | + </item> | |
| 29 | + <item> | |
| 30 | + <layout class="QHBoxLayout" name="horizontalLayout"> | |
| 31 | + <item> | |
| 32 | + <widget class="QLCDNumber" name="lcdRunNumber"> | |
| 33 | + <property name="digitCount"> | |
| 34 | + <number>55</number> | |
| 35 | + </property> | |
| 36 | + <property name="segmentStyle"> | |
| 37 | + <enum>QLCDNumber::Flat</enum> | |
| 38 | + </property> | |
| 39 | + </widget> | |
| 40 | + </item> | |
| 41 | + </layout> | |
| 42 | + </item> | |
| 43 | + <item> | |
| 44 | + <widget class="QLabel" name="label_2"> | |
| 45 | + <property name="text"> | |
| 46 | + <string>Value of Pi</string> | |
| 47 | + </property> | |
| 48 | + <property name="alignment"> | |
| 49 | + <set>Qt::AlignBottom|Qt::AlignHCenter</set> | |
| 50 | + </property> | |
| 51 | + </widget> | |
| 52 | + </item> | |
| 53 | + <item> | |
| 54 | + <layout class="QHBoxLayout" name="horizontalLayout_2"> | |
| 55 | + <item> | |
| 56 | + <widget class="QLCDNumber" name="lcdValue"> | |
| 57 | + <property name="smallDecimalPoint"> | |
| 58 | + <bool>true</bool> | |
| 59 | + </property> | |
| 60 | + <property name="digitCount"> | |
| 61 | + <number>55</number> | |
| 62 | + </property> | |
| 63 | + <property name="segmentStyle"> | |
| 64 | + <enum>QLCDNumber::Flat</enum> | |
| 65 | + </property> | |
| 66 | + <property name="value" stdset="0"> | |
| 67 | + <double>0.000000000000000</double> | |
| 68 | + </property> | |
| 69 | + <property name="intValue" stdset="0"> | |
| 70 | + <number>0</number> | |
| 71 | + </property> | |
| 72 | + </widget> | |
| 73 | + </item> | |
| 74 | + </layout> | |
| 75 | + </item> | |
| 76 | + <item> | |
| 77 | + <widget class="QProgressBar" name="pbRunProgress"> | |
| 78 | + <property name="value"> | |
| 79 | + <number>24</number> | |
| 80 | + </property> | |
| 81 | + <property name="format"> | |
| 82 | + <string>%p</string> | |
| 83 | + </property> | |
| 84 | + </widget> | |
| 85 | + </item> | |
| 86 | + </layout> | |
| 87 | + </item> | |
| 88 | + <item row="1" column="0"> | |
| 89 | + <widget class="QPushButton" name="cmdRunButton"> | |
| 90 | + <property name="text"> | |
| 91 | + <string>Run</string> | |
| 92 | + </property> | |
| 93 | + </widget> | |
| 94 | + </item> | |
| 95 | + </layout> | |
| 96 | + </widget> | |
| 97 | + <resources/> | |
| 98 | + <connections/> | |
| 99 | +</ui> | ... | ... |