#include "TArrow.h"

TArrow


class description - source file - inheritance tree (.pdf)

class TArrow : public TLine, public TAttFill

Inheritance Chart:
TObject
TAttLine
<-
TLine
TAttFill
<-
TArrow

    public:
TArrow() TArrow(Double_t x1, Double_t y1, Double_t x2, Double_t y2, Float_t arrowsize = 0.05, Option_t* option = ">") TArrow(const TArrow& arrow) virtual ~TArrow() static TClass* Class() virtual void Copy(TObject& arrow) const virtual void Draw(Option_t* option = "") virtual void DrawArrow(Double_t x1, Double_t y1, Double_t x2, Double_t y2, Float_t arrowsize = 0, Option_t* option = "") Float_t GetAngle() const Float_t GetArrowSize() const static Float_t GetDefaultAngle() static Float_t GetDefaultArrowSize() static Option_t* GetDefaultOption() virtual Option_t* GetOption() const virtual TClass* IsA() const TArrow& operator=(const TArrow&) virtual void Paint(Option_t* option = "") virtual void PaintArrow(Double_t x1, Double_t y1, Double_t x2, Double_t y2, Float_t arrowsize = 0.05, Option_t* option = ">") virtual void SavePrimitive(ofstream& out, Option_t* option) virtual void SetAngle(Float_t angle = 60) virtual void SetArrowSize(Float_t arrowsize = 0.05) static void SetDefaultAngle(Float_t Angle) static void SetDefaultArrowSize(Float_t ArrowSize) static void SetDefaultOption(Option_t* Option) virtual void SetOption(Option_t* option = ">") virtual void ShowMembers(TMemberInspector& insp, char* parent) virtual void Streamer(TBuffer& b) void StreamerNVirtual(TBuffer& b)

Data Members


    protected:
Float_t fAngle Arrow opening angle (degrees) Float_t fArrowSize Arrow Size TString fOption Arrow shapes static Float_t fgDefaultAngle default Arrow opening angle (degrees) static Float_t fgDefaultArrowSize default Arrow Size static TString fgDefaultOption default Arrow shapes

Class Description

  Different arrow formats as explained in TArrow::TArrow or in
  the picture below are provided.
  Once an arrow is drawn on the screen:
    - One can click on one of the edges and move this edge.
    - One can click on any other arrow part to move the entire arrow.
/* */


TArrow(): TLine(),TAttFill()
 Arrow default constructor.

TArrow(Double_t x1, Double_t y1,Double_t x2, Double_t y2, Float_t arrowsize ,Option_t *option) :TLine(x1,y1,x2,y2), TAttFill(0,1001)
 Arrow normal constructor.

 Define an arrow between points x1,y1 and x2,y2
 the arrowsize is in percentage of the pad height
 Opening angle between the two sides of the arrow is fAngle (60 degrees)

  option = ">"      -------->
  option = "|->"    |------->
  option = "<"      <--------
  option = "<-|"    <-------|
  option = "->-"    ---->----
  option = "-<-"    ----<----
  option = "-|>-"   ---|>----
  option = "<>"     <------->
  option = "<|>"    <|-----|>  arrow defined by a triangle

  Note:
  - If FillColor == 0 draw open triangle else  draw full triangle with fillcolor
    default is filled with LineColor
  - "Begin" and "end" bars can be combined with any other options.

~TArrow()
 Arrow default destructor.

TArrow(const TArrow &arrow) : TLine(arrow), TAttFill(arrow)
 Copy constructor.

void Copy(TObject &obj) const
 Copy this arrow to arrow.

void Draw(Option_t *option)
 Draw this arrow with its current attributes.

void DrawArrow(Double_t x1, Double_t y1,Double_t x2, Double_t y2, Float_t arrowsize ,Option_t *option)
 Draw this arrow with new coordinates.

 if arrowsize is <= 0, arrowsize will be the current arrow size
 if option="", option will be the current arrow option

void Paint(Option_t *option)
 Paint this arrow with its current attributes.

void PaintArrow(Double_t x1, Double_t y1, Double_t x2, Double_t y2, Float_t arrowsize, Option_t *option)
 Draw this arrow


                             +
                             |.
                             | .
                             |  .
     +-----------------------|---+------------------+
  (x1,y1)                    |  .                (x2,y2)
                             | .
                             |.
                             +

void SavePrimitive(ofstream &out, Option_t *)
 Save primitive as a C++ statement(s) on output stream out

void SetDefaultAngle(Float_t Angle)
 Set default angle.

void SetDefaultArrowSize (Float_t ArrowSize)
 Set default arrow sive.

void SetDefaultOption(Option_t *Option)
 Set default option.

Float_t GetDefaultAngle()
 Get default angle.

Float_t GetDefaultArrowSize()
 Get default arrow size.

Option_t* GetDefaultOption()
 Get default option.



Inline Functions


            Float_t GetAngle() const
            Float_t GetArrowSize() const
          Option_t* GetOption() const
               void SetAngle(Float_t angle = 60)
               void SetArrowSize(Float_t arrowsize = 0.05)
               void SetOption(Option_t* option = ">")
            TClass* Class()
            TClass* IsA() const
               void ShowMembers(TMemberInspector& insp, char* parent)
               void Streamer(TBuffer& b)
               void StreamerNVirtual(TBuffer& b)
            TArrow& operator=(const TArrow&)


Author: Rene Brun 17/10/95
Last update: root/graf:$Name: $:$Id: TArrow.cxx,v 1.20 2005/11/11 17:31:48 couet Exp $
Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *


ROOT page - Class index - Class Hierarchy - Top of the page

This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.