ITextDocument2::GetEffectColor method

Retrieves the color used for special text attributes.

Syntax


HRESULT GetEffectColor(
  [in]   long Index,
  [out]  long *pValue
);

Parameters

Index [in]

Type: long

The index of the color to retrieve. It can be one of the following values.

IndexMeaning
0

Text color.

1

RGB(0, 0, 0)

2

RGB(0, 0, 255)

3

RGB(0, 255, 255)

4

RGB(0, 255, 0)

5

RGB(255, 0, 255)

6

RGB(255, 0, 0)

7

RGB(255, 255, 0)

8

RGB(255, 255, 255)

9

RGB(0, 0, 128)

10

RGB(0, 128, 128)

11

RGB(0, 128, 0)

12

RGB(128, 0, 128)

13

RGB(128, 0, 0)

14

RGB(128, 128, 0)

15

RGB(128, 128, 128)

16

RGB(192, 192, 192)

 

pValue [out]

Type: long*

The color that corresponds to the specified index.

Return value

Type: HRESULT

If the method succeeds, it returns NOERROR. Otherwise, it returns an HRESULT error code.

Remarks

The first 16 index values are for special underline colors. If an index between 1 and 16 hasn't been defined by a call to the ITextDocument2:SetEffectColor method, GetEffectColor returns the corresponding Microsoft Word default color.

Requirements

Minimum supported client

Windows 8 [desktop apps only]

Minimum supported server

Windows Server 2012 [desktop apps only]

Header

Tom.h

DLL

Msftedit.dll

See also

ITextDocument2
ITextDocument2::SetEffectColor

 

 

Community Additions

ADD
Show:
© 2014 Microsoft