資源簡介
c++編寫的QT平臺上的計算器小程序,跟windows7上自帶的一樣,并且可以三個計算器切換,原創。

代碼片段和文件信息
#include?“alluse.h“
#include?
#include?
#include
alluse::alluse()
{
????QPushButton?*?pMCBtn?=?new?QPushButton(“MC“);
????QPushButton?*?pMRBtn?=?new?QPushButton(“MR“);
????QPushButton?*?pMSBtn?=?new?QPushButton(“MS“);
????QPushButton?*?pMPlusBtn?=?new?QPushButton(“M+“);
????QPushButton?*?pMMinusBtn?=?new?QPushButton(“M-“);
????QPushButton?*?pBackSpaceBtn?=?new?QPushButton(QStringLiteral(“←“));
????QPushButton?*?pCEBtn?=?new?QPushButton(“CE“);
????QPushButton?*?pCBtn?=?new?QPushButton(“C“);
????QPushButton?*?pPMBtn?=?new?QPushButton(QStringLiteral(“±“));
????QPushButton?*?pRadicalBtn?=?new?QPushButton(QStringLiteral(“√“));
????QPushButton?*?p0Btn?=?new?QPushButton(“0“);
????QPushButton?*?p1Btn?=?new?QPushButton(“1“);
????QPushButton?*?p2Btn?=?new?QPushButton(“2“);
????QPushButton?*?p3Btn?=?new?QPushButton(“3“);
????QPushButton?*?p4Btn?=?new?QPushButton(“4“);
????QPushButton?*?p5Btn?=?new?QPushButton(“5“);
????QPushButton?*?p6Btn?=?new?QPushButton(“6“);
????QPushButton?*?p7Btn?=?new?QPushButton(“7“);
????QPushButton?*?p8Btn?=?new?QPushButton(“8“);
????QPushButton?*?p9Btn?=?new?QPushButton(“9“);
????QPushButton?*?pDivideBtn?=?new?QPushButton(“/“);
????QPushButton?*?pRemainderBtn?=?new?QPushButton(“%“);
????QPushButton?*?pReciprocalBtn?=?new?QPushButton(“1/x“);
????QPushButton?*?pMultiplyBtn?=?new?QPushButton(“*“);
????QPushButton?*?pAddBtn?=?new?QPushButton(“+“);
????QPushButton?*?pMinusBtn?=?new?QPushButton(“-“);
????QPushButton?*?pEqualBtn?=?new?QPushButton(“=“);
????QPushButton?*?pPointBtn?=?new?QPushButton(“.“);
????this->addWidget(pMCBtn?0?0);
????this->addWidget(pMRBtn?0?1);
????this->addWidget(pMSBtn?0?2);
????this->addWidget(pMPlusBtn?0?3);
????this->addWidget(pMMinusBtn?0?4);
????this->addWidget(pBackSpaceBtn?1?0);
????this->addWidget(pCEBtn?1?1);
????this->addWidget(pCBtn?1?2);
????this->addWidget(pPMBtn?1?3);
????this->addWidget(pRadicalBtn?1?4);
????this->addWidget(p7Btn?2?0);
????this->addWidget(p8Btn?2?1);
????this->addWidget(p9Btn?2?2);
????this->addWidget(pDivideBtn?2?3);
????this->addWidget(pRemainderBtn?2?4);
????this->addWidget(p4Btn?3?0);
????this->addWidget(p5Btn?3?1);
????this->addWidget(p6Btn?3?2);
????this->addWidget(pMultiplyBtn?3?3);
????this->addWidget(pReciprocalBtn?3?4);
????this->addWidget(p1Btn?4?0);
????this->addWidget(p2Btn?4?1);
????this->addWidget(p3Btn?4?2);
????this->addWidget(pMinusBtn?4?3);
????this->addWidget(pEqualBtn?4?4?2?1);
????pEqualBtn->setSizePolicy(QSizePolicy::Expanding?QSizePolicy::Expanding);
????this->addWidget(p0Btn?5?0?1?2);
????p0Btn->setSizePolicy(QSizePolicy::Expanding?QSizePolicy::Expanding);
????this->addWidget(pPointBtn?5?2);
????this->addWidget(pAddBtn?5?3);
????pMCBtn->setSizePolicy(QSizePolicy::Expanding?QSizePolicy::Expanding);
????pMRBtn->setSizePolicy(QSizePolicy::Expanding?QSizePolicy::Expanding);
????pMSBtn->setS
?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----
?????目錄???????????0??2018-08-21?16:26??ThreeCalculators\
?????文件?????????523??2018-08-08?17:13??ThreeCalculators\ThreeCalculators.pro
?????文件???????18776??2018-08-21?16:26??ThreeCalculators\ThreeCalculators.pro.user
?????文件????????4929??2018-08-08?17:14??ThreeCalculators\alluse.cpp
?????文件?????????152??2018-08-08?17:14??ThreeCalculators\alluse.h
?????文件?????????952??2018-08-08?17:22??ThreeCalculators\main.cpp
?????文件????????1991??2018-08-08?17:22??ThreeCalculators\mainwindow.cpp
?????文件?????????480??2018-08-08?17:20??ThreeCalculators\mainwindow.h
?????文件?????????654??2018-08-08?17:00??ThreeCalculators\mainwindow.ui
?????文件????????7164??2018-08-08?17:18??ThreeCalculators\programer.cpp
?????文件?????????166??2018-08-08?17:19??ThreeCalculators\programer.h
?????文件????????6103??2018-08-08?17:22??ThreeCalculators\science.cpp
?????文件?????????160??2018-08-08?17:14??ThreeCalculators\science.h
?????文件?????????560??2018-08-08?17:33??ThreeCalculators\standard.cpp
?????文件?????????164??2018-08-08?17:14??ThreeCalculators\standard.h
評論
共有 條評論