Logo Search packages:      
Sourcecode: inkscape version File versions

style.h File Reference


Detailed Description

SPStyle - a style object for SPItem objects

Authors: Lauris Kaplinski <lauris@kaplinski.com>

Copyright (C) 2001-2002 Lauris Kaplinski Copyright (C) 2001 Ximian, Inc.

Released under GNU GPL, read the file 'COPYING' for more information

Definition in file style.h.

#include "color.h"
#include "forward.h"
#include "sp-marker-loc.h"
#include "sp-filter.h"
#include "sp-filter-reference.h"
#include "uri-references.h"
#include "uri.h"
#include "sp-paint-server.h"
#include <sigc++/connection.h>

Go to the source code of this file.

Namespaces

namespace  Inkscape
namespace  Inkscape::XML

Classes

class  NRVpathDash
 Stroke dash details. More...
struct  SPIEnum
 Enum type internal to SPStyle. More...
struct  SPIFilter
 Filter type internal to SPStyle. More...
struct  SPIFloat
 Float type internal to SPStyle. More...
struct  SPIFontSize
 Fontsize type internal to SPStyle. More...
struct  SPIInt
 Int type internal to SPStyle. More...
struct  SPILength
 Length type internal to SPStyle. More...
struct  SPILengthOrNormal
 Extended length type internal to SPStyle. More...
struct  SPIPaint
 Paint type internal to SPStyle. More...
struct  SPIScale24
 24 bit data type internal to SPStyle. More...
struct  SPIShort
 Short type internal to SPStyle. More...
struct  SPIString
 String type internal to SPStyle. More...
struct  SPITextDecoration
 Text decoration type internal to SPStyle. More...
struct  SPStyle
 An SVG style object. More...
struct  SPTextStyle
 An SPTextStyle has a refcount, a font family, and a font name. More...

Defines

#define SP_F8_16_FROM_FLOAT(v)   ((int) ((v) * ((1 << 16) + 0.9999)))
#define SP_F8_16_TO_FLOAT(v)   ((gdouble) (v) / (1 << 16))
#define SP_FONT_SIZE   ((1 << 24) - 1)
#define SP_OBJECT_STYLE_FILL_SERVER(o)   (SP_OBJECT (o)->style->getFillPaintServer())
#define SP_OBJECT_STYLE_STROKE_SERVER(o)   (SP_OBJECT (o)->style->getStrokePaintServer())
#define SP_SCALE24_FROM_FLOAT(v)   unsigned(((v) * SP_SCALE24_MAX) + .5)
#define SP_SCALE24_MAX   (0xff0000)
#define SP_SCALE24_MUL(_v1, _v2)   unsigned((double)(_v1) * (_v2) / SP_SCALE24_MAX + .5)
#define SP_SCALE24_TO_FLOAT(v)   ((double) (v) / SP_SCALE24_MAX)
#define SP_STYLE_FILL_SERVER(s)   (((SPStyle *) (s))->getFillPaintServer())
#define SP_STYLE_FLAG_ALWAYS   (1 << 2)
#define SP_STYLE_FLAG_IFDIFF   (1 << 1)
#define SP_STYLE_FLAG_IFSET   (1 << 0)
#define SP_STYLE_STROKE_SERVER(s)   (((SPStyle *) (s))->getStrokePaintServer())

Enumerations

enum  {
  SP_CSS_UNIT_NONE, SP_CSS_UNIT_PX, SP_CSS_UNIT_PT, SP_CSS_UNIT_PC,
  SP_CSS_UNIT_MM, SP_CSS_UNIT_CM, SP_CSS_UNIT_IN, SP_CSS_UNIT_EM,
  SP_CSS_UNIT_EX, SP_CSS_UNIT_PERCENT
}
enum  { SP_FONT_SIZE_LITERAL, SP_FONT_SIZE_LENGTH, SP_FONT_SIZE_PERCENTAGE }
enum  SPCSSBlockProgression { SP_CSS_BLOCK_PROGRESSION_TB, SP_CSS_BLOCK_PROGRESSION_RL, SP_CSS_BLOCK_PROGRESSION_LR }
enum  SPCSSDirection { SP_CSS_DIRECTION_LTR, SP_CSS_DIRECTION_RTL }
enum  SPCSSDisplay {
  SP_CSS_DISPLAY_NONE, SP_CSS_DISPLAY_INLINE, SP_CSS_DISPLAY_BLOCK, SP_CSS_DISPLAY_LIST_ITEM,
  SP_CSS_DISPLAY_RUN_IN, SP_CSS_DISPLAY_COMPACT, SP_CSS_DISPLAY_MARKER, SP_CSS_DISPLAY_TABLE,
  SP_CSS_DISPLAY_INLINE_TABLE, SP_CSS_DISPLAY_TABLE_ROW_GROUP, SP_CSS_DISPLAY_TABLE_HEADER_GROUP, SP_CSS_DISPLAY_TABLE_FOOTER_GROUP,
  SP_CSS_DISPLAY_TABLE_ROW, SP_CSS_DISPLAY_TABLE_COLUMN_GROUP, SP_CSS_DISPLAY_TABLE_COLUMN, SP_CSS_DISPLAY_TABLE_CELL,
  SP_CSS_DISPLAY_TABLE_CAPTION
}
enum  SPCSSFontSize {
  SP_CSS_FONT_SIZE_XX_SMALL, SP_CSS_FONT_SIZE_X_SMALL, SP_CSS_FONT_SIZE_SMALL, SP_CSS_FONT_SIZE_MEDIUM,
  SP_CSS_FONT_SIZE_LARGE, SP_CSS_FONT_SIZE_X_LARGE, SP_CSS_FONT_SIZE_XX_LARGE, SP_CSS_FONT_SIZE_SMALLER,
  SP_CSS_FONT_SIZE_LARGER
}
enum  SPCSSFontStretch {
  SP_CSS_FONT_STRETCH_ULTRA_CONDENSED, SP_CSS_FONT_STRETCH_EXTRA_CONDENSED, SP_CSS_FONT_STRETCH_CONDENSED, SP_CSS_FONT_STRETCH_SEMI_CONDENSED,
  SP_CSS_FONT_STRETCH_NORMAL, SP_CSS_FONT_STRETCH_SEMI_EXPANDED, SP_CSS_FONT_STRETCH_EXPANDED, SP_CSS_FONT_STRETCH_EXTRA_EXPANDED,
  SP_CSS_FONT_STRETCH_ULTRA_EXPANDED, SP_CSS_FONT_STRETCH_NARROWER, SP_CSS_FONT_STRETCH_WIDER
}
enum  SPCSSFontStyle { SP_CSS_FONT_STYLE_NORMAL, SP_CSS_FONT_STYLE_ITALIC, SP_CSS_FONT_STYLE_OBLIQUE }
enum  SPCSSFontVariant { SP_CSS_FONT_VARIANT_NORMAL, SP_CSS_FONT_VARIANT_SMALL_CAPS }
enum  SPCSSFontWeight {
  SP_CSS_FONT_WEIGHT_100, SP_CSS_FONT_WEIGHT_200, SP_CSS_FONT_WEIGHT_300, SP_CSS_FONT_WEIGHT_400,
  SP_CSS_FONT_WEIGHT_500, SP_CSS_FONT_WEIGHT_600, SP_CSS_FONT_WEIGHT_700, SP_CSS_FONT_WEIGHT_800,
  SP_CSS_FONT_WEIGHT_900, SP_CSS_FONT_WEIGHT_NORMAL, SP_CSS_FONT_WEIGHT_BOLD, SP_CSS_FONT_WEIGHT_LIGHTER,
  SP_CSS_FONT_WEIGHT_BOLDER
}
enum  SPCSSTextAlign {
  SP_CSS_TEXT_ALIGN_START, SP_CSS_TEXT_ALIGN_END, SP_CSS_TEXT_ALIGN_LEFT, SP_CSS_TEXT_ALIGN_RIGHT,
  SP_CSS_TEXT_ALIGN_CENTER, SP_CSS_TEXT_ALIGN_JUSTIFY
}
enum  SPCSSTextTransform { SP_CSS_TEXT_TRANSFORM_CAPITALIZE, SP_CSS_TEXT_TRANSFORM_UPPERCASE, SP_CSS_TEXT_TRANSFORM_LOWERCASE, SP_CSS_TEXT_TRANSFORM_NONE }
enum  SPCSSWritingMode { SP_CSS_WRITING_MODE_LR_TB, SP_CSS_WRITING_MODE_RL_TB, SP_CSS_WRITING_MODE_TB_RL, SP_CSS_WRITING_MODE_TB_LR }
enum  SPEnableBackground { SP_CSS_BACKGROUND_ACCUMULATE, SP_CSS_BACKGROUND_NEW }
enum  SPOverflow { SP_CSS_OVERFLOW_VISIBLE, SP_CSS_OVERFLOW_HIDDEN, SP_CSS_OVERFLOW_SCROLL, SP_CSS_OVERFLOW_AUTO }
enum  SPTextAnchor { SP_CSS_TEXT_ANCHOR_START, SP_CSS_TEXT_ANCHOR_MIDDLE, SP_CSS_TEXT_ANCHOR_END }
enum  SPVisibility { SP_CSS_VISIBILITY_HIDDEN, SP_CSS_VISIBILITY_COLLAPSE, SP_CSS_VISIBILITY_VISIBLE }

Functions

gchar * attribute_unquote (gchar const *val)
gchar * css2_escape_quote (gchar const *val)
SPCSSAttr * sp_css_attr_from_object (SPObject *object, guint flags=SP_STYLE_FLAG_IFSET)
SPCSSAttr * sp_css_attr_from_style (SPStyle const *const style, guint flags)
SPCSSAttr * sp_css_attr_scale (SPCSSAttr *css, double ex)
SPCSSAttr * sp_css_attr_unset_text (SPCSSAttr *css)
SPCSSAttr * sp_css_attr_unset_uris (SPCSSAttr *css)
void sp_style_merge_from_dying_parent (SPStyle *style, SPStyle const *parent)
void sp_style_merge_from_parent (SPStyle *style, SPStyle const *parent)
void sp_style_merge_from_style_string (SPStyle *style, gchar const *p)
SPStylesp_style_new (SPDocument *document)
SPStylesp_style_new_from_object (SPObject *object)
void sp_style_read_from_object (SPStyle *style, SPObject *object)
void sp_style_read_from_repr (SPStyle *style, Inkscape::XML::Node *repr)
SPStylesp_style_ref (SPStyle *style)
void sp_style_set_property_url (SPObject *item, gchar const *property, SPObject *linked, bool recursive)
void sp_style_set_to_uri_string (SPStyle *style, bool isfill, const gchar *uri)
SPStylesp_style_unref (SPStyle *style)
void sp_style_unset_property_attrs (SPObject *o)
gchar * sp_style_write_difference (SPStyle const *from, SPStyle const *to)
gchar * sp_style_write_string (SPStyle const *style, guint flags=SP_STYLE_FLAG_IFSET)


Generated by  Doxygen 1.6.0   Back to index