CMS 3D CMS Logo

Public Types | Public Member Functions | Private Member Functions | Private Attributes

FWGeometryTableView Class Reference

#include <FWGeometryTableView.h>

Inheritance diagram for FWGeometryTableView:
FWViewBase FWParameterSetterEditorBase FWConfigurableParameterizable FWParameterizable FWConfigurable

List of all members.

Public Types

enum  EMode { kNode, kVolume }

Public Member Functions

virtual void addTo (FWConfiguration &) const
void cdNode (int)
void cdTop ()
void cdUp ()
void cellClicked (Int_t iRow, Int_t iColumn, Int_t iButton, Int_t iKeyMod, Int_t iGlobalX, Int_t iGlobalY)
void chosenItem (int)
void filterListCallback ()
void filterTextEntryCallback ()
 FWGeometryTableView (TEveWindowSlot *, FWColorManager *, TGeoNode *, TObjArray *)
int getAutoExpand () const
std::string getFilter () const
bool getIgnoreVisLevelWhenFilter () const
FWGeometryTableManagergetTableManager ()
int getTopNodeIdx () const
int getVisLevel () const
bool getVolumeMode () const
void nodeColorChangeRequested (Color_t)
void populate3DViewsFromConfig ()
void printTable ()
virtual void saveImageTo (const std::string &iName) const
void selectView (int)
void setBackgroundColor ()
virtual void setFrom (const FWConfiguration &)
void setPath (int, std::string &)
void updateFilter (std::string &)
virtual ~FWGeometryTableView ()

Private Member Functions

void autoExpandChanged ()
 ClassDef (FWGeometryTableView, 0)
 FWGeometryTableView (const FWGeometryTableView &)
void loadGeometry ()
void makeSetter (TGCompositeFrame *frame, FWParameterBase *param)
void modeChanged ()
const FWGeometryTableViewoperator= (const FWGeometryTableView &)
void refreshTable3D ()
void resetSetters ()

Private Attributes

FWLongParameter m_autoExpand
FWColorManagerm_colorManager
FWColorPopupm_colorPopup
FWGeoTopNodem_eveTopNode
TEveWindowFrame * m_eveWindow
FWStringParameter m_filter
FWGUIValidatingTextEntrym_filterEntry
FWGeoMaterialValidatorm_filterValidator
TGCompositeFrame * m_frame
FWEnumParameter m_mode
std::vector< boost::shared_ptr
< FWParameterSetterBase > > 
m_setters
TGCompositeFrame * m_settersFrame
FWGeometryTableManagerm_tableManager
FWTableWidgetm_tableWidget
FWLongParameter m_topNodeIdx
FWViewCombom_viewBox
const FWConfigurationm_viewersConfig
FWLongParameter m_visLevel
FWBoolParameter m_visLevelFilter

Detailed Description

Definition at line 46 of file FWGeometryTableView.h.


Member Enumeration Documentation

Enumerator:
kNode 
kVolume 

Definition at line 54 of file FWGeometryTableView.h.

{ kNode, kVolume };

Constructor & Destructor Documentation

FWGeometryTableView::FWGeometryTableView ( TEveWindowSlot *  iParent,
FWColorManager colMng,
TGeoNode *  tn,
TObjArray *  volumes 
)

Definition at line 211 of file FWGeometryTableView.cc.

References FWEnumParameter::addEntry(), autoExpandChanged(), cdTop(), FWGenericParameter< T >::changed_, FWTableWidget::disableGrowInWidth(), FWGUIValidatingTextEntry::getListBox(), FWGeometryTableManager::loadGeometry(), m_autoExpand, m_eveWindow, m_filterEntry, m_filterValidator, m_frame, m_mode, m_settersFrame, m_tableManager, m_tableWidget, m_viewBox, m_visLevel, m_visLevelFilter, modeChanged(), refreshTable3D(), resetSetters(), FWTableWidget::SetBackgroundColor(), FWTableWidget::SetHeaderBackgroundColor(), FWTableWidget::SetLineSeparatorColor(), FWGUIValidatingTextEntry::setMaxListBoxHeight(), and FWGUIValidatingTextEntry::setValidator().

   : FWViewBase(FWViewType::kGeometryTable),
     m_mode(this, "Mode:", 0l, 0l, 1l),
     m_filter(this,"Materials:",std::string()),
     m_autoExpand(this,"ExpandList:", 1l, 0l, 100l),
     m_visLevel(this,"VisLevel:", 3l, 1l, 100l),
     m_visLevelFilter(this,"IgnoreVisLevelOnFilter", true),
     m_topNodeIdx(this, "TopNodeIndex", -1l, 0, 1e7),
     m_colorManager(colMng),
     m_tableManager(0),
     m_eveTopNode(0),
     m_colorPopup(0),
     m_eveWindow(0),
     m_frame(0),
     m_viewBox(0),
     m_filterEntry(0),
     m_filterValidator(0),
     m_viewersConfig(0)
{
   m_eveWindow = iParent->MakeFrame(0);
   TGCompositeFrame* xf = m_eveWindow->GetGUICompositeFrame();

   m_frame = new TGVerticalFrame(xf);
   xf->AddFrame(m_frame, new TGLayoutHints(kLHintsExpandX | kLHintsExpandY));

   m_mode.addEntry(0, "Node");
   m_mode.addEntry(1, "Volume");
   
   m_tableManager = new FWGeometryTableManager(this);
   m_mode.changed_.connect(boost::bind(&FWGeometryTableView::modeChanged,this));
   m_autoExpand.changed_.connect(boost::bind(&FWGeometryTableView::autoExpandChanged, this));
   m_visLevel.changed_.connect(boost::bind(&FWGeometryTableView::refreshTable3D,this));
   m_visLevelFilter.changed_.connect(boost::bind(&FWGeometryTableView::refreshTable3D,this));


   // top row
   {
      TGHorizontalFrame* hp =  new TGHorizontalFrame(m_frame);
 
      if (0) { TGTextButton* fileOpen = new TGTextButton (hp, "Open Geometry File");
         hp->AddFrame(fileOpen);
         fileOpen->Connect("Clicked()","FWGeometryTableView",this,"browse()");
      }
      {
         TGTextButton* rb = new TGTextButton (hp, "CdTop");
         hp->AddFrame(rb, new TGLayoutHints(kLHintsNormal, 2, 2, 0, 0) );
         rb->Connect("Clicked()","FWGeometryTableView",this,"cdTop()");
      } {
         TGTextButton* rb = new TGTextButton (hp, "CdUp");
         hp->AddFrame(rb, new TGLayoutHints(kLHintsNormal, 2, 2, 0, 0));
         rb->Connect("Clicked()","FWGeometryTableView",this,"cdUp()");
      }

      {
         m_viewBox = new FWViewCombo(hp, this);
         hp->AddFrame( m_viewBox,new TGLayoutHints(kLHintsExpandY, 2, 2, 0, 0));
      }
      {
         hp->AddFrame(new TGLabel(hp, "Filter:"), new TGLayoutHints(kLHintsBottom, 10, 0, 0, 2));
         m_filterEntry = new FWGUIValidatingTextEntry(hp);
         m_filterEntry->SetHeight(20);
         m_filterValidator = new FWGeoMaterialValidator(m_tableManager);
         m_filterEntry->setValidator(m_filterValidator);
         hp->AddFrame(m_filterEntry, new TGLayoutHints(kLHintsExpandX,  1, 2, 1, 0));
         m_filterEntry->setMaxListBoxHeight(150);
         m_filterEntry->getListBox()->Connect("Selected(int)", "FWGeometryTableView",  this, "filterListCallback()");
         m_filterEntry->Connect("ReturnPressed()", "FWGeometryTableView",  this, "filterTextEntryCallback()");

         gVirtualX->GrabKey( m_filterEntry->GetId(),gVirtualX->KeysymToKeycode((int)kKey_A),  kKeyControlMask, true);
      }
      m_frame->AddFrame(hp,new TGLayoutHints(kLHintsLeft|kLHintsExpandX, 4, 2, 2, 0));
   }

   m_settersFrame = new TGHorizontalFrame(m_frame);
   m_frame->AddFrame( m_settersFrame, new TGLayoutHints(kLHintsExpandX,4,2,2,2));
   m_settersFrame->SetCleanup(kDeepCleanup);

   m_tableWidget = new FWTableWidget(m_tableManager, m_frame); 
   m_frame->AddFrame(m_tableWidget,new TGLayoutHints(kLHintsExpandX|kLHintsExpandY,2,2,0,0));
   m_tableWidget->SetBackgroundColor(0xffffff);
   m_tableWidget->SetLineSeparatorColor(0x000000);
   m_tableWidget->SetHeaderBackgroundColor(0xececec);
   m_tableWidget->Connect("cellClicked(Int_t,Int_t,Int_t,Int_t,Int_t,Int_t)",
                          "FWGeometryTableView",this,
                          "cellClicked(Int_t,Int_t,Int_t,Int_t,Int_t,Int_t)");
   m_tableWidget->disableGrowInWidth();
   resetSetters();

   if (tn)
   {
      m_tableManager->loadGeometry(tn, volumes);
      cdTop();
   }

   m_frame->MapSubwindows();
   m_frame->Layout();
   xf->Layout();
   m_frame->MapWindow();
}
FWGeometryTableView::~FWGeometryTableView ( ) [virtual]

Definition at line 311 of file FWGeometryTableView.cc.

References m_eveTopNode, m_eveWindow, m_frame, m_tableManager, and x.

{
   if (m_eveTopNode)
   {
      while ( m_eveTopNode->HasParents()) {
         TEveElement* x =  *m_eveTopNode->BeginParents();
        x->RemoveElement(m_eveTopNode);
      }
      m_eveTopNode->DecDenyDestroy();
   }

   // take out composite frame and delete it directly (zwithout the timeout)
   TGCompositeFrame *frame = m_eveWindow->GetGUICompositeFrame();
   frame->RemoveFrame( m_frame );
   delete m_frame;

   m_eveWindow->DestroyWindowAndSlot();
   delete m_tableManager;
}
FWGeometryTableView::FWGeometryTableView ( const FWGeometryTableView ) [private]

Member Function Documentation

void FWGeometryTableView::addTo ( FWConfiguration iTo) const [virtual]

Reimplemented from FWConfigurableParameterizable.

Definition at line 334 of file FWGeometryTableView.cc.

References FWConfiguration::addKeyValue(), m_eveTopNode, and n.

{
   FWConfigurableParameterizable::addTo(iTo);

   FWConfiguration viewers(1);
   if (m_eveTopNode)
   { 
      for (TEveElement::List_i it = m_eveTopNode->BeginParents(); it != m_eveTopNode->EndParents(); ++it )
      {
         FWConfiguration tempArea;
         TEveScene* scene = dynamic_cast<TEveScene*>(*it);
         std::string n = scene->GetElementName();
         viewers.addKeyValue(n, tempArea);
      }
   }
   iTo.addKeyValue("Viewers", viewers, true);
}
void FWGeometryTableView::autoExpandChanged ( ) [private]
void FWGeometryTableView::cdNode ( int  idx)

Definition at line 647 of file FWGeometryTableView.cc.

References FWGeometryTableManager::getNodePath(), m_tableManager, AlCaHLTBitMon_ParallelJobs::p, and setPath().

Referenced by chosenItem(), and setFrom().

{
   std::string p;
   m_tableManager->getNodePath(idx, p);
   setPath(idx, p);
}
void FWGeometryTableView::cdTop ( )

Definition at line 654 of file FWGeometryTableView.cc.

References m_tableManager, path(), FWGeometryTableManager::refEntries(), and setPath().

Referenced by FWGeometryTableView().

{
   std::string path = "/" ;
   path += m_tableManager->refEntries().at(0).name();
   setPath(-1, path ); 
}
void FWGeometryTableView::cdUp ( )
void FWGeometryTableView::cellClicked ( Int_t  iRow,
Int_t  iColumn,
Int_t  iButton,
Int_t  iKeyMod,
Int_t  iGlobalX,
Int_t  iGlobalY 
)

Definition at line 472 of file FWGeometryTableView.cc.

References FWColorManager::backgroundColorIndex(), colors, FWTableManagerBase::dataChanged(), FWColorManager::fillLimitedColors(), FWGeometryTableManager::firstColumnClicked(), FWGeometryTableManager::getVisibility(), FWGeometryTableManager::getVisibilityChld(), FWColorPopup::InitContent(), FWColorManager::kBlackIndex, kCamera, FWGeometryTableManager::kColor, kInspectMaterial, kInspectShape, FWGeometryTableManager::kName, kSetTopNode, kSetTopNodeCam, kTableDebug, FWGeometryTableManager::kVisChild, kVisOff, kVisOn, FWGeometryTableManager::kVisSelf, m_colorManager, m_colorPopup, m_eveTopNode, m_tableManager, FWColorPopup::PlacePopup(), FWGeometryTableManager::refSelected(), FWColorPopup::ResetColors(), FWColorPopup::SetName(), FWGeometryTableManager::setSelection(), FWGeometryTableManager::setVisibility(), and FWGeometryTableManager::setVisibilityChld().

{
   m_tableManager->setSelection(iRow, iColumn, iButton);
   FWGeometryTableManager::NodeInfo& ni = *m_tableManager->refSelected();

   if (iButton == kButton1) 
   {
      if (iColumn == FWGeometryTableManager::kName)
      {
         m_tableManager->firstColumnClicked(iRow);
         return;
      }
      else if (iColumn == FWGeometryTableManager::kColor)
      { 
         std::vector<Color_t> colors;
         m_colorManager->fillLimitedColors(colors);
      
         if (!m_colorPopup) {
            m_colorPopup = new FWColorPopup(gClient->GetDefaultRoot(), colors.front());
            m_colorPopup->InitContent("", colors);
            m_colorPopup->Connect("ColorSelected(Color_t)","FWGeometryTableView", const_cast<FWGeometryTableView*>(this), "nodeColorChangeRequested(Color_t)");
         }
         m_colorPopup->SetName("Selected");
         m_colorPopup->ResetColors(colors, m_colorManager->backgroundColorIndex()==FWColorManager::kBlackIndex);
         m_colorPopup->PlacePopup(x, y, m_colorPopup->GetDefaultWidth(), m_colorPopup->GetDefaultHeight());
         return;
      }
      else
      {
         bool elementChanged = false;
         if (iColumn ==  FWGeometryTableManager::kVisSelf)
         {
            m_tableManager->setVisibility(ni, !m_tableManager->getVisibility(ni));
            elementChanged = true;
         }
         if (iColumn ==  FWGeometryTableManager::kVisChild)
         { 
            m_tableManager->setVisibilityChld(ni, !m_tableManager->getVisibilityChld(ni));; 
            elementChanged = true;
         }


         if (m_eveTopNode && elementChanged)
         {
            m_eveTopNode->ElementChanged();
            gEve->RegisterRedraw3D();
         }
      }
        

      m_tableManager->dataChanged();

   }
   else if (iColumn == FWGeometryTableManager::kName)
   {
      FWPopupMenu* m_nodePopup = new FWPopupMenu();
      m_nodePopup->AddEntry("Set As Top Node", kSetTopNode);
      m_nodePopup->AddEntry("Set As Top Node And Camera Center", kSetTopNodeCam);
      m_nodePopup->AddSeparator();
      m_nodePopup->AddEntry("Rnr Off For All Children", kVisOff);
      m_nodePopup->AddEntry("Rnr On For All Children", kVisOn);
      m_nodePopup->AddSeparator();
      m_nodePopup->AddEntry("Set Camera Center", kCamera);
      m_nodePopup->AddSeparator();
      m_nodePopup->AddEntry("InspectMaterial", kInspectMaterial);
      m_nodePopup->AddEntry("InspectShape", kInspectShape);
     m_nodePopup->AddEntry("Table Debug", kTableDebug);

      m_nodePopup->PlaceMenu(x,y,true,true);
      m_nodePopup->Connect("Activated(Int_t)",
                           "FWGeometryTableView",
                           const_cast<FWGeometryTableView*>(this),
                           "chosenItem(Int_t)");
   }
}
void FWGeometryTableView::chosenItem ( int  x)

Definition at line 548 of file FWGeometryTableView.cc.

References cdNode(), FWGeometryTableManager::getNodeMatrix(), kCamera, kInspectMaterial, kInspectShape, kSetTopNode, kSetTopNodeCam, kTableDebug, kVisOff, kVisOn, FWGeometryTableManager::NodeInfo::m_node, FWGeometryTableManager::m_selectedIdx, m_tableManager, mergeVDriftHistosByStation::name, FWGeometryTableManager::printMaterials(), refreshTable3D(), FWGeometryTableManager::refSelected(), FWGeometryTableManager::setDaughtersSelfVisibility(), and v.

{
   FWGeometryTableManager::NodeInfo& ni = *m_tableManager->refSelected();
   TGeoVolume* gv = ni.m_node->GetVolume();
   bool visible = true;
   bool resetHome = false;
   if (gv)
   {
      switch (x) {
        case kVisOff:
            visible = false;
        case kVisOn:
           m_tableManager->setDaughtersSelfVisibility(visible);
            refreshTable3D();
            break;

         case kInspectMaterial:
            gv->InspectMaterial();
            break;
         case kInspectShape:
            gv->InspectShape();
            break;
         case kTableDebug:
            // std::cout << "node name " << ni.name() << "parent " <<m_tableManager->refEntries()[ni.m_parent].name() <<  std::endl;
            // printf("node expanded [%d] imported[%d] children[%d]\n", ni.m_expanded,m_tableManager->nodeImported(m_tableManager->m_selectedIdx) ,  ni.m_node->GetNdaughters());
            //            m_tableManager->printChildren(
            // m_tableManager->m_selectedIdx);
            m_tableManager->printMaterials();
            break;

         case kSetTopNode:
            cdNode(m_tableManager->m_selectedIdx);
            break;

         case kSetTopNodeCam:
            cdNode(m_tableManager->m_selectedIdx);
            resetHome = true;
         case kCamera:
         {
            TGeoHMatrix mtx;
            m_tableManager->getNodeMatrix( ni, mtx);

            static double pnt[3];
            TGeoBBox* bb = static_cast<TGeoBBox*>( ni.m_node->GetVolume()->GetShape());
            const double* origin = bb->GetOrigin();
            mtx.LocalToMaster(origin, pnt);

            TEveElementList* vl = gEve->GetViewers();
            for (TEveElement::List_i it = vl->BeginChildren(); it != vl->EndChildren(); ++it)
            {
               TEveViewer* v = ((TEveViewer*)(*it));
               TString name = v->GetElementName();
               if (name.Contains("3D"))
               {
                  v->GetGLViewer()->SetDrawCameraCenter(true);
                  TGLCamera& cam = v->GetGLViewer()->CurrentCamera();
                  cam.SetExternalCenter(true);
                  cam.SetCenterVec(pnt[0], pnt[1], pnt[2]);
               }
            }
            if (resetHome) gEve->FullRedraw3D(true, true);
            break;
         }
      }
   }
}
FWGeometryTableView::ClassDef ( FWGeometryTableView  ,
 
) [private]
void FWGeometryTableView::filterListCallback ( )

Definition at line 712 of file FWGeometryTableView.cc.

References FWGUIValidatingTextEntry::getListBox(), list(), m_filterEntry, m_filterValidator, FWGeoMaterialValidator::m_list, and updateFilter().

{ 
   //   std::cout << "list click ed \n" ;
   TGListBox* list =   m_filterEntry->getListBox();
   TList selected;
   list->GetSelectedEntries(&selected);
   if (selected.GetEntries() == 1)
   {
      const TGLBEntry* entry = dynamic_cast<TGLBEntry*> (selected.First());
      updateFilter( m_filterValidator->m_list[ entry->EntryId()].n);
   } 
}
void FWGeometryTableView::filterTextEntryCallback ( )

Definition at line 697 of file FWGeometryTableView.cc.

References funct::exp(), fwLog, FWGeoMaterialValidator::isStringValid(), fwlog::kError, m_filterEntry, m_filterValidator, and updateFilter().

{
   // std::cout << "text entry click ed \n" ;
   std::string exp = m_filterEntry->GetText();
   if ( m_filterValidator->isStringValid(exp)) 
   {
      updateFilter(exp);
   }
   else
   {
      fwLog(fwlog::kError) << "filter expression not valid." << std::endl;
      return;
   }
}
int FWGeometryTableView::getAutoExpand ( ) const [inline]
std::string FWGeometryTableView::getFilter ( ) const [inline]
bool FWGeometryTableView::getIgnoreVisLevelWhenFilter ( ) const [inline]
FWGeometryTableManager* FWGeometryTableView::getTableManager ( ) [inline]
int FWGeometryTableView::getTopNodeIdx ( ) const [inline]
int FWGeometryTableView::getVisLevel ( ) const [inline]

Definition at line 79 of file FWGeometryTableView.h.

References m_visLevel, and FWGenericParameter< T >::value().

Referenced by FWGeoTopNode::Paint().

{return m_visLevel.value(); }
bool FWGeometryTableView::getVolumeMode ( ) const [inline]
void FWGeometryTableView::loadGeometry ( ) [private]
void FWGeometryTableView::makeSetter ( TGCompositeFrame *  frame,
FWParameterBase param 
) [private]

Definition at line 420 of file FWGeometryTableView.cc.

References m_frame, m_setters, and FWParameterSetterBase::makeSetterFor().

Referenced by resetSetters().

{
   boost::shared_ptr<FWParameterSetterBase> ptr( FWParameterSetterBase::makeSetterFor(param) );
   ptr->attach(param, this);
 
   TGFrame* m_frame = ptr->build(frame, false);
   frame->AddFrame(m_frame, new TGLayoutHints(kLHintsExpandX));

   m_setters.push_back(ptr);
}
void FWGeometryTableView::modeChanged ( ) [private]

Definition at line 758 of file FWGeometryTableView.cc.

References m_tableManager, refreshTable3D(), and FWGeometryTableManager::updateFilter().

Referenced by FWGeometryTableView().

{
   // reset filter when change mode
   //   std::cout << "chage mode \n";
   m_tableManager->updateFilter();
   refreshTable3D();
}
void FWGeometryTableView::nodeColorChangeRequested ( Color_t  col)
const FWGeometryTableView& FWGeometryTableView::operator= ( const FWGeometryTableView ) [private]
void FWGeometryTableView::populate3DViewsFromConfig ( )

Definition at line 368 of file FWGeometryTableView.cc.

References FWConfiguration::keyValues(), m_eveTopNode, m_viewBox, m_viewersConfig, asciidump::s, and FWViewCombo::setElement().

Referenced by FWGUIManager::setFrom().

{
   // post-config 
   if (m_viewersConfig) {
      TEveElementList* scenes = gEve->GetScenes();
      const FWConfiguration::KeyValues* keyVals = m_viewersConfig->keyValues();
      if(0!=keyVals) 
      {
         for(FWConfiguration::KeyValuesIt it = keyVals->begin(); it!= keyVals->end(); ++it) {
    
            TString sname = it->first;
            TEveElement* s = scenes->FindChild(sname);
            if (s)
            {
               // std::cout << sname.Data() << std::endl;   
               if (!m_eveTopNode) {
                  m_eveTopNode = new FWGeoTopNode(this);
                  m_eveTopNode->IncDenyDestroy();
                  m_viewBox->setElement(m_eveTopNode);
               }
               s->AddElement(m_eveTopNode);
            }
         }   
      }
   }
}
void FWGeometryTableView::printTable ( )

Definition at line 638 of file FWGeometryTableView.cc.

References m_tableManager, and FWGeometryTableManager::printChildren().

{
   // print all entries
   m_tableManager->printChildren(-1);
}
void FWGeometryTableView::refreshTable3D ( ) [private]

Definition at line 775 of file FWGeometryTableView.cc.

References m_eveTopNode, m_tableManager, and FWGeometryTableManager::redrawTable().

Referenced by chosenItem(), FWGeometryTableView(), modeChanged(), nodeColorChangeRequested(), setPath(), and updateFilter().

{
   m_tableManager->redrawTable();

   if ( m_eveTopNode) {
      m_eveTopNode->ElementChanged();
      gEve->FullRedraw3D(false, true);
   } 
}
void FWGeometryTableView::resetSetters ( ) [private]

Definition at line 396 of file FWGeometryTableView.cc.

References f, m_autoExpand, m_frame, m_mode, m_setters, m_settersFrame, m_visLevel, m_visLevelFilter, and makeSetter().

Referenced by FWGeometryTableView(), and setFrom().

{

   if (!m_settersFrame->GetList()->IsEmpty())
   {
      m_setters.clear();

      TGFrameElement *el = (TGFrameElement*) m_settersFrame->GetList()->First();
      TGHorizontalFrame* f = (TGHorizontalFrame*) el->fFrame;
      m_settersFrame->RemoveFrame(f);
   }

   TGHorizontalFrame* frame =  new TGHorizontalFrame(m_settersFrame);
   m_settersFrame->AddFrame(frame, new TGLayoutHints(kLHintsExpandX,4,2,2,2) );
   m_settersFrame->SetCleanup(kDeepCleanup);
   makeSetter(frame, &m_mode);
   makeSetter(frame, &m_autoExpand);
   makeSetter(frame, &m_visLevel);
   makeSetter(frame, &m_visLevelFilter);
   m_settersFrame->MapSubwindows();
   m_frame->Layout();
}
virtual void FWGeometryTableView::saveImageTo ( const std::string &  iName) const [inline, virtual]

Implements FWViewBase.

Definition at line 89 of file FWGeometryTableView.h.

{}
void FWGeometryTableView::selectView ( int  idx)

Definition at line 435 of file FWGeometryTableView.cc.

References m_eveTopNode, m_viewBox, FWViewCombo::setElement(), and v.

{
   TEveElement::List_i it = gEve->GetViewers()->BeginChildren();
   std::advance(it, idx);
   TEveViewer* v = (TEveViewer*)(*it);
   TEveSceneInfo* si = (TEveSceneInfo*)v->FindChild(Form("SI - EventScene %s",v->GetElementName()));

   bool added = false;
   if (!m_eveTopNode) {
      m_eveTopNode = new FWGeoTopNode(this);
      m_eveTopNode->IncDenyDestroy();
      m_viewBox->setElement(m_eveTopNode);
   }
   else
   {
      for (TEveElement::List_i it = m_eveTopNode->BeginParents(); it != m_eveTopNode->EndParents(); ++it ){
         if (*it == si->GetScene()) {
            added = true;
            break;
         }
      }
   }
   printf("add node %s \n", si->GetElementName());

   if (added)
      si->GetScene()->RemoveElement(m_eveTopNode);
   else
      si->GetScene()->AddElement(m_eveTopNode);

   m_eveTopNode->ElementChanged();
   gEve->Redraw3D();
}
void FWGeometryTableView::setBackgroundColor ( )
void FWGeometryTableView::setFrom ( const FWConfiguration iFrom) [virtual]
void FWGeometryTableView::setPath ( int  parentIdx,
std::string &  path 
)

Definition at line 672 of file FWGeometryTableView.cc.

References FWGeometryTableManager::checkExpandLevel(), m_eveTopNode, m_tableManager, m_topNodeIdx, FWGeometryTableManager::redrawTable(), refreshTable3D(), FWGenericParameter< T >::set(), FWGeometryTableManager::topGeoNodeChanged(), and FWGeometryTableManager::updateFilter().

Referenced by cdNode(), cdTop(), and cdUp().

{
   m_topNodeIdx.set(parentIdx);
#ifdef PERFTOOL_BROWSER  
   ProfilerStart(Form("cdPath%d.prof", parentIdx));
#endif

   m_tableManager->topGeoNodeChanged(parentIdx);
   m_tableManager->updateFilter();
   m_tableManager->checkExpandLevel();

   refreshTable3D();
   // printf("END Set Path to [%s], curren node %s \n", m_path.value().c_str(), topNode->GetName()); 

   m_tableManager->redrawTable();
   if ( m_eveTopNode) {
      m_eveTopNode->ElementChanged();
      gEve->FullRedraw3D(false, true);
   } 

#ifdef PERFTOOL_BROWSER  
   ProfilerStop();
#endif 
}
void FWGeometryTableView::updateFilter ( std::string &  exp)

Member Data Documentation

Definition at line 103 of file FWGeometryTableView.h.

Referenced by FWGeometryTableView(), getAutoExpand(), and resetSetters().

Definition at line 109 of file FWGeometryTableView.h.

Referenced by cellClicked(), and setBackgroundColor().

Definition at line 116 of file FWGeometryTableView.h.

Referenced by cellClicked().

TEveWindowFrame* FWGeometryTableView::m_eveWindow [private]

Definition at line 118 of file FWGeometryTableView.h.

Referenced by FWGeometryTableView(), and ~FWGeometryTableView().

Definition at line 102 of file FWGeometryTableView.h.

Referenced by getFilter(), setFrom(), and updateFilter().

TGCompositeFrame* FWGeometryTableView::m_frame [private]

Definition at line 101 of file FWGeometryTableView.h.

Referenced by FWGeometryTableView(), getVolumeMode(), and resetSetters().

std::vector<boost::shared_ptr<FWParameterSetterBase> > FWGeometryTableView::m_setters [private]

Definition at line 129 of file FWGeometryTableView.h.

Referenced by makeSetter(), and resetSetters().

TGCompositeFrame* FWGeometryTableView::m_settersFrame [private]

Definition at line 113 of file FWGeometryTableView.h.

Referenced by FWGeometryTableView(), and resetSetters().

Definition at line 110 of file FWGeometryTableView.h.

Referenced by FWGeometryTableView(), and setBackgroundColor().

Definition at line 106 of file FWGeometryTableView.h.

Referenced by getTopNodeIdx(), setFrom(), and setPath().

Definition at line 126 of file FWGeometryTableView.h.

Referenced by populate3DViewsFromConfig(), and setFrom().

Definition at line 104 of file FWGeometryTableView.h.

Referenced by FWGeometryTableView(), getVisLevel(), and resetSetters().