CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Private Attributes
FWAdapterRowHeaderTableManager Class Reference

#include <Fireworks/TableWidget/interface/FWAdapterRowHeaderTableManager.h>

Inheritance diagram for FWAdapterRowHeaderTableManager:
FWTableManagerBase

Public Member Functions

FWTableCellRendererBasecellRenderer (int iRow, int iCol) const override
 
 FWAdapterRowHeaderTableManager (FWTableManagerBase *)
 
 FWAdapterRowHeaderTableManager (const FWAdapterRowHeaderTableManager &)=delete
 
std::vector< std::string > getTitles () const override
 returns the title names for each column More...
 
void implSort (int col, bool sortOrder) override
 Called by 'sort' method to actually handle the sorting of the rows. Arguments are the same as 'sort'. More...
 
int numberOfColumns () const override
 Number of columns in the table. More...
 
int numberOfRows () const override
 Number of rows in the table. More...
 
const
FWAdapterRowHeaderTableManager
operator= (const FWAdapterRowHeaderTableManager &)=delete
 
int unsortedRowNumber (int) const override
 when passed the index to the sorted order of the rows it returns the original row number from the underlying data More...
 
 ~FWAdapterRowHeaderTableManager () override
 
- Public Member Functions inherited from FWTableManagerBase
virtual void buttonPressedInRowHeader (Int_t row, Event_t *event, Int_t relX, Int_t relY)
 Called if mouse button pressed in Row Header, defaults is to do nothing. More...
 
virtual void buttonReleasedInRowHeader (Int_t row, Event_t *event, Int_t relX, Int_t relY)
 
virtual bool cellDataIsSortable () const
 
virtual unsigned int cellHeight () const
 require all cells to be the same height More...
 
 ClassDefOverride (FWTableManagerBase, 0)
 
void dataChanged ()
 Classes which inherit from FWTableManagerBase must call this when their underlying data changes. More...
 
 FWTableManagerBase ()
 
virtual bool hasLabelHeaders () const
 
virtual bool hasRowHeaders () const
 Returns 'true' if this table has row headers. Defaults return value is false. More...
 
virtual std::vector< unsigned int > maxWidthForColumns () const
 for each column in the table this returns the present maximum width for that column More...
 
virtual FWTableCellRendererBaserowHeader (int iSortedRowNumber) const
 Returns the renderer for the row header for the sorted row number iSortedRowNumber. More...
 
void sort (int iCol, bool iSortOrder)
 Call to have table sorted on values in column iCol with the sort order being descending if iSortOrder is 'true'. More...
 
int sortColumn (void)
 The current sort column. More...
 
bool sortOrder (void)
 The current sort order for the table. More...
 
void visualPropertiesChanged ()
 Classes which inherit from FWTableManagerBase must call this when how the data is shown (e.g. color) changes. More...
 
 ~FWTableManagerBase () override
 

Private Attributes

const FWTableManagerBasem_table
 

Additional Inherited Members

Detailed Description

Description: a TableManager used to pass the row header info of another table as the body of this table

Usage: This class is an implementation detail of how the FWTableWidget handles the row headers. The drawing of the row headers is done by the same widget as handles the drawing of the body. The FWAdapterRowHeaderTableManager is used to make the row header information appear to be just another table so that it works with the above mentioned widget.

Definition at line 31 of file FWAdapterRowHeaderTableManager.h.

Constructor & Destructor Documentation

FWAdapterRowHeaderTableManager::FWAdapterRowHeaderTableManager ( FWTableManagerBase iTable)

Definition at line 29 of file FWAdapterRowHeaderTableManager.cc.

29  : m_table(iTable) {
30  iTable->Connect("dataChanged()", "FWTableManagerBase", static_cast<FWTableManagerBase*>(this), "dataChanged()");
31  iTable->Connect("visualPropertiesChanged()",
32  "FWTableManagerBase",
33  static_cast<FWTableManagerBase*>(this),
34  "visualPropertiesChanged()");
35 }
FWAdapterRowHeaderTableManager::~FWAdapterRowHeaderTableManager ( )
override

Definition at line 42 of file FWAdapterRowHeaderTableManager.cc.

42 {}
FWAdapterRowHeaderTableManager::FWAdapterRowHeaderTableManager ( const FWAdapterRowHeaderTableManager )
delete

Member Function Documentation

FWTableCellRendererBase * FWAdapterRowHeaderTableManager::cellRenderer ( int  iSortedRowNumber,
int  iCol 
) const
overridevirtual

Returns the particular renderer used to handle the requested cell. Arguments: iSortedRowNumber: the row number from the present sort (i.e. the cell number of the view) iCol: the column number of the cell. The returned value must be used immediately and not held onto since the same Renderer can be used for subsequent calls

Implements FWTableManagerBase.

Definition at line 75 of file FWAdapterRowHeaderTableManager.cc.

References m_table, and FWTableManagerBase::rowHeader().

75  {
76  return m_table->rowHeader(iRow);
77 }
virtual FWTableCellRendererBase * rowHeader(int iSortedRowNumber) const
Returns the renderer for the row header for the sorted row number iSortedRowNumber.
std::vector< std::string > FWAdapterRowHeaderTableManager::getTitles ( ) const
overridevirtual

returns the title names for each column

Implements FWTableManagerBase.

Definition at line 70 of file FWAdapterRowHeaderTableManager.cc.

References names, and AlCaHLTBitMon_QueryRunRegistry::string.

70  {
71  std::vector<std::string> names(1, std::string("labels"));
72  return names;
73 }
const std::string names[nVars_]
void FWAdapterRowHeaderTableManager::implSort ( int  iCol,
bool  iSortOrder 
)
overridevirtual

Called by 'sort' method to actually handle the sorting of the rows. Arguments are the same as 'sort'.

Implements FWTableManagerBase.

Definition at line 59 of file FWAdapterRowHeaderTableManager.cc.

59 {}
int FWAdapterRowHeaderTableManager::numberOfColumns ( ) const
overridevirtual

Number of columns in the table.

Implements FWTableManagerBase.

Definition at line 66 of file FWAdapterRowHeaderTableManager.cc.

66 { return 1; }
int FWAdapterRowHeaderTableManager::numberOfRows ( ) const
overridevirtual

Number of rows in the table.

Implements FWTableManagerBase.

Definition at line 64 of file FWAdapterRowHeaderTableManager.cc.

References m_table, and FWTableManagerBase::numberOfRows().

64 { return m_table->numberOfRows(); }
virtual int numberOfRows() const =0
Number of rows in the table.
const FWAdapterRowHeaderTableManager& FWAdapterRowHeaderTableManager::operator= ( const FWAdapterRowHeaderTableManager )
delete
int FWAdapterRowHeaderTableManager::unsortedRowNumber ( int  iSortedRowNumber) const
overridevirtual

when passed the index to the sorted order of the rows it returns the original row number from the underlying data

Implements FWTableManagerBase.

Definition at line 68 of file FWAdapterRowHeaderTableManager.cc.

References m_table, and FWTableManagerBase::unsortedRowNumber().

68 { return m_table->unsortedRowNumber(iRow); }
virtual int unsortedRowNumber(int iSortedRowNumber) const =0
when passed the index to the sorted order of the rows it returns the original row number from the und...

Member Data Documentation

const FWTableManagerBase* FWAdapterRowHeaderTableManager::m_table
private

Definition at line 54 of file FWAdapterRowHeaderTableManager.h.

Referenced by cellRenderer(), numberOfRows(), and unsortedRowNumber().