только кучу ошибок выводит, все такого типа, даже не знаю что это
ошибка: expected constructor, destructor, or type conversion before '->' token
может код поможет
#include "widget.h"
#include "math.h"
#include "ui_widget.h"
#include <QLineEdit>
#include <QCheckBox>
Widget::Widget(QWidget *parent) : QWidget(parent),
ui(new Ui::Widget)
{
ui->setupUi(this);
ui->doubleSpinBox->inputContext();
ui->doubleSpinBox_2->inputContext();
ui->doubleSpinBox_3->inputContext();
ui->doubleSpinBox_4->inputContext();
ui->doubleSpinBox_5->inputContext();
ui->doubleSpinBox_6->inputContext();
ui->doubleSpinBox_7->inputContext();
ui->doubleSpinBox_8->inputContext();
ui->lineEdit->setReadOnly(true);
ui->lineEdit_2->setReadOnly(true);
ui->lineEdit_3->setReadOnly(true);
ui->lineEdit_4->setReadOnly(true);
ui->lineEdit_5->setReadOnly(true);
ui->lineEdit_6->setReadOnly(true);
ui->lineEdit_7->setReadOnly(true);
ui->lineEdit_8->setReadOnly(true);
ui->lineEdit_9->setReadOnly(true);
ui->lineEdit_10->setReadOnly(true);
ui->lineEdit_11->setReadOnly(true);
ui->lineEdit_12->setReadOnly(true);
ui->lineEdit_13->setReadOnly(true);
ui->checkBox->setChecked(false);
ui->checkBox_2->setChecked(false);
ui->checkBox_3->setChecked(false);
ui->checkBox_4->setChecked(false);
ui->checkBox_5->setChecked(false);
ui->checkBox_6->setChecked(false);
connect(ui->pushButton, SIGNAL( clicked() ), SLOT(Rasschitat()));
}
Widget::~Widget(){
delete ui;
}
void Widget::Rasschitat(){
double a,b,c,d,e,i,f,g,j,h;
a=0.05; b=2;c=0.25;d=0.35;e=0.1;i=0.4;f=0.5;g=4;j=0.15;h=1.5;
if(ui->checkBox->isChecked()){
ui->lineEdit_5->setText(QString::number(ui->doubleSpinBox_4->text().toDouble() * c));
else;
ui->lineEdit_5->clear();
}
ui->lineEdit->setText(QString::number(ui->doubleSpinBox->text().toDouble() * ui->doubleSpinBox_2->text().toDouble() * ui->doubleSpinBox_3->text().toDouble()));
ui->lineEdit_2->setText(QString::number(ui->doubleSpinBox_9->text().toDouble() * ui->doubleSpinBox_2->text().toDouble() * ui->doubleSpinBox_3->text().toDouble()));
ui->lineEdit_3->setText(QString::number(ui->doubleSpinBox_10->text().toDouble() * ui->doubleSpinBox_5->text().toDouble() * ui->doubleSpinBox_3->text().toDouble()));
ui->lineEdit_4->setText(QString::number(ui->doubleSpinBox_2->text().toDouble() * ui->lineEdit->text().toDouble() * a ));
ui->lineEdit_14->setText(QString::number(ui->lineEdit_4->text().toDouble() + b * ui->doubleSpinBox_2->text().toDouble()));
ui->lineEdit_6->setText(QString::number(ui->doubleSpinBox_4->text().toDouble() * d));
ui->lineEdit_7->setText(QString::number(ui->doubleSpinBox_4->text().toDouble() * ui->doubleSpinBox_6->text().toDouble() * e));
ui->lineEdit_8->setText(QString::number(ui->doubleSpinBox_4->text().toDouble() * ui->doubleSpinBox_7->text().toDouble() * i));
ui->lineEdit_9->setText(QString::number(ui->doubleSpinBox_4->text().toDouble() * ui->doubleSpinBox_8->text().toDouble() * f));
ui->lineEdit_10->setText(QString::number(ui->doubleSpinBox_4->text().toDouble() * g));
ui->lineEdit_11->setText(QString::number(ui->doubleSpinBox_4->text().toDouble() * j));
ui->lineEdit_12->setText(QString::number(ui->doubleSpinBox_4->text().toDouble() * h));
ui->lineEdit_13->setText(QString::number(ui->lineEdit->text().toDouble() + ui->lineEdit_2->text().toDouble() + ui->lineEdit_3->text().toDouble()+ ui->lineEdit_4->text().toDouble()+ ui->lineEdit_5->text().toDouble()+ ui->lineEdit_6->text().toDouble()+ ui->lineEdit_7->text().toDouble()+ ui->lineEdit_8->text().toDouble()+ ui->lineEdit_9->text().toDouble()+ ui->lineEdit_10->text().toDouble()+ ui->lineEdit_11->text().toDouble()+ ui->lineEdit_12->text().toDouble()+ ui->lineEdit_14->text().toDouble() ));
}
спасибо, разобрался
ошибка в синтаксисе