183 gClient->GetColorByName(
"#ff0000", color);
197 gClient->GetColorByName(
"#ff0000", color);
217 gClient->GetColorByName(
"#ff0000", color);
222 gClient->GetColorByName(
"#0000ff", color);
246 gClient->GetColorByName(
"#ff0000", color);
265 for (ipict = 0; ipict < 6; ipict++)
281 for (ipict = 0; ipict < 6; ipict++)
297 for (ipict = 0; ipict < 6; ipict++)
307 for (ipict = 0; ipict < 3; ipict++)
316 gClient->GetColorByName(
"#ff0000", color);
322 gClient->GetColorByName(
"#0000ff", color);
346 gClient->GetColorByName(
"#ff0000", color);
362 gClient->GetColorByName(
"#0000ff", color);
376 gClient->GetColorByName(
"#0000ff", color);
392 for (ipict = 0; ipict < 2; ipict++)
400 gClient->GetColorByName(
"#ff0000", color);
406 gClient->GetColorByName(
"#0000ff", color);
438 gClient->GetColorByName(
"#ff0000", color);
485 for (ipict = 0; ipict < 2; ipict++)
494 gClient->GetColorByName(
"#ff0000", color);
500 gClient->GetColorByName(
"#0000ff", color);
524 gClient->GetColorByName(
"#ff0000", color);
550 gClient->GetColorByName(
"#0000ff", color);
572 gClient->GetColorByName(
"#ff0000", color);
578 gClient->GetColorByName(
"#0000ff", color);
602 gClient->GetColorByName(
"#ff0000", color);
622 for (ipict = 0; ipict < 3; ipict++)
630 gClient->GetColorByName(
"#ff0000", color);
636 gClient->GetColorByName(
"#0000ff", color);
723 c->Connect(
"Selected(TVirtualPad*,TObject*,Int_t)",
"TGeoManagerEditor",
this,
724 "SelectedSlot(TVirtualPad*,TObject*,Int_t)");
733 "SelectedSlot(TVirtualPad*,TObject*,Int_t)");
771 fBSelTop->
Connect(
"Clicked()",
"TGeoManagerEditor",
this,
"DoSelectTopVolume()");
943 fSelectedShape =
new TGeoTrap(
TString::Format(
"trap_%i",
id), 1., 15., 45., 0.5, 0.3, 0.5, 30., 0.5, 0.3, 0.5, 30.);
957 new TGeoGtra(
TString::Format(
"gtra_%i",
id), 1., 15., 45., 45., 0.5, 0.3, 0.5, 30., 0.5, 0.3, 0.5, 30.);
1046 fSelectedShape =
new TGeoCtub(
TString::Format(
"ctub_%i",
id), 0.5, 1., 1., 0., 45., 0., 0., -1, 0., 0., 1);
1139 Error(
"DoCreateMaterial",
"Cannot find selected element in list");
ULong_t Pixel_t
Pixel value.
void Error(const char *location, const char *msgfmt,...)
Use this function in case an error occurred.
winID h TVirtualViewer3D TVirtualGLPainter p
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t height
@ kMANAGER_MATERIAL_SELECT
@ kMANAGER_MATERIAL_SELECT2
@ kMANAGER_ELEMENT_SELECT
@ kMANAGER_MEDIUM_SELECT2
@ kMANAGER_DENSITY_SELECT
R__EXTERN TGeoManager * gGeoManager
virtual Int_t GetSize() const
Return the capacity of the collection, i.e.
const TGPicture * GetPicture(const char *name)
Get picture from the picture pool.
A combobox (also known as a drop down listbox) allows the selection of one item out of a list of item...
virtual Int_t GetSelected() const
virtual void AddEntry(TGString *s, Int_t id)
virtual void Select(Int_t id, Bool_t emit=kTRUE)
Make the selected item visible in the combo box window and emit signals according to the second param...
The base class for composite widgets (menu bars, list boxes, etc.).
virtual void AddFrame(TGFrame *f, TGLayoutHints *l=nullptr)
Add frame to the composite frame using the specified layout hints.
virtual void Cleanup()
Cleanup and delete all objects contained in this composite frame.
virtual void ShowFrame(TGFrame *f)
Show sub frame.
void SetCleanup(Int_t mode=kLocalCleanup) override
Turn on automatic cleanup of child frames in dtor.
virtual void HideFrame(TGFrame *f)
Hide sub frame.
virtual void ChangeOptions(UInt_t options)
Change frame options. Options is an OR of the EFrameTypes.
void Resize(UInt_t w=0, UInt_t h=0) override
Resize the frame.
virtual UInt_t GetDefaultHeight() const
void SetBackgroundColor(Pixel_t back) override
Set background color (override from TGWindow base class).
static Pixel_t GetDefaultFrameBackground()
Get default frame background.
A horizontal 3D line is a line that typically separates a toolbar from the menubar.
TGHotString is a string with a "hot" character underlined.
This class handles GUI labels.
virtual void SetTextColor(Pixel_t color, Bool_t global=kFALSE)
Changes text color.
virtual void SetText(TGString *newText)
Set new text in label.
This class describes layout hints used by the layout classes.
TGNumberEntry is a number entry input widget with up/down buttons.
TGNumberEntryField * GetNumberEntry() const
Get the number entry field.
void Associate(const TGWindow *w) override
Make w the window that will receive the generated messages.
virtual Long_t GetIntNumber() const
void SetNumAttr(EAttribute attr=kNEAAnyNumber)
virtual Double_t GetNumber() const
virtual void SetNumber(Double_t val, Bool_t emit=kTRUE)
UInt_t GetDefaultHeight() const override
void SetNumStyle(EStyle style)
TGClient * fClient
Connection to display server.
TGButton * GetButton() const
TGFrame * GetContainer() const
A shutter widget contains a set of shutter items that can be open and closed like a shutter.
virtual void AddItem(TGShutterItem *item)
Add shutter item to shutter frame.
TGShutterItem * GetItem(const char *name)
returns a shutter item by name (name is hot string of shutter item)
void Layout() override
Layout shutter items.
virtual Bool_t SetTab(Int_t tabIndex, Bool_t emit=kTRUE)
Brings the composite frame with the index tabIndex to the front and generate the following event if t...
A text buffer is used in several widgets, like TGTextEntry, TGFileDialog, etc.
Yield an action as soon as it is clicked.
A TGTextEntry is a one line text input widget.
const char * GetText() const
virtual void SetToolTipText(const char *text, Long_t delayms=500)
Set tool tip text associated with this text entry.
virtual void SetText(const char *text, Bool_t emit=kTRUE)
Sets text entry to text, clears the selection and moves the cursor to the end of the line.
ROOT GUI Window base class.
TCanvas * GetCanvas() const override
virtual void DisconnectFromCanvas()
Disconnect this editor from the Selected signal of fCanvas.
Base frame for implementing GUI - a service class.
TGedEditor * fGedEditor
manager of this frame
virtual TGVerticalFrame * CreateEditorTabSubFrame(const char *name)
Create a vertical frame to be used by 'owner' in extra tab 'name'.
Bool_t fInit
init flag for setting signals/slots
Class describing rotation + translation.
TGeoElement * GetElement(Int_t z)
Int_t GetNelements() const
Base class for chemical elements.
Editor for TGeoManager class.
void DoCreateCons()
Create a cone segment.
void DoCreateArb8()
Create an arbitrary polygone with maximum 8 vertices sitting on 2 parallel planes.
void DoCreatePgon()
Create a polygone shape.
void DoSelectMedium()
Slot for selecting an existing medium.
TGeoMaterial * fSelectedMaterial
void DoCreateAssembly()
Create a new volume assembly.
TGNumberEntry * fMediumId
TGPictureButton * fBSelMedium2
void DoCreateHype()
Create a hyperboloid.
void ConnectSelected(TCanvas *c)
void DoSelectMaterial()
Slot for selecting an existing material.
TGCompositeFrame * fVolumeTab
TGPictureButton * fVolumeButton[2]
void DoSelectShape()
Slot for selecting an existing shape.
void DoEditVolume()
Slot for editing selected volume.
void DoSelectShape2()
Slot for selecting a shape for making a volume.
TGPictureButton * fBSelMatrix
TGPictureButton * fMatrixButton[3]
TGPictureButton * fMediumButton
void DoEditMedium()
Slot for editing selected medium.
TGTextButton * fEditMedium
void DoCreatePara()
Create a parallelipiped.
void DoSelectTopVolume()
Slot for setting top geometry volume.
void DoCreateTubs()
Create a tube segment.
TGTextEntry * fMediumName
void DoCreateTrd1()
Create a Trd1.
void SetModel(TObject *obj) override
Refresh editor according the selected obj.
TGTextButton * fEditVolume
TGeoMedium * fSelectedMedium2
void DisconnectSelected()
void DoCreateGtra()
Create a twisted trapezoid.
TGTextButton * fEditMaterial
void DoEditMatrix()
Slot for editing selected matrix.
void DoCloseGeometry()
Slot for closing the geometry.
TGPictureButton * fBSelShape2
void DoCreateParab()
Create a paraboloid.
void DoSelectMedium2()
Slot for selecting an existing medium for making a volume.
void DoCreateBox()
Create a box.
TGComboBox * fElementList
void DoSetTopVolume()
Set top volume for the geometry.
TGTextButton * fEditShape
TGTextEntry * fManagerName
void DoSelectVolume()
Slot for selecting an existing volume.
void DoName()
Change name/title of the geometry.
void DoEditMaterial()
Slot for editing selected material.
virtual void ConnectSignals2Slots()
Connect signals to slots.
void DoCreateTranslation()
Create a new translation.
void DoCreateMixture()
Create a new mixture.
TGPictureButton * fBSelMaterial
TGeoMaterial * fSelectedMaterial2
TGTextEntry * fVolumeName
TGPictureButton * fBSelVolume
void ShowSelectMaterial(Bool_t show=kTRUE)
Show/hide interface for material selection.
void DoCreateTrd2()
Create a Trd2.
TGeoMatrix * fSelectedMatrix
void DoCreateVolume()
Create a new volume.
void DoCreateCone()
Create a cone.
void DoCreateXtru()
Create an extruded polygone.
TGTextButton * fSetTopVolume
TGeoShape * fSelectedShape
TGeoVolume * fSelectedVolume
void DoExportGeometry()
Export geometry as .root or .C file.
TGTextEntry * fMatrixName
void DoCreateTube()
Create a tube.
TGPictureButton * fBSelMaterial2
TGTextButton * fEditMatrix
TGTextButton * fExportButton
TGeoMedium * fSelectedMedium
TGTextEntry * fMaterialName
void DoCreatePcon()
Create a polycone shape.
TGTextEntry * fManagerTitle
void DoCreateTorus()
Create a torus shape.
void DoCreateTrap()
Create a general trapezoid.
TGTextButton * fCloseGeometry
void DoCreateSphe()
Create a sphere.
TGPictureButton * fBSelShape
TGRadioButton * fExportOption[2]
void DoSelectMaterial2()
Slot for selecting an existing material and making a medium.
void DoCreateMaterial()
Create a new material.
TGPictureButton * fBSelTop
~TGeoManagerEditor() override
Destructor.
void ShowSelectMedium(Bool_t show=kTRUE)
Show/hide interface for medium selection.
virtual void SelectedSlot(TVirtualPad *pad, TObject *obj, Int_t event)
Connected to TCanvas::Selected.
TGeoShape * fSelectedShape2
void ShowSelectVolume(Bool_t show=kTRUE)
Show/hide interface for volume selection.
void DoCreateMedium()
Create a new medium.
TCanvas * fConnectedCanvas
void ShowSelectShape(Bool_t show=kTRUE)
Show/hide interface for shape selection.
void ShowSelectMatrix(Bool_t show=kTRUE)
Show/hide interface for matrix selection.
void DoSelectMatrix()
Slot for selecting an existing matrix.
static void LoadLib()
Dummy static function, used to load plugin.
TGPictureButton * fMaterialButton[2]
TGNumberEntry * fEntryDensity
void DoEditShape()
Slot for editing selected shape.
void DoCreateEltu()
Create an elliptical tube.
void DoCreateCombi()
Create a new translation + rotation.
void DoCreateComposite()
Create a composite shape.
void DoCreateRotation()
Create a new rotation.
TGPictureButton * fBSelMedium
TGPictureButton * fShapeButton[21]
void DoCreateCtub()
Create a cut tube.
TGeoManagerEditor(const TGWindow *p=nullptr, Int_t width=140, Int_t height=30, UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground())
Constructor for manager editor.
The manager class for any TGeo geometry.
TList * GetListOfMedia() const
TGeoElementTable * GetElementTable()
Returns material table. Creates it if not existing.
TObjArray * GetListOfVolumes() const
TObjArray * GetListOfMatrices() const
virtual Int_t Export(const char *filename, const char *name="", Option_t *option="vg")
Export this geometry to a file.
TGeoVolume * GetMasterVolume() const
void CloseGeometry(Option_t *option="d")
Closing geometry implies checking the geometry validity, fixing shapes with negative parameters (run-...
void SetTopVolume(TGeoVolume *vol)
Set the top volume and corresponding node as starting point of the geometry.
void BuildDefaultMaterials()
Now just a shortcut for GetElementTable.
TList * GetListOfMaterials() const
TObjArray * GetListOfShapes() const
TGeoVolume * GetTopVolume() const
Base class describing materials.
Geometrical transformation package.
virtual void RegisterYourself()
Register the matrix in the current manager, which will become the owner.
Media are used to store properties related to tracking and which are useful only when using geometry ...
Class describing rotations.
Base abstract class for all shapes.
void Draw(Option_t *option="") override
Draw this shape.
const char * GetName() const override
Get the shape name.
TVirtualPad * GetPad() const
void GetVolumeEditor(TGeoVolume *vol)
Get editor for a volume.
TGCompositeFrame * fVolumeTab
void GetMaterialEditor(TGeoMaterial *material)
Get editor for a material.
static TGeoTabManager * GetMakeTabManager(TGedEditor *ged)
Static method to return the tab manager currently appended to the pad or create one if not existing.
TGCompositeFrame * GetVolumeTab() const
void GetMediumEditor(TGeoMedium *medium)
Get editor for a medium.
static void Cleanup(TGCompositeFrame *frame)
Static method to cleanup hierarchically all daughters of a composite frame.
void GetShapeEditor(TGeoShape *shape)
Get editor for a shape.
void SetTab()
Set a given tab element as active one.
void SetVolTabEnabled(Bool_t flag=kTRUE)
Enable/disable tabs.
void GetMatrixEditor(TGeoMatrix *matrix)
Get editor for a matrix.
Class describing translations.
static TObject * GetSelected()
static; return selected object
TGeoVolume, TGeoVolumeMulti, TGeoVolumeAssembly are the volume classes.
void Draw(Option_t *option="") override
draw top volume according to option
virtual void SetTitle(const char *title="")
Set the title of the TNamed.
const char * GetName() const override
Returns name of object.
const char * GetTitle() const override
Returns title of object.
virtual void SetName(const char *name)
Set the name of the TNamed.
Int_t GetEntries() const override
Return the number of objects in array (i.e.
Mother of all ROOT objects.
void SetBit(UInt_t f, Bool_t set)
Set or unset the user status bits as specified in f.
virtual Bool_t InheritsFrom(const char *classname) const
Returns kTRUE if object inherits from class "classname".
Bool_t Connect(const char *signal, const char *receiver_class, void *receiver, const char *slot)
Non-static method is used to connect from the signal of this object to the receiver slot.
Bool_t Disconnect(const char *signal=nullptr, void *receiver=nullptr, const char *slot=nullptr)
Disconnects signal of this object from slot of receiver.
TSubString Strip(EStripType s=kTrailing, char c=' ') const
Return a substring of self stripped at beginning and/or end.
const char * Data() const
TString & Remove(Ssiz_t pos)
static TString Format(const char *fmt,...)
Static method which formats a string using a printf style format descriptor and return a TString.
virtual void ShowAxis()=0
TVirtualPad is an abstract base class for the Pad and Canvas classes.
virtual TView * GetView() const =0