IColor::RGB Property
From PDF XChange PDF SDK
m (Automatic page editing by robot) |
|||
(One intermediate revision by one other user not shown) | |||
Line 3: | Line 3: | ||
{{#customTitle:IColor::RGB Property}} | {{#customTitle:IColor::RGB Property}} | ||
{{#parentPage:PXV:IColor#Properties|RGB|property}} | {{#parentPage:PXV:IColor#Properties|RGB|property}} | ||
− | |||
{{ToReview}} | {{ToReview}} | ||
− | Property '''RGB''' of interface [[PXV:IColor|IColor]] returns/sets Value of ULONG . | + | Property '''RGB''' of interface [[PXV:IColor|IColor]] returns/sets Value of ULONG constructed from the three values of the RGB color. Each of the values should be 255 based and the value itself is constructed by using this macro:<br /> |
+ | <code>#define RGB(r,g,b) ((COLORREF)(((BYTE)(r)|((WORD)((BYTE)(g))<<8))|(((DWORD)(BYTE)(b))<<16)))</code> | ||
== Syntax == | == Syntax == | ||
− | <pre class="brush:cpp;gutter:false">HRESULT get_RGB([out, retval] ULONG* | + | <pre class="brush:cpp;gutter:false">HRESULT get_RGB([out, retval] ULONG* nRGB); |
− | HRESULT put_RGB([in] ULONG | + | HRESULT put_RGB([in] ULONG nRGB); |
</pre> | </pre> | ||
== See Also == | == See Also == | ||
[[PXV:IColor|IColor]] | [[PXV:IColor|IColor]] |
Latest revision as of 02:35, 16 March 2017
Property RGB of interface IColor returns/sets Value of ULONG constructed from the three values of the RGB color. Each of the values should be 255 based and the value itself is constructed by using this macro:
#define RGB(r,g,b) ((COLORREF)(((BYTE)(r)|((WORD)((BYTE)(g))<<8))|(((DWORD)(BYTE)(b))<<16)))
Syntax
HRESULT get_RGB([out, retval] ULONG* nRGB); HRESULT put_RGB([in] ULONG nRGB);