59 wbox.TWbox::Copy(*
this);
67 src.TWbox::Copy(*
this);
173 Float_t xsize = 20, ysize = 26;
174 gStyle->GetPaperSize(xsize, ysize);
176 if (xsize * ratio > ysize)
180 ww = 72 / 2.54 * xsize;
181 wh = 72 / 2.54 * ysize;
210 Double_t frameXs[7] = {}, frameYs[7] = {};
213 frameXs[0] = xl; frameYs[0] = yl;
214 frameXs[1] = xl + realBsX; frameYs[1] = yl + realBsY;
215 frameXs[2] = frameXs[1]; frameYs[2] = yt - realBsY;
216 frameXs[3] = xt - realBsX; frameYs[3] = frameYs[2];
217 frameXs[4] = xt; frameYs[4] = yt;
218 frameXs[5] = xl; frameYs[5] = yt;
219 frameXs[6] = xl; frameYs[6] = yl;
222 pp->SetAttFill(*
this);
223 pp->DrawFillArea(7, frameXs, frameYs);
226 frameXs[0] = xl; frameYs[0] = yl;
227 frameXs[1] = xl + realBsX; frameYs[1] = yl + realBsY;
228 frameXs[2] = xt - realBsX; frameYs[2] = frameYs[1];
229 frameXs[3] = frameXs[2]; frameYs[3] = yt - realBsY;
230 frameXs[4] = xt; frameYs[4] = yt;
231 frameXs[5] = xt; frameYs[5] = yl;
232 frameXs[6] = xl; frameYs[6] = yl;
235 pp->SetAttFill(*
this);
236 pp->DrawFillArea(7, frameXs, frameYs);
240 if (with_selection) {
243 pp->SetAttLine(*
this);
254 SavePrimitiveConstructor(out,
Class(),
"wbox",
TString::Format(
"%g, %g, %g, %g",
fX1,
fY1,
fX2,
fY2),
kFALSE);
bool Bool_t
Boolean (0=false, 1=true) (bool).
int Int_t
Signed integer 4 bytes (int).
short Color_t
Color number (short).
float Float_t
Float 4 bytes (float).
short Short_t
Signed Short integer 2 bytes (short).
double Double_t
Double 8 bytes.
const char Option_t
Option string (const char).
Option_t Option_t SetFillStyle
Option_t Option_t SetLineColor
Option_t Option_t TPoint TPoint const char x2
Option_t Option_t TPoint TPoint const char x1
Option_t Option_t TPoint TPoint const char y2
Option_t Option_t SetFillColor
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t src
Option_t Option_t TPoint TPoint const char y1
virtual Color_t GetFillColor() const
Return the fill area color.
virtual Bool_t IsTransparent() const
virtual void SaveFillAttributes(std::ostream &out, const char *name, Int_t coldef=1, Int_t stydef=1001)
virtual Color_t GetLineColor() const
Return the line color.
virtual void SaveLineAttributes(std::ostream &out, const char *name, Int_t coldef=1, Int_t stydef=1, Int_t widdef=1)
virtual void PaintBox(Double_t x1, Double_t y1, Double_t x2, Double_t y2, Option_t *option="")
Draw this box with new coordinates.
Double_t fX1
X of 1st point.
void ExecuteEvent(Int_t event, Int_t px, Int_t py) override
Execute action corresponding to one event.
TBox()
Box default constructor.
Double_t fY2
Y of 2nd point.
Double_t fX2
X of 2nd point.
Double_t fY1
Y of 1st point.
void Copy(TObject &box) const override
Copy a Box.
virtual void AppendPad(Option_t *option="")
Append graphics object to current pad.
void SetBit(UInt_t f, Bool_t set)
Set or unset the user status bits as specified in f.
static void SavePrimitiveDraw(std::ostream &out, const char *variable_name, Option_t *option=nullptr)
Save invocation of primitive Draw() method Skipped if option contains "nodraw" string.
TObject()
TObject constructor.
static void SavePrimitiveConstructor(std::ostream &out, TClass *cl, const char *variable_name, const char *constructor_agrs="", Bool_t empty_line=kTRUE)
Save object constructor in the output stream "out".
@ kCanDelete
if object in a list can be deleted
static TString Format(const char *fmt,...)
Static method which formats a string using a printf style format descriptor and return a TString.
TVirtualPad is an abstract base class for the Pad and Canvas classes.
virtual Double_t GetX2() const =0
virtual Int_t YtoPixel(Double_t y) const =0
virtual UInt_t GetWh() const =0
virtual Double_t GetY1() const =0
virtual TVirtualPadPainter * GetPainter()=0
virtual Double_t GetAbsWNDC() const =0
virtual Double_t GetAbsHNDC() const =0
virtual Double_t GetY2() const =0
virtual Int_t XtoPixel(Double_t x) const =0
virtual UInt_t GetWw() const =0
virtual Double_t GetX1() const =0
virtual void PaintFrame(Double_t x1, Double_t y1, Double_t x2, Double_t y2, Color_t color, Short_t bordersize, Short_t bordermode, Bool_t tops)
Paint a 3D frame around a box.
void Paint(Option_t *option="") override
Paint this wbox with its current attributes.
void SavePrimitive(std::ostream &out, Option_t *option="") override
Save primitive as a C++ statement(s) on output stream out.
virtual void PaintWbox(Double_t x1, Double_t y1, Double_t x2, Double_t y2, Color_t color=33, Short_t bordersize=5, Short_t bordermode=-1)
Draw this wbox with new coordinates.
Int_t GetDarkColor() const
void Draw(Option_t *option="") override
Draw this wbox with its current attributes.
Int_t GetLightColor() const
Short_t fBorderSize
window box bordersize in pixels
TWbox & operator=(const TWbox &src)
assignment operator
Short_t fBorderMode
Bordermode (-1=down, 0 = no border, 1=up).
void PaintBorderOn(TVirtualPad *pad, Double_t x1, Double_t y1, Double_t x2, Double_t y2, Short_t bordersize, Short_t bordermode, Bool_t with_selection=kFALSE)
Paint a 3D border around a box.
void ExecuteEvent(Int_t event, Int_t px, Int_t py) override
Execute action corresponding to one event.
virtual TWbox * DrawWbox(Double_t x1, Double_t y1, Double_t x2, Double_t y2, Color_t color=33, Short_t bordersize=5, Short_t bordermode=-1)
Draw this wbox with new coordinates.
void Copy(TObject &wbox) const override
Copy this wbox to wbox.