Logo ROOT   6.08/07
Reference Guide
TAttFill.h
Go to the documentation of this file.
1 // @(#)root/base:$Id$
2 // Author: Rene Brun 12/12/94
3 
4 /*************************************************************************
5  * Copyright (C) 1995-2000, 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_TAttFill
13 #define ROOT_TAttFill
14 
15 
16 #ifndef ROOT_Rtypes
17 #include "Rtypes.h"
18 #endif
19 #ifndef ROOT_Riosfwd
20 #include "Riosfwd.h"
21 #endif
22 
23 
24 class TAttFill {
25 
26 protected:
27  Color_t fFillColor; ///< Fill area color
28  Style_t fFillStyle; ///< Fill area style
29 
30 public:
31  TAttFill();
32  TAttFill(Color_t fcolor,Style_t fstyle);
33  virtual ~TAttFill();
34  void Copy(TAttFill &attfill) const;
35  virtual Color_t GetFillColor() const { return fFillColor; } ///< Return the fill area color
36  virtual Style_t GetFillStyle() const { return fFillStyle; } ///< Return the fill area style
37  virtual Bool_t IsTransparent() const;
38  virtual void Modify();
39  virtual void ResetAttFill(Option_t *option="");
40  virtual void SaveFillAttributes(std::ostream &out, const char *name, Int_t coldef=1, Int_t stydef=1001);
41  virtual void SetFillAttributes(); // *MENU*
42  virtual void SetFillColor(Color_t fcolor) { fFillColor = fcolor; } ///< Set the fill area color
43  virtual void SetFillColorAlpha(Color_t fcolor, Float_t falpha);
44  virtual void SetFillStyle(Style_t fstyle) { fFillStyle = fstyle; } ///< Set the fill area style
45 
46  ClassDef(TAttFill,2) //Fill area attributes
47 };
48 
50 { return fFillStyle >= 4000 && fFillStyle <= 4100 ? kTRUE : kFALSE; }
51 
52  enum EFillStyle {kFDotted1 = 3001, kFDotted2 = 3002, kFDotted3 = 3003,
53  kFHatched1 = 3004, kHatched2 = 3005, kFHatched3 = 3006,
54  kFHatched4 = 3007, kFWicker = 3008, kFScales = 3009,
55  kFBricks = 3010, kFSnowflakes = 3011, kFCircles = 3012,
56  kFTiles = 3013, kFMondrian = 3014, kFDiamonds = 3015,
57  kFWaves1 = 3016, kFDashed1 = 3017, kFDashed2 = 3018,
58  kFAlhambra = 3019, kFWaves2 = 3020, kFStars1 = 3021,
59  kFStars2 = 3022, kFPyramids = 3023, kFFrieze = 3024,
60  kFMetopes = 3025, kFEmpty = 0 , kFSolid = 1};
61 
62 #endif
virtual void SetFillAttributes()
Invoke the DialogCanvas Fill attributes.
Definition: TAttFill.cxx:249
virtual ~TAttFill()
AttFill destructor.
Definition: TAttFill.cxx:193
short Style_t
Definition: RtypesCore.h:76
float Float_t
Definition: RtypesCore.h:53
const char Option_t
Definition: RtypesCore.h:62
int Int_t
Definition: RtypesCore.h:41
bool Bool_t
Definition: RtypesCore.h:59
const Bool_t kFALSE
Definition: Rtypes.h:92
virtual void SetFillStyle(Style_t fstyle)
Set the fill area style.
Definition: TAttFill.h:44
EFillStyle
Definition: TAttFill.h:52
Fill Area Attributes class.
Definition: TAttFill.h:24
#define ClassDef(name, id)
Definition: Rtypes.h:254
virtual void ResetAttFill(Option_t *option="")
Reset this fill attributes to default values.
Definition: TAttFill.cxx:223
virtual void Modify()
Change current fill area attributes if necessary.
Definition: TAttFill.cxx:209
short Color_t
Definition: RtypesCore.h:79
virtual void SetFillColor(Color_t fcolor)
Set the fill area color.
Definition: TAttFill.h:42
virtual void SaveFillAttributes(std::ostream &out, const char *name, Int_t coldef=1, Int_t stydef=1001)
Save fill attributes as C++ statement(s) on output stream out.
Definition: TAttFill.cxx:232
virtual Color_t GetFillColor() const
Return the fill area color.
Definition: TAttFill.h:35
TAttFill()
AttFill default constructor.
Definition: TAttFill.cxx:172
Color_t fFillColor
Fill area color.
Definition: TAttFill.h:27
virtual Style_t GetFillStyle() const
Return the fill area style.
Definition: TAttFill.h:36
virtual Bool_t IsTransparent() const
Definition: TAttFill.h:49
const Bool_t kTRUE
Definition: Rtypes.h:91
virtual void SetFillColorAlpha(Color_t fcolor, Float_t falpha)
Set a transparent fill color.
Definition: TAttFill.cxx:258
char name[80]
Definition: TGX11.cxx:109
Style_t fFillStyle
Fill area style.
Definition: TAttFill.h:28
void Copy(TAttFill &attfill) const
Copy this fill attributes to a new TAttFill.
Definition: TAttFill.cxx:200