12#ifndef ROOT_TGImageMap
13#define ROOT_TGImageMap
#define ClassDef(name, id)
R__EXTERN TGRegionWithId * gCurrentRegion
Array of shorts (16 bits per element).
A subclasses of TGWindow, and is used as base class for some simple widgets (buttons,...
(with TGRegion and TGRegionWithId help classes)
void SetToolTipText(const char *text, Long_t delayms=300)
Set tooltip text for main region.
virtual ~TGImageMap()
Cleanup image map widget.
ENavMode fNavMode
navigation mode
TGPopupMenu * GetPopup(Int_t id)
Return popup for regions with specified id.
Int_t fLastVisited
id of the last visited region
virtual void OnMouseOut(Int_t id)
Handle when mouse moves from region id.
virtual Bool_t HandleMotion(Event_t *event)
Handle mouse motion events.
virtual void OnMouseOver(Int_t id)
Handle when mouse moves over region id.
TGToolTip * fMainTip
tooltip text for main region
TList * fTrash
collect all objects that need to be cleaned up
virtual void DoubleClicked()
Handle when mouse is double clicked on main map.
virtual Bool_t HandleButton(Event_t *event)
Handle button events.
TGImageMap & operator=(const TGImageMap &)=delete
void SetPicture(const TGPicture *)
Change a picture in a picture button.
void AddRegion(const TGRegion ®ion, Int_t id)
Add a region to the image map.
TGPopupMenu * CreatePopup(Int_t id)
Create popup menu or returns existing for regions with specified id.
TList * fListOfRegions
list of regions
void SetCursor(ECursor cursor=kHand)
virtual Bool_t HandleDoubleClick(Event_t *event)
Handle double click events.
TGImageMap(const TGImageMap &)=delete
ECursor fCursorMouseOver
cursor shape in regions
virtual void RegionClicked(Int_t id)
Handle when mouse was clicked on region id.
ECursor fCursorMouseOut
cursor shape out of regions
The TGPicture class implements pictures and icons used in the different GUI elements and widgets.
void SetPopup(TGPopupMenu *popup)
TGPopupMenu * fPopup
popup menu
TGRegionWithId & operator=(const TGRegionWithId &)=delete
void SetToolTipText(const char *text, Long_t delayms, const TGFrame *frame)
Set tool tip text associated with this region.
void DisplayPopup()
Display popup menu associated with this region.
TGPopupMenu * GetPopup() const
virtual ~TGRegionWithId()
Cleanup.
TGRegionWithId()
Create GUI region (with id and possible tooltip).
TGToolTip * GetToolTipText() const
TGRegion & operator+=(const TGRegion &r)
TGRegion CopyRegion() const
Copy a region.
Bool_t IsEmpty() const
Return true if region is empty.
TGRegion & operator&=(const TGRegion &r)
virtual ~TGRegion()
Delete a region.
TGDimension GetDimension() const
Return dimension of region (width, height).
TGRegion Unite(const TGRegion &r) const
Return the union of this region with r.
TGRegion operator^(const TGRegion &r) const
TGRegion & operator^=(const TGRegion &r)
Bool_t Contains(const TPoint &p) const
Return true if point p is contained in the region.
Bool_t IsNull() const
Return true if region is not set.
TGRegion operator-(const TGRegion &r) const
TGRegion & operator|=(const TGRegion &r)
TGRegion operator&(const TGRegion &r) const
TGRegion operator|(const TGRegion &r) const
TGPosition GetPosition() const
Return position of region (x, y).
TGRegion Eor(const TGRegion &r) const
Returns a region which is the difference between the union and intersection this region and r.
Bool_t operator==(const TGRegion &r) const
Region == operator.
TGRegion operator+(const TGRegion &r) const
Bool_t operator!=(const TGRegion &r) const
TGRegion Subtract(const TGRegion &r) const
Returns a region which is r subtracted from this region.
TGRegion & operator-=(const TGRegion &r)
TGRegion Intersect(const TGRegion &r) const
Returns a region which is the intersection of this region and r.
TGRegion()
Create a region object.
TGRegion & operator=(const TGRegion &r)
Region assignment operator.
ROOT GUI Window base class.
Mother of all ROOT objects.