Back to home page

EIC code displayed by LXR

 
 

    


Warning, file /include/root/TMarker.h was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).

0001 // @(#)root/graf:$Id$
0002 // Author: Rene Brun   12/05/95
0003 
0004 /*************************************************************************
0005  * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers.               *
0006  * All rights reserved.                                                  *
0007  *                                                                       *
0008  * For the licensing terms see $ROOTSYS/LICENSE.                         *
0009  * For the list of contributors see $ROOTSYS/README/CREDITS.             *
0010  *************************************************************************/
0011 
0012 #ifndef ROOT_TMarker
0013 #define ROOT_TMarker
0014 
0015 
0016 #include "TObject.h"
0017 #include "TAttMarker.h"
0018 #include "TAttBBox2D.h"
0019 
0020 class TPoint;
0021 
0022 class TMarker : public TObject, public TAttMarker, public TAttBBox2D {
0023 
0024 protected:
0025    Double_t     fX;           ///< X position of marker (left,center,etc..)
0026    Double_t     fY;           ///< Y position of marker (left,center,etc..)
0027 
0028 public:
0029    // TMarker status bits
0030    enum {
0031       kMarkerNDC = BIT(14)  ///< Marker position is in NDC
0032    };
0033 
0034    TMarker();
0035    TMarker(Double_t x, Double_t y, Int_t marker);
0036    TMarker(const TMarker &marker);
0037    ~TMarker() override;
0038 
0039    void             Copy(TObject &marker) const override;
0040    Int_t            DistancetoPrimitive(Int_t px, Int_t py) override;
0041    void             Draw(Option_t *option="") override;
0042    virtual TMarker *DrawMarker(Double_t x, Double_t y);
0043    void             ExecuteEvent(Int_t event, Int_t px, Int_t py) override;
0044    Double_t         GetX() const  {return fX;}
0045    Double_t         GetY() const  {return fY;}
0046    void             ls(Option_t *option="") const override;
0047    void             Paint(Option_t *option="") override;
0048    virtual void     PaintMarker(Double_t x, Double_t y);
0049    virtual void     PaintMarkerNDC(Double_t u, Double_t v);
0050    void             Print(Option_t *option="") const override;
0051    void             SavePrimitive(std::ostream &out, Option_t *option = "") override;
0052    virtual void     SetNDC(Bool_t isNDC=kTRUE);
0053    virtual void     SetX(Double_t x) { fX = x;} // *MENU*
0054    virtual void     SetY(Double_t y) { fY = y;} // *MENU*
0055 
0056    Rectangle_t      GetBBox() override;
0057    TPoint           GetBBoxCenter() override;
0058    void             SetBBoxCenter(const TPoint &p) override;
0059    void             SetBBoxCenterX(const Int_t x) override;
0060    void             SetBBoxCenterY(const Int_t y) override;
0061    void             SetBBoxX1(const Int_t x) override;
0062    void             SetBBoxX2(const Int_t x) override;
0063    void             SetBBoxY1(const Int_t y) override;
0064    void             SetBBoxY2(const Int_t y) override;
0065 
0066    static  void     DisplayMarkerTypes();
0067    static  void     DisplayMarkerLineWidths();
0068 
0069    ClassDefOverride(TMarker,3)  //Marker
0070 };
0071 
0072 #endif