Version: 8.3.0
SMESHGUI_FilterLibraryDlg Class Reference

#include <SMESHGUI_FilterLibraryDlg.h>

Inheritance diagram for SMESHGUI_FilterLibraryDlg:

Data Structures

class  Dialog
 Class : SMESHGUI_FilterLibraryDlg::Dialog Description : Dialog for opening filter library. More...
 

Public Types

enum  { ADD_TO, COPY_FROM, EDIT }
 

Public Member Functions

 SMESHGUI_FilterLibraryDlg (SMESHGUI *, QWidget *, const QList< int > &, const int)
 Class : SMESHGUI_FilterLibraryDlg Description : Dialog to specify filters for VTK viewer. More...
 
 SMESHGUI_FilterLibraryDlg (SMESHGUI *, QWidget *, const int, const int)
 
virtual ~SMESHGUI_FilterLibraryDlg ()
 
void Init (const QList< int > &, const int)
 
void Init (const int, const int)
 
const SMESHGUI_FilterTableGetTable () const
 
void SetTable (const SMESHGUI_FilterTable *)
 

Protected Slots

virtual void reject ()
 

Private Types

enum  { BTN_OK, BTN_Apply, BTN_Close, BTN_Help }
 

Private Slots

void onOk ()
 
bool onApply ()
 
void onHelp ()
 
void onDeactivate ()
 
void onBrowse ()
 
void onReturnPressed ()
 
void onFilterChanged ()
 
void onAddBtnPressed ()
 
void onDeleteBtnPressed ()
 
void onFilterNameChanged (const QString &)
 
void onEntityTypeChanged (const int)
 
void onNeedValidation ()
 
void onSelectionDone ()
 

Private Member Functions

void enterEvent (QEvent *)
 
void keyPressEvent (QKeyEvent *)
 
void construct (const QList< int > &, const int)
 
QWidgetcreateButtonFrame (QWidget *)
 
QWidgetcreateMainFrame (QWidget *)
 
bool isValid (const bool=true) const
 
bool isNameValid (const bool=true) const
 
SMESH::Filter_ptr createFilter (const int=-1)
 
QStringList prepareFilters () const
 
QString autoExtension (const QString &) const
 
bool setSelected (const QString &)
 
int getIndex (const QString &) const
 
void updateControlsVisibility ()
 
void updateMainButtons ()
 
void enableMainButtons ()
 
void processNewLibrary ()
 
QString getFileName () const
 
void setFileName (const QString &, const bool=true)
 
QStringList filterWildCards (const QString &) const
 
QString & getDefaultLibraryName () const
 
QString getDefaultFilterName () const
 
void addFilterToLib (const QString &)
 
void updateList ()
 
bool isPermissionValid (const bool)
 

Private Attributes

QWidgetmyMainFrame
 
QMap< int, QPushButton * > myButtons
 
SMESHGUI_FilterTablemyTable
 
QLineEdit * myFileName
 
QPushButton * myOpenBtn
 
QListWidget * myListBox
 
QPushButton * myAddBtn
 
QPushButton * myDeleteBtn
 
QWidgetmyNameGrp
 
QLineEdit * myName
 
SMESHGUImySMESHGUI
 
QList< intmyTypes
 
int myMode
 
SMESH::FilterLibrary_var myLibrary
 
QString myCurrFilterName
 
int myCurrFilter
 
QString myHelpFileName
 

Member Enumeration Documentation

anonymous enum
private
Enumerator
BTN_OK 
BTN_Apply 
BTN_Close 
BTN_Help 
anonymous enum
Enumerator
ADD_TO 
COPY_FROM 
EDIT 

Constructor & Destructor Documentation

SMESHGUI_FilterLibraryDlg::SMESHGUI_FilterLibraryDlg ( SMESHGUI theModule,
QWidget parent,
const QList< int > &  theTypes,
const int  theMode 
)

Class : SMESHGUI_FilterLibraryDlg Description : Dialog to specify filters for VTK viewer.

References construct().

SMESHGUI_FilterLibraryDlg::SMESHGUI_FilterLibraryDlg ( SMESHGUI theModule,
QWidget parent,
const int  theType,
const int  theMode 
)

References construct().

SMESHGUI_FilterLibraryDlg::~SMESHGUI_FilterLibraryDlg ( )
virtual

Member Function Documentation

void SMESHGUI_FilterLibraryDlg::addFilterToLib ( const QString &  theName)
private
QString SMESHGUI_FilterLibraryDlg::autoExtension ( const QString &  theFileName) const
private
void SMESHGUI_FilterLibraryDlg::construct ( const QList< int > &  theTypes,
const int  theMode 
)
private
QWidget * SMESHGUI_FilterLibraryDlg::createButtonFrame ( QWidget theParent)
private
SMESH::Filter_ptr SMESHGUI_FilterLibraryDlg::createFilter ( const int  theType = -1)
private
void SMESHGUI_FilterLibraryDlg::enableMainButtons ( )
private
void SMESHGUI_FilterLibraryDlg::enterEvent ( QEvent *  )
private
QStringList SMESHGUI_FilterLibraryDlg::filterWildCards ( const QString &  theFilter) const
private
QString SMESHGUI_FilterLibraryDlg::getDefaultFilterName ( ) const
private
QString & SMESHGUI_FilterLibraryDlg::getDefaultLibraryName ( ) const
private

Referenced by Init(), and onApply().

QString SMESHGUI_FilterLibraryDlg::getFileName ( ) const
private

References myFileName.

Referenced by onBrowse(), and processNewLibrary().

int SMESHGUI_FilterLibraryDlg::getIndex ( const QString &  theName) const
private

References myListBox.

Referenced by onDeleteBtnPressed(), and setSelected().

const SMESHGUI_FilterTable * SMESHGUI_FilterLibraryDlg::GetTable ( ) const

References myTable.

Referenced by SMESHGUI_FilterTable::onCopyFromBtn().

void SMESHGUI_FilterLibraryDlg::Init ( const int  type,
const int  theMode 
)

References Init().

bool SMESHGUI_FilterLibraryDlg::isNameValid ( const bool  theMess = true) const
private

References SMESHGUI::desktop(), myCurrFilterName, myLibrary, and myName.

Referenced by isValid().

bool SMESHGUI_FilterLibraryDlg::isPermissionValid ( const bool  theIsExistingOnly)
private
bool SMESHGUI_FilterLibraryDlg::isValid ( const bool  theMess = true) const
private
void SMESHGUI_FilterLibraryDlg::keyPressEvent ( QKeyEvent *  e)
private

References onHelp().

void SMESHGUI_FilterLibraryDlg::onDeactivate ( )
privateslot

Referenced by Init().

void SMESHGUI_FilterLibraryDlg::onDeleteBtnPressed ( )
privateslot
void SMESHGUI_FilterLibraryDlg::onEntityTypeChanged ( const int  theType)
privateslot
void SMESHGUI_FilterLibraryDlg::onFilterNameChanged ( const QString &  theName)
privateslot

References myListBox.

Referenced by createMainFrame().

void SMESHGUI_FilterLibraryDlg::onHelp ( )
privateslot

References myHelpFileName, and mySMESHGUI.

Referenced by createButtonFrame(), and keyPressEvent().

void SMESHGUI_FilterLibraryDlg::onNeedValidation ( )
privateslot
void SMESHGUI_FilterLibraryDlg::onOk ( )
privateslot
void SMESHGUI_FilterLibraryDlg::onReturnPressed ( )
privateslot
QStringList SMESHGUI_FilterLibraryDlg::prepareFilters ( ) const
private

Referenced by onBrowse().

void SMESHGUI_FilterLibraryDlg::processNewLibrary ( )
private
void SMESHGUI_FilterLibraryDlg::reject ( )
protectedvirtualslot

References mySMESHGUI, and SMESHGUI::ResetState().

Referenced by createButtonFrame(), and Init().

void SMESHGUI_FilterLibraryDlg::setFileName ( const QString &  txt,
const bool  autoExt = true 
)
private

References autoExtension(), and myFileName.

Referenced by onBrowse().

bool SMESHGUI_FilterLibraryDlg::setSelected ( const QString &  theName)
private
void SMESHGUI_FilterLibraryDlg::updateControlsVisibility ( )
private
void SMESHGUI_FilterLibraryDlg::updateMainButtons ( )
private

References BTN_Apply, BTN_Close, myButtons, and myTypes.

Referenced by createButtonFrame(), and Init().

Field Documentation

QPushButton* SMESHGUI_FilterLibraryDlg::myAddBtn
private
QMap<int, QPushButton*> SMESHGUI_FilterLibraryDlg::myButtons
private
int SMESHGUI_FilterLibraryDlg::myCurrFilter
private
QPushButton* SMESHGUI_FilterLibraryDlg::myDeleteBtn
private
QLineEdit* SMESHGUI_FilterLibraryDlg::myFileName
private
QString SMESHGUI_FilterLibraryDlg::myHelpFileName
private

Referenced by construct(), and onHelp().

QWidget* SMESHGUI_FilterLibraryDlg::myMainFrame
private

Referenced by construct().

QWidget* SMESHGUI_FilterLibraryDlg::myNameGrp
private
QPushButton* SMESHGUI_FilterLibraryDlg::myOpenBtn
private

Referenced by createMainFrame().

SMESHGUI* SMESHGUI_FilterLibraryDlg::mySMESHGUI
private
QList<int> SMESHGUI_FilterLibraryDlg::myTypes
private