Logo ROOT  
Reference Guide
ROOT::Experimental::RDrawable Class Reference

Base class for drawable entities: objects that can be painted on a RPad.

Author
Axel Naumann axel@.nosp@m.cern.nosp@m..ch
Sergey Linev s.lin.nosp@m.ev@g.nosp@m.si.de
Date
2015-08-07
Warning
This is part of the ROOT 7 prototype! It will change without notice. It might trigger earthquakes. Feedback is welcome!

Definition at line 99 of file RDrawable.hxx.

Public Member Functions

 RDrawable (const std::string &type)
 
virtual ~RDrawable ()
 
void ClearStyle ()
 
virtual void Execute (const std::string &)
 
const std::string & GetCssClass () const
 
const std::string & GetCssType () const
 
const std::string & GetId () const
 
virtual void PopulateMenu (RMenuItems &)
 Method can be used to provide menu items for the drawn object. More...
 
void SetCssClass (const std::string &cl)
 
void SetId (const std::string &id)
 
virtual void UseStyle (const std::shared_ptr< RStyle > &style)
 

Protected Member Functions

virtual void CollectShared (Internal::RIOSharedVector_t &)
 
virtual std::unique_ptr< RDisplayItemDisplay () const
 Creates display item for drawable By default item contains drawble data itself. More...
 
RAttrMapGetAttrMap ()
 
const RAttrMapGetAttrMap () const
 
bool MatchSelector (const std::string &selector) const
 Preliminary method which checks if drawable matches with given selector Following selector are allowed: "type" or "#id" or ".class_name" Here type is drawable kind like 'rect' or 'pad' id is drawable identifier, specified with RDrawable::SetId() method class_name is drawable class name, specified with RDrawable::SetCssClass() method. More...
 

Private Attributes

RAttrMap fAttr
 attributes values More...
 
std::string fCssClass
 user defined drawable class, can later go inside map More...
 
std::string fCssType
 ! drawable type, not stored in the root file, must be initialized in constructor More...
 
std::string fId
 optional object identifier, may be used in CSS as well More...
 
std::weak_ptr< RStylefStyle
 ! style applied for RDrawable More...
 

Friends

class RAttrBase
 
class RLegend
 
class RPadBase
 
class RStyle
 

#include <ROOT/RDrawable.hxx>

Inheritance diagram for ROOT::Experimental::RDrawable:
[legend]

Constructor & Destructor Documentation

◆ RDrawable()

ROOT::Experimental::RDrawable::RDrawable ( const std::string &  type)
inlineexplicit

Definition at line 126 of file RDrawable.hxx.

◆ ~RDrawable()

ROOT::Experimental::RDrawable::~RDrawable ( )
virtual

Definition at line 18 of file RDrawable.cxx.

Member Function Documentation

◆ ClearStyle()

void ROOT::Experimental::RDrawable::ClearStyle ( )
inline

Definition at line 138 of file RDrawable.hxx.

◆ CollectShared()

virtual void ROOT::Experimental::RDrawable::CollectShared ( Internal::RIOSharedVector_t )
inlineprotectedvirtual

◆ Display()

std::unique_ptr< ROOT::Experimental::RDisplayItem > ROOT::Experimental::RDrawable::Display ( ) const
protectedvirtual

Creates display item for drawable By default item contains drawble data itself.

Reimplemented in ROOT::Experimental::RPad, and ROOT::Experimental::RObjectDrawable.

Definition at line 42 of file RDrawable.cxx.

◆ Execute()

void ROOT::Experimental::RDrawable::Execute ( const std::string &  )
virtual

◆ GetAttrMap() [1/2]

RAttrMap & ROOT::Experimental::RDrawable::GetAttrMap ( )
inlineprotected

Definition at line 117 of file RDrawable.hxx.

◆ GetAttrMap() [2/2]

const RAttrMap & ROOT::Experimental::RDrawable::GetAttrMap ( ) const
inlineprotected

Definition at line 118 of file RDrawable.hxx.

◆ GetCssClass()

const std::string & ROOT::Experimental::RDrawable::GetCssClass ( ) const
inline

Definition at line 141 of file RDrawable.hxx.

◆ GetCssType()

const std::string & ROOT::Experimental::RDrawable::GetCssType ( ) const
inline

Definition at line 143 of file RDrawable.hxx.

◆ GetId()

const std::string & ROOT::Experimental::RDrawable::GetId ( ) const
inline

Definition at line 145 of file RDrawable.hxx.

◆ MatchSelector()

bool ROOT::Experimental::RDrawable::MatchSelector ( const std::string &  selector) const
protected

Preliminary method which checks if drawable matches with given selector Following selector are allowed: "type" or "#id" or ".class_name" Here type is drawable kind like 'rect' or 'pad' id is drawable identifier, specified with RDrawable::SetId() method class_name is drawable class name, specified with RDrawable::SetCssClass() method.

Definition at line 33 of file RDrawable.cxx.

◆ PopulateMenu()

virtual void ROOT::Experimental::RDrawable::PopulateMenu ( RMenuItems )
inlinevirtual

Method can be used to provide menu items for the drawn object.

Reimplemented in ROOT::Experimental::RObjectDrawable, and ROOT::Experimental::RHistDrawable< DIMENSIONS >.

Definition at line 133 of file RDrawable.hxx.

◆ SetCssClass()

void ROOT::Experimental::RDrawable::SetCssClass ( const std::string &  cl)
inline

Definition at line 140 of file RDrawable.hxx.

◆ SetId()

void ROOT::Experimental::RDrawable::SetId ( const std::string &  id)
inline

Definition at line 146 of file RDrawable.hxx.

◆ UseStyle()

virtual void ROOT::Experimental::RDrawable::UseStyle ( const std::shared_ptr< RStyle > &  style)
inlinevirtual

Reimplemented in ROOT::Experimental::RPadBase.

Definition at line 137 of file RDrawable.hxx.

Friends And Related Function Documentation

◆ RAttrBase

friend class RAttrBase
friend

Definition at line 102 of file RDrawable.hxx.

◆ RLegend

friend class RLegend
friend

Definition at line 104 of file RDrawable.hxx.

◆ RPadBase

friend class RPadBase
friend

Definition at line 101 of file RDrawable.hxx.

◆ RStyle

friend class RStyle
friend

Definition at line 103 of file RDrawable.hxx.

Member Data Documentation

◆ fAttr

RAttrMap ROOT::Experimental::RDrawable::fAttr
private

attributes values

Definition at line 107 of file RDrawable.hxx.

◆ fCssClass

std::string ROOT::Experimental::RDrawable::fCssClass
private

user defined drawable class, can later go inside map

Definition at line 110 of file RDrawable.hxx.

◆ fCssType

std::string ROOT::Experimental::RDrawable::fCssType
private

! drawable type, not stored in the root file, must be initialized in constructor

Definition at line 109 of file RDrawable.hxx.

◆ fId

std::string ROOT::Experimental::RDrawable::fId
private

optional object identifier, may be used in CSS as well

Definition at line 111 of file RDrawable.hxx.

◆ fStyle

std::weak_ptr<RStyle> ROOT::Experimental::RDrawable::fStyle
private

! style applied for RDrawable

Definition at line 108 of file RDrawable.hxx.

Libraries for ROOT::Experimental::RDrawable:
[legend]

The documentation for this class was generated from the following files: