RichEdit problème couleur de fond des lettres

Résolu
cs_TeniX Messages postés 118 Date d'inscription mercredi 24 décembre 2003 Statut Membre Dernière intervention 11 décembre 2011 - 3 févr. 2006 à 21:46
cs_TeniX Messages postés 118 Date d'inscription mercredi 24 décembre 2003 Statut Membre Dernière intervention 11 décembre 2011 - 4 févr. 2006 à 10:30
Salut,

J'ai un probléme pour mètre en couleur le fond du texte

Je crée un richedit sous cette forme:

Rich = CreateWindowEx(WS_EX_CLIENTEDGE, RICHEDIT_CLASS, "",
WS_CHILD | ES_AUTOHSCROLL | ES_AUTOVSCROLL | ES_MULTILINE
| ES_WANTRETURN | WS_HSCROLL | WS_VSCROLL | WS_VISIBLE, 100, 100, 300,300, hwnd, (HMENU)30,hInst, NULL);

Dans la modification du format des caractère le style:


CHARFORMAT2 Format;
CHARRANGE Selection;

ZeroMemory(&Format, sizeof(CHARFORMAT2));
Format.cbSize = sizeof(CHARFORMAT2);
Format.dwMask = CFM_BOLD | CFM_COLOR | CFM_FACE | CFM_ITALIC | CFM_SIZE | CFM_UNDERLINE | CFM_BACKCOLOR;

le CFM_BACKCOLOR -> il me dit erreur veuillez declaré , pourtant quand je le met pas la coloration du texte marche , j'ai vue CFM_BACKCOLOR dans une source , je me demande si c'était une erreur ou un include oublier par hazard.

Merci pour vos réponse.

2 réponses

julienbj Messages postés 452 Date d'inscription jeudi 4 décembre 2003 Statut Membre Dernière intervention 19 décembre 2008 15
3 févr. 2006 à 23:11
Dans le fichier richedit.h:

#define CFM_BACKCOLOR 0x04000000

Vive le C
Tchao
[mailto:julienbj@hotmail.com Savon]
3
cs_TeniX Messages postés 118 Date d'inscription mercredi 24 décembre 2003 Statut Membre Dernière intervention 11 décembre 2011 2
4 févr. 2006 à 10:30
Merci julienbj ;)

@bientot
0
Rejoignez-nous