Getting a specific version of rich edit
-
It seem like I remember that rich edit used to line break on CR/LF 0x0d + 0X0D now it seems either 0x0a 0x0c (form feed) of 0x0d (carriage return causes) causes a line break Is there a way to look for a specific version of rich edit I means the class names for 1.0 thru 3.0 the doc says use RICHEDIT_CLASS which loads Riched20.dll more so I remember that rich edit would only line break on CR AND LF not sure which version as I would like to use that version
-
It seem like I remember that rich edit used to line break on CR/LF 0x0d + 0X0D now it seems either 0x0a 0x0c (form feed) of 0x0d (carriage return causes) causes a line break Is there a way to look for a specific version of rich edit I means the class names for 1.0 thru 3.0 the doc says use RICHEDIT_CLASS which loads Riched20.dll more so I remember that rich edit would only line break on CR AND LF not sure which version as I would like to use that version
Hi, You can override both the word and line breaking behaviors. Have a look at using the EM_SETWORDBREAKPROC message[^] to set the EDITWORDBREAKPROCA function[^]. Best Wishes, -David Delaune
-
Hi, You can override both the word and line breaking behaviors. Have a look at using the EM_SETWORDBREAKPROC message[^] to set the EDITWORDBREAKPROCA function[^]. Best Wishes, -David Delaune
Hi here is my wordbreak function
int CALLBACK EditWordBreakProc(LPTSTR lpszEditText, int ichCurrent, int cchEditText, int code)
{
char FAR* lpCurrentChar;
int nIndex;
int nLastAction;switch (code) { case WB\_ISDELIMITER: if (lpszEditText\[ichCurrent\] == 0x0a0d) return TRUE; else return FALSE; break; }
}
Here is where I invoke it
fptrx = &EditWordBreakProc; storagepointer->SendMessage(EM\_SETWORDBREAKPROC, 0,(LPARAM) fptrx);
long numstream = storagepointer->StreamIn(SF_TEXT,STORAGESTREAM);
variable definition
funcptrx fptrx;
int CALLBACK EditWordBreakProc(LPTSTR lpszEditText, int ichCurrent, int cchEditText, int code);
typedef int (CALLBACK *funcptrx) (LPTSTR, int, int, int);