10#define ROOT7_RDrawable
21namespace Experimental {
58 virtual void SetShared(
void *shared)
final {
fShared = *((std::shared_ptr<T> *) shared); }
122 virtual std::unique_ptr<RDisplayItem>
Display()
const;
135 virtual void Execute(
const std::string &);
152template <
class DRAWABLE, std::enable_if_t<std::is_base_of<RDrawable, DRAWABLE>{}>* =
nullptr>
virtual void SetShared(void *shared)=0
virtual void * MakeShared()=0
virtual const void * GetIOPtr() const =0
virtual ~RIOSharedBase()=default
virtual bool HasShared() const =0
T * fIO
plain pointer for IO
std::shared_ptr< T > fShared
! holder of object
virtual void SetShared(void *shared) final
RIOShared(const std::shared_ptr< T > &ptr)
const void * GetIOPtr() const final
virtual void * MakeShared() final
virtual bool HasShared() const final
const T * operator->() const
RIOShared & operator=(const std::shared_ptr< T > &ptr)
std::shared_ptr< T > get_shared() const
Base class for all attributes, used with RDrawable.
Base class for drawable entities: objects that can be painted on a RPad.
const RAttrMap & GetAttrMap() const
virtual void PopulateMenu(RMenuItems &)
Method can be used to provide menu items for the drawn object.
std::weak_ptr< RStyle > fStyle
! style applied for RDrawable
const std::string & GetId() const
virtual void Execute(const std::string &)
void SetCssClass(const std::string &cl)
RAttrMap fAttr
attributes values
std::string fCssClass
user defined drawable class, can later go inside map
std::string fId
optional object identifier, may be used in CSS as well
const std::string & GetCssType() const
virtual std::unique_ptr< RDisplayItem > Display() const
Creates display item for drawable By default item contains drawble data itself.
virtual void UseStyle(const std::shared_ptr< RStyle > &style)
const std::string & GetCssClass() const
void SetId(const std::string &id)
virtual void CollectShared(Internal::RIOSharedVector_t &)
RDrawable(const std::string &type)
bool MatchSelector(const std::string &selector) const
Preliminary method which checks if drawable matches with given selector Following selector are allowe...
std::string fCssType
! drawable type, not stored in the root file, must be initialized in constructor
Base class for graphic containers for RDrawable-s.
A set of defaults for graphics attributes, e.g.
std::vector< RIOSharedBase * > RIOSharedVector_t
auto GetDrawable(const std::shared_ptr< DRAWABLE > &drawable)
Central method to insert drawable in list of pad primitives By default drawable placed as is.