ROOT
Version v6.32
master
v6.36
v6.34
v6.30
v6.28
v6.26
v6.24
v6.22
v6.20
v6.18
v6.16
v6.14
v6.12
v6.10
v6.08
v6.06
Reference Guide
▼
ROOT
ROOT Reference Documentation
Tutorials
▼
Functional Parts
►
Core ROOT classes
►
std Extension classes
►
Parallelized classes
►
The Geometry Package
►
Graphics
►
Event display with ROOT7
►
GUI
►
Web Widgets
►
Web Display
►
Histogram Library
►
Input/Output Library
►
Math
►
N-D parametric functions
►
VecOps
►
Monte Carlo
►
HTTP server
►
PROOF
►
TMVA
►
RooFit
►
Dataframe
►
ROOT7 classes
►
NTuple-related classes
►
Tree Library
►
TreePlayer Library
▼
Tutorials
►
Histograms tutorials
►
Tree tutorials
►
Dataframe tutorials
►
ROOT 7 tutorials
►
FOAM tutorials
►
Containers tutorials
►
Event display tutorials
►
Event display ROOT7 tutorials
►
Geometry tutorials
►
Fast Fourier Transforms tutorials
►
Fit Tutorials
►
RooFit Tutorials
►
Graphs tutorials
►
Graphics tutorials
►
OpenGL tutorials
►
Tutorials specific to Mac/Cocoa
►
GUI tutorials
►
HistFactory Tutorials
►
HTTP tutorials
►
Image tutorials
►
IO tutorials
►
Math tutorials
►
Matrix tutorials
►
Monte Carlo tutorials
►
Multicore tutorials
►
Net tutorials
►
Physics tutorials
►
PyRoot tutorials
►
Pythia tutorials
►
Quadratic programming package.
►
R tutorials
►
RooStats Tutorials
►
Spectrum tutorials
►
TSPlot tutorials
►
SQL tutorials
►
TMVA tutorials
►
TUnfold tutorials
►
Unuran tutorials
►
VecOps tutorials
►
FITS files interface tutorials
►
XML tutorials
►
Proof tutorials
►
Webgui tutorials
▼
Legacy tutorials
►
Containers tutorials
►
Multi Layer Perceptron tutorials
►
Regexp tutorials
►
Thread tutorials
benchmarks.C
geant3tasks.C
htmlex.C
MyTasks.cxx
ProofNtuple.C
ProofNtuple.h
ProofPythia.C
ProofPythia.h
rootalias.C
rootenv.C
rootmarks.C
tasks.C
demos.C
demoshelp.C
hsimple.C
rootlogoff.C
rootlogon.C
►
R Interface for Statistical Computing
►
Namespaces
►
All Classes
►
Files
Release Notes
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Modules
Pages
Loading...
Searching...
No Matches
rootalias.C File Reference
Tutorials
»
Legacy tutorials
Detailed Description
Defines aliases:
ls(path)
edit(filename)
dir(path)
pwd()
cd(path)
//______________________________________________________________________________
void
edit
(
char
*file)
{
char
s[64], *
e
;
if
(!
strcmp
(
gSystem
->
GetName
(),
"WinNT"
)) {
if
((
e
=
getenv
(
"EDITOR"
)))
sprintf
(s,
"start %s %s"
,
e
, file);
else
sprintf
(s,
"start notepad %s"
, file);
}
else
{
if
((
e
=
getenv
(
"EDITOR"
)))
sprintf
(s,
"%s %s"
,
e
, file);
else
sprintf
(s,
"xterm -e vi %s &"
, file);
}
gSystem
->
Exec
(s);
}
//______________________________________________________________________________
void
ls(
char
*path=0)
{
char
s[256];
strcpy
(s, (!
strcmp
(
gSystem
->
GetName
(),
"WinNT"
)) ?
"dir /w "
:
"ls "
);
if
(path)
strcat
(s,path);
gSystem
->
Exec
(s);
}
//______________________________________________________________________________
void
dir
(
char
*path=0)
{
char
s[256];
strcpy
(s,(!
strcmp
(
gSystem
->
GetName
(),
"WinNT"
)) ?
"dir "
:
"ls -l "
);
if
(path)
strcat
(s,path);
gSystem
->
Exec
(s);
}
//______________________________________________________________________________
const
char
*pwd()
{
return
gSystem
->
WorkingDirectory
();
}
//______________________________________________________________________________
const
char
*cd(
char
*path=0)
{
if
(path)
gSystem
->
ChangeDirectory
(path);
return
pwd();
}
TCanvas
*
bench
= 0;
//______________________________________________________________________________
void
bexec2
(
char
*
macro
)
{
printf
(
"in bexec dir=%s\n"
,pwd());
if
(
gROOT
->IsBatch())
printf
(
"Processing benchmark: %s\n"
,
macro
);
TPaveText
*
summary
= (
TPaveText
*)
bench
->GetPrimitive(
"TPave"
);
TText
*
tmacro
=
summary
->GetLineWith(
macro
);
if
(
tmacro
)
tmacro
->SetTextColor(4);
bench
->Modified();
bench
->Update();
gROOT
->Macro(
macro
);
TPaveText
*
summary2
= (
TPaveText
*)
bench
->GetPrimitive(
"TPave"
);
TText
*
tmacro2
=
summary2
->GetLineWith(
macro
);
if
(
tmacro2
)
tmacro2
->SetTextColor(2);
bench
->Modified();
bench
->Update();
}
e
#define e(i)
Definition
RSha256.hxx:103
TRangeDynCast
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
Definition
TCollection.h:358
gROOT
#define gROOT
Definition
TROOT.h:406
gSystem
R__EXTERN TSystem * gSystem
Definition
TSystem.h:566
ROOT::Detail::TRangeCast
Definition
TCollection.h:311
TCanvas
The Canvas class.
Definition
TCanvas.h:23
TNamed::GetName
const char * GetName() const override
Returns name of object.
Definition
TNamed.h:47
TPaveText
A Pave (see TPave) with text, lines or/and boxes inside.
Definition
TPaveText.h:21
TSystem::Exec
virtual Int_t Exec(const char *shellcmd)
Execute a command.
Definition
TSystem.cxx:653
TSystem::ChangeDirectory
virtual Bool_t ChangeDirectory(const char *path)
Change directory.
Definition
TSystem.cxx:862
TSystem::WorkingDirectory
virtual const char * WorkingDirectory()
Return working directory.
Definition
TSystem.cxx:871
TText
Base class for several text objects.
Definition
TText.h:22
Author
Rene Brun
Definition in file
rootalias.C
.
tutorials
legacy
rootalias.C
ROOT v6-32 - Reference Guide Generated on Sun Apr 20 2025 05:38:08 (GVA Time) using Doxygen 1.10.0