TEXTMODE enumeration (richedit.h)

Indicates the text mode of a rich edit control. The EM_SETTEXTMODE and EM_GETTEXTMODE messages use this enumeration type.

Syntax

typedef enum tagTextMode {
  TM_PLAINTEXT = 1,
  TM_RICHTEXT = 2,
  TM_SINGLELEVELUNDO = 4,
  TM_MULTILEVELUNDO = 8,
  TM_SINGLECODEPAGE = 16,
  TM_MULTICODEPAGE = 32
} TEXTMODE;

Constants

 
TM_PLAINTEXT
Value: 1
Indicates plain-text mode, in which the control is similar to a standard edit control. For more information about plain-text mode, see the Remarks section of EM_SETTEXTMODE.
TM_RICHTEXT
Value: 2
Indicates rich-text mode, in which the control has the standard rich edit functionality. Rich-text mode is the default setting.
TM_SINGLELEVELUNDO
Value: 4
The control allows the user to undo only the last action in the undo queue.
TM_MULTILEVELUNDO
Value: 8
The control supports multiple undo actions. This is the default setting. Use the EM_SETUNDOLIMIT message to set the maximum number of undo actions.
TM_SINGLECODEPAGE
Value: 16
The control only allows the English keyboard and a keyboard corresponding to the default character set. For example, you could have Greek and English. Note that this prevents Unicode text from entering the control. For example, use this value if a Rich Edit control must be restricted to ANSI text.
TM_MULTICODEPAGE
Value: 32
The control allows multiple code pages and Unicode text into the control. This is the default setting.

Requirements

Requirement Value
Minimum supported client Windows Vista [desktop apps only]
Minimum supported server Windows Server 2003 [desktop apps only]
Header richedit.h

See also

EM_GETTEXTMODE

EM_SETTEXTMODE

Reference