46#define WIN32_LEAN_AND_MEAN
50#define ImmGetCompositionStringW IMM_FN(ImmGetCompositionStringW)
51#define ImmGetCompositionWindow IMM_FN(ImmGetCompositionWindow)
52#define ImmGetContext IMM_FN(ImmGetContext)
53#define ImmIsIME IMM_FN(ImmIsIME)
54#define ImmLockIMC IMM_FN(ImmLockIMC)
55#define ImmNotifyIME IMM_FN(ImmNotifyIME)
56#define ImmReleaseContext IMM_FN(ImmReleaseContext)
57#define ImmSetCompositionFontW IMM_FN(ImmSetCompositionFontW)
58#define ImmSetCompositionWindow IMM_FN(ImmSetCompositionWindow)
59#define ImmUnlockIMC IMM_FN(ImmUnlockIMC)
66#define BUFLIMIT_INITIAL 30000
68#define ROUND_TO_GROW(size) (((size) + (GROWLENGTH - 1)) & ~(GROWLENGTH - 1))
69#define HSCROLL_FRACTION 3
74#define EF_MODIFIED 0x0001
75#define EF_FOCUSED 0x0002
76#define EF_UPDATE 0x0004
77#define EF_VSCROLL_TRACK 0x0008
78#define EF_HSCROLL_TRACK 0x0010
79#define EF_AFTER_WRAP 0x0080
81#define EF_USE_SOFTBRK 0x0100
82#define EF_DIALOGMODE 0x0200
120 INT undo_insert_count;
123 UINT undo_buffer_size;
134 void *word_break_proc;
144 INT wheelDeltaRemainder;
160 UINT composition_len;
161 int composition_start;
171#define SWAP_UINT32(x,y) do { UINT temp = (UINT)(x); (x) = (UINT)(y); (y) = temp; } while(0)
172#define ORDER_UINT(x,y) do { if ((UINT)(y) < (UINT)(x)) SWAP_UINT32((x),(y)); } while(0)
178 TRACE(
"notification %d sent to %p.\n",
code,
es->hwndParent);
192 return (
es->undo_insert_count ||
strlenW(
es->undo_text));
203 es->undo_insert_count = 0;
204 *
es->undo_text =
'\0';
229 DWORD dwEmulatedVersion;
238 version = dwProcVersion < dwEmulatedVersion ? dwProcVersion : dwEmulatedVersion;
268 if(
es->text_length == (
UINT)-1)
270 return es->text_length;
324 ERR(
"unknown action code, please report !\n");
348 if (
es->word_break_proc)
354 TRACE_(relay)(
"(UNICODE wordbrk=%p,str=%s,idx=%d,cnt=%d,act=%d)\n",
371 TRACE_(relay)(
"(ANSI wordbrk=%p,str=%s,idx=%d,cnt=%d,act=%d)\n",
398 line_def = line_def->
next;
441 WARN(
"ScriptStringAnalyse failed (%x)\n",
hr);
451 return line_def->
ssa;
474 ScriptStringAnalyse(udc, &
es->password_char,
length, (3*
length/2+16), -1,
SSA_LINK|
SSA_FALLBACK|
SSA_GLYPHS|
SSA_PASSWORD, -1,
NULL,
NULL,
NULL,
NULL,
NULL, &
es->ssa);
476 ScriptStringAnalyse(udc, &
es->password_char,
length, (1.5*
length+16), -1,
SSA_LINK|
SSA_FALLBACK|
SSA_GLYPHS|
SSA_PASSWORD, -1,
NULL,
NULL,
NULL,
NULL,
NULL, &
es->ssa);
481 ScriptStringAnalyse(udc,
es->text,
length, (3*
length/2+16), -1,
SSA_LINK|
SSA_FALLBACK|
SSA_GLYPHS, -1,
NULL,
NULL,
NULL,
NULL,
NULL, &
es->ssa);
483 ScriptStringAnalyse(udc,
es->text,
length, (1.5*
length+16), -1,
SSA_LINK|
SSA_FALLBACK|
SSA_GLYPHS, -1,
NULL,
NULL,
NULL,
NULL,
NULL, &
es->ssa);
495 line_def =
es->first_line_def;
496 while (line_def &&
line)
498 line_def = line_def->
next;
508 INT vlc = (
es->format_rect.bottom -
es->format_rect.top) /
es->line_height;
528 INT line_index = 0, nstart_line, nstart_index;
529 INT line_count =
es->line_count;
534 if (istart == iend && delta == 0)
537 previous_line =
NULL;
538 current_line =
es->first_line_def;
543 if (istart < current_line->
index + current_line->
length ||
547 previous_line = current_line;
548 current_line = current_line->
next;
550 }
while (current_line);
554 FIXME(
" modification occurred outside buffer\n");
559 nstart_line = line_index;
560 nstart_index = current_line->
index;
567 current_line = previous_line;
569 start_line = current_line;
571 fw =
es->format_rect.right -
es->format_rect.left;
572 current_position =
es->text + current_line->
index;
575 if (current_line != start_line)
577 if (!current_line || current_line->
index + delta > current_position -
es->text)
584 if (new_line ==
NULL)
587 new_line->
next = previous_line->
next;
588 previous_line->
next = new_line;
589 current_line = new_line;
592 else if (current_line->
index + delta < current_position - es->
text)
595 previous_line->
next = current_line->
next;
597 current_line = previous_line->
next;
603 if (current_position -
es->text > iend)
609 current_line->
index = current_position -
es->text;
613 cp = current_position;
615 if (*
cp ==
'\n')
break;
616 if ((*
cp ==
'\r') && (*(
cp + 1) ==
'\n'))
625 }
else if ((
cp > current_position) && (*(
cp - 1) ==
'\r')) {
628 }
else if (*
cp ==
'\n') {
641 if (current_line->
ssa)
649 else current_line->
width = 0;
656 if (current_line->
width > fw && fw >
es->char_width) {
666 if (
d > 1.2f)
d -= 0.2f;
675 if (current_line->
ssa)
683 }
while (prev && current_line->
width > fw);
693 if (current_line->
ssa)
701 current_line->
width -= piDx[prev];
703 }
while ( prev > 0 && current_line->
width > fw);
709 prev = (fw /
es->char_width);
714 if (current_line->
index == nstart_index && istart > current_line->
index + prev)
715 istart = current_line->
index + prev;
718 else if (current_line == start_line &&
719 current_line->
index != nstart_index && orig_net_length < prev)
723 nstart_line = line_index;
724 nstart_index = current_line->
index;
725 istart = current_line->
index + orig_net_length;
734 if (current_line->
ssa)
740 current_line->
width = 0;
742 else current_line->
width = 0;
744 else if (current_line == start_line &&
745 current_line->
index != nstart_index &&
750 nstart_line = line_index;
751 nstart_index = current_line->
index;
752 istart = current_line->
index + orig_net_length;
758 switch (current_line->
ending) {
773 es->text_width =
max(
es->text_width, current_line->
width);
774 current_position += current_line->
length;
775 previous_line = current_line;
778 if ((line_index < es->y_offset) || (line_index >
es->y_offset + vlc))
781 current_line = current_line->
next;
793 pnext = current_line->
next;
796 current_line = pnext;
804 current_line->
index += delta;
805 current_line = current_line->
next;
818 rc.
top =
es->format_rect.top + nstart_line *
es->line_height -
819 (
es->y_offset *
es->line_height);
822 rc.
left =
es->format_rect.left;
829 rc.
right =
es->format_rect.right;
833 rc.
left =
es->format_rect.left;
834 rc.
right =
es->format_rect.right;
839 if (line_count < es->line_count)
841 else if (line_count >
es->line_count)
842 rc.
bottom = line_count *
es->line_height;
844 rc.
bottom = line_index *
es->line_height;
846 rc.
bottom -= (
es->y_offset *
es->line_height);
865 es->text_width =
size->cx;
887 INT line = (
y -
es->format_rect.top) /
es->line_height +
es->y_offset;
891 while ((
line > 0) && line_def->next) {
892 line_index += line_def->length;
893 line_def = line_def->next;
897 x +=
es->x_offset -
es->format_rect.left;
899 x -= (
es->format_rect.right -
es->format_rect.left) - line_def->width;
901 x -= ((
es->format_rect.right -
es->format_rect.left) - line_def->width) / 2;
902 if (
x >= line_def->width) {
904 *after_wrap = (line_def->ending ==
END_WRAP);
905 return line_index + line_def->net_length;
907 if (x <= 0 || !line_def->
ssa) {
917 *after_wrap = ((
index == line_index + line_def->net_length) &&
924 x -=
es->format_rect.left;
930 INT indent = (
es->format_rect.right -
es->format_rect.left) -
es->text_width;
955 if (
x + xoff > 0 || !
es->ssa)
972 else if (
x >
size->cx)
1000 *
x =
min(
max(*
x,
es->format_rect.left),
es->format_rect.right - 1);
1001 *
y =
min(
max(*
y,
es->format_rect.top),
es->format_rect.bottom - 1);
1018 return es->line_count - 1;
1023 line_def =
es->first_line_def;
1025 while ((
index >= 0) && line_def->
next) {
1027 line_def = line_def->
next;
1046 if (
line >=
es->line_count)
1050 line_def =
es->first_line_def;
1053 while ((
index >= 0) && line_def->
next) {
1054 line_index += line_def->
length;
1055 line_def = line_def->
next;
1060 line_index += line_def->
length;
1061 line_def = line_def->
next;
1095 line_def =
es->first_line_def;
1097 while ((
index >= 0) && line_def->
next) {
1098 line_def = line_def->
next;
1126 y = (
l -
es->y_offset) *
es->line_height;
1128 if (after_wrap && (
li ==
index) &&
l) {
1130 line_def =
es->first_line_def;
1132 line_def = line_def->
next;
1137 y -=
es->line_height;
1142 line_def =
es->first_line_def;
1144 line_def = line_def->
next;
1146 lw = line_def->
width;
1147 w =
es->format_rect.right -
es->format_rect.left;
1155 x = (lw > 0 ?
es->x_offset :
x -
es->x_offset);
1183 xoff +=
es->char_width * leftover;
1214 w =
es->format_rect.right -
es->format_rect.left;
1215 if (
w >
es->text_width)
1218 x +=
w -
es->text_width;
1220 x += (
w -
es->text_width) / 2;
1226 x +=
es->format_rect.left;
1227 y +=
es->format_rect.top;
1249 rc->
top =
es->format_rect.top + (
line -
es->y_offset) *
es->line_height;
1253 line_def =
es->first_line_def;
1256 while ((
index >= 0) && line_def->
next) {
1257 line_index += line_def->
length;
1258 line_def = line_def->
next;
1263 line_index += line_def->
length;
1264 line_def = line_def->
next;
1273 rc->
top =
es->format_rect.top;
1283 pt3+=
es->format_rect.left;
1293 es->text_length = (
UINT)-1;
1317 TRACE(
"Synchronizing with 32-bit ANSI buffer\n");
1323 ERR(
"no buffer ... please report\n");
1330 if(!
es->hloc32W)
return;
1338 if(countW_new >
es->buffer_size + 1)
1341 TRACE(
"Resizing 32-bit UNICODE buffer from %d+1 to %d WCHARs\n",
es->buffer_size, countW_new);
1345 es->hloc32W = hloc32W_new;
1347 TRACE(
"Real new size %d+1 WCHARs\n",
es->buffer_size);
1350 WARN(
"FAILED! Will synchronize partially\n");
1372 WARN(
"edit hwnd %p already destroyed\n",
es->hwndSelf);
1376 if (!
es->lock_count) {
1377 ERR(
"lock_count == 0 ... please report\n");
1381 ERR(
"es->text == 0 ... please report\n");
1385 if (force || (
es->lock_count == 1)) {
1393 TRACE(
"Synchronizing with 32-bit ANSI buffer\n");
1394 TRACE(
"%d WCHARs translated to %d bytes\n", countW, countA_new);
1396 if(countA_new > countA)
1400 TRACE(
"Resizing 32-bit ANSI buffer from %d to %d bytes\n", countA, alloc_size);
1404 es->hloc32A = hloc32A_new;
1406 TRACE(
"Real new size %d bytes\n", countA);
1409 WARN(
"FAILED! Will synchronize partially\n");
1420 ERR(
"no buffer ... please report\n");
1441 TRACE(
"trying to ReAlloc to %d+1 characters\n",
size);
1449 TRACE(
"Old 32 bit handle %p, new handle %p\n",
es->hloc32W, hNew32W);
1450 es->hloc32W = hNew32W;
1457 if (
es->buffer_size <
size) {
1458 WARN(
"FAILED ! We now have %d+1\n",
es->buffer_size);
1462 TRACE(
"We now have %d+1\n",
es->buffer_size);
1479 if (size <= es->undo_buffer_size)
1482 TRACE(
"trying to ReAlloc to %d+1\n",
size);
1486 es->undo_buffer_size = alloc_size/
sizeof(
WCHAR) - 1;
1491 WARN(
"FAILED ! We now have %d+1\n",
es->undo_buffer_size);
1505 es->flags &= ~EF_UPDATE;
1520 es->flags &= ~EF_UPDATE;
1565 if ((el < es->y_offset) || (sl >
es->y_offset + vlc))
1570 if (sl < es->y_offset) {
1574 if (el >
es->y_offset + vlc) {
1575 el =
es->y_offset + vlc;
1591 for (
l = sl + 1 ;
l < el ;
l++) {
1649 UINT old_start =
es->selection_start;
1650 UINT old_end =
es->selection_end;
1655 end =
es->selection_end;
1661 es->selection_end =
end;
1665 es->flags &= ~EF_AFTER_WRAP;
1683 if (
end != old_start)
1693 if (old_start >
end )
1721 si.
nMax =
es->line_count - 1;
1722 si.
nPage = (
es->format_rect.bottom -
es->format_rect.top) /
es->line_height;
1724 TRACE(
"SB_VERT, nMin=%d, nMax=%d, nPage=%d, nPos=%d\n",
1735 si.
nMax =
es->text_width - 1;
1736 si.
nPage =
es->format_rect.right -
es->format_rect.left;
1738 TRACE(
"SB_HORZ, nMin=%d, nMax=%d, nPage=%d, nPos=%d\n",
1757 INT x_offset_in_pixels;
1758 INT lines_per_page = (
es->format_rect.bottom -
es->format_rect.top) /
1763 x_offset_in_pixels =
es->x_offset;
1771 if (-
dx > x_offset_in_pixels)
1772 dx = -x_offset_in_pixels;
1773 if (
dx >
es->text_width - x_offset_in_pixels)
1774 dx =
es->text_width - x_offset_in_pixels;
1775 nyoff =
max(0,
es->y_offset +
dy);
1776 if (nyoff >=
es->line_count - lines_per_page)
1777 nyoff =
max(0,
es->line_count - lines_per_page);
1778 dy = (
es->y_offset - nyoff) *
es->line_height;
1783 es->y_offset = nyoff;
1787 es->x_offset +=
dx /
es->char_width;
1815 dx *=
es->char_width;
1840 if (
es->y_offset <
es->line_count - 1)
1845 dy = -(
es->format_rect.bottom -
es->format_rect.top) /
es->line_height;
1848 if (
es->y_offset <
es->line_count - 1)
1849 dy = (
es->format_rect.bottom -
es->format_rect.top) /
es->line_height;
1857 if(
es->y_offset +
dy >
es->line_count - vlc)
1858 dy =
max(
es->line_count - vlc, 0) -
es->y_offset;
1920 EDIT_ImmSetCompositionWindow(
es,
pt);
1939 INT cw =
es->char_width;
1947 if (
l >=
es->y_offset + vlc)
1948 dy =
l - vlc + 1 -
es->y_offset;
1949 if (l < es->y_offset)
1950 dy =
l -
es->y_offset;
1951 ww =
es->format_rect.right -
es->format_rect.left;
1952 if (x < es->format_rect.left)
1954 if (
x >
es->format_rect.right)
1956 if (
dy ||
dx || (
es->y_offset && (
es->line_count -
es->y_offset < vlc)))
1959 if(
es->x_offset +
dx + ww >
es->text_width)
1960 dx =
es->text_width - ww -
es->x_offset;
1961 if(
dx ||
dy || (
es->y_offset && (
es->line_count -
es->y_offset < vlc)))
1970 format_width =
es->format_rect.right -
es->format_rect.left;
1971 if (x < es->format_rect.left) {
1976 }
while ((
x < goal) &&
es->x_offset);
1979 }
else if (
x >
es->format_rect.right) {
1987 }
while ((
x > goal) && (x_last >
es->format_rect.right));
2005 INT e =
es->selection_end;
2010 (
es->text[
e - 1] ==
'\r') && (
es->text[
e] ==
'\n')) {
2012 if (
e && (
es->text[
e - 1] ==
'\r'))
2032 INT s =
es->selection_start;
2033 INT e =
es->selection_end;
2075 INT e =
es->selection_end;
2080 if (
es->text[
e] ==
'\n')
2082 else if ((
es->text[
e] ==
'\r') && (
es->text[
e + 1] ==
'\n'))
2124 INT s =
es->selection_start;
2125 INT e =
es->selection_end;
2132 y + (
es->format_rect.bottom -
es->format_rect.top),
2152 INT s =
es->selection_start;
2153 INT e =
es->selection_end;
2160 y - (
es->format_rect.bottom -
es->format_rect.top),
2180 INT s =
es->selection_start;
2181 INT e =
es->selection_end;
2202 INT s =
es->selection_start;
2203 INT e =
es->selection_end;
2233 INT s =
es->selection_start;
2234 INT e =
es->selection_end;
2266 HFONT hUnderline = 0;
2282 if (
es->composition_len == 0)
2301 es->tabs_count,
es->tabs,
es->format_rect.left -
es->x_offset));
2311 if (
es->composition_len == 0)
2349 if ((line < es->y_offset) || (
line >
es->y_offset + vlc) || (
line >=
es->line_count))
2363 int line_idx =
line;
2370 while (line_def && line_idx)
2372 line_def = line_def->
next;
2375 w =
es->format_rect.right -
es->format_rect.left;
2376 lw = line_def->
width;
2383 x +=
es->format_rect.left;
2390 s =
min(
es->selection_start,
es->selection_end);
2391 e =
max(
es->selection_start,
es->selection_end);
2398 else if (
rev && (
s !=
e) &&
2420 es->format_rect.right =
max(
es->format_rect.right,
es->format_rect.left +
es->char_width);
2423 INT fw, vlc, max_x_offset, max_y_offset;
2426 es->format_rect.bottom =
es->format_rect.top + vlc *
es->line_height;
2429 fw =
es->format_rect.right -
es->format_rect.left;
2430 max_x_offset =
es->text_width - fw;
2431 if(max_x_offset < 0) max_x_offset = 0;
2432 if(
es->x_offset > max_x_offset)
2433 es->x_offset = max_x_offset;
2436 max_y_offset =
es->line_count - vlc;
2437 if(max_y_offset < 0) max_y_offset = 0;
2438 if(
es->y_offset > max_y_offset)
2439 es->y_offset = max_y_offset;
2446 es->format_rect.bottom =
es->format_rect.top +
es->line_height;
2450 es->format_rect.bottom =
min(
es->format_rect.bottom, ClientRect.
bottom);
2476 es->format_rect.left++;
2477 es->format_rect.right--;
2479 if (
es->format_rect.bottom -
es->format_rect.top
2480 >=
es->line_height + 2)
2482 es->format_rect.top++;
2483 es->format_rect.bottom--;
2489 es->format_rect.left +=
bw;
2490 es->format_rect.right -=
bw;
2491 if (
es->format_rect.bottom -
es->format_rect.top
2492 >=
es->line_height + 2 * bh)
2494 es->format_rect.top += bh;
2495 es->format_rect.bottom -= bh;
2499 es->format_rect.left +=
es->left_margin;
2500 es->format_rect.right -=
es->right_margin;
2546 es->flags &= ~EF_USE_SOFTBRK;
2549 FIXME(
"soft break enabled, not implemented\n");
2574 hLocal =
es->hloc32W;
2580 UINT countA, alloc_size;
2581 TRACE(
"Allocating 32-bit ANSI alias buffer\n");
2586 ERR(
"Could not allocate %d bytes for 32-bit ANSI alias buffer\n", alloc_size);
2593 hLocal =
es->hloc32A;
2599 es->hlocapp = hLocal;
2601 TRACE(
"Returning %p, LocalSize() = %ld\n", hLocal,
LocalSize(hLocal));
2614 INT line_len, dst_len;
2618 if (
line >=
es->line_count)
2628 if(dst_len <= line_len)
2643 if(!
ret && line_len)
2692 TRACE(
"%s, can_undo %d, send_update %d\n",
2693 debugstr_w(lpsz_replace), can_undo, send_update);
2695 s =
es->selection_start;
2696 e =
es->selection_end;
2699 if ((
s ==
e) && !strl)
2704 size = tl - (
e -
s) + strl;
2710 if ((honor_limit) && (
size >
es->buffer_limit))
2714 if (
es->buffer_limit < (tl - (
e-
s)))
2717 strl =
min(strl,
es->buffer_limit - (tl - (
e-
s)));
2725 TRACE(
"deleting stuff.\n");
2739 for (
p =
es->text + tl ;
p >=
es->text +
s ;
p--)
2741 for (
i = 0 ,
p =
es->text +
s ;
i < strl ;
i++)
2742 p[
i] = lpsz_replace[
i];
2751 INT st =
min(
es->selection_start,
es->selection_end);
2756 strl -
abs(
es->selection_end -
es->selection_start),
hrgn);
2762 for (
i = 0 ,
p =
es->text ;
i <
e -
s ;
i++)
2766 abs(
es->selection_end -
es->selection_start) - strl,
hrgn);
2774 INT fw =
es->format_rect.right -
es->format_rect.left;
2779 while ((
es->text_width > fw) &&
s + strl >=
s) {
2782 es->text_length = -1;
2794 if (!
es->undo_insert_count && (*
es->undo_text && (
s ==
es->undo_position))) {
2798 (
es->undo_text + utl)[
e -
s] = 0;
2799 }
else if (!
es->undo_insert_count && (*
es->undo_text && (
e ==
es->undo_position))) {
2802 for (
p =
es->undo_text + utl ;
p >=
es->undo_text ;
p--)
2804 for (
i = 0 ,
p =
es->undo_text ;
i <
e -
s ;
i++)
2806 es->undo_position =
s;
2811 es->undo_text[
e -
s] = 0;
2812 es->undo_position =
s;
2815 es->undo_insert_count = 0;
2821 if ((
s ==
es->undo_position) ||
2822 ((
es->undo_insert_count) &&
2823 (
s ==
es->undo_position +
es->undo_insert_count)))
2828 es->undo_insert_count += strl;
2831 es->undo_position =
s;
2832 es->undo_insert_count = strl;
2834 *
es->undo_text =
'\0';
2847 INT delta = strl -
abs(
es->selection_end -
es->selection_start);
2849 if (delta < 0 && es->x_offset)
2851 if (
abs(delta) >
es->x_offset)
2854 es->x_offset += delta;
2877 es->flags &= ~EF_UPDATE;
2897 WARN(
"called with NULL handle\n");
2924 ERR(
"Could not allocate new unicode buffer\n");
2935 es->hloc32W = hloc32W_new;
2947 es->x_offset =
es->y_offset = 0;
2948 es->selection_start =
es->selection_end = 0;
2950 es->flags &= ~EF_MODIFIED;
2951 es->flags &= ~EF_UPDATE;
3007 INT default_left_margin = 0;
3008 INT default_right_margin = 0;
3020 default_left_margin =
width / 2;
3021 default_right_margin =
width / 2;
3026 default_left_margin =
es->left_margin;
3027 default_right_margin =
es->right_margin;
3031 default_left_margin =
width / 2;
3032 default_right_margin =
width / 2;
3040 es->format_rect.left -=
es->left_margin;
3044 es->left_margin = default_left_margin;
3045 es->format_rect.left +=
es->left_margin;
3049 es->format_rect.right +=
es->right_margin;
3053 es->right_margin = default_right_margin;
3054 es->format_rect.right -=
es->right_margin;
3062 TRACE(
"left=%d, right=%d\n",
es->left_margin,
es->right_margin);
3078 if (
es->password_char ==
c)
3082 es->password_char =
c;
3088 es->style &= ~ES_PASSWORD;
3132 if (
es->word_break_proc == wbp)
3135 es->word_break_proc = wbp;
3170 TRACE(
"before UNDO:insertion length = %d, deletion buffer = %s\n",
3182 TRACE(
"after UNDO:insertion length = %d, deletion buffer = %s\n",
3236 INT s =
min(
es->selection_start,
es->selection_end);
3237 INT e =
max(
es->selection_start,
es->selection_end);
3295 if (
es->bCaptureState)
3316 static const WCHAR cr_lfW[] = {
'\r',
'\n',0};
3324 static const WCHAR tabW[] = {
'\t',0};
3332 if (
es->selection_start !=
es->selection_end)
3403 ERR(
"unknown menu item, please report\n");
3448 if (
x == -1 &&
y == -1)
3457 WIN_GetRectangles(
es->hwndSelf, COORDS_SCREEN,
NULL, &rc );
3483 if(!
count)
return 0;
3506 HWND hLBox =
es->hwndListBox;
3518 TRACE_(combo)(
"[%p]: handling msg %x (%x)\n",
es->hwndSelf,
msg,
key);
3625 if (
es->selection_start !=
es->selection_end) {
3690 FIXME(
"Ctrl+Backspace\n");
3710 es->flags &= ~EF_FOCUSED;
3716 es->wheelDeltaRemainder = 0;
3718 if (
es->hwndListBox ==
NULL) {
3728 es->flags &= ~EF_FOCUSED;
3734 es->wheelDeltaRemainder = 0;
3750 INT e =
es->selection_end;
3755 es->bCaptureState =
TRUE;
3765 es->region_posx =
es->region_posy = 0;
3781 es->bCaptureState =
TRUE;
3787 es->region_posx =
es->region_posy = 0;
3804 if (
es->bCaptureState) {
3848 es->region_posx = (prex <
x) ? -1 : ((prex >
x) ? 1 : 0);
3849 es->region_posy = (prey <
y) ? -1 : ((prey >
y) ? 1 : 0);
3917 es->format_rect.top,
3918 es->format_rect.right,
3919 es->format_rect.bottom);
3927 if (!
es->bEnableState)
3932 for (
i =
es->y_offset ;
i <=
min(
es->y_offset + vlc,
es->y_offset +
es->line_count - 1) ;
i++) {
4007 es->line_height =
tm.tmHeight;
4008 es->char_width =
tm.tmAveCharWidth;
4067 if (!unicode &&
text)
4079 ERR(
"SetSel may generate UPDATE message whose handler may reset "
4096 es->flags &= ~EF_MODIFIED;
4155 DWORD style_change_mask;
4165 new_style =
style->styleNew & style_change_mask;
4174 new_style &= ~ES_UPPERCASE;
4177 es->style = (
es->style & ~style_change_mask) | new_style;
4181 WARN (
"Invalid style change %ld\n",
which);
4194 if ((
key ==
VK_BACK) && (key_data & 0x2000)) {
4213 if (
es->region_posx < 0) {
4215 }
else if (
es->region_posx > 0) {
4241 fw =
es->format_rect.right -
es->format_rect.left;
4244 TRACE(
"SB_LINELEFT\n");
4246 dx = -
es->char_width;
4249 TRACE(
"SB_LINERIGHT\n");
4250 if (
es->x_offset <
es->text_width)
4251 dx =
es->char_width;
4254 TRACE(
"SB_PAGELEFT\n");
4259 TRACE(
"SB_PAGERIGHT\n");
4260 if (
es->x_offset <
es->text_width)
4269 TRACE(
"SB_RIGHT\n");
4270 if (
es->x_offset <
es->text_width)
4271 dx =
es->text_width -
es->x_offset;
4282 if(pos < 0 || pos > 100)
return 0;
4284 fw =
es->format_rect.right -
es->format_rect.left;
4285 new_x =
pos * (
es->text_width - fw) / 100;
4286 dx =
es->text_width ? (new_x -
es->x_offset) : 0;
4290 TRACE(
"SB_THUMBPOSITION %d\n",
pos);
4291 es->flags &= ~EF_HSCROLL_TRACK;
4298 if(pos < 0 || pos > 100)
return 0;
4300 fw =
es->format_rect.right -
es->format_rect.left;
4301 new_x =
pos * (
es->text_width - fw) / 100;
4302 dx =
es->text_width ? (new_x -
es->x_offset) : 0;
4311 TRACE(
"SB_ENDSCROLL\n");
4327 INT fw =
es->format_rect.right -
es->format_rect.left;
4328 ret =
es->text_width ?
es->x_offset * 100 / (
es->text_width - fw) : 0;
4330 TRACE(
"EM_GETTHUMB: returning %ld\n",
ret);
4334 TRACE(
"EM_LINESCROLL16\n");
4339 ERR(
"undocumented WM_HSCROLL action %d (0x%04x), please report\n",
4345 INT fw =
es->format_rect.right -
es->format_rect.left;
4347 if(
es->x_offset +
dx + fw >
es->text_width)
4348 dx =
es->text_width - fw -
es->x_offset;
4388 TRACE(
"SB_BOTTOM\n");
4389 dy =
es->line_count - 1 -
es->y_offset;
4401 if(pos < 0 || pos > 100)
return 0;
4403 new_y =
pos * (
es->line_count - vlc) / 100;
4404 dy =
es->line_count ? (new_y -
es->y_offset) : 0;
4405 TRACE(
"line_count=%d, y_offset=%d, pos=%d, dy = %d\n",
4410 TRACE(
"SB_THUMBPOSITION %d\n",
pos);
4411 es->flags &= ~EF_VSCROLL_TRACK;
4419 if(pos < 0 || pos > 100)
return 0;
4421 new_y =
pos * (
es->line_count - vlc) / 100;
4422 dy =
es->line_count ? (new_y -
es->y_offset) : 0;
4423 TRACE(
"line_count=%d, y_offset=%d, pos=%d, dy = %d\n",
4434 TRACE(
"SB_ENDSCROLL\n");
4451 ret =
es->line_count ?
es->y_offset * 100 / (
es->line_count - vlc) : 0;
4453 TRACE(
"EM_GETTHUMB: returning %ld\n",
ret);
4462 ERR(
"undocumented WM_VSCROLL action %d (0x%04x), please report\n",
4510 ERR(
"Unable to allocate IME CompositionString\n");
4516 lpCompStr[buflen/
sizeof(
WCHAR)] = 0;
4531 ERR(
"Unable to allocate IME Attribute String\n");
4537 lpCompStrAttr[dwBufLenAttr] = 0;
4543 if (
es->selection_end <
es->composition_start)
4544 es->composition_start =
es->selection_end;
4547 es->selection_start =
es->composition_start;
4549 if (
es->composition_len > 0)
4550 es->selection_end =
es->composition_start +
es->composition_len;
4552 es->selection_end =
es->selection_start;
4555 es->composition_len =
abs(
es->composition_start -
es->selection_end);
4557 es->selection_start =
es->composition_start;
4558 es->selection_end =
es->selection_start +
es->composition_len;
4579 ERR(
"Unable to alloc buffer for IME string\n");
4584 lpResultStr[buflen/
sizeof(
WCHAR)] = 0;
4588 if (
es->selection_end <
es->composition_start)
4589 es->composition_start =
es->selection_end;
4591 es->selection_start =
es->composition_start;
4592 es->selection_end =
es->composition_start +
es->composition_len;
4594 es->composition_start =
es->selection_end;
4595 es->composition_len = 0;
4607 if (
es->selection_start !=
es->selection_end)
4610 if (
es->composition_len == 0 &&
es->selection_start !=
es->selection_end)
4613 es->composition_start =
es->selection_end;
4652 TRACE(
"Creating %s edit control, style = %08x\n",
4653 unicode ?
"Unicode" :
"ANSI", lpcs->
style);
4665 es->is_unicode = unicode;
4687 es->style &= ~ES_UPPERCASE;
4695 es->style &= ~ES_PASSWORD;
4699 es->style &= ~ES_CENTER;
4700 es->style &= ~WS_HSCROLL;
4701 es->style &= ~ES_AUTOHSCROLL;
4706 es->style &= ~ES_CENTER;
4707 es->style &= ~WS_HSCROLL;
4708 es->style &= ~WS_VSCROLL;
4710 es->password_char =
'*';
4720 es->undo_buffer_size =
es->buffer_size;
4739 es->style &= ~WS_BORDER;
4788 es->selection_start =
es->selection_end = 0;
4817 if (
es->hloc32W && (
es->hloc32W !=
es->hlocapp)) {
4820 if (
es->hloc32A && (
es->hloc32A !=
es->hlocapp)) {
4824 pc =
es->first_line_def;
4874 ERR(
"Wrong window class for Edit! fnId 0x%x\n",pWnd->
fnid);
4965 FIXME(
"undocumented message 0x%x, please report\n",
msg);
5059 es->style &= ~ES_READONLY;
5062 if (old_style ^
es->style)
5083 WCHAR charW =
es->password_char;
5142 if (
es->hwndListBox)
5164 strng[1] =
wParam & 0xff;
5184 if (
es->hwndListBox)
5201 if (
wParam <= 0x000fffff)
5335 case WM_STYLECHANGED:
5339 case WM_STYLECHANGING:
5358 UINT pulScrollLines = 3;
5365 wheelDelta = GET_WHEEL_DELTA_WPARAM(
wParam);
5367 if ((wheelDelta < 0 && es->wheelDeltaRemainder < 0) ||
5368 (wheelDelta > 0 &&
es->wheelDeltaRemainder > 0))
5369 es->wheelDeltaRemainder += wheelDelta;
5371 es->wheelDeltaRemainder = wheelDelta;
5372 if (
es->wheelDeltaRemainder && pulScrollLines)
5375 pulScrollLines = (
int)
min((
UINT)
es->line_count, pulScrollLines);
5377 es->wheelDeltaRemainder -=
WHEEL_DELTA * cLineScroll / (
int)pulScrollLines;
5388 lParam &= ~ISC_SHOWUICOMPOSITIONWINDOW;
5408 case WM_IME_STARTCOMPOSITION:
5414 es->composition_start =
es->selection_end;
5415 es->composition_len = 0;
5419 case WM_IME_COMPOSITION:
5426 case WM_IME_ENDCOMPOSITION:
5430 if (
es->composition_len > 0)
5433 es->selection_end =
es->selection_start;
5434 es->composition_len= 0;
5457 case IMR_QUERYCHARPOSITION:
5460 IMECHARPOSITION *chpos = (IMECHARPOSITION *)
lParam;
5465 chpos->cLineHeight =
es->line_height;
5466 chpos->rcDocument =
es->format_rect;
ACPI_SIZE strlen(const char *String)
#define WINE_DEFAULT_DEBUG_CHANNEL(t)
static const WCHAR nameW[]
LONG WINAPI ImmGetCompositionStringW(HIMC hIMC, DWORD dwIndex, LPVOID lpBuf, DWORD dwBufLen)
LRESULT WINAPI EditWndProcW(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
LRESULT WINAPI EditWndProcA(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
static void EDIT_WM_Paint(EDITSTATE *es, HDC hdc)
static void EDIT_MoveEnd(EDITSTATE *es, BOOL extend, BOOL ctrl)
static void EDIT_PaintLine(EDITSTATE *es, HDC dc, INT line, BOOL rev)
static void EDIT_GetResultStr(HIMC hIMC, EDITSTATE *es)
static BOOL EDIT_IsInsideDialog(EDITSTATE *es)
static INT get_vertical_line_count(EDITSTATE *es)
static INT EDIT_WordBreakProc(EDITSTATE *es, LPWSTR s, INT index, INT count, INT action)
static LRESULT EDIT_WM_LButtonDblClk(EDITSTATE *es)
static void EDIT_MoveBackward(EDITSTATE *es, BOOL extend)
static LRESULT EDIT_WM_Char(EDITSTATE *es, WCHAR c)
static void EDIT_WM_SetFont(EDITSTATE *es, HFONT font, BOOL redraw)
static SCRIPT_STRING_ANALYSIS EDIT_UpdateUniscribeData(EDITSTATE *es, HDC dc, INT line)
static void EDIT_EM_ReplaceSel(EDITSTATE *es, BOOL can_undo, const WCHAR *lpsz_replace, UINT strl, BOOL send_update, BOOL honor_limit)
static void EDIT_CalcLineWidth_SL(EDITSTATE *es)
static LRESULT EDIT_WM_MButtonDown(EDITSTATE *es)
static void EDIT_EM_ScrollCaret(EDITSTATE *es)
static void EDIT_InvalidateUniscribeData_linedef(LINEDEF *line_def)
#define ROUND_TO_GROW(size)
static BOOL EDIT_CheckCombo(EDITSTATE *es, UINT msg, INT key)
static void EDIT_SetRectNP(EDITSTATE *es, const RECT *rc)
static BOOL EDIT_EM_FmtLines(EDITSTATE *es, BOOL add_eol)
static void EDIT_WM_Copy(EDITSTATE *es)
static void EDIT_ML_InvalidateText(EDITSTATE *es, INT start, INT end)
static void EDIT_GetLineRect(EDITSTATE *es, INT line, INT scol, INT ecol, LPRECT rc)
static BOOL EDIT_EM_LineScroll_internal(EDITSTATE *es, INT dx, INT dy)
static void EDIT_SetCaretPos(EDITSTATE *es, INT pos, BOOL after_wrap)
static void EDIT_GetCompositionStr(HIMC hIMC, LPARAM CompFlag, EDITSTATE *es)
static void EDIT_BuildLineDefs_ML(EDITSTATE *es, INT istart, INT iend, INT delta, HRGN hrgn)
static void EDIT_MoveUp_ML(EDITSTATE *es, BOOL extend)
static INT EDIT_PaintText(EDITSTATE *es, HDC dc, INT x, INT y, INT line, INT col, INT count, BOOL rev)
static LRESULT EDIT_EM_CharFromPos(EDITSTATE *es, INT x, INT y)
static void EDIT_MoveHome(EDITSTATE *es, BOOL extend, BOOL ctrl)
static LRESULT EDIT_WM_HScroll(EDITSTATE *es, INT action, INT pos)
static void EDIT_WM_Cut(EDITSTATE *es)
static void EDIT_EM_SetPasswordChar(EDITSTATE *es, WCHAR c)
static SCRIPT_STRING_ANALYSIS EDIT_UpdateUniscribeData_linedef(EDITSTATE *es, HDC dc, LINEDEF *line_def)
struct tagLINEDEF LINEDEF
static void EDIT_AdjustFormatRect(EDITSTATE *es)
static INT EDIT_WM_GetText(const EDITSTATE *es, INT count, LPWSTR dst)
static void EDIT_WM_ContextMenu(EDITSTATE *es, INT x, INT y)
static LRESULT EDIT_WM_MouseMove(EDITSTATE *es, INT x, INT y)
static void EDIT_MovePageUp_ML(EDITSTATE *es, BOOL extend)
static void EDIT_LockBuffer(EDITSTATE *es)
static void EDIT_UnlockBuffer(EDITSTATE *es, BOOL force)
static LRESULT EDIT_WM_NCDestroy(EDITSTATE *es)
static LRESULT EDIT_WM_LButtonDown(EDITSTATE *es, DWORD keys, INT x, INT y)
static BOOL notify_parent(const EDITSTATE *es, INT code)
static INT EDIT_EM_LineIndex(const EDITSTATE *es, INT line)
static void EDIT_ConfinePoint(const EDITSTATE *es, LPINT x, LPINT y)
static HLOCAL EDIT_EM_GetHandle(EDITSTATE *es)
static INT EDIT_EM_GetLine(EDITSTATE *es, INT line, LPWSTR dst)
static BOOL EDIT_EM_Undo(EDITSTATE *es)
static UINT get_text_length(EDITSTATE *es)
static void EDIT_InvalidateUniscribeData(EDITSTATE *es)
static void EDIT_WM_Paste(EDITSTATE *es)
static void EDIT_UpdateScrollInfo(EDITSTATE *es)
static void EDIT_MovePageDown_ML(EDITSTATE *es, BOOL extend)
static LRESULT EDIT_WM_KillFocus(HTHEME theme, EDITSTATE *es)
static void EDIT_MoveWordForward(EDITSTATE *es, BOOL extend)
static LRESULT EDIT_WM_SysKeyDown(EDITSTATE *es, INT key, DWORD key_data)
static LRESULT EDIT_EM_GetThumb(EDITSTATE *es)
static LRESULT EDIT_WM_NCCreate(HWND hwnd, LPCREATESTRUCTW lpcs)
static LRESULT EDIT_WM_LButtonUp(EDITSTATE *es)
static void EDIT_WM_Clear(EDITSTATE *es)
static BOOL EDIT_EM_CanUndo(const EDITSTATE *es)
static void EDIT_EM_EmptyUndoBuffer(EDITSTATE *es)
static INT EDIT_CharFromPos(EDITSTATE *es, INT x, INT y, LPBOOL after_wrap)
static void EDIT_EM_SetMargins(EDITSTATE *es, INT action, WORD left, WORD right, BOOL repaint)
static void EDIT_MoveWordBackward(EDITSTATE *es, BOOL extend)
static void text_buffer_changed(EDITSTATE *es)
static HBRUSH EDIT_NotifyCtlColor(EDITSTATE *es, HDC hdc)
static void EDIT_WM_SetFocus(HTHEME theme, EDITSTATE *es)
static void EDIT_EM_SetHandle(EDITSTATE *es, HLOCAL hloc)
static LRESULT EDIT_WM_Create(EDITSTATE *es, const WCHAR *name)
static void EDIT_InvalidateText(EDITSTATE *es, INT start, INT end)
static LRESULT EDIT_WM_KeyDown(EDITSTATE *es, INT key)
static void EDIT_EM_SetLimitText(EDITSTATE *es, UINT limit)
static void EDIT_WM_Timer(EDITSTATE *es)
static LRESULT EDIT_EM_PosFromChar(EDITSTATE *es, INT index, BOOL after_wrap)
static void EDIT_MoveForward(EDITSTATE *es, BOOL extend)
static LRESULT EDIT_EM_Scroll(EDITSTATE *es, INT action)
static LRESULT EDIT_EM_GetSel(const EDITSTATE *es, PUINT start, PUINT end)
static void EDIT_EM_SetWordBreakProc(EDITSTATE *es, EDITWORDBREAKPROCW wbp)
static void EDIT_SL_InvalidateText(EDITSTATE *es, INT start, INT end)
static void EDIT_MoveDown_ML(EDITSTATE *es, BOOL extend)
static LRESULT EDIT_WM_StyleChanged(EDITSTATE *es, WPARAM which, const STYLESTRUCT *style)
static INT EDIT_CallWordBreakProc(EDITSTATE *es, INT start, INT index, INT count, INT action)
static INT EDIT_EM_LineFromChar(EDITSTATE *es, INT index)
static void EDIT_ContextMenuCommand(EDITSTATE *es, UINT id)
static LRESULT EDIT_WM_VScroll(EDITSTATE *es, INT action, INT pos)
static BOOL EDIT_MakeFit(EDITSTATE *es, UINT size)
static void EDIT_WM_SetText(EDITSTATE *es, LPCWSTR text)
static BOOL EDIT_MakeUndoFit(EDITSTATE *es, UINT size)
static void EDIT_UpdateTextRegion(EDITSTATE *es, HRGN hrgn, BOOL bErase)
static void EDIT_UpdateText(EDITSTATE *es, const RECT *rc, BOOL bErase)
static BOOL EDIT_EM_SetTabStops(EDITSTATE *es, INT count, const INT *tabs)
static BOOL EDIT_EM_SetSel(EDITSTATE *es, UINT start, UINT end, BOOL after_wrap)
static void EDIT_ImeComposition(HWND hwnd, LPARAM CompFlag, EDITSTATE *es)
static BOOL EDIT_EM_LineScroll(EDITSTATE *es, INT dx, INT dy)
static void EDIT_WM_Size(EDITSTATE *es, UINT action)
static INT EDIT_EM_LineLength(EDITSTATE *es, INT index)
static const WCHAR indent[]
static __inline const char * debugstr_an(const char *s, int n)
#define HeapFree(x, y, z)
#define WINE_DECLARE_DEBUG_CHANNEL(x)
#define WideCharToMultiByte
#define MultiByteToWideChar
static const WCHAR version[]
BOOL WINAPI ImmSetCompositionFontW(HIMC hIMC, LPLOGFONTW lplf)
BOOL WINAPI ImmIsIME(HKL hKL)
BOOL WINAPI ImmNotifyIME(HIMC hIMC, DWORD dwAction, DWORD dwIndex, DWORD_PTR dwValue)
BOOL WINAPI ImmSetCompositionWindow(HIMC hIMC, LPCOMPOSITIONFORM lpCompForm)
BOOL WINAPI ImmUnlockIMC(HIMC hIMC)
HIMC WINAPI ImmGetContext(HWND hWnd)
BOOL WINAPI ImmReleaseContext(HWND hWnd, HIMC hIMC)
LPINPUTCONTEXT WINAPI ImmLockIMC(HIMC hIMC)
#define ValidateHwnd(hwnd)
static void cleanup(void)
DWORD WINAPI GetProcessVersion(IN DWORD ProcessId)
BOOL WINAPI GetVersionExW(IN LPOSVERSIONINFOW lpVersionInformation)
HRESULT WINAPI ScriptStringFree(SCRIPT_STRING_ANALYSIS *pssa)
HRESULT WINAPI ScriptStringGetLogicalWidths(SCRIPT_STRING_ANALYSIS ssa, int *piDx)
HRESULT WINAPI ScriptStringAnalyse(HDC hdc, const void *pString, int cString, int cGlyphs, int iCharset, DWORD dwFlags, int iReqWidth, SCRIPT_CONTROL *psControl, SCRIPT_STATE *psState, const int *piDx, SCRIPT_TABDEF *pTabdef, const BYTE *pbInClass, SCRIPT_STRING_ANALYSIS *pssa)
HRESULT WINAPI ScriptStringOut(SCRIPT_STRING_ANALYSIS ssa, int iX, int iY, UINT uOptions, const RECT *prc, int iMinSel, int iMaxSel, BOOL fDisabled)
const SIZE *WINAPI ScriptString_pSize(SCRIPT_STRING_ANALYSIS ssa)
const int *WINAPI ScriptString_pcOutChars(SCRIPT_STRING_ANALYSIS ssa)
HRESULT WINAPI ScriptStringXtoCP(SCRIPT_STRING_ANALYSIS ssa, int iX, int *piCh, int *piTrailing)
HRESULT WINAPI ScriptStringCPtoX(SCRIPT_STRING_ANALYSIS ssa, int icp, BOOL fTrailing, int *pX)
HRESULT WINAPI ScriptBreak(const WCHAR *chars, int count, const SCRIPT_ANALYSIS *sa, SCRIPT_LOGATTR *la)
unsigned int(__cdecl typeof(jpeg_read_scanlines))(struct jpeg_decompress_struct *
unsigned short(__cdecl typeof(TIFFCurrentDirectory))(struct tiff *)
GLint GLint GLint GLint GLint x
GLuint GLuint GLsizei count
GLint GLint GLint GLint GLint GLint y
GLint GLint GLsizei width
GLenum GLuint GLenum GLsizei const GLchar * buf
GLuint GLsizei GLsizei * length
GLubyte GLubyte GLubyte GLubyte w
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble * u
LPVOID NTAPI GlobalLock(HGLOBAL hMem)
HLOCAL NTAPI LocalReAlloc(HLOCAL hMem, SIZE_T dwBytes, UINT uFlags)
BOOL NTAPI GlobalUnlock(HGLOBAL hMem)
HLOCAL NTAPI LocalAlloc(UINT uFlags, SIZE_T dwBytes)
LPVOID NTAPI LocalLock(HLOCAL hMem)
BOOL NTAPI LocalUnlock(HLOCAL hMem)
SIZE_T NTAPI LocalSize(HLOCAL hMem)
HGLOBAL NTAPI GlobalAlloc(UINT uFlags, SIZE_T dwBytes)
HLOCAL NTAPI LocalFree(HLOCAL hMem)
struct INPUTCONTEXTDX * LPINPUTCONTEXTDX
#define NI_COMPOSITIONSTR
#define GetWin32ClientInfo()
BOOL NTAPI NtUserSetWindowFNID(HWND hWnd, WORD fnID)
REFIID LPVOID DWORD_PTR dw
#define memcpy(s1, s2, n)
struct task_struct * current
static const char textA[]
static const WCHAR textW[]
static DWORD *static HFONT(WINAPI *pCreateFontIndirectExA)(const ENUMLOGFONTEXDVA *)
static float(__cdecl *square_half_float)(float x
static const CLSID *static CLSID *static const GUID VARIANT VARIANT *static IServiceProvider DWORD *static HMENU
static SCRIPT_CACHE SCRIPT_ANALYSIS * psa
void redraw(int x, int y, int cx, int cy)
static unsigned __int64 next
wchar_t const *const size_t const buffer_size
SCRIPT_STRING_ANALYSIS ssa
#define WM_CBLOSTTEXTFOCUS
const char * SPY_GetMsgName(UINT msg, HWND hWnd)
HBRUSH FASTCALL GetControlBrush(PWND pwnd, HDC hdc, UINT ctlType)
static const WCHAR editW[]
const struct builtin_class_descr EDIT_builtin_class
LRESULT WINAPI EditWndProc_common(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam, BOOL unicode)
static LRESULT DefWindowProcT(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam, BOOL unicode)
static const WCHAR empty_stringW[]
static DWORD get_app_version(void)
int WINAPI GetBkMode(_In_ HDC)
BOOL WINAPI GetTextMetricsW(_In_ HDC, _Out_ LPTEXTMETRICW)
HGDIOBJ WINAPI GetStockObject(_In_ int)
int WINAPI GetObjectW(_In_ HANDLE h, _In_ int c, _Out_writes_bytes_opt_(c) LPVOID pv)
int WINAPI GetClipBox(_In_ HDC, _Out_ LPRECT)
COLORREF WINAPI SetBkColor(_In_ HDC, _In_ COLORREF)
HRGN WINAPI CreateRectRgn(_In_ int, _In_ int, _In_ int, _In_ int)
LONG WINAPI GdiGetCharDimensions(HDC, LPTEXTMETRICW, LONG *)
COLORREF WINAPI GetTextColor(_In_ HDC)
int WINAPI IntersectClipRect(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int)
HGDIOBJ WINAPI GetCurrentObject(_In_ HDC, _In_ UINT)
HGDIOBJ WINAPI SelectObject(_In_ HDC, _In_ HGDIOBJ)
int WINAPI CombineRgn(_In_opt_ HRGN hrgnDest, _In_opt_ HRGN hrgnSrc1, _In_opt_ HRGN hrgnSrc2, _In_ int fnCombineMode)
COLORREF WINAPI GetBkColor(_In_ HDC)
#define CHINESEBIG5_CHARSET
BOOL WINAPI PatBlt(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int, _In_ DWORD)
BOOL WINAPI TextOutW(_In_ HDC hdc, _In_ int x, _In_ int y, _In_reads_(c) LPCWSTR lpString, _In_ int c)
int WINAPI FillRect(HDC, LPCRECT, HBRUSH)
HFONT WINAPI CreateFontIndirectW(_In_ const LOGFONTW *)
int WINAPI SetBkMode(_In_ HDC, _In_ int)
COLORREF WINAPI SetTextColor(_In_ HDC, _In_ COLORREF)
BOOL WINAPI SetRectRgn(_In_ HRGN, _In_ int, _In_ int, _In_ int, _In_ int)
BOOL WINAPI GetTextExtentPoint32W(_In_ HDC hdc, _In_reads_(c) LPCWSTR lpString, _In_ int c, _Out_ LPSIZE psizl)
HWND WINAPI SetCapture(_In_ HWND hWnd)
int WINAPI ReleaseDC(_In_opt_ HWND, _In_ HDC)
DWORD WINAPI GetSysColor(_In_ int)
BOOL WINAPI CopyRect(_Out_ LPRECT, _In_ LPCRECT)
BOOL WINAPI IsWindow(_In_opt_ HWND)
#define WM_CTLCOLORSTATIC
HKL WINAPI GetKeyboardLayout(_In_ DWORD)
#define GetWindowLongPtrW
BOOL WINAPI ShowCaret(_In_opt_ HWND)
#define EM_GETWORDBREAKPROC
BOOL WINAPI ReleaseCapture(void)
#define EM_GETPASSWORDCHAR
#define COLOR_WINDOWFRAME
int(CALLBACK * EDITWORDBREAKPROCA)(LPSTR, int, int, int)
LRESULT WINAPI DefWindowProcW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
LRESULT WINAPI DefWindowProcA(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
BOOL WINAPI PostMessageW(_In_opt_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
struct tagSCROLLINFO SCROLLINFO
#define EM_SETPASSWORDCHAR
HBRUSH WINAPI GetSysColorBrush(_In_ int)
HANDLE WINAPI SetClipboardData(_In_ UINT, _In_opt_ HANDLE)
#define EM_EMPTYUNDOBUFFER
LONG WINAPI SetWindowLongW(_In_ HWND, _In_ int, _In_ LONG)
LONG WINAPI GetWindowLongW(_In_ HWND, _In_ int)
struct tagCREATESTRUCTA * LPCREATESTRUCTA
BOOL WINAPI CloseClipboard(void)
BOOL WINAPI IsRectEmpty(_In_ LPCRECT)
HWND WINAPI GetCapture(void)
BOOL WINAPI OpenClipboard(_In_opt_ HWND)
HANDLE WINAPI GetClipboardData(_In_ UINT)
int WINAPI MapWindowPoints(_In_opt_ HWND hWndFrom, _In_opt_ HWND hWndTo, _Inout_updates_(cPoints) LPPOINT lpPoints, _In_ UINT cPoints)
#define EM_GETFIRSTVISIBLELINE
HWND WINAPI GetDlgItem(_In_opt_ HWND, _In_ int)
UINT_PTR WINAPI SetTimer(_In_opt_ HWND, _In_ UINT_PTR, _In_ UINT, _In_opt_ TIMERPROC)
#define WM_IME_SETCONTEXT
BOOL WINAPI PtInRect(_In_ LPCRECT, _In_ POINT)
BOOL WINAPI GetClientRect(_In_ HWND, _Out_ LPRECT)
HMENU WINAPI GetSubMenu(_In_ HMENU, _In_ int)
HWND WINAPI SetFocus(_In_opt_ HWND)
BOOL WINAPI EndPaint(_In_ HWND, _In_ const PAINTSTRUCT *)
#define SIF_DISABLENOSCROLL
BOOL WINAPI IntersectRect(_Out_ LPRECT, _In_ LPCRECT, _In_ LPCRECT)
BOOL WINAPI EmptyClipboard(void)
#define EM_SETWORDBREAKPROC
#define COLOR_HIGHLIGHTTEXT
HDC WINAPI GetDC(_In_opt_ HWND)
BOOL WINAPI InvalidateRgn(_In_ HWND, _In_opt_ HRGN, _In_ BOOL)
DWORD WINAPI CharUpperBuffW(_Inout_updates_(cchLength) LPWSTR lpsz, _In_ DWORD cchLength)
int(CALLBACK * EDITWORDBREAKPROCW)(LPWSTR, int, int, int)
#define CB_GETDROPPEDSTATE
BOOL WINAPI SystemParametersInfoW(_In_ UINT uiAction, _In_ UINT uiParam, _Inout_opt_ PVOID pvParam, _In_ UINT fWinIni)
#define WM_IME_COMPOSITIONFULL
BOOL WINAPI SetRectEmpty(_Out_ LPRECT)
HWND WINAPI GetParent(_In_ HWND)
BOOL WINAPI DestroyMenu(_In_ HMENU)
BOOL WINAPI TrackPopupMenu(_In_ HMENU, _In_ UINT, _In_ int, _In_ int, _Reserved_ int, _In_ HWND, _Reserved_ LPCRECT)
int WINAPI SetScrollInfo(_In_ HWND, _In_ int, _In_ LPCSCROLLINFO, _In_ BOOL)
BOOL WINAPI SetCaretPos(_In_ int, _In_ int)
int WINAPI GetScrollPos(_In_ HWND, _In_ int)
BOOL WINAPI CreateCaret(_In_ HWND, _In_opt_ HBITMAP, _In_ int, _In_ int)
BOOL WINAPI DestroyCaret(void)
BOOL WINAPI InvalidateRect(_In_opt_ HWND, _In_opt_ LPCRECT, _In_ BOOL)
HDC WINAPI BeginPaint(_In_ HWND, _Out_ LPPAINTSTRUCT)
BOOL WINAPI KillTimer(_In_opt_ HWND, _In_ UINT_PTR)
#define SystemParametersInfo
#define SetWindowLongPtrW
BOOL WINAPI IsWindowVisible(_In_ HWND)
BOOL WINAPI EnableMenuItem(_In_ HMENU, _In_ UINT, _In_ UINT)
int WINAPI ScrollWindowEx(_In_ HWND, _In_ int, _In_ int, _In_opt_ LPCRECT, _In_opt_ LPCRECT, _In_opt_ HRGN, _Out_opt_ LPRECT, _In_ UINT)
int WINAPI GetSystemMetrics(_In_ int)
BOOL WINAPI IsClipboardFormatAvailable(_In_ UINT)
LRESULT WINAPI SendMessageW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
SHORT WINAPI GetKeyState(_In_ int)
DWORD WINAPI CharLowerBuffW(_Inout_updates_(cchLength) LPWSTR lpsz, _In_ DWORD cchLength)
LONG WINAPI TabbedTextOutW(_In_ HDC hdc, _In_ int x, _In_ int y, _In_reads_(chCount) LPCWSTR lpString, _In_ int chCount, _In_ int nTabPositions, _In_reads_opt_(nTabPositions) CONST INT *lpnTabStopPositions, _In_ int nTabOrigin)
HMENU WINAPI LoadMenuA(_In_opt_ HINSTANCE, _In_ LPCSTR)
struct _OSVERSIONINFOW OSVERSIONINFOW