Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
R
Root
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Admin message
为了安全,强烈建议开启2FA双因子认证:User Settings -> Account -> Enable two-factor authentication!!!
Show more breadcrumbs
cxwx
Root
Commits
6fa302be
Commit
6fa302be
authored
7 years ago
by
Axel Naumann
Browse files
Options
Downloads
Patches
Plain Diff
Moved to TDrawingOptsBase.cxx.
parent
b216ccb2
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
graf2d/gpad/v7/src/TCanvas.cxx
+0
-107
0 additions, 107 deletions
graf2d/gpad/v7/src/TCanvas.cxx
with
0 additions
and
107 deletions
graf2d/gpad/v7/src/TCanvas.cxx
+
0
−
107
View file @
6fa302be
...
@@ -122,111 +122,4 @@ void ROOT::Experimental::TCanvas::SaveAs(const std::string &filename, bool async
...
@@ -122,111 +122,4 @@ void ROOT::Experimental::TCanvas::SaveAs(const std::string &filename, bool async
fPainter
->
DoWhenReady
(
"JPEG"
,
filename
,
async
,
callback
);
fPainter
->
DoWhenReady
(
"JPEG"
,
filename
,
async
,
callback
);
}
}
void
ROOT
::
Experimental
::
TCanvas
::
RegisterColor
(
size_t
&
idx
,
const
TColor
&
col
)
{
if
(
idx
==
(
size_t
)
-
1
)
{
idx
=
fColorTable
.
size
();
fColorTable
.
push_back
(
col
);
}
else
{
fColorTable
[
idx
]
=
col
;
}
}
// TODO: removal from GetHeldCanvases().
// TODO: removal from GetHeldCanvases().
template
<
class
PRIMITIVE
>
void
ROOT
::
Experimental
::
Internal
::
TOptsAttrAndUseCount
<
PRIMITIVE
>::
Clear
()
{
if
(
fUseCount
)
{
R__ERROR_HERE
(
"Gpad"
)
<<
"Refusing to clear a referenced primitive (use count "
<<
fUseCount
<<
")!"
;
return
;
}
// destroy fVal:
fVal
.
~
PRIMITIVE
();
}
template
<
class
PRIMITIVE
>
void
ROOT
::
Experimental
::
Internal
::
TOptsAttrAndUseCount
<
PRIMITIVE
>::
Create
(
const
PRIMITIVE
&
val
)
{
if
(
fUseCount
)
{
R__ERROR_HERE
(
"Gpad"
)
<<
"Refusing to create a primitive over an existing one (use count "
<<
fUseCount
<<
")!"
;
return
;
}
// copy-construct fVal:
new
(
fVal
)
PRIMITIVE
(
val
);
fUseCount
=
1
;
}
template
<
class
PRIMITIVE
>
void
ROOT
::
Experimental
::
Internal
::
TOptsAttrAndUseCount
<
PRIMITIVE
>::
IncrUse
(
const
PRIMITIVE
&
val
)
{
if
(
fUseCount
==
0
)
{
R__ERROR_HERE
(
"Gpad"
)
<<
"Refusing to increase use count on a non-existing primitive!"
;
return
;
}
++
fUseCount
;
}
template
<
class
PRIMITIVE
>
void
ROOT
::
Experimental
::
Internal
::
TOptsAttrAndUseCount
<
PRIMITIVE
>::
DecrUse
(
const
PRIMITIVE
&
val
)
{
if
(
fUseCount
==
0
)
{
R__ERROR_HERE
(
"Gpad"
)
<<
"Refusing to decrease use count on a non-existing primitive!"
;
return
;
}
--
fUseCount
;
if
(
fUseCount
==
0
)
Clear
();
}
// Available specialization:
template
class
ROOT
::
Experimental
::
Internal
::
TOptsAttrAndUseCount
<
TColor
>;
template
class
ROOT
::
Experimental
::
Internal
::
TOptsAttrAndUseCount
<
long
long
>;
template
class
ROOT
::
Experimental
::
Internal
::
TOptsAttrAndUseCount
<
double
>;
template
<
class
PRIMITIVE
>
size_t
TOptsAttrTable
::
Register
(
const
PRIMITIVE
&
val
)
{
auto
isFree
=
[](
const
value_type
&
el
)
->
bool
{
return
el
.
IsFree
()
};
auto
iSlot
=
std
::
find_if
(
fTable
.
begin
(),
fTable
.
last
(),
isFree
);
if
(
iSlot
!=
fTable
.
end
())
{
iSlot
.
Create
(
val
);
return
iSlot
-
fTable
.
begin
();
}
fTable
.
emplace_back
(
val
);
return
fTable
.
size
()
-
1
;
}
// Available specialization:
template
class
ROOT
::
Experimental
::
Internal
::
TOptsAttrTable
<
TColor
>;
template
class
ROOT
::
Experimental
::
Internal
::
TOptsAttrTable
<
long
long
>;
template
class
ROOT
::
Experimental
::
Internal
::
TOptsAttrTable
<
double
>;
template
ROOT
::
Experimental
::
Internal
::
TOptsAttrTable
<
TColor
>
&
ROOT
::
Experimental
::
TCanvas
::
GetAttrTable
<
TColor
>
()
{
return
fColorTable
;
}
template
ROOT
::
Experimental
::
Internal
::
TOptsAttrTable
<
long
long
>
&
ROOT
::
Experimental
::
TCanvas
::
GetAttrTable
<
long
long
>
()
{
return
fIntAttrTable
;
}
template
ROOT
::
Experimental
::
Internal
::
TOptsAttrTable
<
double
>
&
ROOT
::
Experimental
::
TCanvas
::
GetAttrTable
<
double
>
()
{
return
fFPAttrTable
;
}
template
const
ROOT
::
Experimental
::
Internal
::
TOptsAttrTable
<
TColor
>
&
ROOT
::
Experimental
::
TCanvas
::
GetAttrTable
<
TColor
>
()
const
{
return
fColorTable
;
}
template
const
ROOT
::
Experimental
::
Internal
::
TOptsAttrTable
<
long
long
>
&
ROOT
::
Experimental
::
TCanvas
::
GetAttrTable
<
long
long
>
()
const
{
return
fIntAttrTable
;
}
template
const
ROOT
::
Experimental
::
Internal
::
TOptsAttrTable
<
double
>
&
ROOT
::
Experimental
::
TCanvas
::
GetAttrTable
<
double
>
()
const
{
return
fFPAttrTable
;
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment