Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
scienceasdf authored Jun 27, 2016
1 parent 172e74d commit 65062c9
Show file tree
Hide file tree
Showing 2 changed files with 59 additions and 28 deletions.
8 changes: 7 additions & 1 deletion widget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
#include<QFileDialog>
#include<QDebug>
#include<QMessageBox>
#include<QProcess>

Widget::Widget(QWidget *parent) :
QWidget(parent),
Expand Down Expand Up @@ -280,7 +281,7 @@ void Widget::wheelEvent(QWheelEvent *event){
if(boolScale){
ratio=(event->delta()>0)?ratio*1.5:ratio/1.5;
update();
ui->scaleLabel->setText(tr("Y轴变形相对于X坐标放大倍数:")+QString::number((int)(ratio*5000)));
ui->scaleLabel->setText(tr("Y轴变形相对于X坐标放大倍数:")+QString::number((long long)(ratio*5000)));
}
}

Expand Down Expand Up @@ -467,3 +468,8 @@ void Widget::on_scaleOpt_clicked()
{
boolScale=!boolScale;
}

void Widget::on_sectionButton_clicked()
{
QProcess::startDetached(QCoreApplication::applicationDirPath()+"/sectionCalc",QStringList());
}
79 changes: 52 additions & 27 deletions widget.ui
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
<property name="geometry">
<rect>
<x>100</x>
<y>50</y>
<y>350</y>
<width>101</width>
<height>20</height>
</rect>
Expand All @@ -37,7 +37,7 @@
<property name="geometry">
<rect>
<x>100</x>
<y>10</y>
<y>310</y>
<width>101</width>
<height>20</height>
</rect>
Expand All @@ -50,7 +50,7 @@
<property name="geometry">
<rect>
<x>10</x>
<y>50</y>
<y>350</y>
<width>91</width>
<height>16</height>
</rect>
Expand All @@ -69,7 +69,7 @@
<property name="geometry">
<rect>
<x>10</x>
<y>10</y>
<y>310</y>
<width>91</width>
<height>21</height>
</rect>
Expand All @@ -88,7 +88,7 @@
<property name="geometry">
<rect>
<x>0</x>
<y>190</y>
<y>490</y>
<width>101</width>
<height>31</height>
</rect>
Expand All @@ -101,7 +101,7 @@
<property name="geometry">
<rect>
<x>90</x>
<y>160</y>
<y>460</y>
<width>111</width>
<height>21</height>
</rect>
Expand Down Expand Up @@ -131,7 +131,7 @@
<property name="geometry">
<rect>
<x>10</x>
<y>290</y>
<y>10</y>
<width>54</width>
<height>21</height>
</rect>
Expand All @@ -144,7 +144,7 @@
<property name="geometry">
<rect>
<x>100</x>
<y>290</y>
<y>10</y>
<width>101</width>
<height>20</height>
</rect>
Expand All @@ -157,7 +157,7 @@
<property name="geometry">
<rect>
<x>100</x>
<y>330</y>
<y>50</y>
<width>101</width>
<height>20</height>
</rect>
Expand All @@ -170,7 +170,7 @@
<property name="geometry">
<rect>
<x>10</x>
<y>330</y>
<y>50</y>
<width>81</width>
<height>21</height>
</rect>
Expand All @@ -183,7 +183,7 @@
<property name="geometry">
<rect>
<x>10</x>
<y>370</y>
<y>90</y>
<width>54</width>
<height>21</height>
</rect>
Expand All @@ -196,7 +196,7 @@
<property name="geometry">
<rect>
<x>100</x>
<y>370</y>
<y>90</y>
<width>101</width>
<height>20</height>
</rect>
Expand All @@ -209,7 +209,7 @@
<property name="geometry">
<rect>
<x>10</x>
<y>90</y>
<y>390</y>
<width>91</width>
<height>21</height>
</rect>
Expand All @@ -231,7 +231,7 @@
<property name="geometry">
<rect>
<x>100</x>
<y>90</y>
<y>390</y>
<width>101</width>
<height>20</height>
</rect>
Expand All @@ -244,7 +244,7 @@
<property name="geometry">
<rect>
<x>10</x>
<y>130</y>
<y>430</y>
<width>91</width>
<height>16</height>
</rect>
Expand All @@ -266,7 +266,7 @@
<property name="geometry">
<rect>
<x>100</x>
<y>130</y>
<y>430</y>
<width>101</width>
<height>20</height>
</rect>
Expand All @@ -279,7 +279,7 @@
<property name="geometry">
<rect>
<x>100</x>
<y>190</y>
<y>490</y>
<width>101</width>
<height>31</height>
</rect>
Expand All @@ -292,7 +292,7 @@
<property name="geometry">
<rect>
<x>10</x>
<y>410</y>
<y>160</y>
<width>81</width>
<height>21</height>
</rect>
Expand All @@ -305,7 +305,7 @@
<property name="geometry">
<rect>
<x>100</x>
<y>410</y>
<y>160</y>
<width>101</width>
<height>20</height>
</rect>
Expand All @@ -318,7 +318,7 @@
<property name="geometry">
<rect>
<x>90</x>
<y>440</y>
<y>190</y>
<width>111</width>
<height>21</height>
</rect>
Expand All @@ -343,8 +343,8 @@
<property name="geometry">
<rect>
<x>3</x>
<y>510</y>
<width>231</width>
<y>230</y>
<width>241</width>
<height>20</height>
</rect>
</property>
Expand All @@ -355,8 +355,8 @@
<widget class="QRadioButton" name="scaleOpt">
<property name="geometry">
<rect>
<x>50</x>
<y>560</y>
<x>60</x>
<y>260</y>
<width>89</width>
<height>16</height>
</rect>
Expand Down Expand Up @@ -436,8 +436,8 @@
<widget class="QLabel" name="label_9">
<property name="geometry">
<rect>
<x>13</x>
<y>230</y>
<x>10</x>
<y>520</y>
<width>181</width>
<height>41</height>
</rect>
Expand Down Expand Up @@ -598,6 +598,29 @@
<bool>true</bool>
</property>
</widget>
<widget class="QCommandLinkButton" name="sectionButton">
<property name="geometry">
<rect>
<x>11</x>
<y>110</y>
<width>191</width>
<height>41</height>
</rect>
</property>
<property name="text">
<string>打开截面几何计算器</string>
</property>
<property name="icon">
<iconset resource="resources.qrc">
<normaloff>:/1074273.png</normaloff>:/1074273.png</iconset>
</property>
<property name="iconSize">
<size>
<width>28</width>
<height>28</height>
</size>
</property>
</widget>
</widget>
<layoutdefault spacing="6" margin="11"/>
<tabstops>
Expand All @@ -612,6 +635,8 @@
<tabstop>ElaText</tabstop>
<tabstop>IzText</tabstop>
</tabstops>
<resources/>
<resources>
<include location="resources.qrc"/>
</resources>
<connections/>
</ui>

0 comments on commit 65062c9

Please sign in to comment.