Version: 9.16.0
Plot2d_AnalyticalCurveDlg Class Reference

#include <Plot2d_AnalyticalCurveDlg.h>

Inheritance diagram for Plot2d_AnalyticalCurveDlg:
Inheritance graph

Classes

class  UpdateLocker
 
class  Updater
 

Public Member Functions

 Plot2d_AnalyticalCurveDlg (Plot2d_CurveContainer *, QWidget *)
 
 ~Plot2d_AnalyticalCurveDlg ()
 
void accept ()
 Private slot. Called when "Ok" button is clicked. More...
 
void reject ()
 Private slot. Called when "Close" button is clicked. More...
 

Private Types

enum  { ItemExisting , ItemAdded , ItemRemoved }
 
typedef QMap< QString, QVariant > CurveProps
 
typedef QMap< Plot2d_AnalyticalCurve *, CurveProps > PropMap
 

Private Slots

void addCurve ()
 Private slot. Called when "Add curve" button is clicked. More...
 
void removeCurve ()
 Private slot. Called when "Remove curve" button is clicked. More...
 
void updateCurve ()
 Private slot. Called when any curve property is changed. More...
 
void updateState ()
 Private slot. Update widgets state. More...
 
void selectionChanged ()
 Private slot. Called when selection in the curve list is changed. More...
 
void help ()
 Show help page. More...
 
void apply ()
 Private slot. Called when "Apply" button is clicked. More...
 

Private Member Functions

void init ()
 
void initPropsFromCurve (Plot2d_AnalyticalCurve *)
 
QListWidgetItem * selected () const
 Get currently selected list widget item. More...
 
Plot2d_AnalyticalCurve * selectedCurve () const
 Get currently selected curve. More...
 
QListWidgetItem * getItem (Plot2d_AnalyticalCurve *) const
 Get widget item by the curve. More...
 
bool processCurves ()
 
QwtPlot * getPlot ()
 
int propStatus (Plot2d_AnalyticalCurve *=0, const int def=ItemExisting)
 Get curve property: status. More...
 
QString propTitle (Plot2d_AnalyticalCurve *=0, const QString &def="")
 Get curve property: title. More...
 
bool propVisible (Plot2d_AnalyticalCurve *=0, bool def=true)
 Get curve property: visible flag. More...
 
QString propFormula (Plot2d_AnalyticalCurve *=0, const QString &def="")
 Get curve property: formula. More...
 
int propIntervals (Plot2d_AnalyticalCurve *=0, int def=100)
 Get curve property: nb intervals. More...
 
Plot2d::MarkerType propMarkerType (Plot2d_AnalyticalCurve *=0, Plot2d::MarkerType def=Plot2d::None)
 Get curve property: marker type. More...
 
Plot2d::LineType propLineType (Plot2d_AnalyticalCurve *=0, Plot2d::LineType def=Plot2d::NoPen)
 Get curve property: line type. More...
 
int propLineWidth (Plot2d_AnalyticalCurve *=0, int def=0)
 Get curve property: line width. More...
 
QColor propColor (Plot2d_AnalyticalCurve *=0, const QColor &def=QColor())
 Get curve property: color. More...
 
bool propAutoAssign (Plot2d_AnalyticalCurve *=0, bool def=true)
 Get curve property: auto-assign flag. More...
 

Private Attributes

Plot2d_CurveContainer * myContainer
 
PropMap myProperties
 
Updater * myUpdater
 
QListWidget * myCurvesList
 
QGroupBox * myCurveParams
 
QLineEdit * myFormula
 
QtxIntSpinBox * myNbIntervals
 
QGroupBox * myCurveProps
 
QCheckBox * myAutoAssign
 
QWidget * myPropsGrp
 
QComboBox * myMarkerType
 
QComboBox * myLineType
 
QtxIntSpinBox * myLineWidth
 
QtxColorButton * myColor
 
QPushButton * myAddButton
 
QPushButton * myRemoveButton
 

Member Typedef Documentation

◆ CurveProps

typedef QMap<QString, QVariant> Plot2d_AnalyticalCurveDlg::CurveProps
private

◆ PropMap

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
private
Enumerator
ItemExisting 
ItemAdded 
ItemRemoved 

Constructor & Destructor Documentation

◆ Plot2d_AnalyticalCurveDlg()

◆ ~Plot2d_AnalyticalCurveDlg()

Plot2d_AnalyticalCurveDlg::~Plot2d_AnalyticalCurveDlg ( )

Destructor

Member Function Documentation

◆ accept()

void Plot2d_AnalyticalCurveDlg::accept ( )

Private slot. Called when "Ok" button is clicked.

References processCurves().

◆ addCurve

void Plot2d_AnalyticalCurveDlg::addCurve ( )
privateslot

◆ apply

void Plot2d_AnalyticalCurveDlg::apply ( )
privateslot

◆ getItem()

QListWidgetItem * Plot2d_AnalyticalCurveDlg::getItem ( Plot2d_AnalyticalCurve *  theCurve) const
private

Get widget item by the curve.

References myCurvesList.

◆ getPlot()

QwtPlot * Plot2d_AnalyticalCurveDlg::getPlot ( )
private

◆ help

void Plot2d_AnalyticalCurveDlg::help ( )
privateslot

◆ init()

◆ initPropsFromCurve()

◆ processCurves()

◆ propAutoAssign()

bool Plot2d_AnalyticalCurveDlg::propAutoAssign ( Plot2d_AnalyticalCurve *  curve = 0,
bool  def = true 
)
private

Get curve property: auto-assign flag.

References myProperties, and PROP_AUTOASSIGN.

◆ propColor()

QColor Plot2d_AnalyticalCurveDlg::propColor ( Plot2d_AnalyticalCurve *  curve = 0,
const QColor &  def = QColor() 
)
private

Get curve property: color.

References myProperties, and PROP_COLOR.

◆ propFormula()

QString Plot2d_AnalyticalCurveDlg::propFormula ( Plot2d_AnalyticalCurve *  curve = 0,
const QString &  def = "" 
)
private

Get curve property: formula.

References myProperties, and PROP_FORMULA.

◆ propIntervals()

int Plot2d_AnalyticalCurveDlg::propIntervals ( Plot2d_AnalyticalCurve *  curve = 0,
int  def = 100 
)
private

Get curve property: nb intervals.

References myProperties, and PROP_NBINTERVALS.

◆ propLineType()

Plot2d::LineType Plot2d_AnalyticalCurveDlg::propLineType ( Plot2d_AnalyticalCurve *  curve = 0,
Plot2d::LineType  def = Plot2d::NoPen 
)
private

Get curve property: line type.

References myProperties, and PROP_LINETYPE.

◆ propLineWidth()

int Plot2d_AnalyticalCurveDlg::propLineWidth ( Plot2d_AnalyticalCurve *  curve = 0,
int  def = 0 
)
private

Get curve property: line width.

References myProperties, and PROP_LINEWIDTH.

◆ propMarkerType()

Plot2d::MarkerType Plot2d_AnalyticalCurveDlg::propMarkerType ( Plot2d_AnalyticalCurve *  curve = 0,
Plot2d::MarkerType  def = Plot2d::None 
)
private

Get curve property: marker type.

References myProperties, and PROP_MARKERTYPE.

◆ propStatus()

int Plot2d_AnalyticalCurveDlg::propStatus ( Plot2d_AnalyticalCurve *  curve = 0,
const int  def = ItemExisting 
)
private

Get curve property: status.

References myProperties, and PROP_STATUS.

◆ propTitle()

QString Plot2d_AnalyticalCurveDlg::propTitle ( Plot2d_AnalyticalCurve *  curve = 0,
const QString &  def = "" 
)
private

Get curve property: title.

References myProperties, and PROP_TITLE.

◆ propVisible()

bool Plot2d_AnalyticalCurveDlg::propVisible ( Plot2d_AnalyticalCurve *  curve = 0,
bool  def = true 
)
private

Get curve property: visible flag.

References myProperties, and PROP_VISIBLE.

◆ reject()

void Plot2d_AnalyticalCurveDlg::reject ( )

Private slot. Called when "Close" button is clicked.

References ItemAdded, myProperties, and propStatus().

◆ removeCurve

void Plot2d_AnalyticalCurveDlg::removeCurve ( )
privateslot

Private slot. Called when "Remove curve" button is clicked.

References ItemAdded, ItemRemoved, myCurvesList, myProperties, PROP_STATUS, and propStatus().

◆ selected()

QListWidgetItem * Plot2d_AnalyticalCurveDlg::selected ( ) const
private

Get currently selected list widget item.

References myCurvesList.

◆ selectedCurve()

Plot2d_AnalyticalCurve * Plot2d_AnalyticalCurveDlg::selectedCurve ( ) const
private

Get currently selected curve.

References selected().

◆ selectionChanged

void Plot2d_AnalyticalCurveDlg::selectionChanged ( )
privateslot

◆ updateCurve

◆ updateState

void Plot2d_AnalyticalCurveDlg::updateState ( )
privateslot

Private slot. Update widgets state.

References myAutoAssign, myCurveParams, myCurveProps, myPropsGrp, myRemoveButton, and selectedCurve().

Member Data Documentation

◆ myAddButton

QPushButton* Plot2d_AnalyticalCurveDlg::myAddButton
private

◆ myAutoAssign

QCheckBox* Plot2d_AnalyticalCurveDlg::myAutoAssign
private

◆ myColor

QtxColorButton* Plot2d_AnalyticalCurveDlg::myColor
private

◆ myContainer

Plot2d_CurveContainer* Plot2d_AnalyticalCurveDlg::myContainer
private

◆ myCurveParams

QGroupBox* Plot2d_AnalyticalCurveDlg::myCurveParams
private

◆ myCurveProps

QGroupBox* Plot2d_AnalyticalCurveDlg::myCurveProps
private

◆ myCurvesList

QListWidget* Plot2d_AnalyticalCurveDlg::myCurvesList
private

◆ myFormula

QLineEdit* Plot2d_AnalyticalCurveDlg::myFormula
private

◆ myLineType

QComboBox* Plot2d_AnalyticalCurveDlg::myLineType
private

◆ myLineWidth

QtxIntSpinBox* Plot2d_AnalyticalCurveDlg::myLineWidth
private

◆ myMarkerType

QComboBox* Plot2d_AnalyticalCurveDlg::myMarkerType
private

◆ myNbIntervals

QtxIntSpinBox* Plot2d_AnalyticalCurveDlg::myNbIntervals
private

◆ myProperties

PropMap Plot2d_AnalyticalCurveDlg::myProperties
private

◆ myPropsGrp

QWidget* Plot2d_AnalyticalCurveDlg::myPropsGrp
private

◆ myRemoveButton

QPushButton* Plot2d_AnalyticalCurveDlg::myRemoveButton
private

◆ myUpdater

Updater* Plot2d_AnalyticalCurveDlg::myUpdater
private

The documentation for this class was generated from the following files: