ReactOS 0.4.15-dev-5667-ged97270
htmlstyle.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  HTMLStyle
 

Macros

#define ATTR_FIX_PX   0x0001
 
#define ATTR_FIX_URL   0x0002
 
#define ATTR_STR_TO_INT   0x0004
 
#define ATTR_HEX_INT   0x0008
 
#define ATTR_REMOVE_COMMA   0x0010
 
#define ATTR_NO_NULL   0x0020
 

Enumerations

enum  styleid_t {
  STYLEID_BACKGROUND , STYLEID_BACKGROUND_ATTACHMENT , STYLEID_BACKGROUND_COLOR , STYLEID_BACKGROUND_IMAGE ,
  STYLEID_BACKGROUND_POSITION , STYLEID_BACKGROUND_POSITION_X , STYLEID_BACKGROUND_POSITION_Y , STYLEID_BACKGROUND_REPEAT ,
  STYLEID_BORDER , STYLEID_BORDER_BOTTOM , STYLEID_BORDER_BOTTOM_COLOR , STYLEID_BORDER_BOTTOM_STYLE ,
  STYLEID_BORDER_BOTTOM_WIDTH , STYLEID_BORDER_COLOR , STYLEID_BORDER_LEFT , STYLEID_BORDER_LEFT_COLOR ,
  STYLEID_BORDER_LEFT_STYLE , STYLEID_BORDER_LEFT_WIDTH , STYLEID_BORDER_RIGHT , STYLEID_BORDER_RIGHT_COLOR ,
  STYLEID_BORDER_RIGHT_STYLE , STYLEID_BORDER_RIGHT_WIDTH , STYLEID_BORDER_STYLE , STYLEID_BORDER_TOP ,
  STYLEID_BORDER_TOP_COLOR , STYLEID_BORDER_TOP_STYLE , STYLEID_BORDER_TOP_WIDTH , STYLEID_BORDER_WIDTH ,
  STYLEID_BOTTOM , STYLEID_BOX_SIZING , STYLEID_CLEAR , STYLEID_CLIP ,
  STYLEID_COLOR , STYLEID_CURSOR , STYLEID_DIRECTION , STYLEID_DISPLAY ,
  STYLEID_FILTER , STYLEID_FLOAT , STYLEID_FONT_FAMILY , STYLEID_FONT_SIZE ,
  STYLEID_FONT_STYLE , STYLEID_FONT_VARIANT , STYLEID_FONT_WEIGHT , STYLEID_HEIGHT ,
  STYLEID_LEFT , STYLEID_LETTER_SPACING , STYLEID_LINE_HEIGHT , STYLEID_LIST_STYLE ,
  STYLEID_LISTSTYLEPOSITION , STYLEID_LISTSTYLETYPE , STYLEID_MARGIN , STYLEID_MARGIN_BOTTOM ,
  STYLEID_MARGIN_LEFT , STYLEID_MARGIN_RIGHT , STYLEID_MARGIN_TOP , STYLEID_MAX_HEIGHT ,
  STYLEID_MAX_WIDTH , STYLEID_MIN_HEIGHT , STYLEID_MIN_WIDTH , STYLEID_OUTLINE ,
  STYLEID_OVERFLOW , STYLEID_OVERFLOW_X , STYLEID_OVERFLOW_Y , STYLEID_PADDING ,
  STYLEID_PADDING_BOTTOM , STYLEID_PADDING_LEFT , STYLEID_PADDING_RIGHT , STYLEID_PADDING_TOP ,
  STYLEID_PAGE_BREAK_AFTER , STYLEID_PAGE_BREAK_BEFORE , STYLEID_POSITION , STYLEID_RIGHT ,
  STYLEID_TABLE_LAYOUT , STYLEID_TEXT_ALIGN , STYLEID_TEXT_DECORATION , STYLEID_TEXT_INDENT ,
  STYLEID_TEXT_TRANSFORM , STYLEID_TOP , STYLEID_VERTICAL_ALIGN , STYLEID_VISIBILITY ,
  STYLEID_WHITE_SPACE , STYLEID_WIDTH , STYLEID_WORD_SPACING , STYLEID_WORD_WRAP ,
  STYLEID_Z_INDEX , STYLEID_MAX_VALUE
}
 

Functions

HRESULT HTMLStyle_Create (HTMLElement *, HTMLStyle **) DECLSPEC_HIDDEN
 
void HTMLStyle2_Init (HTMLStyle *) DECLSPEC_HIDDEN
 
void HTMLStyle3_Init (HTMLStyle *) DECLSPEC_HIDDEN
 
HRESULT get_nsstyle_attr (nsIDOMCSSStyleDeclaration *, styleid_t, BSTR *, DWORD) DECLSPEC_HIDDEN
 
HRESULT set_nsstyle_attr (nsIDOMCSSStyleDeclaration *, styleid_t, LPCWSTR, DWORD) DECLSPEC_HIDDEN
 
HRESULT set_nsstyle_attr_var (nsIDOMCSSStyleDeclaration *nsstyle, styleid_t sid, VARIANT *value, DWORD flags) DECLSPEC_HIDDEN
 
HRESULT get_nsstyle_attr_var (nsIDOMCSSStyleDeclaration *nsstyle, styleid_t sid, VARIANT *p, DWORD flags) DECLSPEC_HIDDEN
 
HRESULT get_elem_style (HTMLElement *, styleid_t, BSTR *) DECLSPEC_HIDDEN
 
HRESULT set_elem_style (HTMLElement *, styleid_t, const WCHAR *) DECLSPEC_HIDDEN
 

Macro Definition Documentation

◆ ATTR_FIX_PX

#define ATTR_FIX_PX   0x0001

Definition at line 139 of file htmlstyle.h.

◆ ATTR_FIX_URL

#define ATTR_FIX_URL   0x0002

Definition at line 140 of file htmlstyle.h.

◆ ATTR_HEX_INT

#define ATTR_HEX_INT   0x0008

Definition at line 142 of file htmlstyle.h.

◆ ATTR_NO_NULL

#define ATTR_NO_NULL   0x0020

Definition at line 144 of file htmlstyle.h.

◆ ATTR_REMOVE_COMMA

#define ATTR_REMOVE_COMMA   0x0010

Definition at line 143 of file htmlstyle.h.

◆ ATTR_STR_TO_INT

#define ATTR_STR_TO_INT   0x0004

Definition at line 141 of file htmlstyle.h.

Enumeration Type Documentation

◆ styleid_t

Enumerator
STYLEID_BACKGROUND 
STYLEID_BACKGROUND_ATTACHMENT 
STYLEID_BACKGROUND_COLOR 
STYLEID_BACKGROUND_IMAGE 
STYLEID_BACKGROUND_POSITION 
STYLEID_BACKGROUND_POSITION_X 
STYLEID_BACKGROUND_POSITION_Y 
STYLEID_BACKGROUND_REPEAT 
STYLEID_BORDER 
STYLEID_BORDER_BOTTOM 
STYLEID_BORDER_BOTTOM_COLOR 
STYLEID_BORDER_BOTTOM_STYLE 
STYLEID_BORDER_BOTTOM_WIDTH 
STYLEID_BORDER_COLOR 
STYLEID_BORDER_LEFT 
STYLEID_BORDER_LEFT_COLOR 
STYLEID_BORDER_LEFT_STYLE 
STYLEID_BORDER_LEFT_WIDTH 
STYLEID_BORDER_RIGHT 
STYLEID_BORDER_RIGHT_COLOR 
STYLEID_BORDER_RIGHT_STYLE 
STYLEID_BORDER_RIGHT_WIDTH 
STYLEID_BORDER_STYLE 
STYLEID_BORDER_TOP 
STYLEID_BORDER_TOP_COLOR 
STYLEID_BORDER_TOP_STYLE 
STYLEID_BORDER_TOP_WIDTH 
STYLEID_BORDER_WIDTH 
STYLEID_BOTTOM 
STYLEID_BOX_SIZING 
STYLEID_CLEAR 
STYLEID_CLIP 
STYLEID_COLOR 
STYLEID_CURSOR 
STYLEID_DIRECTION 
STYLEID_DISPLAY 
STYLEID_FILTER 
STYLEID_FLOAT 
STYLEID_FONT_FAMILY 
STYLEID_FONT_SIZE 
STYLEID_FONT_STYLE 
STYLEID_FONT_VARIANT 
STYLEID_FONT_WEIGHT 
STYLEID_HEIGHT 
STYLEID_LEFT 
STYLEID_LETTER_SPACING 
STYLEID_LINE_HEIGHT 
STYLEID_LIST_STYLE 
STYLEID_LISTSTYLEPOSITION 
STYLEID_LISTSTYLETYPE 
STYLEID_MARGIN 
STYLEID_MARGIN_BOTTOM 
STYLEID_MARGIN_LEFT 
STYLEID_MARGIN_RIGHT 
STYLEID_MARGIN_TOP 
STYLEID_MAX_HEIGHT 
STYLEID_MAX_WIDTH 
STYLEID_MIN_HEIGHT 
STYLEID_MIN_WIDTH 
STYLEID_OUTLINE 
STYLEID_OVERFLOW 
STYLEID_OVERFLOW_X 
STYLEID_OVERFLOW_Y 
STYLEID_PADDING 
STYLEID_PADDING_BOTTOM 
STYLEID_PADDING_LEFT 
STYLEID_PADDING_RIGHT 
STYLEID_PADDING_TOP 
STYLEID_PAGE_BREAK_AFTER 
STYLEID_PAGE_BREAK_BEFORE 
STYLEID_POSITION 
STYLEID_RIGHT 
STYLEID_TABLE_LAYOUT 
STYLEID_TEXT_ALIGN 
STYLEID_TEXT_DECORATION 
STYLEID_TEXT_INDENT 
STYLEID_TEXT_TRANSFORM 
STYLEID_TOP 
STYLEID_VERTICAL_ALIGN 
STYLEID_VISIBILITY 
STYLEID_WHITE_SPACE 
STYLEID_WIDTH 
STYLEID_WORD_SPACING 
STYLEID_WORD_WRAP 
STYLEID_Z_INDEX 
STYLEID_MAX_VALUE 

Definition at line 37 of file htmlstyle.h.

37 {
124} styleid_t;
styleid_t
Definition: htmlstyle.h:37
@ STYLEID_OVERFLOW_Y
Definition: htmlstyle.h:100
@ STYLEID_OVERFLOW_X
Definition: htmlstyle.h:99
@ STYLEID_BORDER_TOP_WIDTH
Definition: htmlstyle.h:64
@ STYLEID_MARGIN_RIGHT
Definition: htmlstyle.h:91
@ STYLEID_BORDER_COLOR
Definition: htmlstyle.h:51
@ STYLEID_BORDER_BOTTOM_WIDTH
Definition: htmlstyle.h:50
@ STYLEID_BACKGROUND_IMAGE
Definition: htmlstyle.h:41
@ STYLEID_BACKGROUND
Definition: htmlstyle.h:38
@ STYLEID_OUTLINE
Definition: htmlstyle.h:97
@ STYLEID_BACKGROUND_REPEAT
Definition: htmlstyle.h:45
@ STYLEID_LETTER_SPACING
Definition: htmlstyle.h:83
@ STYLEID_BOX_SIZING
Definition: htmlstyle.h:67
@ STYLEID_POSITION
Definition: htmlstyle.h:108
@ STYLEID_BORDER_WIDTH
Definition: htmlstyle.h:65
@ STYLEID_FONT_STYLE
Definition: htmlstyle.h:78
@ STYLEID_TEXT_ALIGN
Definition: htmlstyle.h:111
@ STYLEID_TEXT_INDENT
Definition: htmlstyle.h:113
@ STYLEID_CLIP
Definition: htmlstyle.h:69
@ STYLEID_TOP
Definition: htmlstyle.h:115
@ STYLEID_BORDER_RIGHT
Definition: htmlstyle.h:56
@ STYLEID_LISTSTYLEPOSITION
Definition: htmlstyle.h:86
@ STYLEID_CURSOR
Definition: htmlstyle.h:71
@ STYLEID_BORDER_TOP_STYLE
Definition: htmlstyle.h:63
@ STYLEID_PADDING_BOTTOM
Definition: htmlstyle.h:102
@ STYLEID_FONT_VARIANT
Definition: htmlstyle.h:79
@ STYLEID_BORDER_BOTTOM
Definition: htmlstyle.h:47
@ STYLEID_FONT_WEIGHT
Definition: htmlstyle.h:80
@ STYLEID_WHITE_SPACE
Definition: htmlstyle.h:118
@ STYLEID_LISTSTYLETYPE
Definition: htmlstyle.h:87
@ STYLEID_MARGIN_LEFT
Definition: htmlstyle.h:90
@ STYLEID_BORDER_LEFT_STYLE
Definition: htmlstyle.h:54
@ STYLEID_PADDING_TOP
Definition: htmlstyle.h:105
@ STYLEID_TEXT_DECORATION
Definition: htmlstyle.h:112
@ STYLEID_WORD_SPACING
Definition: htmlstyle.h:120
@ STYLEID_BORDER_RIGHT_COLOR
Definition: htmlstyle.h:57
@ STYLEID_MAX_VALUE
Definition: htmlstyle.h:123
@ STYLEID_CLEAR
Definition: htmlstyle.h:68
@ STYLEID_TABLE_LAYOUT
Definition: htmlstyle.h:110
@ STYLEID_HEIGHT
Definition: htmlstyle.h:81
@ STYLEID_MARGIN_TOP
Definition: htmlstyle.h:92
@ STYLEID_MARGIN
Definition: htmlstyle.h:88
@ STYLEID_BACKGROUND_POSITION_X
Definition: htmlstyle.h:43
@ STYLEID_TEXT_TRANSFORM
Definition: htmlstyle.h:114
@ STYLEID_VERTICAL_ALIGN
Definition: htmlstyle.h:116
@ STYLEID_OVERFLOW
Definition: htmlstyle.h:98
@ STYLEID_BORDER_TOP
Definition: htmlstyle.h:61
@ STYLEID_PAGE_BREAK_AFTER
Definition: htmlstyle.h:106
@ STYLEID_DISPLAY
Definition: htmlstyle.h:73
@ STYLEID_FILTER
Definition: htmlstyle.h:74
@ STYLEID_BORDER_RIGHT_WIDTH
Definition: htmlstyle.h:59
@ STYLEID_BORDER_TOP_COLOR
Definition: htmlstyle.h:62
@ STYLEID_BACKGROUND_POSITION
Definition: htmlstyle.h:42
@ STYLEID_COLOR
Definition: htmlstyle.h:70
@ STYLEID_LIST_STYLE
Definition: htmlstyle.h:85
@ STYLEID_MAX_WIDTH
Definition: htmlstyle.h:94
@ STYLEID_MIN_WIDTH
Definition: htmlstyle.h:96
@ STYLEID_PADDING_RIGHT
Definition: htmlstyle.h:104
@ STYLEID_BORDER_RIGHT_STYLE
Definition: htmlstyle.h:58
@ STYLEID_BORDER_BOTTOM_STYLE
Definition: htmlstyle.h:49
@ STYLEID_BACKGROUND_ATTACHMENT
Definition: htmlstyle.h:39
@ STYLEID_VISIBILITY
Definition: htmlstyle.h:117
@ STYLEID_MAX_HEIGHT
Definition: htmlstyle.h:93
@ STYLEID_WIDTH
Definition: htmlstyle.h:119
@ STYLEID_FLOAT
Definition: htmlstyle.h:75
@ STYLEID_MARGIN_BOTTOM
Definition: htmlstyle.h:89
@ STYLEID_RIGHT
Definition: htmlstyle.h:109
@ STYLEID_BORDER_BOTTOM_COLOR
Definition: htmlstyle.h:48
@ STYLEID_PADDING_LEFT
Definition: htmlstyle.h:103
@ STYLEID_BORDER_LEFT
Definition: htmlstyle.h:52
@ STYLEID_BORDER_LEFT_WIDTH
Definition: htmlstyle.h:55
@ STYLEID_FONT_FAMILY
Definition: htmlstyle.h:76
@ STYLEID_BOTTOM
Definition: htmlstyle.h:66
@ STYLEID_MIN_HEIGHT
Definition: htmlstyle.h:95
@ STYLEID_Z_INDEX
Definition: htmlstyle.h:122
@ STYLEID_DIRECTION
Definition: htmlstyle.h:72
@ STYLEID_BORDER_LEFT_COLOR
Definition: htmlstyle.h:53
@ STYLEID_LINE_HEIGHT
Definition: htmlstyle.h:84
@ STYLEID_BACKGROUND_POSITION_Y
Definition: htmlstyle.h:44
@ STYLEID_WORD_WRAP
Definition: htmlstyle.h:121
@ STYLEID_PAGE_BREAK_BEFORE
Definition: htmlstyle.h:107
@ STYLEID_BORDER
Definition: htmlstyle.h:46
@ STYLEID_FONT_SIZE
Definition: htmlstyle.h:77
@ STYLEID_PADDING
Definition: htmlstyle.h:101
@ STYLEID_BORDER_STYLE
Definition: htmlstyle.h:60
@ STYLEID_LEFT
Definition: htmlstyle.h:82
@ STYLEID_BACKGROUND_COLOR
Definition: htmlstyle.h:40

Function Documentation

◆ get_elem_style()

HRESULT get_elem_style ( HTMLElement elem,
styleid_t  styleid,
BSTR ret 
)

Definition at line 3219 of file htmlstyle.c.

3220{
3222 HRESULT hres;
3223
3225 if(FAILED(hres))
3226 return hres;
3227
3228 hres = get_nsstyle_attr(style, styleid, ret, 0);
3229 nsIDOMCSSStyleDeclaration_Release(style);
3230 return hres;
3231}
Arabic default style
Definition: afstyles.h:94
static HRESULT get_style_from_elem(HTMLElement *elem, nsIDOMCSSStyleDeclaration **ret)
Definition: htmlstyle.c:3164
HRESULT get_nsstyle_attr(nsIDOMCSSStyleDeclaration *nsstyle, styleid_t sid, BSTR *p, DWORD flags)
Definition: htmlstyle.c:529
#define FAILED(hr)
Definition: intsafe.h:51
HRESULT hres
Definition: protocol.c:465
static size_t elem
Definition: string.c:68
int ret

Referenced by HTMLBodyElement_get_scroll().

◆ get_nsstyle_attr()

HRESULT get_nsstyle_attr ( nsIDOMCSSStyleDeclaration nsstyle,
styleid_t  sid,
BSTR p,
DWORD  flags 
)

Definition at line 529 of file htmlstyle.c.

530{
531 nsAString str_value;
532 const PRUnichar *value;
534
535 nsAString_Init(&str_value, NULL);
536
537 get_nsstyle_attr_nsval(nsstyle, sid, &str_value);
538
539 nsAString_GetData(&str_value, &value);
541 nsAString_Finish(&str_value);
542
543 TRACE("%s -> %s\n", debugstr_w(style_tbl[sid].name), debugstr_w(*p));
544 return hres;
545}
FT_UInt sid
Definition: cffcmap.c:139
#define NULL
Definition: types.h:112
GLbitfield flags
Definition: glext.h:7161
GLfloat GLfloat p
Definition: glext.h:8902
static HRESULT nsstyle_to_bstr(const WCHAR *val, DWORD flags, BSTR *p)
Definition: htmlstyle.c:483
static HRESULT get_nsstyle_attr_nsval(nsIDOMCSSStyleDeclaration *nsstyle, styleid_t sid, nsAString *value)
Definition: htmlstyle.c:465
static const style_tbl_entry_t style_tbl[]
Definition: htmlstyle.c:201
#define debugstr_w
Definition: kernel32.h:32
void nsAString_Finish(nsAString *) DECLSPEC_HIDDEN
Definition: nsembed.c:836
UINT32 nsAString_GetData(const nsAString *, const PRUnichar **) DECLSPEC_HIDDEN
Definition: nsembed.c:831
BOOL nsAString_Init(nsAString *, const PRUnichar *) DECLSPEC_HIDDEN
Definition: nsembed.c:817
WCHAR PRUnichar
Definition: nsiface.idl:48
#define TRACE(s)
Definition: solgame.cpp:4
Definition: name.c:39
Definition: pdh_main.c:94

Referenced by get_elem_style(), get_style_attr(), HTMLCurrentStyle3_get_whiteSpace(), HTMLCurrentStyle_get_backgroundImage(), HTMLCurrentStyle_get_backgroundRepeat(), HTMLCurrentStyle_get_borderBottomStyle(), HTMLCurrentStyle_get_borderColor(), HTMLCurrentStyle_get_borderLeftStyle(), HTMLCurrentStyle_get_borderRightStyle(), HTMLCurrentStyle_get_borderStyle(), HTMLCurrentStyle_get_borderTopStyle(), HTMLCurrentStyle_get_borderWidth(), HTMLCurrentStyle_get_cursor(), HTMLCurrentStyle_get_display(), HTMLCurrentStyle_get_fontFamily(), HTMLCurrentStyle_get_fontStyle(), HTMLCurrentStyle_get_fontVariant(), HTMLCurrentStyle_get_margin(), HTMLCurrentStyle_get_overflow(), HTMLCurrentStyle_get_padding(), HTMLCurrentStyle_get_position(), HTMLCurrentStyle_get_textAlign(), HTMLCurrentStyle_get_textDecoration(), HTMLCurrentStyle_get_textTransform(), HTMLCurrentStyle_get_visibility(), HTMLStyle2_get_direction(), HTMLStyle2_get_overflowX(), HTMLStyle2_get_overflowY(), HTMLStyle2_get_position(), HTMLStyle2_get_tableLayout(), HTMLStyle3_get_wordWrap(), HTMLStyle6_get_boxSizing(), HTMLStyle6_get_outline(), HTMLStyle_get_clip(), HTMLStyle_get_pageBreakAfter(), HTMLStyle_get_pageBreakBefore(), and HTMLStyle_get_whiteSpace().

◆ get_nsstyle_attr_var()

HRESULT get_nsstyle_attr_var ( nsIDOMCSSStyleDeclaration nsstyle,
styleid_t  sid,
VARIANT p,
DWORD  flags 
)

Definition at line 547 of file htmlstyle.c.

548{
549 nsAString str_value;
550 const PRUnichar *value;
551 BOOL set = FALSE;
552 HRESULT hres = S_OK;
553
554 nsAString_Init(&str_value, NULL);
555
556 get_nsstyle_attr_nsval(nsstyle, sid, &str_value);
557
558 nsAString_GetData(&str_value, &value);
559
560 if(flags & ATTR_STR_TO_INT) {
561 const PRUnichar *ptr = value;
562 BOOL neg = FALSE;
563 INT i = 0;
564
565 if(*ptr == '-') {
566 neg = TRUE;
567 ptr++;
568 }
569
570 while(isdigitW(*ptr))
571 i = i*10 + (*ptr++ - '0');
572
573 if(!*ptr) {
574 V_VT(p) = VT_I4;
575 V_I4(p) = neg ? -i : i;
576 set = TRUE;
577 }
578 }
579
580 if(!set) {
581 BSTR str;
582
584 if(SUCCEEDED(hres)) {
585 V_VT(p) = VT_BSTR;
586 V_BSTR(p) = str;
587 }
588 }
589
590 nsAString_Finish(&str_value);
591
593 return S_OK;
594}
Definition: _set.h:50
#define TRUE
Definition: types.h:120
#define FALSE
Definition: types.h:117
OLECHAR * BSTR
Definition: compat.h:2293
@ VT_BSTR
Definition: compat.h:2303
@ VT_I4
Definition: compat.h:2298
unsigned int BOOL
Definition: ntddk_ex.h:94
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
#define ATTR_STR_TO_INT
Definition: htmlstyle.h:141
#define S_OK
Definition: intsafe.h:52
#define SUCCEEDED(hr)
Definition: intsafe.h:50
static PVOID ptr
Definition: dispmode.c:27
static const char * debugstr_variant(const VARIANT *var)
Definition: container.c:46
#define V_VT(A)
Definition: oleauto.h:211
#define V_BSTR(A)
Definition: oleauto.h:226
#define V_I4(A)
Definition: oleauto.h:247
#define isdigitW(n)
Definition: unicode.h:50
const WCHAR * str
int32_t INT
Definition: typedefs.h:58

Referenced by HTMLCurrentStyle_get_backgroundColor(), HTMLCurrentStyle_get_borderBottomColor(), HTMLCurrentStyle_get_borderBottomWidth(), HTMLCurrentStyle_get_borderLeftColor(), HTMLCurrentStyle_get_borderLeftWidth(), HTMLCurrentStyle_get_borderRightColor(), HTMLCurrentStyle_get_borderRightWidth(), HTMLCurrentStyle_get_borderTopColor(), HTMLCurrentStyle_get_borderTopWidth(), HTMLCurrentStyle_get_bottom(), HTMLCurrentStyle_get_color(), HTMLCurrentStyle_get_fontSize(), HTMLCurrentStyle_get_fontWeight(), HTMLCurrentStyle_get_height(), HTMLCurrentStyle_get_left(), HTMLCurrentStyle_get_letterSpacing(), HTMLCurrentStyle_get_lineHeight(), HTMLCurrentStyle_get_marginBottom(), HTMLCurrentStyle_get_marginLeft(), HTMLCurrentStyle_get_marginRight(), HTMLCurrentStyle_get_marginTop(), HTMLCurrentStyle_get_paddingBottom(), HTMLCurrentStyle_get_paddingLeft(), HTMLCurrentStyle_get_paddingRight(), HTMLCurrentStyle_get_paddingTop(), HTMLCurrentStyle_get_right(), HTMLCurrentStyle_get_textIndent(), HTMLCurrentStyle_get_top(), HTMLCurrentStyle_get_verticalAlign(), HTMLCurrentStyle_get_width(), HTMLCurrentStyle_get_zIndex(), HTMLStyle2_get_bottom(), HTMLStyle2_get_right(), HTMLStyle4_get_minHeight(), HTMLStyle5_get_maxHeight(), HTMLStyle5_get_maxWidth(), HTMLStyle5_get_minWidth(), HTMLStyle_get_backgroundColor(), HTMLStyle_get_borderBottomColor(), HTMLStyle_get_borderBottomWidth(), HTMLStyle_get_borderLeftColor(), HTMLStyle_get_borderLeftWidth(), HTMLStyle_get_borderRightColor(), HTMLStyle_get_borderRightWidth(), HTMLStyle_get_borderTopColor(), HTMLStyle_get_borderTopWidth(), HTMLStyle_get_color(), HTMLStyle_get_fontSize(), HTMLStyle_get_height(), HTMLStyle_get_left(), HTMLStyle_get_letterSpacing(), HTMLStyle_get_lineHeight(), HTMLStyle_get_marginBottom(), HTMLStyle_get_marginLeft(), HTMLStyle_get_marginRight(), HTMLStyle_get_marginTop(), HTMLStyle_get_paddingBottom(), HTMLStyle_get_paddingLeft(), HTMLStyle_get_paddingRight(), HTMLStyle_get_paddingTop(), HTMLStyle_get_textIndent(), HTMLStyle_get_top(), HTMLStyle_get_verticalAlign(), HTMLStyle_get_width(), HTMLStyle_get_wordSpacing(), and HTMLStyle_get_zIndex().

◆ HTMLStyle2_Init()

void HTMLStyle2_Init ( HTMLStyle This)

Definition at line 620 of file htmlstyle2.c.

621{
622 This->IHTMLStyle2_iface.lpVtbl = &HTMLStyle2Vtbl;
623}
static const IHTMLStyle2Vtbl HTMLStyle2Vtbl
Definition: htmlstyle2.c:547

Referenced by HTMLStyle_Create().

◆ HTMLStyle3_Init()

void HTMLStyle3_Init ( HTMLStyle This)

Definition at line 938 of file htmlstyle3.c.

939{
940 This->IHTMLStyle3_iface.lpVtbl = &HTMLStyle3Vtbl;
941 This->IHTMLStyle4_iface.lpVtbl = &HTMLStyle4Vtbl;
942 This->IHTMLStyle5_iface.lpVtbl = &HTMLStyle5Vtbl;
943 This->IHTMLStyle6_iface.lpVtbl = &HTMLStyle6Vtbl;
944}
static const IHTMLStyle6Vtbl HTMLStyle6Vtbl
Definition: htmlstyle3.c:896
static const IHTMLStyle3Vtbl HTMLStyle3Vtbl
Definition: htmlstyle3.c:320
static const IHTMLStyle4Vtbl HTMLStyle4Vtbl
Definition: htmlstyle3.c:452
static const IHTMLStyle5Vtbl HTMLStyle5Vtbl
Definition: htmlstyle3.c:590

Referenced by HTMLStyle_Create().

◆ HTMLStyle_Create()

HRESULT HTMLStyle_Create ( HTMLElement elem,
HTMLStyle **  ret 
)

Definition at line 3188 of file htmlstyle.c.

3189{
3192 HRESULT hres;
3193
3194 hres = get_style_from_elem(elem, &nsstyle);
3195 if(FAILED(hres))
3196 return hres;
3197
3198 style = heap_alloc_zero(sizeof(HTMLStyle));
3199 if(!style) {
3200 nsIDOMCSSStyleDeclaration_Release(nsstyle);
3201 return E_OUTOFMEMORY;
3202 }
3203
3204 style->IHTMLStyle_iface.lpVtbl = &HTMLStyleVtbl;
3205 style->ref = 1;
3206 style->nsstyle = nsstyle;
3207 style->elem = elem;
3210
3211 nsIDOMCSSStyleDeclaration_AddRef(nsstyle);
3212
3213 init_dispex(&style->dispex, (IUnknown*)&style->IHTMLStyle_iface, &HTMLStyle_dispex);
3214
3215 *ret = style;
3216 return S_OK;
3217}
#define E_OUTOFMEMORY
Definition: ddrawi.h:100
static const IHTMLStyleVtbl HTMLStyleVtbl
Definition: htmlstyle.c:2939
static dispex_static_data_t HTMLStyle_dispex
Definition: htmlstyle.c:3157
void HTMLStyle2_Init(HTMLStyle *) DECLSPEC_HIDDEN
Definition: htmlstyle2.c:620
void HTMLStyle3_Init(HTMLStyle *) DECLSPEC_HIDDEN
Definition: htmlstyle3.c:938
HRESULT init_dispex(jsdisp_t *dispex, script_ctx_t *ctx, const builtin_info_t *builtin_info, jsdisp_t *prototype)
Definition: dispex.c:919

Referenced by HTMLElement2_get_runtimeStyle(), and HTMLElement_get_style().

◆ set_elem_style()

HRESULT set_elem_style ( HTMLElement elem,
styleid_t  styleid,
const WCHAR val 
)

Definition at line 3233 of file htmlstyle.c.

3234{
3236 HRESULT hres;
3237
3239 if(FAILED(hres))
3240 return hres;
3241
3242 hres = set_nsstyle_attr(style, styleid, val, 0);
3243 nsIDOMCSSStyleDeclaration_Release(style);
3244 return hres;
3245}
GLuint GLfloat * val
Definition: glext.h:7180
HRESULT set_nsstyle_attr(nsIDOMCSSStyleDeclaration *nsstyle, styleid_t sid, const WCHAR *value, DWORD flags)
Definition: htmlstyle.c:382

Referenced by HTMLBodyElement_put_scroll().

◆ set_nsstyle_attr()

HRESULT set_nsstyle_attr ( nsIDOMCSSStyleDeclaration ,
styleid_t  ,
LPCWSTR  ,
DWORD   
)

◆ set_nsstyle_attr_var()

HRESULT set_nsstyle_attr_var ( nsIDOMCSSStyleDeclaration nsstyle,
styleid_t  sid,
VARIANT value,
DWORD  flags 
)

Definition at line 447 of file htmlstyle.c.

448{
449 const WCHAR *val;
450 WCHAR buf[14];
452
454 if(FAILED(hres))
455 return hres;
456
457 return set_nsstyle_attr(nsstyle, sid, val, flags);
458}
GLenum GLuint GLenum GLsizei const GLchar * buf
Definition: glext.h:7751
static HRESULT var_to_styleval(const VARIANT *v, WCHAR *buf, DWORD flags, const WCHAR **ret)
Definition: htmlstyle.c:411
__wchar_t WCHAR
Definition: xmlstorage.h:180

Referenced by HTMLStyle2_put_bottom(), HTMLStyle2_put_right(), HTMLStyle4_put_minHeight(), HTMLStyle5_put_maxHeight(), HTMLStyle5_put_maxWidth(), HTMLStyle5_put_minWidth(), HTMLStyle_put_backgroundColor(), HTMLStyle_put_borderBottomColor(), HTMLStyle_put_borderBottomWidth(), HTMLStyle_put_borderLeftColor(), HTMLStyle_put_borderLeftWidth(), HTMLStyle_put_borderRightColor(), HTMLStyle_put_borderRightWidth(), HTMLStyle_put_borderTopColor(), HTMLStyle_put_borderTopWidth(), HTMLStyle_put_color(), HTMLStyle_put_fontSize(), HTMLStyle_put_height(), HTMLStyle_put_left(), HTMLStyle_put_letterSpacing(), HTMLStyle_put_lineHeight(), HTMLStyle_put_marginBottom(), HTMLStyle_put_marginLeft(), HTMLStyle_put_marginRight(), HTMLStyle_put_marginTop(), HTMLStyle_put_paddingBottom(), HTMLStyle_put_paddingLeft(), HTMLStyle_put_paddingRight(), HTMLStyle_put_paddingTop(), HTMLStyle_put_textIndent(), HTMLStyle_put_top(), HTMLStyle_put_verticalAlign(), HTMLStyle_put_width(), HTMLStyle_put_wordSpacing(), and HTMLStyle_put_zIndex().