QElectroTech  0.8-dev
Public Types | Signals | Public Member Functions | Public Attributes | Private Slots | Private Member Functions | Private Attributes | List of all members
NumPartEditorW Class Reference

#include <numparteditorw.h>

Inherits QWidget.

Collaboration diagram for NumPartEditorW:
Collaboration graph

Public Types

enum  type {
  unit, unitfolio, ten, tenfolio,
  hundred, hundredfolio, string, idfolio,
  folio, plant, locmach, elementline,
  elementcolumn, elementprefix
}
 

Signals

void changed ()
 

Public Member Functions

 NumPartEditorW (int type, QWidget *parent=nullptr)
 NumPartEditorW::NumPartEditorW Constructor. More...
 
 NumPartEditorW (NumerotationContext &, int, int type, QWidget *parent=nullptr)
 NumPartEditorW::NumPartEditorW Constructor Build with value of context at position i. More...
 
 ~NumPartEditorW () override
 
NumerotationContext toNumContext ()
 NumPartEditorW::toNumContext. More...
 
bool isValid ()
 NumPartEditorW::isValid. More...
 

Public Attributes

type type_
 

Private Slots

void on_type_cb_activated (int)
 NumPartEditorW::on_type_cb_activated Action when user change the type comboBox. More...
 
void on_value_field_textEdited ()
 NumPartEditorW::on_value_field_textChanged emit changed when value_field text changed. More...
 
void on_increase_spinBox_valueChanged (int)
 NumPartEditorW::on_increase_spinBox_valueChanged emit changed when increase_spinBox value changed. More...
 
void setType (NumPartEditorW::type t, bool=false)
 NumPartEditorW::setType Set good behavior by type t. More...
 

Private Member Functions

void setVisibleItems ()
 
void disableItem (int index)
 
void setCurrentIndex (NumPartEditorW::type)
 NumPartEditorW::setCurrentIndex Set Current Index of type_cb. More...
 

Private Attributes

Ui::NumPartEditorW * ui
 
QValidator * intValidator
 
int m_edited_type = -1
 

Member Enumeration Documentation

◆ type

Enumerator
unit 
unitfolio 
ten 
tenfolio 
hundred 
hundredfolio 
string 
idfolio 
folio 
plant 
locmach 
elementline 
elementcolumn 
elementprefix 

Constructor & Destructor Documentation

◆ NumPartEditorW() [1/2]

NumPartEditorW::NumPartEditorW ( int  type,
QWidget *  parent = nullptr 
)
explicit

NumPartEditorW::NumPartEditorW Constructor.

Parameters
type
parent
Here is the call graph for this function:

◆ NumPartEditorW() [2/2]

NumPartEditorW::NumPartEditorW ( NumerotationContext context,
int  i,
int  type,
QWidget *  parent = nullptr 
)

NumPartEditorW::NumPartEditorW Constructor Build with value of context at position i.

Parameters
context
i
type
parent
Here is the call graph for this function:

◆ ~NumPartEditorW()

NumPartEditorW::~NumPartEditorW ( )
override

Destructor

Member Function Documentation

◆ changed

void NumPartEditorW::changed ( )
signal
Here is the caller graph for this function:

◆ disableItem()

void NumPartEditorW::disableItem ( int  index)
private

◆ isValid()

bool NumPartEditorW::isValid ( )

NumPartEditorW::isValid.

Returns
true if value field isn't empty or if type is folio

◆ on_increase_spinBox_valueChanged

void NumPartEditorW::on_increase_spinBox_valueChanged ( int  )
privateslot

NumPartEditorW::on_increase_spinBox_valueChanged emit changed when increase_spinBox value changed.

◆ on_type_cb_activated

void NumPartEditorW::on_type_cb_activated ( int  )
privateslot

NumPartEditorW::on_type_cb_activated Action when user change the type comboBox.

Here is the call graph for this function:

◆ on_value_field_textEdited

void NumPartEditorW::on_value_field_textEdited ( )
privateslot

NumPartEditorW::on_value_field_textChanged emit changed when value_field text changed.

◆ setCurrentIndex()

void NumPartEditorW::setCurrentIndex ( NumPartEditorW::type  t)
private

NumPartEditorW::setCurrentIndex Set Current Index of type_cb.

Parameters
t: type used
Here is the caller graph for this function:

◆ setType

void NumPartEditorW::setType ( NumPartEditorW::type  t,
bool  fnum = false 
)
privateslot

NumPartEditorW::setType Set good behavior by type t.

Parameters
t: type used
fnum: force the behavior of numeric type
Here is the call graph for this function:
Here is the caller graph for this function:

◆ setVisibleItems()

void NumPartEditorW::setVisibleItems ( )
private
Here is the caller graph for this function:

◆ toNumContext()

NumerotationContext NumPartEditorW::toNumContext ( )

NumPartEditorW::toNumContext.

Returns
the display to NumerotationContext
Here is the call graph for this function:

Member Data Documentation

◆ intValidator

QValidator* NumPartEditorW::intValidator
private

◆ m_edited_type

int NumPartEditorW::m_edited_type = -1
private

◆ type_

type NumPartEditorW::type_

◆ ui

Ui::NumPartEditorW* NumPartEditorW::ui
private

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