API Documentation
Loading...
Searching...
No Matches
ModelTableColumnSpec Struct Reference

#include <DesignTableModel.h>

Collaboration diagram for ModelTableColumnSpec:
[legend]

Classes

struct  RelativePathObject
 

Public Types

enum  ModelTableType { e_design_parameter , e_model_material , e_custom_callback }
 
enum  RelativePath {
  e_parent , e_last_child , e_child_index = 10 , e_child_0 = e_child_index ,
  e_child_1 , e_child_2 , e_child_3 , e_child_4 ,
  e_child_5 , e_child_6 , e_child_7
}
 

Public Member Functions

QVariant data (const DesignObject &obj, int role=Qt::DisplayRole) const
 
DesignObject getTarget (const DesignObject &a, bool try_to_create) const
 
TranslatedString headerTitle () const
 
bool isCheckEditable () const
 
bool isSortEqual (const DesignObject &a, const DesignObject &b) const
 
bool isSortLessThan (const DesignObject &a, const DesignObject &b) const
 
bool isTextEditable () const
 
bool isValid () const
 
 ModelTableColumnSpec ()
 
 ModelTableColumnSpec (const DesignParameter &parameter)
 
 ModelTableColumnSpec (const DesignParameter &parameter, Buffer< RelativePathObject > relative_mode)
 
 ModelTableColumnSpec (const std::function< void(UUID)> &callback)
 
 ModelTableColumnSpec (const TranslatedString &text, const String &icon, const std::function< void(UUID)> &callback)
 
 ModelTableColumnSpec (ModelTableType type)
 
bool setData (const DesignObject &obj, const QVariant &value, int role)
 
String stringDisplayData (const DesignObject &obj) const
 

Public Attributes

std::function< void(UUID)> callback
 
ModelTableType column_type
 
TranslatedString custom_column_name
 
String custom_icon
 
TranslatedString custom_text
 
DesignParameter design_parameter
 
bool is_clicked = false
 
bool is_currently_editable = false
 
bool is_editable
 
uint04 max_decimal_places
 
uint04 min_decimal_places
 
Buffer< RelativePathObjectrelative_path
 

Protected Member Functions

QVariant parameterData (const DesignObject &obj, int role) const
 

Member Enumeration Documentation

◆ ModelTableType

Enumerator
e_design_parameter 
e_model_material 
e_custom_callback 

◆ RelativePath

Enumerator
e_parent 
e_last_child 
e_child_index 
e_child_0 
e_child_1 
e_child_2 
e_child_3 
e_child_4 
e_child_5 
e_child_6 
e_child_7 

Constructor & Destructor Documentation

◆ ModelTableColumnSpec() [1/6]

◆ ModelTableColumnSpec() [2/6]

ModelTableColumnSpec ( const std::function< void(UUID)> & callback)
explicit

◆ ModelTableColumnSpec() [3/6]

ModelTableColumnSpec ( const DesignParameter & parameter)
explicit

◆ ModelTableColumnSpec() [4/6]

ModelTableColumnSpec ( const DesignParameter & parameter,
Buffer< RelativePathObject > relative_mode )
explicit

◆ ModelTableColumnSpec() [5/6]

◆ ModelTableColumnSpec() [6/6]

ModelTableColumnSpec ( const TranslatedString & text,
const String & icon,
const std::function< void(UUID)> & callback )

Member Function Documentation

◆ data()

QVariant data ( const DesignObject & obj,
int role = Qt::DisplayRole ) const
nodiscard

◆ getTarget()

DesignObject getTarget ( const DesignObject & a,
bool try_to_create ) const
nodiscard

◆ headerTitle()

TranslatedString headerTitle ( ) const
nodiscard

◆ isCheckEditable()

bool isCheckEditable ( ) const
nodiscard

◆ isSortEqual()

bool isSortEqual ( const DesignObject & a,
const DesignObject & b ) const
nodiscard

◆ isSortLessThan()

bool isSortLessThan ( const DesignObject & a,
const DesignObject & b ) const
nodiscard

◆ isTextEditable()

bool isTextEditable ( ) const
nodiscard

◆ isValid()

bool isValid ( ) const
nodiscard

◆ parameterData()

QVariant parameterData ( const DesignObject & obj,
int role ) const
nodiscardprotected

◆ setData()

bool setData ( const DesignObject & obj,
const QVariant & value,
int role )
nodiscard

◆ stringDisplayData()

String stringDisplayData ( const DesignObject & obj) const
nodiscard

Member Data Documentation

◆ callback

std::function<void(UUID)> callback

◆ column_type

ModelTableType column_type

◆ custom_column_name

TranslatedString custom_column_name

◆ custom_icon

String custom_icon

◆ custom_text

TranslatedString custom_text

◆ design_parameter

DesignParameter design_parameter

◆ is_clicked

bool is_clicked = false

◆ is_currently_editable

bool is_currently_editable = false

◆ is_editable

bool is_editable

◆ max_decimal_places

uint04 max_decimal_places

◆ min_decimal_places

uint04 min_decimal_places

◆ relative_path

Buffer<RelativePathObject> relative_path

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