Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
ROOT::Experimental::RStyle Class Reference

A set of defaults for graphics attributes, e.g.

for histogram fill color, line width, frame offsets etc. Uses CSS syntax.

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

Definition at line 32 of file RStyle.hxx.

Classes

struct  Block_t
 

Public Member Functions

RAttrMapAddBlock (const std::string &selector)
 
void Clear ()
 Parse string with CSS code inside.
 
const RAttrMap::Value_tEval (const std::string &field, const RDrawable &drawable) const
 Evaluate attribute value for provided RDrawable.
 
const RAttrMap::Value_tEval (const std::string &field, const std::string &selector) const
 Evaluate attribute value for provided selector - exact match is expected.
 
bool ParseString (const std::string &css_code)
 Parse string with CSS code inside All data will be append to existing style records.
 

Static Public Member Functions

static std::shared_ptr< RStyleParse (const std::string &css_code)
 Parse CSS code and returns std::shared_ptr<RStyle> when successful.
 

Private Attributes

std::list< Block_tfBlocks
 

#include <ROOT/RStyle.hxx>

Member Function Documentation

◆ AddBlock()

RAttrMap & ROOT::Experimental::RStyle::AddBlock ( const std::string &  selector)
inline

Definition at line 50 of file RStyle.hxx.

◆ Clear()

void ROOT::Experimental::RStyle::Clear ( )

Parse string with CSS code inside.

Definition at line 63 of file RStyle.cxx.

◆ Eval() [1/2]

const ROOT::Experimental::RAttrMap::Value_t * ROOT::Experimental::RStyle::Eval ( const std::string &  field,
const RDrawable drawable 
) const

Evaluate attribute value for provided RDrawable.

Definition at line 22 of file RStyle.cxx.

◆ Eval() [2/2]

const ROOT::Experimental::RAttrMap::Value_t * ROOT::Experimental::RStyle::Eval ( const std::string &  field,
const std::string &  selector 
) const

Evaluate attribute value for provided selector - exact match is expected.

Definition at line 42 of file RStyle.cxx.

◆ Parse()

std::shared_ptr< ROOT::Experimental::RStyle > ROOT::Experimental::RStyle::Parse ( const std::string &  css_code)
static

Parse CSS code and returns std::shared_ptr<RStyle> when successful.

Definition at line 274 of file RStyle.cxx.

◆ ParseString()

bool ROOT::Experimental::RStyle::ParseString ( const std::string &  css_code)

Parse string with CSS code inside All data will be append to existing style records.

Definition at line 72 of file RStyle.cxx.

Member Data Documentation

◆ fBlocks

std::list<Block_t> ROOT::Experimental::RStyle::fBlocks
private

Definition at line 64 of file RStyle.hxx.

Libraries for ROOT::Experimental::RStyle:

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