Logo ROOT   6.14/05
Reference Guide
pad.cxx
Go to the documentation of this file.
1 /// \file
2 /// \ingroup tutorial_v7
3 ///
4 /// \macro_code
5 ///
6 /// \date 2015-03-22
7 /// \warning This is part of the ROOT 7 prototype! It will change without notice. It might trigger earthquakes. Feedback
8 /// is welcome!
9 /// \author Axel Naumann <axel@cern.ch>
10 
11 /*************************************************************************
12  * Copyright (C) 1995-2015, Rene Brun and Fons Rademakers. *
13  * All rights reserved. *
14  * *
15  * For the licensing terms see $ROOTSYS/LICENSE. *
16  * For the list of contributors see $ROOTSYS/README/CREDITS. *
17  *************************************************************************/
18 
19 #include "Rtypes.h"
20 
21 R__LOAD_LIBRARY(libROOTGpadv7);
22 
23 #include "ROOT/TCanvas.hxx"
24 #include "ROOT/TFrame.hxx"
25 #include "ROOT/TLine.hxx"
26 
27 void pad()
28 {
29  using namespace ROOT;
30  using namespace ROOT::Experimental;
31 
32  auto canvas = Experimental::TCanvas::Create("what to do with a pad!");
33  auto pads = canvas->Divide(3, 3);
34  auto &pad12 = pads[1][2];
35  pad12->SetAllAxisBounds({{50., 250.}, {-1., 1.}});
36  // Please fix TLine such that {x,y} are TPadPos!
37  //pad12->Draw(Experimental::TLine({100._user, 0.5_normal}, {200._user, 0.5_normal}));
38 
39  canvas->Show();
40 }
Namespace for new ROOT classes and functions.
Definition: StringConv.hxx:21
#define R__LOAD_LIBRARY(LIBRARY)
Definition: Rtypes.h:467
static std::shared_ptr< TCanvas > Create(const std::string &title)
Definition: TCanvas.cxx:74