Image Component Library (ICL)
Public Member Functions | Private Attributes | List of all members
icl::qt::GUIDefinition Class Reference

Utilty class to simplify creation of GUI components. More...

#include <GUIDefinition.h>

Public Member Functions

 GUIDefinition (const std::string &def, GUI *gui, QLayout *parentLayout=0, ProxyLayout *parentProxyLayout=0, QWidget *parentWidget=0)
 create a new GUI Definition More...
 
const std::string & type () const
 return the type string More...
 
const std::string & label () const
 return the lable string More...
 
const std::string & handle () const
 return the handle id string More...
 
const utils::Sizesize () const
 return this size (or utils::Size::null) More...
 
const utils::SizeminSize () const
 retunrs the minimum size of the widget or size::null More...
 
const utils::SizemaxSize () const
 returns the maxinum size of the widget or size::null More...
 
int margin () const
 returns the layout margin More...
 
int spacing () const
 returns the layout spacing More...
 
GUIgetGUI () const
 return the parent GUI More...
 
QLayout * parentLayout () const
 return the parent layout or null if there is nor parent More...
 
ProxyLayoutgetProxyLayout () const
 returns the parent widgets proxy layout More...
 
unsigned int numParams () const
 returns the number of params More...
 
const std::string & param (unsigned int idx) const
 returns a param at given index More...
 
int intParam (unsigned int idx) const
 returns a param at given index as int (using atoi) More...
 
float floatParam (unsigned int idx) const
 returns a param at given index as float (using atof) More...
 
const std::string & input (unsigned int idx) const
 returns an input name More...
 
const std::string & output (unsigned int idx) const
 returns an output name More...
 
unsigned int numInputs () const
 returns the number of params More...
 
unsigned int numOutputs () const
 returns the number of params More...
 
void show () const
 show this GUIDefinition to std::out More...
 
const std::string & defString () const
 returns the whole definition string (for debugging!) More...
 
QWidget * parentWidget () const
 returns the current parent widget (or 0 if there is non) More...
 
const std::vector< std::string > & allParams () const
 returns a list of all parameters More...
 
const std::string & toolTip () const
 returns the tooltip text More...
 
bool hasToolTip () const
 returns whether the tooltip text is not "" More...
 

Private Attributes

std::string m_sDefinitionString
 
std::string m_sType
 
std::vector< std::string > m_vecParams
 
std::vector< std::string > m_vecOutputs
 
std::vector< std::string > m_vecInputs
 
std::string m_sLabel
 
std::string m_sHandle
 
utils::Size m_oSize
 
utils::Size m_oMinSize
 
utils::Size m_oMaxSize
 
int m_iMargin
 
int m_iSpacing
 
GUIm_poGUI
 
QLayout * m_poParentLayout
 
QWidget * m_poParentWidget
 
ProxyLayoutm_poParentProxyLayout
 
std::string m_toolTip
 

Detailed Description

Utilty class to simplify creation of GUI components.

Constructor & Destructor Documentation

◆ GUIDefinition()

icl::qt::GUIDefinition::GUIDefinition ( const std::string &  def,
GUI gui,
QLayout *  parentLayout = 0,
ProxyLayout parentProxyLayout = 0,
QWidget *  parentWidget = 0 
)

create a new GUI Definition

Member Function Documentation

◆ allParams()

const std::vector<std::string>& icl::qt::GUIDefinition::allParams ( ) const
inline

returns a list of all parameters

◆ defString()

const std::string& icl::qt::GUIDefinition::defString ( ) const
inline

returns the whole definition string (for debugging!)

◆ floatParam()

float icl::qt::GUIDefinition::floatParam ( unsigned int  idx) const

returns a param at given index as float (using atof)

◆ getGUI()

GUI* icl::qt::GUIDefinition::getGUI ( ) const
inline

return the parent GUI

◆ getProxyLayout()

ProxyLayout* icl::qt::GUIDefinition::getProxyLayout ( ) const
inline

returns the parent widgets proxy layout

◆ handle()

const std::string& icl::qt::GUIDefinition::handle ( ) const
inline

return the handle id string

◆ hasToolTip()

bool icl::qt::GUIDefinition::hasToolTip ( ) const
inline

returns whether the tooltip text is not ""

◆ input()

const std::string& icl::qt::GUIDefinition::input ( unsigned int  idx) const

returns an input name

if the given input index was actually not defined, a dummy input name is created

◆ intParam()

int icl::qt::GUIDefinition::intParam ( unsigned int  idx) const

returns a param at given index as int (using atoi)

◆ label()

const std::string& icl::qt::GUIDefinition::label ( ) const
inline

return the lable string

◆ margin()

int icl::qt::GUIDefinition::margin ( ) const
inline

returns the layout margin

◆ maxSize()

const utils::Size& icl::qt::GUIDefinition::maxSize ( ) const
inline

returns the maxinum size of the widget or size::null

◆ minSize()

const utils::Size& icl::qt::GUIDefinition::minSize ( ) const
inline

retunrs the minimum size of the widget or size::null

◆ numInputs()

unsigned int icl::qt::GUIDefinition::numInputs ( ) const
inline

returns the number of params

◆ numOutputs()

unsigned int icl::qt::GUIDefinition::numOutputs ( ) const
inline

returns the number of params

◆ numParams()

unsigned int icl::qt::GUIDefinition::numParams ( ) const
inline

returns the number of params

◆ output()

const std::string& icl::qt::GUIDefinition::output ( unsigned int  idx) const

returns an output name

if the given output index was actually not defined, a dummy output name is created

◆ param()

const std::string& icl::qt::GUIDefinition::param ( unsigned int  idx) const

returns a param at given index

◆ parentLayout()

QLayout* icl::qt::GUIDefinition::parentLayout ( ) const
inline

return the parent layout or null if there is nor parent

◆ parentWidget()

QWidget* icl::qt::GUIDefinition::parentWidget ( ) const
inline

returns the current parent widget (or 0 if there is non)

◆ show()

void icl::qt::GUIDefinition::show ( ) const

show this GUIDefinition to std::out

◆ size()

const utils::Size& icl::qt::GUIDefinition::size ( ) const
inline

return this size (or utils::Size::null)

◆ spacing()

int icl::qt::GUIDefinition::spacing ( ) const
inline

returns the layout spacing

◆ toolTip()

const std::string& icl::qt::GUIDefinition::toolTip ( ) const
inline

returns the tooltip text

◆ type()

const std::string& icl::qt::GUIDefinition::type ( ) const
inline

return the type string

Member Data Documentation

◆ m_iMargin

int icl::qt::GUIDefinition::m_iMargin
private

◆ m_iSpacing

int icl::qt::GUIDefinition::m_iSpacing
private

◆ m_oMaxSize

utils::Size icl::qt::GUIDefinition::m_oMaxSize
private

◆ m_oMinSize

utils::Size icl::qt::GUIDefinition::m_oMinSize
private

◆ m_oSize

utils::Size icl::qt::GUIDefinition::m_oSize
private

◆ m_poGUI

GUI* icl::qt::GUIDefinition::m_poGUI
private

◆ m_poParentLayout

QLayout* icl::qt::GUIDefinition::m_poParentLayout
private

◆ m_poParentProxyLayout

ProxyLayout* icl::qt::GUIDefinition::m_poParentProxyLayout
private

◆ m_poParentWidget

QWidget* icl::qt::GUIDefinition::m_poParentWidget
private

◆ m_sDefinitionString

std::string icl::qt::GUIDefinition::m_sDefinitionString
private

◆ m_sHandle

std::string icl::qt::GUIDefinition::m_sHandle
private

◆ m_sLabel

std::string icl::qt::GUIDefinition::m_sLabel
private

◆ m_sType

std::string icl::qt::GUIDefinition::m_sType
private

◆ m_toolTip

std::string icl::qt::GUIDefinition::m_toolTip
private

◆ m_vecInputs

std::vector<std::string> icl::qt::GUIDefinition::m_vecInputs
private

◆ m_vecOutputs

std::vector<std::string> icl::qt::GUIDefinition::m_vecOutputs
private

◆ m_vecParams

std::vector<std::string> icl::qt::GUIDefinition::m_vecParams
private

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