inlib  1.2.0
Public Member Functions | Public Attributes
inlib::sg::style Class Reference
Inheritance diagram for inlib::sg::style:
Inheritance graph
[legend]
Collaboration diagram for inlib::sg::style:
Collaboration graph
[legend]

List of all members.

Public Member Functions

virtual nodecopy () const
virtual const std::string & s_cls () const
 style ()
virtual ~style ()
 style (const style &a_from)
styleoperator= (const style &a_from)
bool from_string (std::ostream &a_out, const cmaps_t &a_cmaps, const std::string &a_s)

Public Attributes

sf_vec< colorf, float > color
sf_vec< colorf, float > highlight_color
sf_vec< colorf, float > back_color
sf< float > line_width
sf< float > marker_size
sf< float > font_size
sf< lpatline_pattern
sf_enum< sg::marker_stylemarker_style
sf_enum< sg::area_stylearea_style
sf_string modeling
sf_string light_model
sf_string tick_modeling
sf_string encoding
sf< bool > smoothing
sf< bool > hinting
sf_string cut
sf_enum< sg::painting_policypainting
sf_enum< sg::hatching_policyhatching
sf_enum< sg::projection_typeprojection
sf_string font
sf< int > multi_node_limit
sf< int > divisions
sf< unsigned int > rotation_steps
sf< float > transparency
sf< float > back_transparency
sf< float > spacing
sf< float > angle
sf< float > scale
sf< float > offset
sf< float > strip_width
sf< bool > visible
sf< float > bar_offset
sf< float > bar_width
sf< bool > editable
sf< bool > automated
sf_string options
sf_string color_mapping
sf< bool > enforced
sf_vec< vec3f, float > translation

Detailed Description

Definition at line 18 of file style.


Constructor & Destructor Documentation

inlib::sg::style::style ( ) [inline]
virtual inlib::sg::style::~style ( ) [inline, virtual]

Definition at line 153 of file style.

{}
inlib::sg::style::style ( const style a_from) [inline]

Definition at line 155 of file style.

  :node(a_from)
  ,color(a_from.color)
  ,highlight_color(a_from.highlight_color)
  ,back_color(a_from.back_color)
  ,line_width(a_from.line_width)
  ,marker_size(a_from.marker_size)
  ,font_size(a_from.font_size)
  ,line_pattern(a_from.line_pattern)
  ,marker_style(a_from.marker_style)
  ,area_style(a_from.area_style)
  ,modeling (a_from.modeling )
  ,light_model(a_from.light_model)
  ,tick_modeling(a_from.tick_modeling)
  ,encoding(a_from.encoding)
  ,smoothing(a_from.smoothing)
  ,hinting(a_from.hinting)
  ,cut(a_from.cut)
  ,painting(a_from.painting)
  ,hatching(a_from.hatching)
  ,projection(a_from.projection)
  ,font(a_from.font)
  ,multi_node_limit(a_from.multi_node_limit)
  ,divisions(a_from.divisions)
  ,rotation_steps(a_from.rotation_steps)
  ,transparency(a_from.transparency)
  ,back_transparency(a_from.back_transparency)
  ,spacing(a_from.spacing)
  ,angle(a_from.angle)
  ,scale(a_from.scale)
  ,offset(a_from.offset)
  ,strip_width(a_from.strip_width)
  ,visible(a_from.visible)
  ,bar_offset(a_from.bar_offset)
  ,bar_width(a_from.bar_width)
  ,editable(a_from.editable)
  ,automated(a_from.automated)
  ,options(a_from.options)
  ,color_mapping(a_from.color_mapping)
  ,enforced(a_from.enforced)
  ,translation(a_from.translation)
  {
    add_fields();
  }

Member Function Documentation

virtual node* inlib::sg::style::copy ( ) const [inline, virtual]

Implements inlib::sg::node.

Definition at line 106 of file style.

{return new style(*this);}
bool inlib::sg::style::from_string ( std::ostream &  a_out,
const cmaps_t a_cmaps,
const std::string &  a_s 
) [inline]

Definition at line 245 of file style.

                                               {
    style_parser sp;

    sp.color(color.value());
    sp.highlight_color(highlight_color.value());
    sp.back_color(back_color.value());
    sp.line_width(line_width.value());
    sp.marker_size(marker_size.value());
    sp.font_size(font_size.value());
    sp.line_pattern(line_pattern.value());
    sp.marker_style(marker_style.value());
    sp.area_style(area_style.value());
    sp.modeling(modeling.value());
    sp.light_model(light_model.value());
    sp.tick_modeling(tick_modeling.value());
    sp.encoding(encoding.value());
    sp.smoothing(smoothing.value());
    sp.hinting(hinting.value());
    sp.cut(cut.value());
    sp.painting(painting.value());
    sp.hatching(hatching.value());
    sp.projection(projection.value());
    sp.font(font.value());
    sp.multi_node_limit(multi_node_limit.value());
    sp.divisions(divisions.value());
    sp.rotation_steps(rotation_steps.value());
    sp.transparency(transparency.value());
    sp.back_transparency(back_transparency.value());
    sp.spacing(spacing.value());
    sp.angle(angle.value());
    sp.scale(scale.value());
    sp.offset(offset.value());
    sp.strip_width(strip_width.value());
    sp.visible(visible.value());
    sp.bar_offset(bar_offset.value());
    sp.bar_width(bar_width.value());
    sp.editable(editable.value());
    sp.automated(automated.value());
    sp.options(options.value());
    sp.color_mapping(color_mapping.value());
    sp.enforced(enforced.value());
    sp.translation(translation.value());

    //if(!sp.parse(a_s,inlib::sg::style_parser::def_error_func)) 
    //  return false;

    if(!sp.parse(a_out,a_cmaps,a_s)) {
      a_out << "inlib::sg::style::from_string :"
            << " parse failed."
            << std::endl;
      return false;    
    }

    color.value(sp.color());
    highlight_color.value(sp.highlight_color());
    back_color.value(sp.back_color());
    line_width.value(sp.line_width());
    marker_size.value(sp.marker_size());
    font_size.value(sp.font_size());
    line_pattern.value(sp.line_pattern());
    marker_style.value(sp.marker_style());
    area_style.value(sp.area_style());
    modeling.value(sp.modeling());
    light_model.value(sp.light_model());
    tick_modeling.value(sp.tick_modeling());
    encoding.value(sp.encoding());
    smoothing.value(sp.smoothing());
    hinting.value(sp.hinting());
    cut.value(sp.cut());
    painting.value(sp.painting());
    hatching.value(sp.hatching());
    projection.value(sp.projection());
    font.value(sp.font());
    multi_node_limit.value(sp.multi_node_limit());
    divisions.value(sp.divisions());
    rotation_steps.value(sp.rotation_steps());
    transparency.value(sp.transparency());
    back_transparency.value(sp.back_transparency());
    spacing.value(sp.spacing());
    angle.value(sp.angle());
    scale.value(sp.scale());
    offset.value(sp.offset());
    strip_width.value(sp.strip_width());
    visible.value(sp.visible());
    bar_offset.value(sp.bar_offset());
    bar_width.value(sp.bar_width());
    editable.value(sp.editable());
    automated.value(sp.automated());
    options.value(sp.options());
    color_mapping.value(sp.color_mapping());
    enforced.value(sp.enforced());
    translation.value(sp.translation());

    return true;
  }
style& inlib::sg::style::operator= ( const style a_from) [inline]

Definition at line 199 of file style.

                                       {
    node::operator=(a_from);

    color = a_from.color;
    highlight_color = a_from.highlight_color;
    back_color = a_from.back_color;
    line_width = a_from.line_width;
    marker_size = a_from.marker_size;
    font_size = a_from.font_size;
    line_pattern = a_from.line_pattern;
    marker_style = a_from.marker_style;
    area_style = a_from.area_style;
    modeling  = a_from.modeling ;
    light_model = a_from.light_model;
    tick_modeling = a_from.tick_modeling;
    encoding = a_from.encoding;
    smoothing = a_from.smoothing;
    hinting = a_from.hinting;
    cut = a_from.cut;
    painting = a_from.painting;
    hatching = a_from.hatching;
    projection = a_from.projection;
    font = a_from.font;
    multi_node_limit = a_from.multi_node_limit;
    divisions = a_from.divisions;
    rotation_steps = a_from.rotation_steps;
    transparency = a_from.transparency;
    back_transparency = a_from.back_transparency;
    spacing = a_from.spacing;
    angle = a_from.angle;
    scale = a_from.scale;
    offset = a_from.offset;
    strip_width = a_from.strip_width;
    visible = a_from.visible;
    bar_offset = a_from.bar_offset;
    bar_width = a_from.bar_width;
    editable = a_from.editable;
    automated = a_from.automated;
    options = a_from.options;
    color_mapping = a_from.color_mapping;
    enforced = a_from.enforced;
    translation = a_from.translation;

    return *this;
  }
virtual const std::string& inlib::sg::style::s_cls ( ) const [inline, virtual]

Implements inlib::sg::node.

Definition at line 107 of file style.

{return s_class();}

Member Data Documentation

Definition at line 50 of file style.

Definition at line 32 of file style.

Definition at line 58 of file style.

Definition at line 26 of file style.

Definition at line 48 of file style.

Definition at line 55 of file style.

Definition at line 56 of file style.

Definition at line 24 of file style.

Definition at line 60 of file style.

Definition at line 39 of file style.

Definition at line 45 of file style.

Definition at line 57 of file style.

Definition at line 36 of file style.

Definition at line 61 of file style.

Definition at line 43 of file style.

Definition at line 29 of file style.

Definition at line 41 of file style.

Definition at line 25 of file style.

Definition at line 38 of file style.

Definition at line 34 of file style.

Definition at line 30 of file style.

Definition at line 27 of file style.

Definition at line 28 of file style.

Definition at line 31 of file style.

Definition at line 33 of file style.

Definition at line 44 of file style.

Definition at line 52 of file style.

Definition at line 59 of file style.

Definition at line 40 of file style.

Definition at line 42 of file style.

Definition at line 46 of file style.

Definition at line 51 of file style.

Definition at line 37 of file style.

Definition at line 49 of file style.

Definition at line 53 of file style.

Definition at line 35 of file style.

Definition at line 62 of file style.

Definition at line 47 of file style.

Definition at line 54 of file style.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines