DOMCSS.idl 6.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253
  1. /*
  2. * Copyright (C) 2006, 2007, 2008 Apple Inc. All rights reserved.
  3. *
  4. * Redistribution and use in source and binary forms, with or without
  5. * modification, are permitted provided that the following conditions
  6. * are met:
  7. * 1. Redistributions of source code must retain the above copyright
  8. * notice, this list of conditions and the following disclaimer.
  9. * 2. Redistributions in binary form must reproduce the above copyright
  10. * notice, this list of conditions and the following disclaimer in the
  11. * documentation and/or other materials provided with the distribution.
  12. *
  13. * THIS SOFTWARE IS PROVIDED BY APPLE COMPUTER, INC. ``AS IS'' AND ANY
  14. * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  15. * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  16. * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE COMPUTER, INC. OR
  17. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
  18. * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
  19. * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
  20. * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
  21. * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  22. * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
  23. * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  24. */
  25. #ifndef DO_NO_IMPORTS
  26. import "oaidl.idl";
  27. import "ocidl.idl";
  28. import "DOMCore.idl";
  29. import "IWebScriptObject.idl";
  30. #endif
  31. interface IDOMObject;
  32. interface IDOMCSSValue;
  33. interface IDOMCSSStyleDeclaration;
  34. interface IDOMCSSStyleSheet;
  35. interface IDOMCSSRule;
  36. interface IDOMElement;
  37. /*
  38. @interface DOMDocument (DOMViewCSS)
  39. */
  40. [
  41. object,
  42. oleautomation,
  43. uuid(43EFE238-A4DF-400a-983D-FCE0C0F56BCD),
  44. pointer_default(unique)
  45. ]
  46. interface IDOMViewCSS : IUnknown
  47. {
  48. /*
  49. - (DOMCSSStyleDeclaration *)getComputedStyle:(DOMElement *)elt :(NSString *)pseudoElt;
  50. */
  51. HRESULT getComputedStyle([in] IDOMElement* elt, [in] BSTR pseudoElt, [out, retval] IDOMCSSStyleDeclaration** result);
  52. }
  53. /*
  54. @interface DOMCSSRuleList : DOMObject
  55. */
  56. [
  57. object,
  58. oleautomation,
  59. uuid(D45DA43D-5EDB-4315-A097-3ED3FA089193),
  60. pointer_default(unique)
  61. ]
  62. interface IDOMCSSRuleList : IDOMObject
  63. {
  64. /*
  65. - (unsigned)length;
  66. */
  67. HRESULT length([out, retval] UINT* result);
  68. /*
  69. - (DOMCSSRule *)item:(unsigned)index;
  70. */
  71. HRESULT item([in] UINT index, [out, retval] IDOMCSSRule** result);
  72. }
  73. /*
  74. @interface DOMCSSRule : DOMObject
  75. */
  76. [
  77. object,
  78. oleautomation,
  79. uuid(05947A31-9E1C-4c98-8608-6688959D6542),
  80. pointer_default(unique)
  81. ]
  82. interface IDOMCSSRule : IDOMObject
  83. {
  84. /*
  85. - (unsigned short)type;
  86. */
  87. HRESULT type([out, retval] unsigned short* result);
  88. /*
  89. - (NSString *)cssText;
  90. */
  91. HRESULT cssText([out, retval] BSTR* text);
  92. /*
  93. - (void)setCssText:(NSString *)cssText;
  94. */
  95. HRESULT setCssText([in] BSTR cssText);
  96. /*
  97. - (DOMCSSStyleSheet *)parentStyleSheet;
  98. */
  99. HRESULT parentStyleSheet([out, retval] IDOMCSSStyleSheet** sheet);
  100. /*
  101. - (DOMCSSRule *)parentRule;
  102. */
  103. HRESULT parentRule([out, retval] IDOMCSSRule** rule);
  104. }
  105. /*
  106. @interface DOMCSSStyleDeclaration : DOMObject
  107. */
  108. [
  109. object,
  110. oleautomation,
  111. uuid(DBBE9A6B-D505-4647-B4AB-40A7CF3EE63E),
  112. pointer_default(unique)
  113. ]
  114. interface IDOMCSSStyleDeclaration : IDOMObject
  115. {
  116. /*
  117. - (NSString *)cssText;
  118. */
  119. HRESULT cssText([out, retval] BSTR* result);
  120. /*
  121. - (void)setCssText:(NSString *)cssText;
  122. */
  123. HRESULT setCssText([in] BSTR cssText);
  124. /*
  125. - (NSString *)getPropertyValue:(NSString *)propertyName;
  126. */
  127. HRESULT getPropertyValue([in] BSTR propertyName, [out, retval] BSTR* result);
  128. /*
  129. - (DOMCSSValue *)getPropertyCSSValue:(NSString *)propertyName;
  130. */
  131. HRESULT getPropertyCSSValue([in] BSTR propertyName, [out, retval] IDOMCSSValue** result);
  132. /*
  133. - (NSString *)removeProperty:(NSString *)propertyName;
  134. */
  135. HRESULT removeProperty([in] BSTR propertyName, [out, retval] BSTR* result);
  136. /*
  137. - (NSString *)getPropertyPriority:(NSString *)propertyName;
  138. */
  139. HRESULT getPropertyPriority([in] BSTR propertyName, [out, retval] BSTR* result);
  140. /*
  141. - (void)setProperty:(NSString *)propertyName :(NSString *)value :(NSString *)priority;
  142. */
  143. HRESULT setProperty([in] BSTR propertyName, [in] BSTR value, [in] BSTR priority);
  144. /*
  145. - (unsigned)length;
  146. */
  147. HRESULT length([out, retval] UINT* result);
  148. /*
  149. - (NSString *)item:(unsigned)index;
  150. */
  151. HRESULT item([in] UINT index, [out, retval] BSTR* result);
  152. /*
  153. - (DOMCSSRule *)parentRule;
  154. */
  155. HRESULT parentRule([out, retval] IDOMCSSRule** result);
  156. }
  157. /*
  158. @interface DOMCSSValue : DOMObject
  159. */
  160. [
  161. object,
  162. oleautomation,
  163. uuid(51D29553-2AF7-4f52-AFE6-3C59196A8BAA),
  164. pointer_default(unique)
  165. ]
  166. interface IDOMCSSValue : IDOMObject
  167. {
  168. /*
  169. - (NSString *)cssText;
  170. */
  171. HRESULT cssText([out, retval] BSTR* text);
  172. /*
  173. - (void)setCssText:(NSString *)cssText;
  174. */
  175. HRESULT setCssText([in] BSTR text);
  176. /*
  177. - (unsigned short)cssValueType;
  178. */
  179. HRESULT cssValueType([out, retval] unsigned short *valueType);
  180. }
  181. /*
  182. @interface DOMCSSStyleSheet : DOMStyleSheet
  183. */
  184. [
  185. object,
  186. oleautomation,
  187. uuid(14B1C213-1458-48a1-AD8F-54BFE64F9ECF),
  188. pointer_default(unique)
  189. ]
  190. interface IDOMCSSStyleSheet : IDOMObject
  191. {
  192. /*
  193. - (DOMCSSRule *)ownerRule;
  194. */
  195. HRESULT ownerRule([out, retval] IDOMCSSRule** rule);
  196. /*
  197. - (DOMCSSRuleList *)cssRules;
  198. */
  199. HRESULT cssRules([out, retval] IDOMCSSRuleList** ruleList);
  200. /*
  201. - (unsigned)insertRule:(NSString *)rule :(unsigned)index;
  202. */
  203. HRESULT insertRule([in] BSTR rule, [in] UINT index, [out, retval] UINT* result);
  204. /*
  205. - (void)deleteRule:(unsigned)index;
  206. */
  207. HRESULT deleteRule([in] UINT index);
  208. }
  209. /*
  210. @interface DOMElement (DOMElementCSSInlineStyle)
  211. */
  212. [
  213. object,
  214. oleautomation,
  215. uuid(585127E2-D698-44c4-83EC-4D1E6E07E90D),
  216. pointer_default(unique)
  217. ]
  218. interface IDOMElementCSSInlineStyle : IUnknown
  219. {
  220. /*
  221. - (DOMCSSStyleDeclaration *)style;
  222. */
  223. HRESULT style([out, retval] IDOMCSSStyleDeclaration** result);
  224. }