2 * Copyright 2006 Jacek Caban for CodeWeavers
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
28 #include "mshtml_private.h"
29 #include "htmlstyle.h"
31 #include "wine/debug.h"
32 #include "wine/unicode.h"
34 WINE_DEFAULT_DEBUG_CHANNEL(mshtml);
36 static const WCHAR attrBackground[] =
37 {'b','a','c','k','g','r','o','u','n','d',0};
38 static const WCHAR attrBackgroundColor[] =
39 {'b','a','c','k','g','r','o','u','n','d','-','c','o','l','o','r',0};
40 static const WCHAR attrBackgroundImage[] =
41 {'b','a','c','k','g','r','o','u','n','d','-','i','m','a','g','e',0};
42 static const WCHAR attrBorder[] =
43 {'b','o','r','d','e','r',0};
44 static const WCHAR attrBorderLeft[] =
45 {'b','o','r','d','e','r','-','l','e','f','t',0};
46 static const WCHAR attrColor[] =
47 {'c','o','l','o','r',0};
48 static const WCHAR attrCursor[] =
49 {'c','u','r','s','o','r',0};
50 static const WCHAR attrDisplay[] =
51 {'d','i','s','p','l','a','y',0};
52 static const WCHAR attrFontFamily[] =
53 {'f','o','n','t','-','f','a','m','i','l','y',0};
54 static const WCHAR attrFontSize[] =
55 {'f','o','n','t','-','s','i','z','e',0};
56 static const WCHAR attrFontStyle[] =
57 {'f','o','n','t','-','s','t','y','l','e',0};
58 static const WCHAR attrFontWeight[] =
59 {'f','o','n','t','-','w','e','i','g','h','t',0};
60 static const WCHAR attrHeight[] =
61 {'h','e','i','g','h','t',0};
62 static const WCHAR attrLeft[] =
64 static const WCHAR attrMargin[] =
65 {'m','a','r','g','i','n',0};
66 static const WCHAR attrMarginLeft[] =
67 {'m','a','r','g','i','n','-','l','e','f','t',0};
68 static const WCHAR attrMarginRight[] =
69 {'m','a','r','g','i','n','-','r','i','g','h','t',0};
70 static const WCHAR attrPaddingLeft[] =
71 {'p','a','d','d','i','n','g','-','l','e','f','t',0};
72 static const WCHAR attrPosition[] =
73 {'p','o','s','i','t','i','o','n',0};
74 static const WCHAR attrTextDecoration[] =
75 {'t','e','x','t','-','d','e','c','o','r','a','t','i','o','n',0};
76 static const WCHAR attrTop[] =
78 static const WCHAR attrVerticalAlign[] =
79 {'v','e','r','t','i','c','a','l','-','a','l','i','g','n',0};
80 static const WCHAR attrVisibility[] =
81 {'v','i','s','i','b','i','l','i','t','y',0};
82 static const WCHAR attrWidth[] =
83 {'w','i','d','t','h',0};
85 static const LPCWSTR style_strings[] = {
112 static const WCHAR valLineThrough[] =
113 {'l','i','n','e','-','t','h','r','o','u','g','h',0};
114 static const WCHAR valUnderline[] =
115 {'u','n','d','e','r','l','i','n','e',0};
117 static const WCHAR px_formatW[] = {'%','d','p','x',0};
118 static const WCHAR emptyW[] = {0};
120 static LPWSTR fix_px_value(LPCWSTR val)
125 while(*ptr && isspaceW(*ptr))
130 while(*ptr && isdigitW(*ptr))
133 if(!*ptr || isspaceW(*ptr)) {
135 int len = strlenW(val)+1;
137 ret = heap_alloc((len+2)*sizeof(WCHAR));
138 memcpy(ret, val, (ptr-val)*sizeof(WCHAR));
144 TRACE("fixed %s -> %s\n", debugstr_w(val), debugstr_w(ret));
149 while(*ptr && !isspaceW(*ptr))
156 static LPWSTR fix_url_value(LPCWSTR val)
160 static const WCHAR urlW[] = {'u','r','l','('};
162 if(strncmpW(val, urlW, sizeof(urlW)/sizeof(WCHAR)) || !strchrW(val, '\\'))
165 ret = heap_strdupW(val);
167 for(ptr = ret; *ptr; ptr++) {
175 #define ATTR_FIX_PX 1
176 #define ATTR_FIX_URL 2
178 HRESULT set_nsstyle_attr(nsIDOMCSSStyleDeclaration *nsstyle, styleid_t sid, LPCWSTR value, DWORD flags)
180 nsAString str_name, str_value, str_empty;
184 static const PRUnichar wszEmpty[] = {0};
186 if(flags & ATTR_FIX_PX)
187 val = fix_px_value(value);
188 if(flags & ATTR_FIX_URL)
189 val = fix_url_value(value);
191 nsAString_Init(&str_name, style_strings[sid]);
192 nsAString_Init(&str_value, val ? val : value);
193 nsAString_Init(&str_empty, wszEmpty);
196 nsres = nsIDOMCSSStyleDeclaration_SetProperty(nsstyle, &str_name, &str_value, &str_empty);
198 ERR("SetProperty failed: %08x\n", nsres);
200 nsAString_Finish(&str_name);
201 nsAString_Finish(&str_value);
202 nsAString_Finish(&str_empty);
207 static inline HRESULT set_style_attr(HTMLStyle *This, styleid_t sid, LPCWSTR value, DWORD flags)
209 return set_nsstyle_attr(This->nsstyle, sid, value, flags);
212 static HRESULT get_nsstyle_attr_nsval(nsIDOMCSSStyleDeclaration *nsstyle, styleid_t sid, nsAString *value)
217 nsAString_Init(&str_name, style_strings[sid]);
219 nsres = nsIDOMCSSStyleDeclaration_GetPropertyValue(nsstyle, &str_name, value);
220 if(NS_FAILED(nsres)) {
221 ERR("SetProperty failed: %08x\n", nsres);
225 nsAString_Finish(&str_name);
230 HRESULT get_nsstyle_attr(nsIDOMCSSStyleDeclaration *nsstyle, styleid_t sid, BSTR *p)
233 const PRUnichar *value;
235 nsAString_Init(&str_value, NULL);
237 get_nsstyle_attr_nsval(nsstyle, sid, &str_value);
239 nsAString_GetData(&str_value, &value);
240 *p = *value ? SysAllocString(value) : NULL;
242 nsAString_Finish(&str_value);
244 TRACE("%s -> %s\n", debugstr_w(style_strings[sid]), debugstr_w(*p));
248 static inline HRESULT get_style_attr(HTMLStyle *This, styleid_t sid, BSTR *p)
250 return get_nsstyle_attr(This->nsstyle, sid, p);
253 static HRESULT check_style_attr_value(HTMLStyle *This, styleid_t sid, LPCWSTR exval, VARIANT_BOOL *p)
256 const PRUnichar *value;
258 nsAString_Init(&str_value, NULL);
260 get_nsstyle_attr_nsval(This->nsstyle, sid, &str_value);
262 nsAString_GetData(&str_value, &value);
263 *p = strcmpW(value, exval) ? VARIANT_FALSE : VARIANT_TRUE;
264 nsAString_Finish(&str_value);
266 TRACE("%s -> %x\n", debugstr_w(style_strings[sid]), *p);
270 #define HTMLSTYLE_THIS(iface) DEFINE_THIS(HTMLStyle, HTMLStyle, iface)
272 static HRESULT WINAPI HTMLStyle_QueryInterface(IHTMLStyle *iface, REFIID riid, void **ppv)
274 HTMLStyle *This = HTMLSTYLE_THIS(iface);
278 if(IsEqualGUID(&IID_IUnknown, riid)) {
279 TRACE("(%p)->(IID_IUnknown %p)\n", This, ppv);
280 *ppv = HTMLSTYLE(This);
281 }else if(IsEqualGUID(&IID_IHTMLStyle, riid)) {
282 TRACE("(%p)->(IID_IHTMLStyle %p)\n", This, ppv);
283 *ppv = HTMLSTYLE(This);
284 }else if(IsEqualGUID(&IID_IHTMLStyle2, riid)) {
285 TRACE("(%p)->(IID_IHTMLStyle2 %p)\n", This, ppv);
286 *ppv = HTMLSTYLE2(This);
287 }else if(dispex_query_interface(&This->dispex, riid, ppv)) {
288 return *ppv ? S_OK : E_NOINTERFACE;
292 IUnknown_AddRef((IUnknown*)*ppv);
296 WARN("unsupported %s\n", debugstr_guid(riid));
297 return E_NOINTERFACE;
300 static ULONG WINAPI HTMLStyle_AddRef(IHTMLStyle *iface)
302 HTMLStyle *This = HTMLSTYLE_THIS(iface);
303 LONG ref = InterlockedIncrement(&This->ref);
305 TRACE("(%p) ref=%d\n", This, ref);
310 static ULONG WINAPI HTMLStyle_Release(IHTMLStyle *iface)
312 HTMLStyle *This = HTMLSTYLE_THIS(iface);
313 LONG ref = InterlockedDecrement(&This->ref);
315 TRACE("(%p) ref=%d\n", This, ref);
319 nsIDOMCSSStyleDeclaration_Release(This->nsstyle);
326 static HRESULT WINAPI HTMLStyle_GetTypeInfoCount(IHTMLStyle *iface, UINT *pctinfo)
328 HTMLStyle *This = HTMLSTYLE_THIS(iface);
329 return IDispatchEx_GetTypeInfoCount(DISPATCHEX(&This->dispex), pctinfo);
332 static HRESULT WINAPI HTMLStyle_GetTypeInfo(IHTMLStyle *iface, UINT iTInfo,
333 LCID lcid, ITypeInfo **ppTInfo)
335 HTMLStyle *This = HTMLSTYLE_THIS(iface);
336 return IDispatchEx_GetTypeInfo(DISPATCHEX(&This->dispex), iTInfo, lcid, ppTInfo);
339 static HRESULT WINAPI HTMLStyle_GetIDsOfNames(IHTMLStyle *iface, REFIID riid,
340 LPOLESTR *rgszNames, UINT cNames,
341 LCID lcid, DISPID *rgDispId)
343 HTMLStyle *This = HTMLSTYLE_THIS(iface);
344 return IDispatchEx_GetIDsOfNames(DISPATCHEX(&This->dispex), riid, rgszNames, cNames, lcid, rgDispId);
347 static HRESULT WINAPI HTMLStyle_Invoke(IHTMLStyle *iface, DISPID dispIdMember,
348 REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams,
349 VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
351 HTMLStyle *This = HTMLSTYLE_THIS(iface);
352 return IDispatchEx_Invoke(DISPATCHEX(&This->dispex), dispIdMember, riid, lcid,
353 wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
356 static HRESULT WINAPI HTMLStyle_put_fontFamily(IHTMLStyle *iface, BSTR v)
358 HTMLStyle *This = HTMLSTYLE_THIS(iface);
360 TRACE("(%p)->(%s)\n", This, debugstr_w(v));
362 return set_style_attr(This, STYLEID_FONT_FAMILY, v, 0);
365 static HRESULT WINAPI HTMLStyle_get_fontFamily(IHTMLStyle *iface, BSTR *p)
367 HTMLStyle *This = HTMLSTYLE_THIS(iface);
369 TRACE("(%p)->(%p)\n", This, p);
371 return get_style_attr(This, STYLEID_FONT_FAMILY, p);
374 static HRESULT WINAPI HTMLStyle_put_fontStyle(IHTMLStyle *iface, BSTR v)
376 HTMLStyle *This = HTMLSTYLE_THIS(iface);
377 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
381 static HRESULT WINAPI HTMLStyle_get_fontStyle(IHTMLStyle *iface, BSTR *p)
383 HTMLStyle *This = HTMLSTYLE_THIS(iface);
385 TRACE("(%p)->(%p)\n", This, p);
387 return get_style_attr(This, STYLEID_FONT_STYLE, p);
390 static HRESULT WINAPI HTMLStyle_put_fontVariant(IHTMLStyle *iface, BSTR v)
392 HTMLStyle *This = HTMLSTYLE_THIS(iface);
393 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
397 static HRESULT WINAPI HTMLStyle_get_fontVariant(IHTMLStyle *iface, BSTR *p)
399 HTMLStyle *This = HTMLSTYLE_THIS(iface);
400 FIXME("(%p)->(%p)\n", This, p);
404 static HRESULT WINAPI HTMLStyle_put_fontWeight(IHTMLStyle *iface, BSTR v)
406 HTMLStyle *This = HTMLSTYLE_THIS(iface);
407 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
411 static HRESULT WINAPI HTMLStyle_get_fontWeight(IHTMLStyle *iface, BSTR *p)
413 HTMLStyle *This = HTMLSTYLE_THIS(iface);
415 TRACE("(%p)->(%p)\n", This, p);
417 return get_style_attr(This, STYLEID_FONT_WEIGHT, p);
420 static HRESULT WINAPI HTMLStyle_put_fontSize(IHTMLStyle *iface, VARIANT v)
422 HTMLStyle *This = HTMLSTYLE_THIS(iface);
424 TRACE("(%p)->(v%d)\n", This, V_VT(&v));
428 return set_style_attr(This, STYLEID_FONT_SIZE, V_BSTR(&v), 0);
430 FIXME("not supported vt %d\n", V_VT(&v));
436 static HRESULT WINAPI HTMLStyle_get_fontSize(IHTMLStyle *iface, VARIANT *p)
438 HTMLStyle *This = HTMLSTYLE_THIS(iface);
440 TRACE("(%p)->(%p)\n", This, p);
443 return get_style_attr(This, STYLEID_FONT_SIZE, &V_BSTR(p));
446 static HRESULT WINAPI HTMLStyle_put_font(IHTMLStyle *iface, BSTR v)
448 HTMLStyle *This = HTMLSTYLE_THIS(iface);
449 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
453 static HRESULT WINAPI HTMLStyle_get_font(IHTMLStyle *iface, BSTR *p)
455 HTMLStyle *This = HTMLSTYLE_THIS(iface);
456 FIXME("(%p)->(%p)\n", This, p);
460 static HRESULT WINAPI HTMLStyle_put_color(IHTMLStyle *iface, VARIANT v)
462 HTMLStyle *This = HTMLSTYLE_THIS(iface);
464 TRACE("(%p)->(v%d)\n", This, V_VT(&v));
468 TRACE("%s\n", debugstr_w(V_BSTR(&v)));
469 return set_style_attr(This, STYLEID_COLOR, V_BSTR(&v), 0);
472 FIXME("unsupported vt=%d\n", V_VT(&v));
478 static HRESULT WINAPI HTMLStyle_get_color(IHTMLStyle *iface, VARIANT *p)
480 HTMLStyle *This = HTMLSTYLE_THIS(iface);
482 TRACE("(%p)->(%p)\n", This, p);
485 return get_style_attr(This, STYLEID_COLOR, &V_BSTR(p));
488 static HRESULT WINAPI HTMLStyle_put_background(IHTMLStyle *iface, BSTR v)
490 HTMLStyle *This = HTMLSTYLE_THIS(iface);
492 TRACE("(%p)->(%s)\n", This, debugstr_w(v));
494 return set_style_attr(This, STYLEID_BACKGROUND, v, 0);
497 static HRESULT WINAPI HTMLStyle_get_background(IHTMLStyle *iface, BSTR *p)
499 HTMLStyle *This = HTMLSTYLE_THIS(iface);
501 TRACE("(%p)->(%p)\n", This, p);
503 return get_style_attr(This, STYLEID_BACKGROUND, p);
506 static HRESULT WINAPI HTMLStyle_put_backgroundColor(IHTMLStyle *iface, VARIANT v)
508 HTMLStyle *This = HTMLSTYLE_THIS(iface);
510 TRACE("(%p)->(v%d)\n", This, V_VT(&v));
514 return set_style_attr(This, STYLEID_BACKGROUND_COLOR, V_BSTR(&v), 0);
517 static const WCHAR format[] = {'#','%','0','6','x',0};
519 wsprintfW(value, format, V_I4(&v));
520 return set_style_attr(This, STYLEID_BACKGROUND_COLOR, value, 0);
523 FIXME("unsupported vt %d\n", V_VT(&v));
529 static HRESULT WINAPI HTMLStyle_get_backgroundColor(IHTMLStyle *iface, VARIANT *p)
531 HTMLStyle *This = HTMLSTYLE_THIS(iface);
532 FIXME("(%p)->(%p)\n", This, p);
536 static HRESULT WINAPI HTMLStyle_put_backgroundImage(IHTMLStyle *iface, BSTR v)
538 HTMLStyle *This = HTMLSTYLE_THIS(iface);
540 TRACE("(%p)->(%s)\n", This, debugstr_w(v));
542 return set_style_attr(This, STYLEID_BACKGROUND_IMAGE, v, ATTR_FIX_URL);
545 static HRESULT WINAPI HTMLStyle_get_backgroundImage(IHTMLStyle *iface, BSTR *p)
547 HTMLStyle *This = HTMLSTYLE_THIS(iface);
548 FIXME("(%p)->(%p)\n", This, p);
552 static HRESULT WINAPI HTMLStyle_put_backgroundRepeat(IHTMLStyle *iface, BSTR v)
554 HTMLStyle *This = HTMLSTYLE_THIS(iface);
555 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
559 static HRESULT WINAPI HTMLStyle_get_backgroundRepeat(IHTMLStyle *iface, BSTR *p)
561 HTMLStyle *This = HTMLSTYLE_THIS(iface);
562 FIXME("(%p)->(%p)\n", This, p);
566 static HRESULT WINAPI HTMLStyle_put_backgroundAttachment(IHTMLStyle *iface, BSTR v)
568 HTMLStyle *This = HTMLSTYLE_THIS(iface);
569 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
573 static HRESULT WINAPI HTMLStyle_get_backgroundAttachment(IHTMLStyle *iface, BSTR *p)
575 HTMLStyle *This = HTMLSTYLE_THIS(iface);
576 FIXME("(%p)->(%p)\n", This, p);
580 static HRESULT WINAPI HTMLStyle_put_backgroundPosition(IHTMLStyle *iface, BSTR v)
582 HTMLStyle *This = HTMLSTYLE_THIS(iface);
583 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
587 static HRESULT WINAPI HTMLStyle_get_backgroundPosition(IHTMLStyle *iface, BSTR *p)
589 HTMLStyle *This = HTMLSTYLE_THIS(iface);
590 FIXME("(%p)->(%p)\n", This, p);
594 static HRESULT WINAPI HTMLStyle_put_backgroundPositionX(IHTMLStyle *iface, VARIANT v)
596 HTMLStyle *This = HTMLSTYLE_THIS(iface);
597 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
601 static HRESULT WINAPI HTMLStyle_get_backgroundPositionX(IHTMLStyle *iface, VARIANT *p)
603 HTMLStyle *This = HTMLSTYLE_THIS(iface);
604 FIXME("(%p)->(%p)\n", This, p);
608 static HRESULT WINAPI HTMLStyle_put_backgroundPositionY(IHTMLStyle *iface, VARIANT v)
610 HTMLStyle *This = HTMLSTYLE_THIS(iface);
611 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
615 static HRESULT WINAPI HTMLStyle_get_backgroundPositionY(IHTMLStyle *iface, VARIANT *p)
617 HTMLStyle *This = HTMLSTYLE_THIS(iface);
618 FIXME("(%p)->(%p)\n", This, p);
622 static HRESULT WINAPI HTMLStyle_put_wordSpacing(IHTMLStyle *iface, VARIANT v)
624 HTMLStyle *This = HTMLSTYLE_THIS(iface);
625 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
629 static HRESULT WINAPI HTMLStyle_get_wordSpacing(IHTMLStyle *iface, VARIANT *p)
631 HTMLStyle *This = HTMLSTYLE_THIS(iface);
632 FIXME("(%p)->(%p)\n", This, p);
636 static HRESULT WINAPI HTMLStyle_put_letterSpacing(IHTMLStyle *iface, VARIANT v)
638 HTMLStyle *This = HTMLSTYLE_THIS(iface);
639 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
643 static HRESULT WINAPI HTMLStyle_get_letterSpacing(IHTMLStyle *iface, VARIANT *p)
645 HTMLStyle *This = HTMLSTYLE_THIS(iface);
646 FIXME("(%p)->(%p)\n", This, p);
650 static HRESULT WINAPI HTMLStyle_put_textDecoration(IHTMLStyle *iface, BSTR v)
652 HTMLStyle *This = HTMLSTYLE_THIS(iface);
653 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
657 static HRESULT WINAPI HTMLStyle_get_textDecoration(IHTMLStyle *iface, BSTR *p)
659 HTMLStyle *This = HTMLSTYLE_THIS(iface);
661 TRACE("(%p)->(%p)\n", This, p);
663 return get_style_attr(This, STYLEID_TEXT_DECORATION, p);
666 static HRESULT WINAPI HTMLStyle_put_textDecorationNone(IHTMLStyle *iface, VARIANT_BOOL v)
668 HTMLStyle *This = HTMLSTYLE_THIS(iface);
669 FIXME("(%p)->(%x)\n", This, v);
673 static HRESULT WINAPI HTMLStyle_get_textDecorationNone(IHTMLStyle *iface, VARIANT_BOOL *p)
675 HTMLStyle *This = HTMLSTYLE_THIS(iface);
676 FIXME("(%p)->(%p)\n", This, p);
680 static HRESULT WINAPI HTMLStyle_put_textDecorationUnderline(IHTMLStyle *iface, VARIANT_BOOL v)
682 HTMLStyle *This = HTMLSTYLE_THIS(iface);
683 FIXME("(%p)->(%x)\n", This, v);
687 static HRESULT WINAPI HTMLStyle_get_textDecorationUnderline(IHTMLStyle *iface, VARIANT_BOOL *p)
689 HTMLStyle *This = HTMLSTYLE_THIS(iface);
691 TRACE("(%p)->(%p)\n", This, p);
693 return check_style_attr_value(This, STYLEID_TEXT_DECORATION, valUnderline, p);
696 static HRESULT WINAPI HTMLStyle_put_textDecorationOverline(IHTMLStyle *iface, VARIANT_BOOL v)
698 HTMLStyle *This = HTMLSTYLE_THIS(iface);
699 FIXME("(%p)->(%x)\n", This, v);
703 static HRESULT WINAPI HTMLStyle_get_textDecorationOverline(IHTMLStyle *iface, VARIANT_BOOL *p)
705 HTMLStyle *This = HTMLSTYLE_THIS(iface);
706 FIXME("(%p)->(%p)\n", This, p);
710 static HRESULT WINAPI HTMLStyle_put_textDecorationLineThrough(IHTMLStyle *iface, VARIANT_BOOL v)
712 HTMLStyle *This = HTMLSTYLE_THIS(iface);
713 FIXME("(%p)->(%x)\n", This, v);
717 static HRESULT WINAPI HTMLStyle_get_textDecorationLineThrough(IHTMLStyle *iface, VARIANT_BOOL *p)
719 HTMLStyle *This = HTMLSTYLE_THIS(iface);
721 TRACE("(%p)->(%p)\n", This, p);
723 return check_style_attr_value(This, STYLEID_TEXT_DECORATION, valLineThrough, p);
726 static HRESULT WINAPI HTMLStyle_put_textDecorationBlink(IHTMLStyle *iface, VARIANT_BOOL v)
728 HTMLStyle *This = HTMLSTYLE_THIS(iface);
729 FIXME("(%p)->(%x)\n", This, v);
733 static HRESULT WINAPI HTMLStyle_get_textDecorationBlink(IHTMLStyle *iface, VARIANT_BOOL *p)
735 HTMLStyle *This = HTMLSTYLE_THIS(iface);
736 FIXME("(%p)->(%p)\n", This, p);
740 static HRESULT WINAPI HTMLStyle_put_verticalAlign(IHTMLStyle *iface, VARIANT v)
742 HTMLStyle *This = HTMLSTYLE_THIS(iface);
744 TRACE("(%p)->(%s)\n", This, debugstr_variant(&v));
748 return set_style_attr(This, STYLEID_VERTICAL_ALIGN, V_BSTR(&v), 0);
750 FIXME("not implemented vt %d\n", V_VT(&v));
757 static HRESULT WINAPI HTMLStyle_get_verticalAlign(IHTMLStyle *iface, VARIANT *p)
759 HTMLStyle *This = HTMLSTYLE_THIS(iface);
763 TRACE("(%p)->(%p)\n", This, p);
765 hres = get_style_attr(This, STYLEID_VERTICAL_ALIGN, &ret);
774 static HRESULT WINAPI HTMLStyle_put_textTransform(IHTMLStyle *iface, BSTR v)
776 HTMLStyle *This = HTMLSTYLE_THIS(iface);
777 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
781 static HRESULT WINAPI HTMLStyle_get_textTransform(IHTMLStyle *iface, BSTR *p)
783 HTMLStyle *This = HTMLSTYLE_THIS(iface);
784 FIXME("(%p)->(%p)\n", This, p);
788 static HRESULT WINAPI HTMLStyle_put_textAlign(IHTMLStyle *iface, BSTR v)
790 HTMLStyle *This = HTMLSTYLE_THIS(iface);
791 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
795 static HRESULT WINAPI HTMLStyle_get_textAlign(IHTMLStyle *iface, BSTR *p)
797 HTMLStyle *This = HTMLSTYLE_THIS(iface);
798 FIXME("(%p)->(%p)\n", This, p);
802 static HRESULT WINAPI HTMLStyle_put_textIndent(IHTMLStyle *iface, VARIANT v)
804 HTMLStyle *This = HTMLSTYLE_THIS(iface);
805 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
809 static HRESULT WINAPI HTMLStyle_get_textIndent(IHTMLStyle *iface, VARIANT *p)
811 HTMLStyle *This = HTMLSTYLE_THIS(iface);
812 FIXME("(%p)->(%p)\n", This, p);
816 static HRESULT WINAPI HTMLStyle_put_lineHeight(IHTMLStyle *iface, VARIANT v)
818 HTMLStyle *This = HTMLSTYLE_THIS(iface);
819 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
823 static HRESULT WINAPI HTMLStyle_get_lineHeight(IHTMLStyle *iface, VARIANT *p)
825 HTMLStyle *This = HTMLSTYLE_THIS(iface);
826 FIXME("(%p)->(%p)\n", This, p);
830 static HRESULT WINAPI HTMLStyle_put_marginTop(IHTMLStyle *iface, VARIANT v)
832 HTMLStyle *This = HTMLSTYLE_THIS(iface);
833 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
837 static HRESULT WINAPI HTMLStyle_get_marginTop(IHTMLStyle *iface, VARIANT *p)
839 HTMLStyle *This = HTMLSTYLE_THIS(iface);
840 FIXME("(%p)->(%p)\n", This, p);
844 static HRESULT WINAPI HTMLStyle_put_marginRight(IHTMLStyle *iface, VARIANT v)
846 HTMLStyle *This = HTMLSTYLE_THIS(iface);
848 TRACE("(%p)->(v(%d))\n", This, V_VT(&v));
852 return set_style_attr(This, STYLEID_MARGIN_RIGHT, emptyW, 0);
856 wsprintfW(buf, px_formatW, V_I4(&v));
857 return set_style_attr(This, STYLEID_MARGIN_RIGHT, buf, 0);
860 return set_style_attr(This, STYLEID_MARGIN_RIGHT, V_BSTR(&v), 0);
862 FIXME("Unsupported vt=%d\n", V_VT(&v));
868 static HRESULT WINAPI HTMLStyle_get_marginRight(IHTMLStyle *iface, VARIANT *p)
870 HTMLStyle *This = HTMLSTYLE_THIS(iface);
871 FIXME("(%p)->(%p)\n", This, p);
875 static HRESULT WINAPI HTMLStyle_put_marginBottom(IHTMLStyle *iface, VARIANT v)
877 HTMLStyle *This = HTMLSTYLE_THIS(iface);
878 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
882 static HRESULT WINAPI HTMLStyle_get_marginBottom(IHTMLStyle *iface, VARIANT *p)
884 HTMLStyle *This = HTMLSTYLE_THIS(iface);
885 FIXME("(%p)->(%p)\n", This, p);
889 static HRESULT WINAPI HTMLStyle_put_marginLeft(IHTMLStyle *iface, VARIANT v)
891 HTMLStyle *This = HTMLSTYLE_THIS(iface);
895 TRACE("(%p)->(NULL)\n", This);
896 return set_style_attr(This, STYLEID_MARGIN_LEFT, emptyW, 0);
900 TRACE("(%p)->(%d)\n", This, V_I4(&v));
902 wsprintfW(buf, px_formatW, V_I4(&v));
903 return set_style_attr(This, STYLEID_MARGIN_LEFT, buf, 0);
906 TRACE("(%p)->(%s)\n", This, debugstr_w(V_BSTR(&v)));
907 return set_style_attr(This, STYLEID_MARGIN_LEFT, V_BSTR(&v), 0);
909 FIXME("Unsupported vt=%d\n", V_VT(&v));
915 static HRESULT WINAPI HTMLStyle_put_margin(IHTMLStyle *iface, BSTR v)
917 HTMLStyle *This = HTMLSTYLE_THIS(iface);
919 TRACE("(%p)->(%s)\n", This, debugstr_w(v));
921 return set_style_attr(This, STYLEID_MARGIN, v, 0);
924 static HRESULT WINAPI HTMLStyle_get_margin(IHTMLStyle *iface, BSTR *p)
926 HTMLStyle *This = HTMLSTYLE_THIS(iface);
928 TRACE("(%p)->(%p)\n", This, p);
930 return get_style_attr(This, STYLEID_MARGIN, p);
933 static HRESULT WINAPI HTMLStyle_get_marginLeft(IHTMLStyle *iface, VARIANT *p)
935 HTMLStyle *This = HTMLSTYLE_THIS(iface);
936 FIXME("(%p)->(%p)\n", This, p);
940 static HRESULT WINAPI HTMLStyle_put_paddingTop(IHTMLStyle *iface, VARIANT v)
942 HTMLStyle *This = HTMLSTYLE_THIS(iface);
943 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
947 static HRESULT WINAPI HTMLStyle_get_paddingTop(IHTMLStyle *iface, VARIANT *p)
949 HTMLStyle *This = HTMLSTYLE_THIS(iface);
950 FIXME("(%p)->(%p)\n", This, p);
954 static HRESULT WINAPI HTMLStyle_put_paddingRight(IHTMLStyle *iface, VARIANT v)
956 HTMLStyle *This = HTMLSTYLE_THIS(iface);
957 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
961 static HRESULT WINAPI HTMLStyle_get_paddingRight(IHTMLStyle *iface, VARIANT *p)
963 HTMLStyle *This = HTMLSTYLE_THIS(iface);
964 FIXME("(%p)->(%p)\n", This, p);
968 static HRESULT WINAPI HTMLStyle_put_paddingBottom(IHTMLStyle *iface, VARIANT v)
970 HTMLStyle *This = HTMLSTYLE_THIS(iface);
971 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
975 static HRESULT WINAPI HTMLStyle_get_paddingBottom(IHTMLStyle *iface, VARIANT *p)
977 HTMLStyle *This = HTMLSTYLE_THIS(iface);
978 FIXME("(%p)->(%p)\n", This, p);
982 static HRESULT WINAPI HTMLStyle_put_paddingLeft(IHTMLStyle *iface, VARIANT v)
984 HTMLStyle *This = HTMLSTYLE_THIS(iface);
986 TRACE("(%p)->(vt=%d)\n", This, V_VT(&v));
992 wsprintfW(buf, px_formatW, V_I4(&v));
993 return set_style_attr(This, STYLEID_PADDING_LEFT, buf, 0);
996 return set_style_attr(This, STYLEID_PADDING_LEFT, V_BSTR(&v), 0);
998 FIXME("unsupported vt=%d\n", V_VT(&v));
1004 static HRESULT WINAPI HTMLStyle_get_paddingLeft(IHTMLStyle *iface, VARIANT *p)
1006 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1007 FIXME("(%p)->(%p)\n", This, p);
1011 static HRESULT WINAPI HTMLStyle_put_padding(IHTMLStyle *iface, BSTR v)
1013 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1014 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1018 static HRESULT WINAPI HTMLStyle_get_padding(IHTMLStyle *iface, BSTR *p)
1020 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1021 FIXME("(%p)->(%p)\n", This, p);
1025 static HRESULT WINAPI HTMLStyle_put_border(IHTMLStyle *iface, BSTR v)
1027 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1029 TRACE("(%p)->(%s)\n", This, debugstr_w(v));
1031 return set_style_attr(This, STYLEID_BORDER, v, 0);
1034 static HRESULT WINAPI HTMLStyle_get_border(IHTMLStyle *iface, BSTR *p)
1036 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1038 TRACE("(%p)->(%p)\n", This, p);
1040 return get_style_attr(This, STYLEID_BORDER, p);
1043 static HRESULT WINAPI HTMLStyle_put_borderTop(IHTMLStyle *iface, BSTR v)
1045 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1046 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1050 static HRESULT WINAPI HTMLStyle_get_borderTop(IHTMLStyle *iface, BSTR *p)
1052 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1053 FIXME("(%p)->(%p)\n", This, p);
1057 static HRESULT WINAPI HTMLStyle_put_borderRight(IHTMLStyle *iface, BSTR v)
1059 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1060 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1064 static HRESULT WINAPI HTMLStyle_get_borderRight(IHTMLStyle *iface, BSTR *p)
1066 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1067 FIXME("(%p)->(%p)\n", This, p);
1071 static HRESULT WINAPI HTMLStyle_put_borderBottom(IHTMLStyle *iface, BSTR v)
1073 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1074 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1078 static HRESULT WINAPI HTMLStyle_get_borderBottom(IHTMLStyle *iface, BSTR *p)
1080 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1081 FIXME("(%p)->(%p)\n", This, p);
1085 static HRESULT WINAPI HTMLStyle_put_borderLeft(IHTMLStyle *iface, BSTR v)
1087 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1089 TRACE("(%p)->(%s)\n", This, debugstr_w(v));
1091 return set_style_attr(This, STYLEID_BORDER_LEFT, v, ATTR_FIX_PX);
1094 static HRESULT WINAPI HTMLStyle_get_borderLeft(IHTMLStyle *iface, BSTR *p)
1096 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1097 FIXME("(%p)->(%p)\n", This, p);
1101 static HRESULT WINAPI HTMLStyle_put_borderColor(IHTMLStyle *iface, BSTR v)
1103 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1104 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1108 static HRESULT WINAPI HTMLStyle_get_borderColor(IHTMLStyle *iface, BSTR *p)
1110 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1111 FIXME("(%p)->(%p)\n", This, p);
1115 static HRESULT WINAPI HTMLStyle_put_borderTopColor(IHTMLStyle *iface, VARIANT v)
1117 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1118 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
1122 static HRESULT WINAPI HTMLStyle_get_borderTopColor(IHTMLStyle *iface, VARIANT *p)
1124 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1125 FIXME("(%p)->(%p)\n", This, p);
1129 static HRESULT WINAPI HTMLStyle_put_borderRightColor(IHTMLStyle *iface, VARIANT v)
1131 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1132 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
1136 static HRESULT WINAPI HTMLStyle_get_borderRightColor(IHTMLStyle *iface, VARIANT *p)
1138 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1139 FIXME("(%p)->(%p)\n", This, p);
1143 static HRESULT WINAPI HTMLStyle_put_borderBottomColor(IHTMLStyle *iface, VARIANT v)
1145 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1146 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
1150 static HRESULT WINAPI HTMLStyle_get_borderBottomColor(IHTMLStyle *iface, VARIANT *p)
1152 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1153 FIXME("(%p)->(%p)\n", This, p);
1157 static HRESULT WINAPI HTMLStyle_put_borderLeftColor(IHTMLStyle *iface, VARIANT v)
1159 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1160 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
1164 static HRESULT WINAPI HTMLStyle_get_borderLeftColor(IHTMLStyle *iface, VARIANT *p)
1166 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1167 FIXME("(%p)->(%p)\n", This, p);
1171 static HRESULT WINAPI HTMLStyle_put_borderWidth(IHTMLStyle *iface, BSTR v)
1173 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1174 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1178 static HRESULT WINAPI HTMLStyle_get_borderWidth(IHTMLStyle *iface, BSTR *p)
1180 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1181 FIXME("(%p)->(%p)\n", This, p);
1185 static HRESULT WINAPI HTMLStyle_put_borderTopWidth(IHTMLStyle *iface, VARIANT v)
1187 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1188 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
1192 static HRESULT WINAPI HTMLStyle_get_borderTopWidth(IHTMLStyle *iface, VARIANT *p)
1194 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1195 FIXME("(%p)->(%p)\n", This, p);
1199 static HRESULT WINAPI HTMLStyle_put_borderRightWidth(IHTMLStyle *iface, VARIANT v)
1201 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1202 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
1206 static HRESULT WINAPI HTMLStyle_get_borderRightWidth(IHTMLStyle *iface, VARIANT *p)
1208 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1209 FIXME("(%p)->(%p)\n", This, p);
1213 static HRESULT WINAPI HTMLStyle_put_borderBottomWidth(IHTMLStyle *iface, VARIANT v)
1215 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1216 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
1220 static HRESULT WINAPI HTMLStyle_get_borderBottomWidth(IHTMLStyle *iface, VARIANT *p)
1222 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1223 FIXME("(%p)->(%p)\n", This, p);
1227 static HRESULT WINAPI HTMLStyle_put_borderLeftWidth(IHTMLStyle *iface, VARIANT v)
1229 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1230 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
1234 static HRESULT WINAPI HTMLStyle_get_borderLeftWidth(IHTMLStyle *iface, VARIANT *p)
1236 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1237 FIXME("(%p)->(%p)\n", This, p);
1241 static HRESULT WINAPI HTMLStyle_put_borderStyle(IHTMLStyle *iface, BSTR v)
1243 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1244 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1248 static HRESULT WINAPI HTMLStyle_get_borderStyle(IHTMLStyle *iface, BSTR *p)
1250 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1251 FIXME("(%p)->(%p)\n", This, p);
1255 static HRESULT WINAPI HTMLStyle_put_borderTopStyle(IHTMLStyle *iface, BSTR v)
1257 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1258 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1262 static HRESULT WINAPI HTMLStyle_get_borderTopStyle(IHTMLStyle *iface, BSTR *p)
1264 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1265 FIXME("(%p)->(%p)\n", This, p);
1269 static HRESULT WINAPI HTMLStyle_put_borderRightStyle(IHTMLStyle *iface, BSTR v)
1271 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1272 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1276 static HRESULT WINAPI HTMLStyle_get_borderRightStyle(IHTMLStyle *iface, BSTR *p)
1278 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1279 FIXME("(%p)->(%p)\n", This, p);
1283 static HRESULT WINAPI HTMLStyle_put_borderBottomStyle(IHTMLStyle *iface, BSTR v)
1285 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1286 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1290 static HRESULT WINAPI HTMLStyle_get_borderBottomStyle(IHTMLStyle *iface, BSTR *p)
1292 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1293 FIXME("(%p)->(%p)\n", This, p);
1297 static HRESULT WINAPI HTMLStyle_put_borderLeftStyle(IHTMLStyle *iface, BSTR v)
1299 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1300 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1304 static HRESULT WINAPI HTMLStyle_get_borderLeftStyle(IHTMLStyle *iface, BSTR *p)
1306 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1307 FIXME("(%p)->(%p)\n", This, p);
1311 static HRESULT WINAPI HTMLStyle_put_width(IHTMLStyle *iface, VARIANT v)
1313 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1315 TRACE("(%p)->(v%d)\n", This, V_VT(&v));
1319 TRACE("%s\n", debugstr_w(V_BSTR(&v)));
1320 return set_style_attr(This, STYLEID_WIDTH, V_BSTR(&v), 0);
1322 FIXME("unsupported vt %d\n", V_VT(&v));
1328 static HRESULT WINAPI HTMLStyle_get_width(IHTMLStyle *iface, VARIANT *p)
1330 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1332 TRACE("(%p)->(%p)\n", This, p);
1335 return get_style_attr(This, STYLEID_WIDTH, &V_BSTR(p));
1338 static HRESULT WINAPI HTMLStyle_put_height(IHTMLStyle *iface, VARIANT v)
1340 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1342 TRACE("(%p)->(%s)\n", This, debugstr_variant(&v));
1346 return set_style_attr(This, STYLEID_HEIGHT, V_BSTR(&v), 0);
1348 FIXME("unimplemented vt %d\n", V_VT(&v));
1355 static HRESULT WINAPI HTMLStyle_get_height(IHTMLStyle *iface, VARIANT *p)
1357 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1361 TRACE("(%p)->(%p)\n", This, p);
1363 hres = get_style_attr(This, STYLEID_HEIGHT, &ret);
1372 static HRESULT WINAPI HTMLStyle_put_styleFloat(IHTMLStyle *iface, BSTR v)
1374 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1375 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1379 static HRESULT WINAPI HTMLStyle_get_styleFloat(IHTMLStyle *iface, BSTR *p)
1381 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1382 FIXME("(%p)->(%p)\n", This, p);
1386 static HRESULT WINAPI HTMLStyle_put_clear(IHTMLStyle *iface, BSTR v)
1388 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1389 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1393 static HRESULT WINAPI HTMLStyle_get_clear(IHTMLStyle *iface, BSTR *p)
1395 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1396 FIXME("(%p)->(%p)\n", This, p);
1400 static HRESULT WINAPI HTMLStyle_put_display(IHTMLStyle *iface, BSTR v)
1402 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1404 TRACE("(%p)->(%s)\n", This, debugstr_w(v));
1406 return set_style_attr(This, STYLEID_DISPLAY, v, 0);
1409 static HRESULT WINAPI HTMLStyle_get_display(IHTMLStyle *iface, BSTR *p)
1411 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1413 TRACE("(%p)->(%p)\n", This, p);
1415 return get_style_attr(This, STYLEID_DISPLAY, p);
1418 static HRESULT WINAPI HTMLStyle_put_visibility(IHTMLStyle *iface, BSTR v)
1420 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1422 TRACE("(%p)->(%s)\n", This, debugstr_w(v));
1424 return set_style_attr(This, STYLEID_VISIBILITY, v, 0);
1427 static HRESULT WINAPI HTMLStyle_get_visibility(IHTMLStyle *iface, BSTR *p)
1429 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1431 TRACE("(%p)->(%p)\n", This, p);
1433 return get_style_attr(This, STYLEID_VISIBILITY, p);
1436 static HRESULT WINAPI HTMLStyle_put_listStyleType(IHTMLStyle *iface, BSTR v)
1438 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1439 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1443 static HRESULT WINAPI HTMLStyle_get_listStyleType(IHTMLStyle *iface, BSTR *p)
1445 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1446 FIXME("(%p)->(%p)\n", This, p);
1450 static HRESULT WINAPI HTMLStyle_put_listStylePosition(IHTMLStyle *iface, BSTR v)
1452 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1453 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1457 static HRESULT WINAPI HTMLStyle_get_listStylePosition(IHTMLStyle *iface, BSTR *p)
1459 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1460 FIXME("(%p)->(%p)\n", This, p);
1464 static HRESULT WINAPI HTMLStyle_put_listStyleImage(IHTMLStyle *iface, BSTR v)
1466 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1467 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1471 static HRESULT WINAPI HTMLStyle_get_listStyleImage(IHTMLStyle *iface, BSTR *p)
1473 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1474 FIXME("(%p)->(%p)\n", This, p);
1478 static HRESULT WINAPI HTMLStyle_put_listStyle(IHTMLStyle *iface, BSTR v)
1480 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1481 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1485 static HRESULT WINAPI HTMLStyle_get_listStyle(IHTMLStyle *iface, BSTR *p)
1487 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1488 FIXME("(%p)->(%p)\n", This, p);
1492 static HRESULT WINAPI HTMLStyle_put_whiteSpace(IHTMLStyle *iface, BSTR v)
1494 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1495 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1499 static HRESULT WINAPI HTMLStyle_get_whiteSpace(IHTMLStyle *iface, BSTR *p)
1501 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1502 FIXME("(%p)->(%p)\n", This, p);
1506 static HRESULT WINAPI HTMLStyle_put_top(IHTMLStyle *iface, VARIANT v)
1508 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1510 TRACE("(%p)->(%s)\n", This, debugstr_variant(&v));
1514 return set_style_attr(This, STYLEID_TOP, V_BSTR(&v), 0);
1516 FIXME("unimplemented vt %d\n", V_VT(&v));
1523 static HRESULT WINAPI HTMLStyle_get_top(IHTMLStyle *iface, VARIANT *p)
1525 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1529 TRACE("(%p)->(%p)\n", This, p);
1531 hres = get_style_attr(This, STYLEID_TOP, &ret);
1540 static HRESULT WINAPI HTMLStyle_put_left(IHTMLStyle *iface, VARIANT v)
1542 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1544 TRACE("(%p)->(%s)\n", This, debugstr_variant(&v));
1548 return set_style_attr(This, STYLEID_LEFT, V_BSTR(&v), 0);
1550 FIXME("unimplemented vt %d\n", V_VT(&v));
1557 static HRESULT WINAPI HTMLStyle_get_left(IHTMLStyle *iface, VARIANT *p)
1559 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1563 TRACE("(%p)->(%p)\n", This, p);
1565 hres = get_style_attr(This, STYLEID_LEFT, &ret);
1574 static HRESULT WINAPI HTMLStyle_get_position(IHTMLStyle *iface, BSTR *p)
1576 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1577 FIXME("(%p)->(%p)\n", This, p);
1581 static HRESULT WINAPI HTMLStyle_put_zIndex(IHTMLStyle *iface, VARIANT v)
1583 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1584 FIXME("(%p)->(v%d)\n", This, V_VT(&v));
1588 static HRESULT WINAPI HTMLStyle_get_zIndex(IHTMLStyle *iface, VARIANT *p)
1590 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1591 FIXME("(%p)->(%p)\n", This, p);
1595 static HRESULT WINAPI HTMLStyle_put_overflow(IHTMLStyle *iface, BSTR v)
1597 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1598 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1602 static HRESULT WINAPI HTMLStyle_get_overflow(IHTMLStyle *iface, BSTR *p)
1604 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1605 FIXME("(%p)->(%p)\n", This, p);
1609 static HRESULT WINAPI HTMLStyle_put_pageBreakBefore(IHTMLStyle *iface, BSTR v)
1611 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1612 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1616 static HRESULT WINAPI HTMLStyle_get_pageBreakBefore(IHTMLStyle *iface, BSTR *p)
1618 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1619 FIXME("(%p)->(%p)\n", This, p);
1623 static HRESULT WINAPI HTMLStyle_put_pageBreakAfter(IHTMLStyle *iface, BSTR v)
1625 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1626 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1630 static HRESULT WINAPI HTMLStyle_get_pageBreakAfter(IHTMLStyle *iface, BSTR *p)
1632 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1633 FIXME("(%p)->(%p)\n", This, p);
1637 static HRESULT WINAPI HTMLStyle_put_cssText(IHTMLStyle *iface, BSTR v)
1639 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1640 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1644 static HRESULT WINAPI HTMLStyle_get_cssText(IHTMLStyle *iface, BSTR *p)
1646 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1647 FIXME("(%p)->(%p)\n", This, p);
1651 static HRESULT WINAPI HTMLStyle_put_pixelTop(IHTMLStyle *iface, long v)
1653 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1654 FIXME("(%p)->()\n", This);
1658 static HRESULT WINAPI HTMLStyle_get_pixelTop(IHTMLStyle *iface, long *p)
1660 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1661 FIXME("(%p)->()\n", This);
1665 static HRESULT WINAPI HTMLStyle_put_pixelLeft(IHTMLStyle *iface, long v)
1667 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1668 FIXME("(%p)->()\n", This);
1672 static HRESULT WINAPI HTMLStyle_get_pixelLeft(IHTMLStyle *iface, long *p)
1674 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1675 FIXME("(%p)->()\n", This);
1679 static HRESULT WINAPI HTMLStyle_put_pixelWidth(IHTMLStyle *iface, long v)
1681 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1682 FIXME("(%p)->()\n", This);
1686 static HRESULT WINAPI HTMLStyle_get_pixelWidth(IHTMLStyle *iface, long *p)
1688 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1689 FIXME("(%p)->()\n", This);
1693 static HRESULT WINAPI HTMLStyle_put_pixelHeight(IHTMLStyle *iface, long v)
1695 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1696 FIXME("(%p)->()\n", This);
1700 static HRESULT WINAPI HTMLStyle_get_pixelHeight(IHTMLStyle *iface, long *p)
1702 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1703 FIXME("(%p)->()\n", This);
1707 static HRESULT WINAPI HTMLStyle_put_posTop(IHTMLStyle *iface, float v)
1709 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1710 FIXME("(%p)->()\n", This);
1714 static HRESULT WINAPI HTMLStyle_get_posTop(IHTMLStyle *iface, float *p)
1716 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1717 FIXME("(%p)->()\n", This);
1721 static HRESULT WINAPI HTMLStyle_put_posLeft(IHTMLStyle *iface, float v)
1723 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1724 FIXME("(%p)->()\n", This);
1728 static HRESULT WINAPI HTMLStyle_get_posLeft(IHTMLStyle *iface, float *p)
1730 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1731 FIXME("(%p)->()\n", This);
1735 static HRESULT WINAPI HTMLStyle_put_posWidth(IHTMLStyle *iface, float v)
1737 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1738 FIXME("(%p)->()\n", This);
1742 static HRESULT WINAPI HTMLStyle_get_posWidth(IHTMLStyle *iface, float *p)
1744 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1745 FIXME("(%p)->()\n", This);
1749 static HRESULT WINAPI HTMLStyle_put_posHeight(IHTMLStyle *iface, float v)
1751 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1752 FIXME("(%p)->()\n", This);
1756 static HRESULT WINAPI HTMLStyle_get_posHeight(IHTMLStyle *iface, float *p)
1758 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1759 FIXME("(%p)->()\n", This);
1763 static HRESULT WINAPI HTMLStyle_put_cursor(IHTMLStyle *iface, BSTR v)
1765 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1767 TRACE("(%p)->(%s)\n", This, debugstr_w(v));
1769 return set_style_attr(This, STYLEID_CURSOR, v, 0);
1772 static HRESULT WINAPI HTMLStyle_get_cursor(IHTMLStyle *iface, BSTR *p)
1774 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1776 TRACE("(%p)->(%p)\n", This, p);
1778 return get_style_attr(This, STYLEID_CURSOR, p);
1781 static HRESULT WINAPI HTMLStyle_put_clip(IHTMLStyle *iface, BSTR v)
1783 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1784 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1788 static HRESULT WINAPI HTMLStyle_get_clip(IHTMLStyle *iface, BSTR *p)
1790 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1791 FIXME("(%p)->(%p)\n", This, p);
1795 static HRESULT WINAPI HTMLStyle_put_filter(IHTMLStyle *iface, BSTR v)
1797 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1798 FIXME("(%p)->(%s)\n", This, debugstr_w(v));
1802 static HRESULT WINAPI HTMLStyle_get_filter(IHTMLStyle *iface, BSTR *p)
1804 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1805 FIXME("(%p)->(%p)\n", This, p);
1809 static HRESULT WINAPI HTMLStyle_setAttribute(IHTMLStyle *iface, BSTR strAttributeName,
1810 VARIANT AttributeValue, LONG lFlags)
1812 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1813 FIXME("(%p)->(%s v%d %08x)\n", This, debugstr_w(strAttributeName),
1814 V_VT(&AttributeValue), lFlags);
1818 static HRESULT WINAPI HTMLStyle_getAttribute(IHTMLStyle *iface, BSTR strAttributeName,
1819 LONG lFlags, VARIANT *AttributeValue)
1821 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1822 FIXME("(%p)->(%s %08x %p)\n", This, debugstr_w(strAttributeName),
1823 lFlags, AttributeValue);
1827 static HRESULT WINAPI HTMLStyle_removeAttribute(IHTMLStyle *iface, BSTR strAttributeName,
1828 LONG lFlags, VARIANT_BOOL *pfSuccess)
1830 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1831 FIXME("(%p)->(%s %08x %p)\n", This, debugstr_w(strAttributeName),
1836 static HRESULT WINAPI HTMLStyle_toString(IHTMLStyle *iface, BSTR *String)
1838 HTMLStyle *This = HTMLSTYLE_THIS(iface);
1839 FIXME("(%p)->(%p)\n", This, String);
1843 static const IHTMLStyleVtbl HTMLStyleVtbl = {
1844 HTMLStyle_QueryInterface,
1847 HTMLStyle_GetTypeInfoCount,
1848 HTMLStyle_GetTypeInfo,
1849 HTMLStyle_GetIDsOfNames,
1851 HTMLStyle_put_fontFamily,
1852 HTMLStyle_get_fontFamily,
1853 HTMLStyle_put_fontStyle,
1854 HTMLStyle_get_fontStyle,
1855 HTMLStyle_put_fontVariant,
1856 HTMLStyle_get_fontVariant,
1857 HTMLStyle_put_fontWeight,
1858 HTMLStyle_get_fontWeight,
1859 HTMLStyle_put_fontSize,
1860 HTMLStyle_get_fontSize,
1863 HTMLStyle_put_color,
1864 HTMLStyle_get_color,
1865 HTMLStyle_put_background,
1866 HTMLStyle_get_background,
1867 HTMLStyle_put_backgroundColor,
1868 HTMLStyle_get_backgroundColor,
1869 HTMLStyle_put_backgroundImage,
1870 HTMLStyle_get_backgroundImage,
1871 HTMLStyle_put_backgroundRepeat,
1872 HTMLStyle_get_backgroundRepeat,
1873 HTMLStyle_put_backgroundAttachment,
1874 HTMLStyle_get_backgroundAttachment,
1875 HTMLStyle_put_backgroundPosition,
1876 HTMLStyle_get_backgroundPosition,
1877 HTMLStyle_put_backgroundPositionX,
1878 HTMLStyle_get_backgroundPositionX,
1879 HTMLStyle_put_backgroundPositionY,
1880 HTMLStyle_get_backgroundPositionY,
1881 HTMLStyle_put_wordSpacing,
1882 HTMLStyle_get_wordSpacing,
1883 HTMLStyle_put_letterSpacing,
1884 HTMLStyle_get_letterSpacing,
1885 HTMLStyle_put_textDecoration,
1886 HTMLStyle_get_textDecoration,
1887 HTMLStyle_put_textDecorationNone,
1888 HTMLStyle_get_textDecorationNone,
1889 HTMLStyle_put_textDecorationUnderline,
1890 HTMLStyle_get_textDecorationUnderline,
1891 HTMLStyle_put_textDecorationOverline,
1892 HTMLStyle_get_textDecorationOverline,
1893 HTMLStyle_put_textDecorationLineThrough,
1894 HTMLStyle_get_textDecorationLineThrough,
1895 HTMLStyle_put_textDecorationBlink,
1896 HTMLStyle_get_textDecorationBlink,
1897 HTMLStyle_put_verticalAlign,
1898 HTMLStyle_get_verticalAlign,
1899 HTMLStyle_put_textTransform,
1900 HTMLStyle_get_textTransform,
1901 HTMLStyle_put_textAlign,
1902 HTMLStyle_get_textAlign,
1903 HTMLStyle_put_textIndent,
1904 HTMLStyle_get_textIndent,
1905 HTMLStyle_put_lineHeight,
1906 HTMLStyle_get_lineHeight,
1907 HTMLStyle_put_marginTop,
1908 HTMLStyle_get_marginTop,
1909 HTMLStyle_put_marginRight,
1910 HTMLStyle_get_marginRight,
1911 HTMLStyle_put_marginBottom,
1912 HTMLStyle_get_marginBottom,
1913 HTMLStyle_put_marginLeft,
1914 HTMLStyle_get_marginLeft,
1915 HTMLStyle_put_margin,
1916 HTMLStyle_get_margin,
1917 HTMLStyle_put_paddingTop,
1918 HTMLStyle_get_paddingTop,
1919 HTMLStyle_put_paddingRight,
1920 HTMLStyle_get_paddingRight,
1921 HTMLStyle_put_paddingBottom,
1922 HTMLStyle_get_paddingBottom,
1923 HTMLStyle_put_paddingLeft,
1924 HTMLStyle_get_paddingLeft,
1925 HTMLStyle_put_padding,
1926 HTMLStyle_get_padding,
1927 HTMLStyle_put_border,
1928 HTMLStyle_get_border,
1929 HTMLStyle_put_borderTop,
1930 HTMLStyle_get_borderTop,
1931 HTMLStyle_put_borderRight,
1932 HTMLStyle_get_borderRight,
1933 HTMLStyle_put_borderBottom,
1934 HTMLStyle_get_borderBottom,
1935 HTMLStyle_put_borderLeft,
1936 HTMLStyle_get_borderLeft,
1937 HTMLStyle_put_borderColor,
1938 HTMLStyle_get_borderColor,
1939 HTMLStyle_put_borderTopColor,
1940 HTMLStyle_get_borderTopColor,
1941 HTMLStyle_put_borderRightColor,
1942 HTMLStyle_get_borderRightColor,
1943 HTMLStyle_put_borderBottomColor,
1944 HTMLStyle_get_borderBottomColor,
1945 HTMLStyle_put_borderLeftColor,
1946 HTMLStyle_get_borderLeftColor,
1947 HTMLStyle_put_borderWidth,
1948 HTMLStyle_get_borderWidth,
1949 HTMLStyle_put_borderTopWidth,
1950 HTMLStyle_get_borderTopWidth,
1951 HTMLStyle_put_borderRightWidth,
1952 HTMLStyle_get_borderRightWidth,
1953 HTMLStyle_put_borderBottomWidth,
1954 HTMLStyle_get_borderBottomWidth,
1955 HTMLStyle_put_borderLeftWidth,
1956 HTMLStyle_get_borderLeftWidth,
1957 HTMLStyle_put_borderStyle,
1958 HTMLStyle_get_borderStyle,
1959 HTMLStyle_put_borderTopStyle,
1960 HTMLStyle_get_borderTopStyle,
1961 HTMLStyle_put_borderRightStyle,
1962 HTMLStyle_get_borderRightStyle,
1963 HTMLStyle_put_borderBottomStyle,
1964 HTMLStyle_get_borderBottomStyle,
1965 HTMLStyle_put_borderLeftStyle,
1966 HTMLStyle_get_borderLeftStyle,
1967 HTMLStyle_put_width,
1968 HTMLStyle_get_width,
1969 HTMLStyle_put_height,
1970 HTMLStyle_get_height,
1971 HTMLStyle_put_styleFloat,
1972 HTMLStyle_get_styleFloat,
1973 HTMLStyle_put_clear,
1974 HTMLStyle_get_clear,
1975 HTMLStyle_put_display,
1976 HTMLStyle_get_display,
1977 HTMLStyle_put_visibility,
1978 HTMLStyle_get_visibility,
1979 HTMLStyle_put_listStyleType,
1980 HTMLStyle_get_listStyleType,
1981 HTMLStyle_put_listStylePosition,
1982 HTMLStyle_get_listStylePosition,
1983 HTMLStyle_put_listStyleImage,
1984 HTMLStyle_get_listStyleImage,
1985 HTMLStyle_put_listStyle,
1986 HTMLStyle_get_listStyle,
1987 HTMLStyle_put_whiteSpace,
1988 HTMLStyle_get_whiteSpace,
1993 HTMLStyle_get_position,
1994 HTMLStyle_put_zIndex,
1995 HTMLStyle_get_zIndex,
1996 HTMLStyle_put_overflow,
1997 HTMLStyle_get_overflow,
1998 HTMLStyle_put_pageBreakBefore,
1999 HTMLStyle_get_pageBreakBefore,
2000 HTMLStyle_put_pageBreakAfter,
2001 HTMLStyle_get_pageBreakAfter,
2002 HTMLStyle_put_cssText,
2003 HTMLStyle_get_cssText,
2004 HTMLStyle_put_pixelTop,
2005 HTMLStyle_get_pixelTop,
2006 HTMLStyle_put_pixelLeft,
2007 HTMLStyle_get_pixelLeft,
2008 HTMLStyle_put_pixelWidth,
2009 HTMLStyle_get_pixelWidth,
2010 HTMLStyle_put_pixelHeight,
2011 HTMLStyle_get_pixelHeight,
2012 HTMLStyle_put_posTop,
2013 HTMLStyle_get_posTop,
2014 HTMLStyle_put_posLeft,
2015 HTMLStyle_get_posLeft,
2016 HTMLStyle_put_posWidth,
2017 HTMLStyle_get_posWidth,
2018 HTMLStyle_put_posHeight,
2019 HTMLStyle_get_posHeight,
2020 HTMLStyle_put_cursor,
2021 HTMLStyle_get_cursor,
2024 HTMLStyle_put_filter,
2025 HTMLStyle_get_filter,
2026 HTMLStyle_setAttribute,
2027 HTMLStyle_getAttribute,
2028 HTMLStyle_removeAttribute,
2032 static const tid_t HTMLStyle_iface_tids[] = {
2037 static dispex_static_data_t HTMLStyle_dispex = {
2041 HTMLStyle_iface_tids
2044 IHTMLStyle *HTMLStyle_Create(nsIDOMCSSStyleDeclaration *nsstyle)
2046 HTMLStyle *ret = heap_alloc_zero(sizeof(HTMLStyle));
2048 ret->lpHTMLStyleVtbl = &HTMLStyleVtbl;
2050 ret->nsstyle = nsstyle;
2051 HTMLStyle2_Init(ret);
2053 nsIDOMCSSStyleDeclaration_AddRef(nsstyle);
2055 init_dispex(&ret->dispex, (IUnknown*)HTMLSTYLE(ret), &HTMLStyle_dispex);
2057 return HTMLSTYLE(ret);