mirror of
https://github.com/reactos/wine.git
synced 2024-11-25 04:39:45 +00:00
riched20: EM_HIDESELECTION implementation.
This commit is contained in:
parent
07fe82dd55
commit
6979719a90
@ -76,7 +76,7 @@
|
||||
- EM_GETWORDBREAKPROCEX
|
||||
- EM_GETWORDWRAPMODE 1.0asian
|
||||
+ EM_GETZOOM 3.0
|
||||
- EM_HIDESELECTION
|
||||
+ EM_HIDESELECTION
|
||||
- EM_LIMITTEXT
|
||||
+ EM_LINEFROMCHAR
|
||||
+ EM_LINEINDEX
|
||||
@ -1022,6 +1022,7 @@ ME_TextEditor *ME_MakeEditor(HWND hWnd) {
|
||||
ed->nScrollPosY = 0;
|
||||
ed->nZoomNumerator = ed->nZoomDenominator = 0;
|
||||
ed->bRedraw = TRUE;
|
||||
ed->bHideSelection = FALSE;
|
||||
ed->nInvalidOfs = -1;
|
||||
ed->pfnWordBreak = NULL;
|
||||
ed->lpOleCallback = NULL;
|
||||
@ -1200,7 +1201,7 @@ static const char * const richedit_messages[] = {
|
||||
"EM_GETOLEINTERFACE",
|
||||
"EM_GETPARAFORMAT",
|
||||
"EM_GETSELTEXT",
|
||||
"EM_HIDESELECTION",
|
||||
"EM_HIDESELECTION",
|
||||
"EM_PASTESPECIAL",
|
||||
"EM_REQUESTRESIZE",
|
||||
"EM_SELECTIONTYPE",
|
||||
@ -1310,7 +1311,6 @@ LRESULT WINAPI RichEditANSIWndProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lP
|
||||
UNSUPPORTED_MSG(EM_GETTYPOGRAPHYOPTIONS)
|
||||
UNSUPPORTED_MSG(EM_GETUNDONAME)
|
||||
UNSUPPORTED_MSG(EM_GETWORDBREAKPROCEX)
|
||||
UNSUPPORTED_MSG(EM_HIDESELECTION)
|
||||
UNSUPPORTED_MSG(EM_LIMITTEXT) /* also known as EM_SETLIMITTEXT */
|
||||
UNSUPPORTED_MSG(EM_PASTESPECIAL)
|
||||
UNSUPPORTED_MSG(EM_SCROLL)
|
||||
@ -1611,6 +1611,12 @@ LRESULT WINAPI RichEditANSIWndProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lP
|
||||
}
|
||||
return count;
|
||||
}
|
||||
case EM_HIDESELECTION:
|
||||
{
|
||||
editor->bHideSelection = (wParam != 0);
|
||||
ME_InvalidateSelection(editor);
|
||||
return 0;
|
||||
}
|
||||
case EM_LINESCROLL:
|
||||
{
|
||||
int nPos = editor->nScrollPosY, nEnd= editor->nTotalLength - editor->sizeWindow.cy;
|
||||
|
@ -316,6 +316,7 @@ typedef struct tagME_TextEditor
|
||||
*TM_SINGLELEVELUNDO or TM_MULTILEVELUNDO
|
||||
*TM_SINGLECODEPAGE or TM_MULTICODEPAGE*/
|
||||
int mode;
|
||||
BOOL bHideSelection;
|
||||
} ME_TextEditor;
|
||||
|
||||
typedef struct tagME_Context
|
||||
|
@ -175,7 +175,10 @@ static void ME_DrawTextWithStyle(ME_Context *c, int x, int y, LPCWSTR szText, in
|
||||
GetTextExtentPoint32W(hDC, szText, nSelFrom, &sz);
|
||||
x += sz.cx;
|
||||
GetTextExtentPoint32W(hDC, szText+nSelFrom, nSelTo-nSelFrom, &sz);
|
||||
PatBlt(hDC, x, ymin, sz.cx, cy, DSTINVERT);
|
||||
|
||||
/* Invert selection if not hidden by EM_HIDESELECTION */
|
||||
if (c->editor->bHideSelection == FALSE)
|
||||
PatBlt(hDC, x, ymin, sz.cx, cy, DSTINVERT);
|
||||
}
|
||||
SetTextColor(hDC, rgbOld);
|
||||
ME_UnselectStyleFont(c->editor, hDC, s, hOldFont);
|
||||
|
Loading…
Reference in New Issue
Block a user