Reference documentation for deal.II version 8.1.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Public Types | Public Slots | Signals | Public Member Functions | Public Attributes | Private Slots | Private Attributes | List of all members
dealii::ParameterGui::BrowseLineEdit Class Reference

#include <browse_lineedit.h>

Inheritance diagram for dealii::ParameterGui::BrowseLineEdit:
[legend]

Public Types

enum  BrowseType { file = 0, directory = 1 }
 

Public Slots

void setText (const QString &str)
 

Signals

void editingFinished ()
 

Public Member Functions

 BrowseLineEdit (const BrowseType type=file, QWidget *parent=0)
 
QSize sizeHint () const
 
QSize minimumSizeHint () const
 
QString text () const
 

Public Attributes

BrowseType browse_type
 

Private Slots

void editing_finished ()
 
void browse ()
 

Private Attributes

QLineEdit * line_editor
 
QPushButton * browse_button
 

Detailed Description

The BrowseLineEdit class provides a special line editor for the parameterGUI. While editing file- or directory names it is much more easier to have a file-dialog and just click on existing files or directories. This editor provides a simple QLineEditor and a browse-button which opens a file- or a directory dialog. Clicking on existing files or directories copies the path to the line editor. Depending on the BrowseType given in the constructor the browse button opens a file or a directory dialog.

Note
This class is used in the graphical user interface for the ParameterHandler class. It is not compiled into the deal.II libraries and can not be used by applications using deal.II.
Author
Martin Steigemann, Wolfgang Bangerth, 2010

Definition at line 48 of file browse_lineedit.h.

Member Enumeration Documentation

The browse button opens a file or a directory dialog. This can be specified in the constructor by setting this flag BrowseType.

Definition at line 58 of file browse_lineedit.h.

Constructor & Destructor Documentation

dealii::ParameterGui::BrowseLineEdit::BrowseLineEdit ( const BrowseType  type = file,
QWidget *  parent = 0 
)

Constructor. The type of the browse dialog can be specified by the flag BrowseType, the default is file.

Member Function Documentation

QSize dealii::ParameterGui::BrowseLineEdit::sizeHint ( ) const

Reimplemented from the QWidget class. Returns the size of the editor.

QSize dealii::ParameterGui::BrowseLineEdit::minimumSizeHint ( ) const

Reimplemented from the QWidget class.

QString dealii::ParameterGui::BrowseLineEdit::text ( ) const

Returns the text of the line editor.

void dealii::ParameterGui::BrowseLineEdit::setText ( const QString &  str)
slot

A slot to set str as text of the line editor.

void dealii::ParameterGui::BrowseLineEdit::editingFinished ( )
signal

This signal will be emitted, if editing is finished.

void dealii::ParameterGui::BrowseLineEdit::editing_finished ( )
privateslot

This slot should be always called, if editing is finished.

void dealii::ParameterGui::BrowseLineEdit::browse ( )
privateslot

This function opens a file- or a directory dialog as specified in the constructor.

Member Data Documentation

BrowseType dealii::ParameterGui::BrowseLineEdit::browse_type

This pattern stores the type of the browse dialog.

Definition at line 82 of file browse_lineedit.h.

QLineEdit* dealii::ParameterGui::BrowseLineEdit::line_editor
private

The line editor.

Definition at line 111 of file browse_lineedit.h.

QPushButton* dealii::ParameterGui::BrowseLineEdit::browse_button
private

The browse button.

Definition at line 115 of file browse_lineedit.h.


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