Logo ROOT  
Reference Guide
Loading...
Searching...
No Matches
TGedMarkerSelect.h
Go to the documentation of this file.
1// @(#)root/ged:$Id$
2// Author: Marek Biskup, Ilka Antcheva 24/07/03
3
4/*************************************************************************
5 * Copyright (C) 1995-2002, Rene Brun and Fons Rademakers. *
6 * All rights reserved. *
7 * *
8 * For the licensing terms see $ROOTSYS/LICENSE. *
9 * For the list of contributors see $ROOTSYS/README/CREDITS. *
10 *************************************************************************/
11
12#ifndef ROOT_TGedMarkerSelect
13#define ROOT_TGedMarkerSelect
14
15
16#include "TGedPatternSelect.h"
17
18class TGToolTip;
19class TGPicture;
20
21
22class TGedMarkerPopup : public TGedPopup {
23
24protected:
25 Style_t fCurrentStyle; //currently selected style
26
27public:
28 TGedMarkerPopup(const TGWindow *p, const TGWindow *m, Style_t markerStyle);
29 ~TGedMarkerPopup() override;
30
31 Bool_t ProcessMessage(Longptr_t msg, Longptr_t parm1, Longptr_t parm2) override;
32
33 ClassDefOverride(TGedMarkerPopup,0) //marker select popup
34};
35
36
38
39protected:
40 Style_t fMarkerStyle; ///< marker style
41 const TGPicture *fPicture; ///< image used for popup window
42
43 void DoRedraw() override;
44
45public:
46 TGedMarkerSelect(const TGWindow *p, Style_t markerStyle, Int_t id);
47 ~TGedMarkerSelect() override { if(fPicture) gClient->FreePicture(fPicture);}
48
49 Bool_t ProcessMessage(Longptr_t msg, Longptr_t parm1, Longptr_t parm2) override;
51 void SetMarkerStyle(Style_t pattern);
52 virtual void MarkerSelected(Style_t marker = 0) { Emit("MarkerSelected(Style_t)", marker ? marker : GetMarkerStyle()); } // *SIGNAL*
53 void SavePrimitive(std::ostream &out, Option_t * = "") override;
54 TGDimension GetDefaultSize() const override { return TGDimension(38, 21); }
55
56 ClassDefOverride(TGedMarkerSelect,0) // Marker selection button
57};
58
59#endif
int Int_t
Signed integer 4 bytes (int).
Definition RtypesCore.h:59
long Longptr_t
Integer large enough to hold a pointer (platform-dependent).
Definition RtypesCore.h:89
bool Bool_t
Boolean (0=false, 1=true) (bool).
Definition RtypesCore.h:77
short Style_t
Style number (short).
Definition RtypesCore.h:96
const char Option_t
Option string (const char).
Definition RtypesCore.h:80
#define ClassDefOverride(name, id)
Definition Rtypes.h:348
#define gClient
Definition TGClient.h:157
The TGPicture class implements pictures and icons used in the different GUI elements and widgets.
Definition TGPicture.h:25
A tooltip can be a one or multiple lines help text that is displayed in a window when the mouse curso...
Definition TGToolTip.h:24
ROOT GUI Window base class.
Definition TGWindow.h:23
TGedMarkerPopup(const TGWindow *p, const TGWindow *m, Style_t markerStyle)
Create marker popup window.
Bool_t ProcessMessage(Longptr_t msg, Longptr_t parm1, Longptr_t parm2) override
Process messages generated by the marker popup window.
~TGedMarkerPopup() override
Destructor.
The TGedMarkerSelect widget is a button showing selected marker and a little down arrow.
void SetMarkerStyle(Style_t pattern)
Set marker.
~TGedMarkerSelect() override
Style_t fMarkerStyle
marker style
void SavePrimitive(std::ostream &out, Option_t *="") override
Save the pattern select widget as a C++ statement(s) on output stream out.
Style_t GetMarkerStyle() const
void DoRedraw() override
Draw selected marker type as current one.
TGDimension GetDefaultSize() const override
default size
const TGPicture * fPicture
image used for popup window
virtual void MarkerSelected(Style_t marker=0)
Bool_t ProcessMessage(Longptr_t msg, Longptr_t parm1, Longptr_t parm2) override
Process messages according to the user input.
TGedMarkerSelect(const TGWindow *p, Style_t markerStyle, Int_t id)
Create and show marker popup window.
TGedPopup(const TGWindow *p, const TGWindow *m, UInt_t w, UInt_t h, UInt_t options=0, Pixel_t back=GetDefaultFrameBackground())
Create a popup frame.
TGedSelect(const TGWindow *p, Int_t id)
Create pattern select button.
void Emit(const char *signal, const T &arg)
Activate signal with single parameter.
Definition TQObject.h:164
TMarker m
Definition textangle.C:8