CRichEditCtrl::GetParaFormat

Gets the paragraph formatting attributes of the current selection.

DWORD GetParaFormat( 
   PARAFORMAT& pf  
) const; 
DWORD GetParaFormat( 
   PARAFORMAT2& pf  
) const;

Parameters

  • pf
    In the first version, a pointer to a PARAFORMAT structure to hold the paragraph formatting attributes of the current selection.

    In the second version, a pointer to a PARAFORMAT2 structure, which is a Rich Edit 2.0 extension to the PARAFORMAT structure, holding the default character formatting attributes.

Return Value

The dwMask data member of pf. It specifies the paragraph formatting attributes that are consistent throughout the current selection.

Remarks

If more than one paragraph is selected, pf receives the attributes of the first selected paragraph. The return value specifies which attributes are consistent throughout the selection.

For more information, see the EM_GETPARAFORMAT message and the PARAFORMAT and PARAFORMAT2 structures in the Windows SDK.

Example

See the example for CRichEditCtrl::SetParaFormat.

Requirements

Header: afxcmn.h

See Also

Reference

CRichEditCtrl Class

Hierarchy Chart

CRichEditCtrl::SetParaFormat

CRichEditCtrl::GetSelectionCharFormat