15 int main(
int argc,
char* argv[] )
17 QApplication application( argc, argv );
25 return application.exec();
43 setWindowTitle( tr(
"2D Plot : Curves" ) );
46 QGridLayout* top =
new QGridLayout(
this );
47 top->setSpacing ( 2 );
48 top->setContentsMargins ( 2, 2, 2, 2 );
51 top->addWidget( lbl_par1, row++, 0 );
54 ct_par1->setRange( -50, 50, 0.01 );
58 top->addWidget(
ct_par1, row++, 0 );
61 top->addWidget( lbl_par2, row++, 0 );
64 ct_par2->setRange( -50, 50, 0.01 );
68 top->addWidget(
ct_par2, row++, 0 );
71 top->addWidget( lbl_par3, row++, 0 );
74 ct_par3->setRange( -50, 50, 0.01 );
78 top->addWidget(
ct_par3, row++, 0 );
81 top->addWidget( lbl_par4, row++, 0 );
84 ct_par4->setRange( -50, 50, 0.01 );
88 top->addWidget(
ct_par4, row++, 0 );
91 top->addWidget( lbl_resolution, row++, 0 );
101 top->addWidget( lbl_model, row++, 0 );
108 top->addWidget(
ct_model, row++, 0 );
113 tr(
"Function Plot" ),
114 tr(
"sedimentation coefficient" ), tr(
"f/f0" ) );
117 data_plot->enableAxis( QwtPlot::xBottom,
true );
118 data_plot->enableAxis( QwtPlot::yLeft ,
true );
119 data_plot->setAxisScale( QwtPlot::xBottom, 0.2, 10.0 );
120 data_plot->setAxisAutoScale( QwtPlot::yLeft );
122 top->addLayout(
plot, 0, 1, 0, 1 );
130 connect( pb_close, SIGNAL( clicked() ), SLOT( close() ) );
131 top->addWidget( pb_close, row++, 0 );
133 top->setColumnStretch( 0, 0 );
134 top->setColumnStretch( 1, 1 );
182 c1->setStyle ( QwtPlotCurve::Lines );
183 c1->setPen ( QColor( Qt::yellow ) );
185 data_plot->setAxisAutoScale( QwtPlot::xBottom );
186 data_plot->setAxisAutoScale( QwtPlot::yLeft );
224 ct_par1->setRange( -50, 50, 0.01 );
225 ct_par2->setRange( -50, 50, 0.01 );
226 ct_par3->setRange( -50, 50, 0.01 );
227 ct_par4->setRange( -50, 50, 0.01 );
234 ct_par1->setRange( 0.001, 50, 0.001 );
235 ct_par2->setRange( 0.0, 1.0, 0.001 );
242 ct_par1->setRange( 0.001, 50, 0.001 );
243 ct_par2->setRange( 0.0, 1.0, 0.001 );