VirtualBox

source: vbox/trunk/src/VBox/Additions/WINNT/Graphics/Wine/include/richedit.h@ 19678

Last change on this file since 19678 was 19678, checked in by vboxsync, 16 years ago

opengl: update wine to 1.1.21, add d3d9.dll to build list

  • Property svn:eol-style set to native
File size: 33.9 KB
Line 
1/*
2 * Copyright (C) 2000 Jean-Claude Batista
3 * Copyright (C) 2002 Andriy Palamarchuk
4 *
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
9 *
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
14 *
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
18 */
19
20/*
21 * Sun LGPL Disclaimer: For the avoidance of doubt, except that if any license choice
22 * other than GPL or LGPL is available it will apply instead, Sun elects to use only
23 * the Lesser General Public License version 2.1 (LGPLv2) at this time for any software where
24 * a choice of LGPL license versions is made available with the language indicating
25 * that LGPLv2 or any later version may be used, or where a choice of which version
26 * of the LGPL is applied is otherwise unspecified.
27 */
28
29#ifndef __WINE_RICHEDIT_H
30#define __WINE_RICHEDIT_H
31
32#include <pshpack4.h>
33
34#ifdef __cplusplus
35extern "C" {
36#endif
37
38#ifndef _RICHEDIT_VER
39#define _RICHEDIT_VER 0x0210
40#endif /* _RICHEDIT_VER */
41
42#define cchTextLimitDefault 0x7fff
43
44#if defined(__GNUC__)
45# define MSFTEDIT_CLASS (const WCHAR []){ 'R','i','c','h','E','d','i','t','5','0','W',0 }
46#elif defined(_MSC_VER)
47# define MSFTEDIT_CLASS L"RichEdit50W"
48#else
49static const WCHAR MSFTEDIT_CLASS[] = { 'R','i','c','h','E','d','i','t','5','0','W',0 };
50#endif
51
52#define RICHEDIT_CLASS20A "RichEdit20A"
53#if defined(__GNUC__)
54# define RICHEDIT_CLASS20W (const WCHAR []){ 'R','i','c','h','E','d','i','t','2','0','W',0 }
55#elif defined(_MSC_VER)
56# define RICHEDIT_CLASS20W L"RichEdit20W"
57#else
58static const WCHAR RICHEDIT_CLASS20W[] = { 'R','i','c','h','E','d','i','t','2','0','W',0 };
59#endif
60#define RICHEDIT_CLASS10A "RICHEDIT"
61
62#if (_RICHEDIT_VER >= 0x0200 )
63#define RICHEDIT_CLASS WINELIB_NAME_AW(RICHEDIT_CLASS20)
64#else
65#define RICHEDIT_CLASS RICHEDIT_CLASS10A
66#endif
67
68#ifndef WM_NOTIFY
69#define WM_NOTIFY 0x004e
70#endif
71#ifndef WM_CONTEXTMENU
72#define WM_CONTEXTMENU 0x007b
73#endif
74#ifndef WM_UNICHAR
75#define WM_UNICHAR 0x0109
76#endif
77#ifndef WM_PRINTCLIENT
78#define WM_PRINTCLIENT 0x0318
79#endif
80
81#ifndef EM_GETLIMITTEXT
82#define EM_GETLIMITTEXT (WM_USER + 37)
83#endif
84#ifndef EM_POSFROMCHAR
85#define EM_POSFROMCHAR (WM_USER + 38)
86#define EM_CHARFROMPOS (WM_USER + 39)
87#endif
88#ifndef EM_SCROLLCARET
89#define EM_SCROLLCARET (WM_USER + 49)
90#endif
91#define EM_CANPASTE (WM_USER + 50)
92#define EM_DISPLAYBAND (WM_USER + 51)
93#define EM_EXGETSEL (WM_USER + 52)
94#define EM_EXLIMITTEXT (WM_USER + 53)
95#define EM_EXLINEFROMCHAR (WM_USER + 54)
96#define EM_EXSETSEL (WM_USER + 55)
97#define EM_FINDTEXT (WM_USER + 56)
98#define EM_FORMATRANGE (WM_USER + 57)
99#define EM_GETCHARFORMAT (WM_USER + 58)
100#define EM_GETEVENTMASK (WM_USER + 59)
101#define EM_GETOLEINTERFACE (WM_USER + 60)
102#define EM_GETPARAFORMAT (WM_USER + 61)
103#define EM_GETSELTEXT (WM_USER + 62)
104#define EM_HIDESELECTION (WM_USER + 63)
105#define EM_PASTESPECIAL (WM_USER + 64)
106#define EM_REQUESTRESIZE (WM_USER + 65)
107#define EM_SELECTIONTYPE (WM_USER + 66)
108#define EM_SETBKGNDCOLOR (WM_USER + 67)
109#define EM_SETCHARFORMAT (WM_USER + 68)
110#define EM_SETEVENTMASK (WM_USER + 69)
111#define EM_SETOLECALLBACK (WM_USER + 70)
112#define EM_SETPARAFORMAT (WM_USER + 71)
113#define EM_SETTARGETDEVICE (WM_USER + 72)
114#define EM_STREAMIN (WM_USER + 73)
115#define EM_STREAMOUT (WM_USER + 74)
116#define EM_GETTEXTRANGE (WM_USER + 75)
117#define EM_FINDWORDBREAK (WM_USER + 76)
118#define EM_SETOPTIONS (WM_USER + 77)
119#define EM_GETOPTIONS (WM_USER + 78)
120#define EM_FINDTEXTEX (WM_USER + 79)
121#define EM_GETWORDBREAKPROCEX (WM_USER + 80)
122#define EM_SETWORDBREAKPROCEX (WM_USER + 81)
123
124#define EM_SETUNDOLIMIT (WM_USER + 82)
125#define EM_REDO (WM_USER + 84)
126#define EM_CANREDO (WM_USER + 85)
127#define EM_GETUNDONAME (WM_USER + 86)
128#define EM_GETREDONAME (WM_USER + 87)
129#define EM_STOPGROUPTYPING (WM_USER + 88)
130
131#define EM_SETTEXTMODE (WM_USER + 89)
132#define EM_GETTEXTMODE (WM_USER + 90)
133#define EM_AUTOURLDETECT (WM_USER + 91)
134#define EM_GETAUTOURLDETECT (WM_USER + 92)
135#define EM_SETPALETTE (WM_USER + 93)
136#define EM_GETTEXTEX (WM_USER + 94)
137#define EM_GETTEXTLENGTHEX (WM_USER + 95)
138#define EM_SHOWSCROLLBAR (WM_USER + 96)
139#define EM_SETTEXTEX (WM_USER + 97)
140
141#define EM_SETPUNCTUATION (WM_USER + 100)
142#define EM_GETPUNCTUATION (WM_USER + 101)
143#define EM_SETWORDWRAPMODE (WM_USER + 102)
144#define EM_GETWORDWRAPMODE (WM_USER + 103)
145#define EM_SETIMECOLOR (WM_USER + 104)
146#define EM_GETIMECOLOR (WM_USER + 105)
147#define EM_SETIMEOPTIONS (WM_USER + 106)
148#define EM_GETIMEOPTIONS (WM_USER + 107)
149#define EM_CONVPOSITION (WM_USER + 108)
150
151#define EM_SETLANGOPTIONS (WM_USER + 120)
152#define EM_GETLANGOPTIONS (WM_USER + 121)
153#define EM_GETIMECOMPMODE (WM_USER + 122)
154
155#define EM_FINDTEXTW (WM_USER + 123)
156#define EM_FINDTEXTEXW (WM_USER + 124)
157
158#define EM_RECONVERSION (WM_USER + 125)
159#define EM_SETIMEMODEBIAS (WM_USER + 126)
160#define EM_GETIMEMODEBIAS (WM_USER + 127)
161
162#define EM_SETBIDIOPTIONS (WM_USER + 200)
163#define EM_GETBIDIOPTIONS (WM_USER + 201)
164
165#define EM_SETTYPOGRAPHYOPTIONS (WM_USER + 202)
166#define EM_GETTYPOGRAPHYOPTIONS (WM_USER + 203)
167
168#define EM_SETEDITSTYLE (WM_USER + 204)
169#define EM_GETEDITSTYLE (WM_USER + 205)
170
171#define EM_OUTLINE (WM_USER + 220)
172
173#define EM_GETSCROLLPOS (WM_USER + 221)
174#define EM_SETSCROLLPOS (WM_USER + 222)
175
176#define EM_SETFONTSIZE (WM_USER + 223)
177#define EM_GETZOOM (WM_USER + 224)
178#define EM_SETZOOM (WM_USER + 225)
179#define EM_GETVIEWKIND (WM_USER + 226)
180#define EM_SETVIEWKIND (WM_USER + 227)
181
182#define EM_GETPAGE (WM_USER + 228)
183#define EM_SETPAGE (WM_USER + 229)
184#define EM_GETHYPHENATEINFO (WM_USER + 230)
185#define EM_SETHYPHENATEINFO (WM_USER + 231)
186#define EM_GETPAGEROTATE (WM_USER + 235)
187#define EM_SETPAGEROTATE (WM_USER + 236)
188#define EM_GETCTFMODEBIAS (WM_USER + 237)
189#define EM_SETCTFMODEBIAS (WM_USER + 238)
190#define EM_GETCTFOPENSTATUS (WM_USER + 240)
191#define EM_SETCTFOPENSTATUS (WM_USER + 241)
192#define EM_GETIMECOMPTEXT (WM_USER + 242)
193#define EM_ISIME (WM_USER + 243)
194#define EM_GETIMEPROPERTY (WM_USER + 244)
195#define EM_GETQUERYRTFOBJ (WM_USER + 269)
196#define EM_SETQUERYRTFOBJ (WM_USER + 270)
197
198/* New notifications */
199#define EN_MSGFILTER 0x0700
200#define EN_REQUESTRESIZE 0x0701
201#define EN_SELCHANGE 0x0702
202#define EN_DROPFILES 0x0703
203#define EN_PROTECTED 0x0704
204#define EN_CORRECTTEXT 0x0705
205#define EN_STOPNOUNDO 0x0706
206#define EN_IMECHANGE 0x0707
207#define EN_SAVECLIPBOARD 0x0708
208#define EN_OLEOPFAILED 0x0709
209#define EN_OBJECTPOSITIONS 0x070a
210#define EN_LINK 0x070b
211#define EN_DRAGDROPDONE 0x070c
212#define EN_PARAGRAPHEXPANDED 0x070d
213#define EN_PAGECHANGE 0x070e
214#define EN_LOWFIRTF 0x070f
215#define EN_ALIGNLTR 0x0710
216#define EN_ALIGNRTL 0x0711
217
218
219typedef DWORD (CALLBACK * EDITSTREAMCALLBACK)( DWORD_PTR, LPBYTE, LONG, LONG * );
220
221
222#define yHeightCharPtsMost 1638
223#define lDefaultTab 720
224
225/* tab stops number limit */
226#define MAX_TAB_STOPS 0x00000020
227
228#define MAX_TABLE_CELLS 63
229
230/* Rich edit control styles */
231#define ES_NOOLEDRAGDROP 0x00000008
232#define ES_DISABLENOSCROLL 0x00002000
233#define ES_SUNKEN 0x00004000
234#define ES_SAVESEL 0x00008000
235#define ES_SELFIME 0x00040000
236#define ES_NOIME 0x00080000
237#define ES_VERTICAL 0x00400000
238#define ES_SELECTIONBAR 0x01000000
239#define ES_EX_NOCALLOLEINIT 0x01000000
240
241/* the character formatting options */
242#define SCF_DEFAULT 0x00000000
243#define SCF_SELECTION 0x00000001
244#define SCF_WORD 0x00000002
245#define SCF_ALL 0x00000004
246#define SCF_USEUIRULES 0x00000008
247#define SCF_ASSOCIATEFONT 0x00000010
248#define SCF_NOKBUPDATE 0x00000020
249#define SCF_ASSOCIATEFONT2 0x00000040
250
251#ifndef WM_NOTIFY
252typedef struct _nmhdr
253{
254 HWND hwndFrom;
255 UINT idFrom;
256 UINT code;
257} NMHDR;
258#endif
259
260/* CHARFORMAT structure */
261typedef struct _charformat
262{
263 UINT cbSize;
264 DWORD dwMask;
265 DWORD dwEffects;
266 LONG yHeight;
267 LONG yOffset;
268 COLORREF crTextColor;
269 BYTE bCharSet;
270 BYTE bPitchAndFamily;
271 char szFaceName[LF_FACESIZE];
272} CHARFORMATA;
273
274typedef struct _charformatw
275{
276 UINT cbSize;
277 DWORD dwMask;
278 DWORD dwEffects;
279 LONG yHeight;
280 LONG yOffset;
281 COLORREF crTextColor;
282 BYTE bCharSet;
283 BYTE bPitchAndFamily;
284 WCHAR szFaceName[LF_FACESIZE];
285} CHARFORMATW;
286
287DECL_WINELIB_TYPE_AW(CHARFORMAT)
288
289typedef struct _charformat2a {
290 UINT cbSize;
291 DWORD dwMask;
292 DWORD dwEffects;
293 LONG yHeight;
294 LONG yOffset;
295 COLORREF crTextColor;
296 BYTE bCharSet;
297 BYTE bPitchAndFamily;
298 char szFaceName[LF_FACESIZE];
299 WORD wWeight;
300 SHORT sSpacing;
301 COLORREF crBackColor;
302 LCID lcid;
303 DWORD dwReserved;
304 SHORT sStyle;
305 WORD wKerning;
306 BYTE bUnderlineType;
307 BYTE bAnimation;
308 BYTE bRevAuthor;
309} CHARFORMAT2A;
310
311typedef struct _charformat2w {
312 UINT cbSize;
313 DWORD dwMask;
314 DWORD dwEffects;
315 LONG yHeight;
316 LONG yOffset;
317 COLORREF crTextColor;
318 BYTE bCharSet;
319 BYTE bPitchAndFamily;
320 WCHAR szFaceName[LF_FACESIZE];
321 WORD wWeight;
322 SHORT sSpacing;
323 COLORREF crBackColor;
324 LCID lcid;
325 DWORD dwReserved;
326 SHORT sStyle;
327 WORD wKerning;
328 BYTE bUnderlineType;
329 BYTE bAnimation;
330 BYTE bRevAuthor;
331} CHARFORMAT2W;
332
333DECL_WINELIB_TYPE_AW(CHARFORMAT2)
334
335#define CHARFORMATDELTA (sizeof(CHARFORMAT2) - sizeof(CHARFORMAT))
336
337/* CHARFORMAT masks */
338#define CFM_BOLD 0x00000001
339#define CFM_ITALIC 0x00000002
340#define CFM_UNDERLINE 0x00000004
341#define CFM_STRIKEOUT 0x00000008
342#define CFM_PROTECTED 0x00000010
343#define CFM_LINK 0x00000020
344#define CFM_SMALLCAPS 0x00000040
345#define CFM_ALLCAPS 0x00000080
346#define CFM_HIDDEN 0x00000100
347#define CFM_OUTLINE 0x00000200
348#define CFM_SHADOW 0x00000400
349#define CFM_EMBOSS 0x00000800
350#define CFM_IMPRINT 0x00001000
351#define CFM_DISABLED 0x00002000
352#define CFM_REVISED 0x00004000
353#define CFM_REVAUTHOR 0x00008000
354#define CFM_SUBSCRIPT 0x00030000
355#define CFM_SUPERSCRIPT 0x00030000
356#define CFM_ANIMATION 0x00040000
357#define CFM_STYLE 0x00080000
358#define CFM_KERNING 0x00100000
359#define CFM_SPACING 0x00200000
360#define CFM_WEIGHT 0x00400000
361#define CFM_UNDERLINETYPE 0x00800000
362#define CFM_LCID 0x02000000
363#define CFM_BACKCOLOR 0x04000000
364#define CFM_CHARSET 0x08000000
365#define CFM_OFFSET 0x10000000
366#define CFM_FACE 0x20000000
367#define CFM_COLOR 0x40000000
368#define CFM_SIZE 0x80000000
369
370#define CFM_EFFECTS (CFM_BOLD | \
371 CFM_ITALIC | \
372 CFM_UNDERLINE | \
373 CFM_COLOR | \
374 CFM_STRIKEOUT | \
375 CFE_PROTECTED | \
376 CFM_LINK)
377
378#define CFM_EFFECTS2 (CFM_EFFECTS | \
379 CFM_DISABLED | \
380 CFM_SMALLCAPS | \
381 CFM_ALLCAPS | \
382 CFM_HIDDEN | \
383 CFM_OUTLINE | \
384 CFM_SHADOW | \
385 CFM_EMBOSS | \
386 CFM_IMPRINT | \
387 CFM_DISABLED | \
388 CFM_REVISED | \
389 CFM_SUBSCRIPT | \
390 CFM_SUPERSCRIPT | \
391 CFM_BACKCOLOR)
392
393#define CFM_ALL (CFM_EFFECTS | \
394 CFM_SIZE | \
395 CFM_FACE | \
396 CFM_OFFSET | \
397 CFM_CHARSET)
398
399#define CFM_ALL2 (CFM_ALL | \
400 CFM_EFFECTS2 | \
401 CFM_BACKCOLOR | \
402 CFM_LCID | \
403 CFM_UNDERLINETYPE | \
404 CFM_WEIGHT | \
405 CFM_REVAUTHOR | \
406 CFM_SPACING | \
407 CFM_KERNING | \
408 CFM_STYLE | \
409 CFM_ANIMATION)
410
411/* CHARFORMAT effects */
412#define CFE_BOLD 0x00000001
413#define CFE_ITALIC 0x00000002
414#define CFE_UNDERLINE 0x00000004
415#define CFE_STRIKEOUT 0x00000008
416#define CFE_PROTECTED 0x00000010
417#define CFE_LINK 0x00000020
418#define CFE_SUBSCRIPT 0x00010000
419#define CFE_SUPERSCRIPT 0x00020000
420#define CFE_AUTOCOLOR 0x40000000
421
422#define CFE_SMALLCAPS CFM_SMALLCAPS
423#define CFE_ALLCAPS CFM_ALLCAPS
424#define CFE_HIDDEN CFM_HIDDEN
425#define CFE_OUTLINE CFM_OUTLINE
426#define CFE_SHADOW CFM_SHADOW
427#define CFE_EMBOSS CFM_EMBOSS
428#define CFE_IMPRINT CFM_IMPRINT
429#define CFE_DISABLED CFM_DISABLED
430#define CFE_REVISED CFM_REVISED
431#define CFE_AUTOBACKCOLOR CFM_BACKCOLOR
432
433#define CFU_UNDERLINENONE 0x00
434#define CFU_UNDERLINE 0x01
435#define CFU_UNDERLINEWORD 0x02
436#define CFU_UNDERLINEDOUBLE 0x03
437#define CFU_UNDERLINEDOTTED 0x04
438#define CFU_UNDERLINEDASH 0x05
439#define CFU_UNDERLINEDASHDOT 0x06
440#define CFU_UNDERLINEDASHDOTDOT 0x07
441#define CFU_UNDERLINEWAVE 0x08
442#define CFU_UNDERLINETHICK 0x09
443#define CFU_UNDERLINEHAIRLINE 0x0a
444#define CFU_UNDERLINEDOUBLEWAVE 0x0b
445#define CFU_UNDERLINEHEAVYWAVE 0x0c
446#define CFU_UNDERLINELONGDASH 0x0d
447#define CFU_UNDERLINETHICKDASH 0x0e
448#define CFU_UNDERLINETHICKDASHDOT 0x0f
449#define CFU_UNDERLINETHICKDASHDOTDOT 0x10
450#define CFU_UNDERLINETHICKDOTTED 0x11
451#define CFU_UNDERLINETHICKLONGDASH 0x12
452#define CFU_INVERT 0xFE
453#define CFU_CF1UNDERLINE 0xFF
454
455/* ECO operations */
456#define ECOOP_SET 0x0001
457#define ECOOP_OR 0x0002
458#define ECOOP_AND 0x0003
459#define ECOOP_XOR 0x0004
460
461/* edit control options */
462#define ECO_AUTOWORDSELECTION 0x00000001
463#define ECO_AUTOVSCROLL 0x00000040
464#define ECO_AUTOHSCROLL 0x00000080
465#define ECO_NOHIDESEL 0x00000100
466#define ECO_READONLY 0x00000800
467#define ECO_WANTRETURN 0x00001000
468#define ECO_SAVESEL 0x00008000
469#define ECO_SELECTIONBAR 0x01000000
470#define ECO_VERTICAL 0x00400000
471
472/* Event notification masks */
473#define ENM_NONE 0x00000000
474#define ENM_CHANGE 0x00000001
475#define ENM_UPDATE 0x00000002
476#define ENM_SCROLL 0x00000004
477#define ENM_SCROLLEVENTS 0x00000008
478#define ENM_DRAGDROPDONE 0x00000010
479#define ENM_PARAGRAPHEXPANDED 0x00000020
480#define ENM_PAGECHANGE 0x00000040
481#define ENM_KEYEVENTS 0x00010000
482#define ENM_MOUSEEVENTS 0x00020000
483#define ENM_REQUESTRESIZE 0x00040000
484#define ENM_SELCHANGE 0x00080000
485#define ENM_DROPFILES 0x00100000
486#define ENM_PROTECTED 0x00200000
487#define ENM_CORRECTTEXT 0x00400000
488#define ENM_IMECHANGE 0x00800000
489#define ENM_LANGCHANGE 0x01000000
490#define ENM_OBJECTPOSITIONS 0x02000000
491#define ENM_LINK 0x04000000
492#define ENM_LOWFIRTF 0x08000000
493
494typedef struct _bidioptions
495{
496 UINT cbSize;
497 WORD wMask;
498 WORD wEffects;
499} BIDIOPTIONS;
500
501#ifndef __RICHEDIT_CHARRANGE_DEFINED
502#define __RICHEDIT_CHARRANGE_DEFINED
503
504typedef struct _charrange
505{
506 LONG cpMin;
507 LONG cpMax;
508} CHARRANGE;
509
510#endif /* __RICHEDIT_CHARRANGE_DEFINED */
511
512typedef struct _textrange
513{
514 CHARRANGE chrg;
515 LPSTR lpstrText;
516} TEXTRANGEA;
517
518typedef struct _textrangew
519{
520 CHARRANGE chrg;
521 LPWSTR lpstrText;
522} TEXTRANGEW;
523
524DECL_WINELIB_TYPE_AW(TEXTRANGE)
525
526typedef struct _editstream
527{
528 DWORD_PTR dwCookie;
529 DWORD dwError;
530 EDITSTREAMCALLBACK pfnCallback;
531} EDITSTREAM;
532
533typedef struct _compcolor {
534 COLORREF crText;
535 COLORREF crBackground;
536 DWORD dwEffects;
537} COMPCOLOR;
538
539typedef struct _encorrecttext {
540 NMHDR nmhdr;
541 CHARRANGE chrg;
542 WORD seltyp;
543} ENCORRECTTEXT;
544
545typedef struct _endropfiles {
546 NMHDR nmhdr;
547 HANDLE hDrop;
548 LONG cp;
549 BOOL fProtected;
550} ENDROPFILES;
551
552typedef struct _enlink {
553 NMHDR nmhdr;
554 UINT msg;
555 WPARAM wParam;
556 LPARAM lParam;
557 CHARRANGE chrg;
558} ENLINK;
559
560typedef struct _enlowfirtf {
561 NMHDR nmhdr;
562 char *szControl;
563} ENLOWFIRTF;
564
565typedef struct {
566 NMHDR nmhdr;
567 LONG iob;
568 LONG lOper;
569 HRESULT hr;
570} ENOLEOPFAILED;
571
572typedef struct _enprotected {
573 NMHDR nmhdr;
574 UINT msg;
575 WPARAM wParam;
576 LPARAM lParam;
577 CHARRANGE chrg;
578} ENPROTECTED, *LPENPROTECTED;
579
580typedef struct _ensaveclipboard {
581 NMHDR nmhdr;
582 LONG cObjectCount;
583 LONG cch;
584} ENSAVECLIPBOARD;
585
586typedef struct _findtextA {
587 CHARRANGE chrg;
588 LPCSTR lpstrText;
589} FINDTEXTA;
590
591typedef struct _findtextW {
592 CHARRANGE chrg;
593 LPCWSTR lpstrText;
594} FINDTEXTW;
595
596DECL_WINELIB_TYPE_AW(FINDTEXT)
597
598typedef struct _findtextexA {
599 CHARRANGE chrg;
600 LPCSTR lpstrText;
601 CHARRANGE chrgText;
602} FINDTEXTEXA;
603
604typedef struct _findtextexW {
605 CHARRANGE chrg;
606 LPCWSTR lpstrText;
607 CHARRANGE chrgText;
608} FINDTEXTEXW;
609
610DECL_WINELIB_TYPE_AW(FINDTEXTEX)
611
612typedef struct _formatrange {
613 HDC hdc;
614 HDC hdcTarget;
615 RECT rc;
616 RECT rcPage;
617 CHARRANGE chrg;
618} FORMATRANGE;
619
620typedef enum tagKHYPH
621{
622 khyphNil = 0,
623 khyphNormal = 1,
624 khyphAddBefore = 2,
625 khyphChangeBefore = 3,
626 khyphDeleteBefore = 4,
627 khyphChangeAfter = 5,
628 khyphDelAndChange = 6
629} KHYPH;
630
631typedef struct hyphresult
632{
633 KHYPH khyph;
634 LONG ichHyph;
635 WCHAR chHyph;
636} HYPHRESULT;
637
638typedef struct tagHyphenateInfo
639{
640 SHORT cbSize;
641 SHORT dxHyphenateZone;
642 void (WINAPI* pfnHyphenate)(WCHAR*, LANGID, LONG, HYPHRESULT*);
643} HYPHENATEINFO;
644
645typedef struct _msgfilter {
646 NMHDR nmhdr;
647 UINT msg;
648 WPARAM wParam;
649 LPARAM lParam;
650} MSGFILTER;
651
652typedef struct _objectpositions {
653 NMHDR nmhdr;
654 LONG cObjectCount;
655 LONG *pcpPositions;
656} OBJECTPOSITIONS;
657
658typedef struct _paraformat {
659 UINT cbSize;
660 DWORD dwMask;
661 WORD wNumbering;
662 WORD wReserved;
663 LONG dxStartIndent;
664 LONG dxRightIndent;
665 LONG dxOffset;
666 WORD wAlignment;
667 SHORT cTabCount;
668 LONG rgxTabs[MAX_TAB_STOPS];
669} PARAFORMAT;
670
671typedef struct _paraformat2 {
672 UINT cbSize;
673 DWORD dwMask;
674 WORD wNumbering;
675 WORD wEffects;
676 LONG dxStartIndent;
677 LONG dxRightIndent;
678 LONG dxOffset;
679 WORD wAlignment;
680 SHORT cTabCount;
681 LONG rgxTabs[MAX_TAB_STOPS];
682 LONG dySpaceBefore, dySpaceAfter, dyLineSpacing;
683 SHORT sStyle;
684 BYTE bLineSpacingRule, bOutlineLevel;
685 WORD wShadingWeight, wShadingStyle;
686 WORD wNumberingStart, wNumberingStyle, wNumberingTab;
687 WORD wBorderSpace, wBorderWidth, wBorders;
688} PARAFORMAT2;
689
690typedef struct _selchange {
691 NMHDR nmhdr;
692 CHARRANGE chrg;
693 WORD seltyp;
694} SELCHANGE;
695
696typedef struct _reqresize {
697 NMHDR nmhdr;
698 RECT rc;
699} REQRESIZE;
700
701typedef struct _repastespecial {
702 DWORD dwAspect;
703 DWORD dwParam;
704} REPASTESPECIAL;
705
706typedef struct _punctuation {
707 UINT iSize;
708 LPSTR szPunctuation;
709} PUNCTUATION;
710
711typedef struct _gettextex {
712 DWORD cb;
713 DWORD flags;
714 UINT codepage;
715 LPCSTR lpDefaultChar;
716 LPBOOL lpUsedDefChar;
717} GETTEXTEX;
718
719typedef struct _imecomptext {
720 LONG cb;
721 DWORD flags;
722} IMECOMPTEXT;
723
724void WINAPI HyphenateProc(WCHAR*, LANGID, LONG, HYPHRESULT*);
725
726#define SF_TEXT 0x00000001
727#define SF_RTF 0x00000002
728#define SF_RTFNOOBJS 0x00000003
729#define SF_TEXTIZED 0x00000004
730#define SF_UNICODE 0x00000010
731#define SF_USECODEPAGE 0x00000020
732#define SF_NCRFORNONASCII 0x00000040
733#define SF_RTFVAL 0x00000700
734
735/* BIDIOPTIONS.wMask flag values */
736#define BOM_DEFPARADIR 0x00000001
737#define BOM_PLAINTEXT 0x00000002
738#define BOM_NEUTRALOVERRIDE 0x00000004
739#define BOM_CONTEXTREADING 0x00000008
740#define BOM_CONTEXTALIGNMENT 0x00000010
741#define BOM_LEGACYBIDICLASS 0x00000040
742
743/* BIDIOPTIONS.wEffects flag values */
744#define BOE_RTLDIR 0x00000001
745#define BOE_PLAINTEXT 0x00000002
746#define BOE_NEUTRALOVERRIDE 0x00000004
747#define BOE_CONTEXTREADING 0x00000008
748#define BOE_CONTEXTALIGNMENT 0x00000010
749#define BOE_LEGACYBIDICLASS 0x00000040
750
751/* Clipboard formats */
752#define CF_RTF TEXT("Rich Text Format")
753#define CF_RTFNOOBJS TEXT("Rich Text Format Without Objects")
754#define CF_RETEXTOBJ TEXT("RichEdit Text and Objects")
755
756/* Mode bias wParam values for EM_SETCTFMODEBIAS message */
757#define CTFMODEBIAS_DEFAULT 0x00000000
758#define CTFMODEBIAS_FILENAME 0x00000001
759#define CTFMODEBIAS_NAME 0x00000002
760#define CTFMODEBIAS_READING 0x00000003
761#define CTFMODEBIAS_DATETIME 0x00000004
762#define CTFMODEBIAS_CONVERSATION 0x00000005
763#define CTFMODEBIAS_NUMERIC 0x00000006
764#define CTFMODEBIAS_HIRAGANA 0x00000007
765#define CTFMODEBIAS_KATAKANA 0x00000008
766#define CTFMODEBIAS_HANGUL 0x00000009
767#define CTFMODEBIAS_HALFWIDTHKATAKANA 0x0000000a
768#define CTFMODEBIAS_FULLWIDTHALPHANUMERIC 0x0000000b
769#define CTFMODEBIAS_HALFWIDTHALPHANUMERIC 0x0000000c
770
771#define EMO_EXIT 0x00000000
772#define EMO_ENTER 0x00000001
773#define EMO_PROMOTE 0x00000002
774#define EMO_EXPAND 0x00000003
775#define EMO_MOVESELECTION 0x00000004
776#define EMO_GETVIEWMODE 0x00000005
777
778#define EMO_EXPANDSELECTION 0x00000000
779#define EMO_EXPANDDOCUMENT 0x00000001
780
781/* Page Rotate values used in wParam of EM_SETPAGEROTATE message */
782#define EPR_0 0x00000000
783#define EPR_270 0x00000001
784#define EPR_180 0x00000002
785#define EPR_90 0x00000003
786
787/* Find flags for wParam of EM_FINDTEXT message */
788#define FR_MATCHDIAC 0x20000000
789#define FR_MATCHKASHIDA 0x40000000
790#define FR_MATCHALEFHAMZA 0x80000000
791
792/* IME Compatibility Mode return values for EM_GETIMECOMPMODE message */
793#define ICM_NOTOPEN 0x00000000
794#define ICM_LEVEL3 0x00000001
795#define ICM_LEVEL2 0x00000002
796#define ICM_LEVEL2_5 0x00000003
797#define ICM_LEVEL2_SUI 0x00000004
798#define ICM_CTF 0x00000005
799
800/* Flags value for IMECOMPTEXT structure */
801#define ICT_RESULTREADSTR 0x00000001
802
803/* Input Method Flags used in EM_SETLANGOPTIONS message */
804#define IMF_AUTOKEYBOARD 0x00000001
805#define IMF_AUTOFONT 0x00000002
806#define IMF_IMECANCELCOMPLETE 0x00000004
807#define IMF_IMEALWAYSSENDNOTIFY 0x00000008
808#define IMF_AUTOFONTSIZEADJUST 0x00000010
809#define IMF_UIFONTS 0x00000020
810#define IMF_DUALFONT 0x00000080
811
812/* Parameters values for the EM_SETIMEMODEBIAS message */
813#define IMF_SMODE_PLAURALCLAUSE 0x00000001
814#define IMF_SMODE_NONE 0x00000002
815
816/* Parameters of the EM_SETIMEOPTIONS message */
817#define IMF_FORCENONE 0x00000001
818#define IMF_FORCEENABLE 0x00000002
819#define IMF_FORCEDISABLE 0x00000004
820#define IMF_CLOSESTATUSWINDOW 0x00000008
821#define IMF_VERTICAL 0x00000020
822#define IMF_FORCEACTIVE 0x00000040
823#define IMF_FORCEINACTIVE 0x00000080
824#define IMF_FORCEREMEMBER 0x00000100
825#define IMF_MULTIPLEEDIT 0x00000400
826
827/* return values of the EM_SELECTION_TYPE message */
828#define SEL_EMPTY 0x00000000
829#define SEL_TEXT 0x00000001
830#define SEL_OBJECT 0x00000002
831#define SEL_MULTICHAR 0x00000004
832#define SEL_MULTIOBJECT 0x00000008
833
834/* ENOLEOPFAILED.lOper value that indicates operation failure */
835#define OLEOP_DOVERB 0x00000001
836
837/* punctionation type values for wParam of EM_SETPUNCTUATION message */
838#define PC_FOLLOWING 0x00000001
839#define PC_LEADING 0x00000002
840#define PC_OVERFLOW 0x00000003
841#define PC_DELIMITER 0x00000004
842
843/* mask values in the PARAFORMAT structure */
844#define PFM_STARTINDENT 0x00000001
845#define PFM_RIGHTINDENT 0x00000002
846#define PFM_OFFSET 0x00000004
847#define PFM_ALIGNMENT 0x00000008
848#define PFM_TABSTOPS 0x00000010
849#define PFM_NUMBERING 0x00000020
850#define PFM_OFFSETINDENT 0x80000000
851
852/* mask values in the PARAFORMAT2 structure */
853#define PFM_SPACEBEFORE 0x00000040
854#define PFM_SPACEAFTER 0x00000080
855#define PFM_LINESPACING 0x00000100
856#define PFM_STYLE 0x00000400
857#define PFM_BORDER 0x00000800
858#define PFM_SHADING 0x00001000
859#define PFM_NUMBERINGSTYLE 0x00002000
860#define PFM_NUMBERINGTAB 0x00004000
861#define PFM_NUMBERINGSTART 0x00008000
862#define PFM_RTLPARA 0x00010000
863#define PFM_KEEP 0x00020000
864#define PFM_KEEPNEXT 0x00040000
865#define PFM_PAGEBREAKBEFORE 0x00080000
866#define PFM_NOLINENUMBER 0x00100000
867#define PFM_NOWIDOWCONTROL 0x00200000
868#define PFM_DONOTHYPHEN 0x00400000
869#define PFM_SIDEBYSIDE 0x00800000
870#define PFM_COLLAPSED 0x01000000
871#define PFM_OUTLINELEVEL 0x02000000
872#define PFM_BOX 0x04000000
873#define PFM_RESERVED2 0x08000000
874#define PFM_TABLEROWDELIMITER 0x10000000
875#define PFM_TEXTWRAPPINGBREAK 0x20000000
876#define PFM_TABLE 0x40000000
877
878#define PFM_ALL (PFM_STARTINDENT | \
879 PFM_RIGHTINDENT | \
880 PFM_OFFSET | \
881 PFM_ALIGNMENT | \
882 PFM_TABSTOPS | \
883 PFM_NUMBERING | \
884 PFM_OFFSETINDENT | \
885 PFM_RTLPARA)
886
887#define PFM_EFFECTS (PFM_RTLPARA | \
888 PFM_KEEP | \
889 PFM_KEEPNEXT | \
890 PFM_PAGEBREAKBEFORE | \
891 PFM_NOLINENUMBER | \
892 PFM_NOWIDOWCONTROL | \
893 PFM_DONOTHYPHEN | \
894 PFM_SIDEBYSIDE | \
895 PFM_TABLEROWDELIMITER | \
896 PFM_TABLE)
897
898#define PFM_ALL2 (PFM_ALL | \
899 PFM_EFFECTS | \
900 PFM_SPACEBEFORE | \
901 PFM_SPACEAFTER | \
902 PFM_LINESPACING | \
903 PFM_STYLE | \
904 PFM_BORDER | \
905 PFM_SHADING | \
906 PFM_NUMBERINGSTYLE | \
907 PFM_NUMBERINGTAB | \
908 PFM_NUMBERINGSTART)
909
910/* numbering option */
911#define PFN_BULLET 0x00000001
912#define PFN_ARABIC 0x00000002
913#define PFN_LCLETTER 0x00000003
914#define PFN_UCLETTER 0x00000004
915#define PFN_LCROMAN 0x00000005
916#define PFN_UCROMAN 0x00000006
917
918/* paragraph format numbering styles */
919#define PFNS_PAREN 0x00000000
920#define PFNS_PARENS 0x00000100
921#define PFNS_PERIOD 0x00000200
922#define PFNS_PLAIN 0x00000300
923#define PFNS_NONUMBER 0x00000400
924#define PFNS_NEWNUMBER 0x00008000
925
926/* paragraph alignment */
927#define PFA_LEFT 0x00000001
928#define PFA_RIGHT 0x00000002
929#define PFA_CENTER 0x00000003
930#define PFA_JUSTIFY 0x00000004
931#define PFA_FULL_INTERWORD 0x00000004
932#define PFA_FULL_INTERLETTER 0x00000005
933#define PFA_FULL_SCALED 0x00000006
934#define PFA_FULL_GLYPHS 0x00000007
935#define PFA_SNAP_GRID 0x00000008
936
937/* paragraph effects */
938#define PFE_RTLPARA 0x00000001
939#define PFE_KEEP 0x00000002
940#define PFE_KEEPNEXT 0x00000004
941#define PFE_PAGEBREAKBEFORE 0x00000008
942#define PFE_NOLINENUMBER 0x00000010
943#define PFE_NOWIDOWCONTROL 0x00000020
944#define PFE_DONOTHYPHEN 0x00000040
945#define PFE_SIDEBYSIDE 0x00000080
946#define PFE_COLLAPSED 0x00000100
947#define PFE_BOX 0x00000400
948#define PFE_TABLEROWDELIMITER 0x00001000
949#define PFE_TEXTWRAPPINGBREAK 0x00002000
950#define PFE_TABLE 0x00004000
951
952/* Set Edit Style flags for EM_SETEDITSTYLE message */
953#define SES_EMULATESYSEDIT 0x00000001
954#define SES_BEEPONMAXTEXT 0x00000002
955#define SES_EXTENDBACKCOLOR 0x00000004
956#define SES_MAPCPS 0x00000008
957#define SES_EMULATE10 0x00000010
958#define SES_USECRLF 0x00000020
959#define SES_NOXLTSYMBOLRANGE 0x00000020
960#define SES_USEAIMM 0x00000040
961#define SES_NOIME 0x00000080
962#define SES_ALLOWBEEPS 0x00000100
963#define SES_UPPERCASE 0x00000200
964#define SES_LOWERCASE 0x00000400
965#define SES_NOINPUTSEQUENCECHK 0x00000800
966#define SES_BIDI 0x00001000
967#define SES_SCROLLONKILLFOCUS 0x00002000
968#define SES_XLTCRCRLFTOCR 0x00004000
969#define SES_DRAFTMODE 0x00008000
970#define SES_USECTF 0x00010000
971#define SES_HIDEGRIDLINES 0x00020000
972#define SES_USEATFONT 0x00040000
973#define SES_CUSTOMLOOK 0x00080000
974#define SES_LBSCROLLNOTIFY 0x00100000
975#define SES_CTFALLOWEMBED 0x00200000
976#define SES_CTFALLOWSMARTTAG 0x00400000
977#define SES_CTFALLOWPROOFING 0x00800000
978
979/* streaming flags */
980#define SFF_WRITEXTRAPAR 0x00000080
981#define SFF_PWD 0x00000800
982#define SFF_KEEPDOCINFO 0x00001000
983#define SFF_PERSISTVIEWSCALE 0x00002000
984#define SFF_PLAINRTF 0x00004000
985#define SFF_SELECTION 0x00008000
986
987typedef enum _undonameid
988{
989 UID_UNKNOWN = 0,
990 UID_TYPING = 1,
991 UID_DELETE = 2,
992 UID_DRAGDROP = 3,
993 UID_CUT = 4,
994 UID_PASTE = 5,
995 UID_AUTOCORRECT = 6
996} UNDONAMEID;
997
998typedef LONG (*EDITWORDBREAKPROCEX)(char*,LONG,BYTE,INT);
999
1000#define VM_OUTLINE 0x00000002
1001#define VM_NORMAL 0x00000004
1002#define VM_PAGE 0x00000009
1003
1004/* options of the EM_FINDWORDBREAK message */
1005#define WB_CLASSIFY 0x00000003
1006#define WB_MOVEWORDLEFT 0x00000004
1007#define WB_MOVEWORDPREV 0x00000004
1008#define WB_MOVEWORDRIGHT 0x00000005
1009#define WB_MOVEWORDNEXT 0x00000005
1010#define WB_LEFTBREAK 0x00000006
1011#define WB_PREVBREAK 0x00000006
1012#define WB_RIGHTBREAK 0x00000007
1013#define WB_NEXTBREAK 0x00000007
1014
1015/* options of the EM_SETWORDWRAPMODE message */
1016#define WBF_WORDWRAP 0x00000010
1017#define WBF_WORDBREAK 0x00000020
1018#define WBF_OVERFLOW 0x00000040
1019#define WBF_LEVEL1 0x00000080
1020#define WBF_LEVEL2 0x00000100
1021#define WBF_CUSTOM 0x00000200
1022
1023#define WBF_CLASS ((BYTE) 0x0F)
1024#define WBF_ISWHITE ((BYTE) 0x10)
1025#define WBF_BREAKLINE ((BYTE) 0x20)
1026#define WBF_BREAKAFTER ((BYTE) 0x40)
1027
1028/* Placeholder unicode character for an embedded object */
1029#ifndef WCH_EMBEDDING
1030#define WCH_EMBEDDING (WCHAR)0xFFFC
1031#endif
1032
1033/* options of the EM_SETTEXTMODE message */
1034#define TM_PLAINTEXT 0x00000001
1035#define TM_RICHTEXT 0x00000002
1036#define TM_SINGLELEVELUNDO 0x00000004
1037#define TM_MULTILEVELUNDO 0x00000008
1038#define TM_SINGLECODEPAGE 0x00000010
1039#define TM_MULTICODEPAGE 0x00000020
1040
1041/* GETTEXTEX structure flags */
1042#define GT_DEFAULT 0x00000000
1043#define GT_USECRLF 0x00000001
1044#define GT_SELECTION 0x00000002
1045#define GT_RAWTEXT 0x00000004
1046#define GT_NOHIDDENTEXT 0x00000008
1047
1048/* Options of the EM_SETTYPOGRAPHYOPTIONS message */
1049#define TO_ADVANCEDTYPOGRAPHY 0x00000001
1050#define TO_SIMPLELINEBREAK 0x00000002
1051#define TO_DISABLECUSTOMTEXTOUT 0x00000004
1052#define TO_ADVANCEDLAYOUT 0x00000008
1053
1054typedef struct _gettextlengthex {
1055 DWORD flags;
1056 UINT codepage;
1057} GETTEXTLENGTHEX;
1058
1059/* Flags of the GETTEXTLENGTHEX structure */
1060#define GTL_DEFAULT 0x00000000
1061#define GTL_USECRLF 0x00000001
1062#define GTL_PRECISE 0x00000002
1063#define GTL_CLOSE 0x00000004
1064#define GTL_NUMCHARS 0x00000008
1065#define GTL_NUMBYTES 0x00000010
1066
1067#define GCM_RIGHTMOUSEDROP 0x8000
1068
1069/* Options of the EM_SETTEXTEX message */
1070typedef struct _settextex {
1071 DWORD flags;
1072 UINT codepage;
1073} SETTEXTEX;
1074
1075/* Flags of the EM_SETTEXTEX message */
1076#define ST_DEFAULT 0x00000000
1077#define ST_KEEPUNDO 0x00000001
1078#define ST_SELECTION 0x00000002
1079
1080#define ST_NEWCHARS 0x00000004
1081
1082#ifdef __cplusplus
1083}
1084#endif
1085
1086#include <poppack.h>
1087
1088#endif /* __WINE_RICHEDIT_H */
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette