CreateNTuple Class Reference

#include <CreateNTuple.h>

Inheritance diagram for CreateNTuple:

Inheritance graph
CreateNTupleBaseQDialog
[legend]
Collaboration diagram for CreateNTuple:

Collaboration graph
CreateNTupleBaseQDialogQLabelQLineEditQVBoxLayoutQHBoxLayoutQPushButtonQPixmapQListViewQCheckBoxQComboBoxDataSourceNTupleObservable
[legend]

List of all members.


Detailed Description

This class manages the Create NTuple dialog.

Author:
Xie Fang <xiefang@stanford.edu>

Definition at line 33 of file CreateNTuple.h.


Public Member Functions

 accept ()
 CreateNTuple (QWidget *parent=0, const char *name=0)
 The constructor.
 done (int r)
 enum {Rejected, Accepted}
 exec ()
 extension () const
 isModal () const
 isSizeGripEnabled () const
 orientation () const
 prop -whether the size grip is enabled
 prop -whether show() should pop up the dialog as modal or modeless
 reject ()
 result () const
 setExtension (QWidget *extension)
 setModal (bool modal)
 setOrientation (Orientation orientation)
 setResult (int i)
 setSizeGripEnabled (bool)
 show ()
 showExtension (bool showIt)

Public Attributes

QPushButtoncancelButton
QCheckBoxcolumnListCheckBox
QPushButtoncreateFileButton
QPushButtoncreateNTupleButton
QCheckBoxcutListCheckBox
QListViewm_ColumnListView
QListViewm_CutListView
QComboBoxm_ntuple_in
QLineEditm_ntuple_out
QLabeltextLabel1
QLabeltextLabel1_2
QLabelTextLabel1_3_2
QLabeltextLabel2

Protected Slots

virtual void languageChange ()

Protected Member Functions

virtual void columnListCheckBox_toggled (bool yes)
 Select or deselect all in column list.
virtual void createButtonClicked ()
 Create a new NTuple.
virtual void createFileButtonClicked ()
 Create a new NTuple and save to a file.
virtual void currentDataSourceChanged (int item)
 Current Item in the ComboBox changed.
virtual void cutListCheckBox_toggled (bool yes)
 Select or deselect all in cut list.

Protected Attributes

QVBoxLayoutlayout10
QHBoxLayoutlayout7
QHBoxLayoutlayout8
QVBoxLayoutlayout9

Private Member Functions

const std::vector
< PlotterBase * > & 
getDataCutList ()
 Get all the data cut used by the DataSource.
void getPlotterList (std::vector< PlotterBase * > &)
 Get all the plotter used by the canvas window.
void initListViews ()
 Initiate the list views, set column names.
void setColumnList ()
 Filter according to the selected column.
void setCutList ()
 Filter according to the selected cut.
void updateColumnList ()
 Update column list view.
void updateCutList ()
 Update cut list view.
void updateNTupleIn ()
 Update the ComboBox.

Private Attributes

unsigned int columnNumber
unsigned int cutNumber
std::vector
< std::string > 
m_column_list
std::vector< const
TupleCut * > 
m_cut_list
 The list of TupleCut objects.
NTuplenewNTuple

Constructor & Destructor Documentation

CreateNTuple ( QWidget parent = 0,
const char *  name = 0 
)

The constructor.

Definition at line 46 of file CreateNTuple.cxx.

References CreateNTuple::currentDataSourceChanged(), CreateNTuple::initListViews(), and CreateNTuple::updateNTupleIn().


Member Function Documentation

void columnListCheckBox_toggled ( bool  yes  )  [protected, virtual]

Select or deselect all in column list.

Reimplemented from CreateNTupleBase.

Definition at line 326 of file CreateNTuple.cxx.

References CreateNTuple::columnNumber, and CreateNTupleBase::m_ColumnListView.

void createButtonClicked (  )  [protected, virtual]

Create a new NTuple.

Implements CreateNTupleBase.

Definition at line 223 of file CreateNTuple.cxx.

References DataSource::columns(), NTupleController::createNTuple(), WindowController::instance(), NTupleController::instance(), DataSourceController::instance(), CreateNTuple::m_column_list, CreateNTuple::m_cut_list, CreateNTupleBase::m_ntuple_out, NTuple::rows(), CreateNTuple::setColumnList(), CreateNTuple::setCutList(), QLineEdit::text(), and CreateNTuple::updateNTupleIn().

void createFileButtonClicked (  )  [protected, virtual]

Create a new NTuple and save to a file.

Implements CreateNTupleBase.

Definition at line 251 of file CreateNTuple.cxx.

References QDialog::accept(), NTupleController::createNTupleToFile(), QMessageBox::critical(), QtFileDialog::getExportTupleFilename(), NTupleController::instance(), FitsController::instance(), DataSourceController::instance(), CreateNTuple::m_column_list, CreateNTuple::m_cut_list, CreateNTupleBase::m_ntuple_out, CreateNTuple::setColumnList(), CreateNTuple::setCutList(), and QLineEdit::text().

void currentDataSourceChanged ( int  item  )  [protected, virtual]

Current Item in the ComboBox changed.

Implements CreateNTupleBase.

Definition at line 182 of file CreateNTuple.cxx.

References DataSourceController::instance(), CreateNTupleBase::m_ntuple_in, CreateNTuple::updateColumnList(), and CreateNTuple::updateCutList().

Referenced by CreateNTuple::CreateNTuple().

void cutListCheckBox_toggled ( bool  yes  )  [protected, virtual]

Select or deselect all in cut list.

Reimplemented from CreateNTupleBase.

Definition at line 306 of file CreateNTuple.cxx.

References CreateNTuple::cutNumber, and CreateNTupleBase::m_CutListView.

const std::vector< PlotterBase * > & getDataCutList (  )  [private]

Get all the data cut used by the DataSource.

Definition at line 208 of file CreateNTuple.cxx.

References CutController::getCutList(), CreateNTuple::getPlotterList(), DataSourceController::instance(), and CutController::instance().

Referenced by CreateNTuple::updateCutList().

void getPlotterList ( std::vector< PlotterBase * > &  plotterlist  )  [private]

Get all the plotter used by the canvas window.

Definition at line 196 of file CreateNTuple.cxx.

References WindowController::instance().

Referenced by CreateNTuple::getDataCutList().

void initListViews (  )  [private]

Initiate the list views, set column names.

Definition at line 166 of file CreateNTuple.cxx.

References QListView::addColumn(), CreateNTupleBase::m_ColumnListView, and CreateNTupleBase::m_CutListView.

Referenced by CreateNTuple::CreateNTuple().

void languageChange (  )  [protected, virtual, slot, inherited]

Definition at line 197 of file CreateNTupleBase.cpp.

References QWhatsThis::add(), QToolTip::add(), CreateNTupleBase::cancelButton, CreateNTupleBase::columnListCheckBox, CreateNTupleBase::createFileButton, CreateNTupleBase::createNTupleButton, CreateNTupleBase::cutListCheckBox, CreateNTupleBase::m_ColumnListView, CreateNTupleBase::m_CutListView, CreateNTupleBase::m_ntuple_in, CreateNTupleBase::m_ntuple_out, QPushButton::setText(), QCheckBox::setText(), QLabel::setText(), CreateNTupleBase::textLabel1, CreateNTupleBase::textLabel1_2, CreateNTupleBase::TextLabel1_3_2, and CreateNTupleBase::textLabel2.

Referenced by CreateNTupleBase::CreateNTupleBase().

void setColumnList (  )  [private]

Filter according to the selected column.

Definition at line 345 of file CreateNTuple.cxx.

References CreateNTuple::columnNumber, QCheckListItem::isOn(), CreateNTuple::m_column_list, and CreateNTupleBase::m_ColumnListView.

Referenced by CreateNTuple::createButtonClicked(), and CreateNTuple::createFileButtonClicked().

void setCutList (  )  [private]

Filter according to the selected cut.

Definition at line 372 of file CreateNTuple.cxx.

References CreateNTuple::cutNumber, CreateNTuple::m_cut_list, and CreateNTupleBase::m_CutListView.

Referenced by CreateNTuple::createButtonClicked(), and CreateNTuple::createFileButtonClicked().

void updateColumnList (  )  [private]

Update column list view.

Definition at line 80 of file CreateNTuple.cxx.

References QListView::clear(), CreateNTuple::columnNumber, DataSourceController::instance(), and CreateNTupleBase::m_ColumnListView.

Referenced by CreateNTuple::currentDataSourceChanged().

void updateCutList (  )  [private]

Update cut list view.

Definition at line 101 of file CreateNTuple.cxx.

References QString::arg(), QListView::clear(), CreateNTuple::cutNumber, CreateNTuple::getDataCutList(), Range::high(), Range::low(), CreateNTuple::m_cut_list, CreateNTupleBase::m_CutListView, hippodraw::Axes::X, and hippodraw::Axes::Y.

Referenced by CreateNTuple::currentDataSourceChanged().

void updateNTupleIn (  )  [private]

Update the ComboBox.

Definition at line 57 of file CreateNTuple.cxx.

References QComboBox::insertItem(), DataSourceController::instance(), and CreateNTupleBase::m_ntuple_in.

Referenced by CreateNTuple::createButtonClicked(), and CreateNTuple::CreateNTuple().


Member Data Documentation

QPushButton* cancelButton [inherited]

Definition at line 47 of file CreateNTupleBase.h.

Referenced by CreateNTupleBase::CreateNTupleBase(), and CreateNTupleBase::languageChange().

QCheckBox* columnListCheckBox [inherited]

Definition at line 40 of file CreateNTupleBase.h.

Referenced by CreateNTupleBase::CreateNTupleBase(), and CreateNTupleBase::languageChange().

unsigned int columnNumber [private]

Definition at line 37 of file CreateNTuple.h.

Referenced by CreateNTuple::columnListCheckBox_toggled(), CreateNTuple::setColumnList(), and CreateNTuple::updateColumnList().

QPushButton* createFileButton [inherited]

Definition at line 46 of file CreateNTupleBase.h.

Referenced by CreateNTupleBase::CreateNTupleBase(), and CreateNTupleBase::languageChange().

QPushButton* createNTupleButton [inherited]

Definition at line 45 of file CreateNTupleBase.h.

Referenced by CreateNTupleBase::CreateNTupleBase(), and CreateNTupleBase::languageChange().

QCheckBox* cutListCheckBox [inherited]

Definition at line 37 of file CreateNTupleBase.h.

Referenced by CreateNTupleBase::CreateNTupleBase(), and CreateNTupleBase::languageChange().

unsigned int cutNumber [private]

Definition at line 38 of file CreateNTuple.h.

Referenced by CreateNTuple::cutListCheckBox_toggled(), CreateNTuple::setCutList(), and CreateNTuple::updateCutList().

QVBoxLayout* layout10 [protected, inherited]

Definition at line 57 of file CreateNTupleBase.h.

Referenced by CreateNTupleBase::CreateNTupleBase().

QHBoxLayout* layout7 [protected, inherited]

Definition at line 56 of file CreateNTupleBase.h.

Referenced by CreateNTupleBase::CreateNTupleBase().

QHBoxLayout* layout8 [protected, inherited]

Definition at line 58 of file CreateNTupleBase.h.

Referenced by CreateNTupleBase::CreateNTupleBase().

QVBoxLayout* layout9 [protected, inherited]

Definition at line 55 of file CreateNTupleBase.h.

Referenced by CreateNTupleBase::CreateNTupleBase().

std::vector< std::string > m_column_list [private]

Definition at line 43 of file CreateNTuple.h.

Referenced by CreateNTuple::createButtonClicked(), CreateNTuple::createFileButtonClicked(), and CreateNTuple::setColumnList().

QListView* m_ColumnListView [inherited]

Definition at line 41 of file CreateNTupleBase.h.

Referenced by CreateNTuple::columnListCheckBox_toggled(), CreateNTupleBase::CreateNTupleBase(), CreateNTuple::initListViews(), CreateNTupleBase::languageChange(), CreateNTuple::setColumnList(), and CreateNTuple::updateColumnList().

std::vector< const TupleCut * > m_cut_list [private]

The list of TupleCut objects.

Definition at line 42 of file CreateNTuple.h.

Referenced by CreateNTuple::createButtonClicked(), CreateNTuple::createFileButtonClicked(), CreateNTuple::setCutList(), and CreateNTuple::updateCutList().

QListView* m_CutListView [inherited]

Definition at line 38 of file CreateNTupleBase.h.

Referenced by CreateNTupleBase::CreateNTupleBase(), CreateNTuple::cutListCheckBox_toggled(), CreateNTuple::initListViews(), CreateNTupleBase::languageChange(), CreateNTuple::setCutList(), and CreateNTuple::updateCutList().

QComboBox* m_ntuple_in [inherited]

Definition at line 44 of file CreateNTupleBase.h.

Referenced by CreateNTupleBase::CreateNTupleBase(), CreateNTuple::currentDataSourceChanged(), CreateNTupleBase::languageChange(), and CreateNTuple::updateNTupleIn().

QLineEdit* m_ntuple_out [inherited]

Definition at line 43 of file CreateNTupleBase.h.

Referenced by CreateNTuple::createButtonClicked(), CreateNTuple::createFileButtonClicked(), CreateNTupleBase::CreateNTupleBase(), and CreateNTupleBase::languageChange().

NTuple* newNTuple [private]

Definition at line 45 of file CreateNTuple.h.

QLabel* textLabel1 [inherited]

Definition at line 36 of file CreateNTupleBase.h.

Referenced by CreateNTupleBase::CreateNTupleBase(), and CreateNTupleBase::languageChange().

QLabel* textLabel1_2 [inherited]

Definition at line 42 of file CreateNTupleBase.h.

Referenced by CreateNTupleBase::CreateNTupleBase(), and CreateNTupleBase::languageChange().

QLabel* TextLabel1_3_2 [inherited]

Definition at line 48 of file CreateNTupleBase.h.

Referenced by CreateNTupleBase::CreateNTupleBase(), and CreateNTupleBase::languageChange().

QLabel* textLabel2 [inherited]

Definition at line 39 of file CreateNTupleBase.h.

Referenced by CreateNTupleBase::CreateNTupleBase(), and CreateNTupleBase::languageChange().


The documentation for this class was generated from the following files:
Generated for HippoDraw Class Library by doxygen