comparison src/styleengine.hh @ 1039:4ed33b76809c

wrap long lines in src/ css code
author corvid <corvid@lavabit.com>
date Sun, 19 Apr 2009 10:25:22 +0200
parents 474b9814a8fa
children a913df1621ac
comparison
equal deleted inserted replaced
1038:4d38b02bc704 1039:4ed33b76809c
25 int importDepth; 25 int importDepth;
26 26
27 dw::core::style::Style *style0 (CssPropertyList *nonCssHints = NULL); 27 dw::core::style::Style *style0 (CssPropertyList *nonCssHints = NULL);
28 dw::core::style::Style *wordStyle0 (CssPropertyList *nonCssHints = NULL); 28 dw::core::style::Style *wordStyle0 (CssPropertyList *nonCssHints = NULL);
29 void apply (dw::core::style::StyleAttrs *attrs, CssPropertyList *props); 29 void apply (dw::core::style::StyleAttrs *attrs, CssPropertyList *props);
30 bool computeValue (int *dest, CssLength value, dw::core::style::Font *font); 30 bool computeValue (int *dest, CssLength value,
31 bool computeValue (int *dest, CssLength value, dw::core::style::Font *font, 31 dw::core::style::Font *font);
32 int percentageBase); 32 bool computeValue (int *dest, CssLength value,
33 dw::core::style::Font *font, int percentageBase);
33 bool computeLength (dw::core::style::Length *dest, CssLength value, 34 bool computeLength (dw::core::style::Length *dest, CssLength value,
34 dw::core::style::Font *font); 35 dw::core::style::Font *font);
35 36
36 public: 37 public:
37 StyleEngine (dw::core::Layout *layout); 38 StyleEngine (dw::core::Layout *layout);
47 return stack->getRef (n->depth - 1); 48 return stack->getRef (n->depth - 1);
48 else 49 else
49 return NULL; 50 return NULL;
50 }; 51 };
51 52
52 void parse (DilloHtml *html, DilloUrl *url, const char *buf, int buflen, CssOrigin origin); 53 void parse (DilloHtml *html, DilloUrl *url, const char *buf, int buflen,
54 CssOrigin origin);
53 void startElement (int tag); 55 void startElement (int tag);
54 void startElement (const char *tagname); 56 void startElement (const char *tagname);
55 void setId (const char *id); 57 void setId (const char *id);
56 const char * getId () { return top ()->id; }; 58 const char * getId () { return top ()->id; };
57 void setClass (const char *klass); 59 void setClass (const char *klass);
70 else 72 else
71 return style0 (); 73 return style0 ();
72 }; 74 };
73 75
74 inline dw::core::style::Style *wordStyle () { 76 inline dw::core::style::Style *wordStyle () {
75 dw::core::style::Style *s = stack->getRef (stack->size () - 1)->wordStyle; 77 dw::core::style::Style *s = stack->getRef(stack->size()-1)->wordStyle;
76 if (s) 78 if (s)
77 return s; 79 return s;
78 else 80 else
79 return wordStyle0 (); 81 return wordStyle0 ();
80 }; 82 };