gtree
Loading...
Searching...
No Matches
GTree Class Reference

Qt widget that displays the geometry hierarchy and allows interactive style edits. More...

#include <gtree.h>

Public Member Functions

 GTree (const std::shared_ptr< GOptions > &gopt, std::unordered_map< std::string, G4Volume * > g4volumes_map, QWidget *parent=nullptr)
 Construct the geometry tree widget.
 
 GTree (const GTree &)=delete
 Non-copyable: the widget owns unique model resources.
 
GTreeoperator= (const GTree &)=delete
 Non-assignable: the widget owns unique model resources.
 
- Public Member Functions inherited from GBase< GTree >
 GBase (const std::shared_ptr< GOptions > &gopt, std::string logger_name="")
 
 GBase (const std::shared_ptr< GLogger > &logger)
 
 GBase (const GBase &)=default
 
 GBase (GBase &&) noexcept=default
 
virtual ~GBase ()
 
GBaseoperator= (const GBase &)=default
 
GBaseoperator= (GBase &&) noexcept=default
 

Additional Inherited Members

- Protected Attributes inherited from GBase< GTree >
std::shared_ptr< GLoggerlog
 

Detailed Description

The widget builds an internal model of systems and volumes from a provided geometry volume map, then constructs a QTreeWidget view with:

  • a visibility checkbox column
  • a per-item color button column
  • a name column

User interactions trigger slots that:

  • update Qt state (checkboxes, button styles, slider labels)
  • send visualization commands to the Geant4 UI manager

The right-side panel shows properties of the selected volume and provides controls for representation and opacity.

Definition at line 228 of file gtree.h.

Constructor & Destructor Documentation

◆ GTree() [1/2]

GTree::GTree ( const std::shared_ptr< GOptions > & gopt,
std::unordered_map< std::string, G4Volume * > g4volumes_map,
QWidget * parent = nullptr )
explicit
Parameters
goptShared pointer to the option set used to configure logging and behavior.
g4volumes_mapMap from full volume names to G4Volume* wrappers.
parentOptional Qt parent used for ownership and lifetime management.

Construction steps:

  1. Build the internal model (g4_systems_tree) from the volume map.
  2. Create and configure the QTreeWidget view.
  3. Create the right-side property panel.
  4. Populate the tree and connect UI signals to slots.

Definition at line 79 of file gtree.cc.

◆ GTree() [2/2]

GTree::GTree ( const GTree & )
delete

Member Function Documentation

◆ operator=()

GTree & GTree::operator= ( const GTree & )
delete

The documentation for this class was generated from the following files: