g4display
Loading...
Searching...
No Matches
g4display::G4SceneText Struct Reference

One text annotation to be inserted into the Geant4 scene. More...

#include <g4Text.h>

Data Fields

std::string text
 Text string to be displayed.
 
std::string color
 Text color name understood by Geant4 (e.g. "black", "red").
 
std::string kind
 Text kind: "2D" for text2D or "3D" for text attached in scene coordinates.
 
std::string layout
 Optional text layout such as "right"; empty keeps Geant4 default layout.
 
double x
 X position.
 
double y
 Y position.
 
double z = GNOT_SPECIFIED_SCENE_TEXT_Z
 Z position used by 3D text.
 
std::string unit
 Unit used by 3D text positions.
 
int size
 Text size parameter passed to Geant4 visualization command.
 
double dx
 3D text X offset.
 
double dy
 3D text Y offset.
 

Detailed Description

Each configured item is converted into Geant4 visualization commands by G4SceneProperties.

Interpretation rules:

  • kind = "2D" creates a /vis/scene/add/text2D command.
  • kind = "3D" creates a /vis/scene/add/text command using x, y, z, unit, dx, and dy.

Definition at line 30 of file g4Text.h.

Field Documentation

◆ color

std::string g4display::G4SceneText::color

Definition at line 36 of file g4Text.h.

◆ dx

double g4display::G4SceneText::dx

Definition at line 60 of file g4Text.h.

◆ dy

double g4display::G4SceneText::dy

Definition at line 63 of file g4Text.h.

◆ kind

std::string g4display::G4SceneText::kind

Definition at line 39 of file g4Text.h.

◆ layout

std::string g4display::G4SceneText::layout

Definition at line 42 of file g4Text.h.

◆ size

int g4display::G4SceneText::size

Definition at line 57 of file g4Text.h.

◆ text

std::string g4display::G4SceneText::text

Definition at line 33 of file g4Text.h.

◆ unit

std::string g4display::G4SceneText::unit

Definition at line 54 of file g4Text.h.

◆ x

double g4display::G4SceneText::x

Definition at line 45 of file g4Text.h.

◆ y

double g4display::G4SceneText::y

Definition at line 48 of file g4Text.h.

◆ z

double g4display::G4SceneText::z = GNOT_SPECIFIED_SCENE_TEXT_Z

Definition at line 51 of file g4Text.h.


The documentation for this struct was generated from the following file: