CMS 3D CMS Logo

List of all members | Public Member Functions | Static Public Attributes | Private Attributes
FWDisplayProperties Class Reference

#include <Fireworks/Core/interface/FWDisplayProperties.h>

Public Member Functions

Color_t color () const
 
 FWDisplayProperties (Color_t iColor, bool isVisible, Char_t transparency)
 
bool isVisible () const
 
bool operator!= (const FWDisplayProperties &iRHS) const
 
bool operator== (const FWDisplayProperties &iRHS) const
 
void setColor (Color_t iColor)
 
void setIsVisible (bool iSet)
 
void setTransparency (Char_t transparency)
 
Char_t transparency () const
 

Static Public Attributes

static const FWDisplayProperties defaultProperties
 

Private Attributes

Color_t m_color
 
bool m_isVisible
 
Char_t m_transparency
 

Detailed Description

Description: <one line="" class="" summary>="">

Usage: <usage>

Definition at line 28 of file FWDisplayProperties.h.

Constructor & Destructor Documentation

FWDisplayProperties::FWDisplayProperties ( Color_t  iColor,
bool  isVisible,
Char_t  transparency 
)

Note that I removed the default values to make sure that properties do not get copied around via the not so uncommon paradigm:

FWDisplayProperties new(old.color(), old.isVisible());

or similar which has the drawback of not carring over transparency information.

In general it's a good idea to have a copy and modify approach when changing updating only one value.

Definition at line 23 of file FWDisplayProperties.cc.

Member Function Documentation

Color_t FWDisplayProperties::color ( ) const
inline

Definition at line 51 of file FWDisplayProperties.h.

References m_color.

Referenced by FWEventItemsManager::add(), FWDigitSetProxyBuilder::addBox(), FWInteractionList::added(), FWTrackHitsDetailView::addHits(), FWConvTrackHitsDetailView::addHits(), FWTrackHitsDetailView::addModules(), FWConvTrackHitsDetailView::addModules(), FWPFCandidateWithHitsProxyBuilder::build(), FWBeamSpotProxyBuilder::build(), FWPFClusterRPZProxyBuilder::build(), FWTauProxyBuilderBase::buildBaseTau(), FWJetProxyBuilder::buildViewType(), FWCollectionSummaryWidget::colorClicked(), CmsShowModelPopup::colorSetChanged(), CmsShowEDI::colorSetChanged(), FWCollectionSummaryWidget::createColorPopup(), FWProxyBuilderBase::createCompound(), FWCollectionSummaryWidget::displayChanged(), CmsShowEDI::fillEDIFrame(), CmsShowModelPopup::fillModelPopup(), FWEventItem::FWEventItem(), FWInteractionList::itemChanged(), FWCollectionSummaryWidget::itemColorClicked(), FWCandidateHGCalLegoProxyBuilder::localModelChanges(), FWPFCandidatesLegoProxyBuilder::localModelChanges(), FWCandidateLegoProxyBuilder::localModelChanges(), FWPFPatJetLegoProxyBuilder< T >::localModelChanges(), FWPFClusterLegoProxyBuilder::localModelChanges(), FWPFEcalRecHitLegoProxyBuilder::localModelChanges(), fireworks::makeRhoPhiSuperCluster(), FWInteractionList::modelChanges(), FWDigitSetProxyBuilder::modelChanges(), FWCollectionSummaryWidget::setBackgroundToWhite(), FWCollectionSummaryModelCellRenderer::setData(), FWEventItem::setDefaultDisplayProperties(), fireworks::setupAddElement(), FWPFBlockProxyBuilder::setupClusterElement(), FWProxyBuilderBase::setupElement(), CmsShowEDI::updateDisplay(), and CmsShowModelPopup::updateDisplay().

51  {
52  return m_color;
53  }
bool FWDisplayProperties::isVisible ( ) const
inline

Definition at line 59 of file FWDisplayProperties.h.

References m_isVisible.

Referenced by FWDigitSetProxyBuilder::addBox(), FWInteractionList::added(), FWPFEcalRecHitRPProxyBuilder::build(), FWSimpleProxyBuilder::build(), FWPFEcalClusterRPZProxyBuilder::build(), FWPFHcalClusterRPZProxyBuilder::build(), FWSimpleProxyBuilder::buildViewType(), FWCollectionSummaryTableManager::buttonReleasedInRowHeader(), FWTableViewTableManager::cellRenderer(), FWModelContextMenuHandler::chosenItem(), FWFromSliceSelector::clear(), FWTableViewTableManager::dataChanged(), FWCollectionSummaryWidget::displayChanged(), FWHistSliceSelector::doSelect(), FWHFTowerSliceSelector::doSelect(), FWHGTowerSliceSelector::doSelect(), FWHistSliceSelector::doUnselect(), FWHFTowerSliceSelector::doUnselect(), FWHGTowerSliceSelector::doUnselect(), FWCandidateTowerProxyBuilder::fillCaloData(), FWPFCandidateTowerProxyBuilder::fillCaloData(), FWCaloTowerProxyBuilderBase::fillCaloData(), FWHFTowerProxyBuilderBase::fillCaloData(), FWHGTowerProxyBuilderBase::fillCaloData(), CmsShowEDI::fillEDIFrame(), CmsShowModelPopup::fillModelPopup(), FWInteractionList::itemChanged(), FWInteractionList::modelChanges(), FWDigitSetProxyBuilder::modelChanges(), FWEventItem::modelInfo(), FWTableViewTableManager::rowHeader(), Vispa.Gui.VispaWidget.VispaWidget::setBodyWidget(), FWCollectionSummaryModelCellRenderer::setData(), FWEventItem::setDefaultDisplayProperties(), FWEventItem::setDisplayProperties(), FWModelContextMenuHandler::showSelectedModelContext(), CmsShowEDI::updateDisplay(), CmsShowModelPopup::updateDisplay(), FWTrackProxyBuilderFullFramework::visibilityModelChanges(), and FWSimpleProxyBuilder::visibilityModelChanges().

59  {
60  return m_isVisible;
61  }
bool FWDisplayProperties::operator!= ( const FWDisplayProperties iRHS) const
inline

Definition at line 68 of file FWDisplayProperties.h.

68  {
69  return not (*this == iRHS);
70  }
bool FWDisplayProperties::operator== ( const FWDisplayProperties iRHS) const
inline

Definition at line 63 of file FWDisplayProperties.h.

References m_color, m_isVisible, and m_transparency.

63  {
64  return m_color == iRHS.m_color
65  && m_isVisible == iRHS.m_isVisible
66  && m_transparency == iRHS.m_transparency;
67  }
void FWDisplayProperties::setColor ( Color_t  iColor)
inline
void FWDisplayProperties::setIsVisible ( bool  iSet)
inline
void FWDisplayProperties::setTransparency ( Char_t  transparency)
inline

Notice that transparency in root is in the range [0, 100]

Definition at line 81 of file FWDisplayProperties.h.

References m_transparency, and transparency().

Referenced by CmsShowEDI::changeItemOpacity(), CmsShowModelPopup::changeModelOpacity(), and FWEventItem::setDefaultDisplayProperties().

81  {
83  transparency = transparency > 100 ? 100 : transparency;
85  }
Char_t transparency() const
Char_t FWDisplayProperties::transparency ( ) const
inline

Member Data Documentation

const FWDisplayProperties FWDisplayProperties::defaultProperties
static

Definition at line 32 of file FWDisplayProperties.h.

Referenced by FWGUIEventDataAdder::addNewItem().

Color_t FWDisplayProperties::m_color
private

Definition at line 98 of file FWDisplayProperties.h.

Referenced by color(), operator==(), and setColor().

bool FWDisplayProperties::m_isVisible
private

Definition at line 99 of file FWDisplayProperties.h.

Referenced by isVisible(), operator==(), and setIsVisible().

Char_t FWDisplayProperties::m_transparency
private

Definition at line 100 of file FWDisplayProperties.h.

Referenced by operator==(), setTransparency(), and transparency().