Dylan Smith
43ad427a15
richedit: Enforce the maximum font size.
...
Trying to set the font size to a value larger than 1638
in points (yHeightCharPtsMost) using EM_SETCHARFORMAT will cause it to be
set to actually set to the maximum.
2008-07-14 12:22:13 +02:00
Aurimas Fischer
88c25518d5
richedit: Spelling fixes.
2008-07-14 12:21:55 +02:00
Dylan Smith
0f14d65c70
richedit: Use system colour for highlighting after v2.0.
...
In version 1.0 of the richedit controls highlighting is done by
inverting the colours. Version 2.0 and up highlight instead draw
the text using system colours for the background and the text.
2008-07-11 14:25:17 +02:00
Dylan Smith
9bcfa942a0
richedit: Prevented underlining the end of paragraph character.
2008-07-11 14:25:02 +02:00
Dylan Smith
5ec188d955
richedit: Tabs are now highlighted and underlined.
2008-07-11 14:24:51 +02:00
Dylan Smith
db3991257f
richedit: Handle overflow of only spaces on first line of paragraph.
...
The uncommon case that this patch handles is enough whitespace being
on the first line of a paragraph to cause it to wrap. In this case the
first non-space character will be wrapped onto the next line.
2008-07-10 18:13:38 +02:00
Dylan Smith
feda29bb0c
richedit: Fixed position of runs in some situations during wrapping.
...
Runs that are skipped over still need to affect the wrapping position,
otherwise they won't affect further run positions.
2008-07-10 18:13:25 +02:00
Dylan Smith
49468e1824
richedit: Tabs cause lines to wrap but not end of paragraph run.
2008-07-10 18:13:13 +02:00
Dylan Smith
e4007e9f97
richedit: Removed redundant wrapping code.
...
Lines in ME_WrapHandleRun were removed because ME_CalcRunExtent is
already called unconditionally just before it in the call to
ME_WrapSizeRun.
2008-07-10 18:12:48 +02:00
Francois Gouget
dbaec0a101
Assorted spelling fixes.
2008-07-10 13:40:15 +02:00
Dylan Smith
7de6c2674a
richedit: Added more conditional cursor changes.
...
Previously the cursor was either an IBEAM, or a reversed arrow when over
the selectionbar.
2008-07-10 12:16:58 +02:00
Dylan Smith
d293b3fc98
richedit: Prevented cursor flicker while moving over selection bar.
...
When the cursor is moved over the selection bar, without holding any
mouse buttons down, the cursor would be repeatably set between the
normal cursor, set by DefWindowProc for the WM_SETCURSOR message, and
the reversed cursor, set by ME_MouseMove.
2008-07-10 12:16:39 +02:00
Dylan Smith
12bc51ca26
richedit: Fixed 2 minor paragraph format effect errors.
...
In ME_SetParaFormat the wEffects that were being set needed to be set
rather than the dwMask.
2008-07-09 11:31:22 +02:00
Dylan Smith
8172d69e8f
richedit: Set the default paragraph format consistently.
...
I created a function to set the default paragraph format to ensure
consistency when this is done. This initial paragraph format is also
now more consistent with native richedit controls. The dwMask value
always appears to have the same value when retrieved from the native
richedit controls, so all the mask values are now initialized when the
PARAFORMAT2 structure is created.
2008-07-09 11:31:22 +02:00
Dylan Smith
aba425eb70
richedit: PFE_TABLE flag is now used instead of private bTable value.
...
The PARAFORMAT structure has a bit in wEffects to indicate whether the
paragraph is a table or not, so this should be used instead of a private
bTable value, since this structure can be retrieved with EM_GETPARAFORMAT.
2008-07-09 11:31:21 +02:00
Dylan Smith
eb4ed9cadf
richedit: Removed unused variable bCaretShown in ME_TextEditor.
2008-07-08 21:08:53 +02:00
Michael Stefaniuc
0164bffd9a
riched20: Fix typo.
2008-07-08 20:37:30 +02:00
Alexandre Julliard
79c64acc7b
tests: Don't depend on the static uuid libraries in the tests.
...
This avoids trouble with the broken MingW libraries when
cross-compiling the tests.
2008-07-08 17:51:45 +02:00
Dylan Smith
762e5818d1
richedit: Hide cursor when text is selected.
...
The cursor should only be shown when there is no selection, since this
is how it is done in Windows. This patch avoids showing the cursor when
there is a selection, and destroys the cursor when a selection is made.
2008-07-08 10:44:45 +02:00
Dylan Smith
69cf4e9ac4
richedit: Implemented triple click selection.
2008-07-08 10:44:32 +02:00
Dylan Smith
7c352b9638
richedit: Implemented paragraph selection.
2008-07-08 10:44:12 +02:00
Dylan Smith
abefc28fe7
richedit: Fixed drag and shift selection for words and lines.
...
Previously word drag and shift selection was not implemented. Line
drag selection was working, but shift selection wasn't.
2008-07-08 10:43:55 +02:00
Dylan Smith
ebded1636b
richedit: Fixed Valgrind error related to undoing.
...
The error was a memory access of a freed object. In ME_AddUndoItem I
checked the top of the undo stack to end a coalescing undo transaction,
assuming that this should be either a valid undo item, or NULL, instead
it was already freed.
2008-07-07 14:16:07 +02:00
Dylan Smith
5b2bdc06d0
richedit: Fixed double click issues by sharing code with single click.
2008-07-07 14:16:07 +02:00
Dylan Smith
379835b634
richedit: Made sure word selection selects only one word.
2008-07-07 14:16:07 +02:00
Dylan Smith
2eec4f03ed
richedit: Fixed the selection bar width.
2008-07-07 11:10:49 +02:00
Dylan Smith
db95d69f99
richedit: Made sure the caret position is stored when moving up/down.
...
The caret's x position is stored in ME_TextEditor.nUDArrowX so that when
the caret is moved up or down, it will stay along the same horizontal
position, or at the end of a line. Unfortunately, the value stored in
nUDArrowX was being unconditionally discarded in ME_ArrowKey, preventing
it from serving its purpose.
2008-07-07 11:10:33 +02:00
Dylan Smith
31a2d64fa4
richedit: Fixed simulated keyboard events on tests.
2008-07-03 13:07:45 +02:00
Dylan Smith
2a139746cc
richedit: Added missing DestroyWindow in a test.
2008-07-01 13:47:03 +02:00
Juan Lang
c40c08b3d3
richedit: Only send update events in 1.0 emulation mode if the event mask specifies it.
...
Fixes a crash in native cryptui.dll when viewing certificate properties.
2008-07-01 13:45:37 +02:00
Dylan Smith
1bec9bb440
richedit: Calculate tab positions relative to end of selection bar.
2008-06-30 12:10:18 +02:00
Dylan Smith
66f948c010
richedit: Clicking below end of text now selects closest character.
...
Before the end of the text was selected when clicking below the end of
the text, rather than using the x position to find the appropriate
character on the last row that is closest to the pixel position.
2008-06-30 12:10:02 +02:00
Dylan Smith
fad2b57cd7
richedit: Ensure caret is seen if moved past end of view over trailing spaces.
2008-06-27 11:09:37 +02:00
Dylan Smith
438d8e1c58
richedit: Caret size must match font size characters to be inserted.
...
When the caret is at the start of a run, it uses the font of the
previous run for inserting characters. The caret size previously was
the wrong height for the characters being inserted when the caret was at
the start of a line, but not the start of a paragraph so this patch
fixes this bug.
2008-06-27 11:09:14 +02:00
Dylan Smith
ee6b6f338e
richedit: Fixed mistake that didn't cause a bug.
...
The check to see if the dwOutputBuffer is full was performed incorrectly
in RTFPutUnicodeString, however, this mistake was actually harmless
since it would just cause an extra loop that does nothing, then the
check would work properly with the variable fit equal to 0.
2008-06-27 11:09:02 +02:00
Dylan Smith
632015dc62
richedit: Set error codes and stop parsing for some rtf syntax errors.
...
Checks were added for hexadecimal values that did not have valid
characters, and for EOF received before the final closing brace of the
rich text stream. The error values were tested on richedit versions 1,
2, 3 & 4.1, and they were all the same for these cases.
2008-06-27 11:08:33 +02:00
Dylan Smith
461830a83d
richedit: Removed redundant code for getting the insert style.
...
The function ME_GetInsertStyle already checks for the case where there
is a selection, so there is no need to duplicate this code for
ME_GetSelectionInsertStyle.
2008-06-27 11:08:19 +02:00
Dylan Smith
d1f1346f54
richedit: Implemented undo coalescing to group typing events.
...
Consecutively typed characters are grouped together to be undone
together. The grouping of typed characters can be stopped by certain
events that are mentioned in MSDN's remarks on the EM_STOPGROUPTYPING
message, which is also implemented by this patch.
2008-06-26 21:18:50 +02:00
Dylan Smith
9b67a38f1a
richedit: Make cursor visible when selecting via mouse above/below editor.
2008-06-26 21:18:28 +02:00
Dylan Smith
cb1d7becf9
richedit: Fixed bug preventing bold from being set with EM_SETCHARFORMAT.
...
Previously bold needed to be set by setting CFM_WEIGHT in the
CHARFORMAT2 structure, and then setting the appropriate wWeight value.
This approach isn't even supported in version 3.0 of the richedit
control. Now bold can be set/unset properly for Windows or Wine using
CFE_BOLD in dwEffects and with CFM_BOLD set in the dwMask flag.
2008-06-26 21:18:20 +02:00
Dylan Smith
60757ca6d5
richedit: Corrected the conversion used for the initial font size.
...
The LOGFONT's lfHeight member is in logical units, and is being used to
set the yHeight member of CHARFORMAT2 which is supposed to be in twips.
2008-06-26 21:18:02 +02:00
Dylan Smith
c96a273f91
richedit: Moved function declarations in header to reflect locations of definitions.
2008-06-26 21:17:48 +02:00
Dylan Smith
903423286c
richedit: Added tests reveal a problem with EM_SETCHARFORMAT's affect on the undo stack.
2008-06-26 21:17:44 +02:00
Dylan Smith
6d76d43718
richedit: Fixed a bug preventing NULL pointers from being in text.
...
Opening a text file with a NULL terminated character in it was causing
an assertion error after a run was being split due to word wrap.
Windows allows NULL terminated characters to be in the text.
2008-06-26 21:16:56 +02:00
Dylan Smith
ba747f4514
richedit: Fixed the forward word movement bug.
...
Using Ctrl-RightArrow to move to the start of the next word did not
previously work when at the start of a word. This means that
Ctrl-RightArrow would not work twice in a row since it should move to
the start of the next word.
2008-06-26 21:16:29 +02:00
Dylan Smith
67024f0f34
richedit: Prevented an assertion error on startup when run on Windows.
...
The call to GetClientRect returns 0 values for the returned RECT when
called in WM_NCCREATE in on Windows, which ended up causing an assertion
error when Wine's riched20.dll replaces the native version. Moving the
call to WM_CREATE fixes this problem (probably because NCCALCSIZE is
called in between).
2008-06-26 21:15:54 +02:00
Dylan Smith
1840a5bcad
richedit: Prevented NULL value from being used to avoid a page fault.
2008-06-26 21:15:33 +02:00
Dylan Smith
6c2026a348
richedit: Show caret after pasting or streaming in text.
...
There was a missing call to ShowCaret after the caret was created.
2008-06-26 21:15:11 +02:00
Dylan Smith
eaf7becabd
richedit: Null pointer check missing on optional parameter.
...
The function ME_FindRunInRow uses two parameters to return values by
reference, and treated these parameters as if they were optional except
for the start of the function which set *pbCaretAtEnd without checking
to see if was a NULL pointer.
2008-06-26 21:14:52 +02:00
Dan Hipschman
36aa6c4c44
riched20: Implement ITextDocument_fnGetSelection.
2008-06-26 21:07:31 +02:00
Alex Villacís Lasso
c774d681ce
richedit: Fix failing EM_GETCHARFORMAT test on all platforms.
...
Default richedit font (System) in Windows causes richedit to report
CFM_BOLD as always set. Switch to Courier New in order to see that
richedit really sets the CFM_BOLD attribute in the correct selection.
2008-06-26 10:51:07 +02:00
Dylan Smith
88a9ca7c41
richedit: Tests for undo coalescing.
...
Tests for undo coalescing from previous patches sent as suggested by
Alex Villacís Lasso.
2008-06-25 11:25:32 +02:00
Dylan Smith
6f9f01f28f
richedit: bCaretAtEnd should not be reset from rewrapping text.
...
The bCaretAtEnd value in ME_TextEditor is used to identify that the
caret is at the end of a wrapped line instead of the start of the next
line in the paragraph since both these positions correspond to the
same position in the document. The bCaretAtEnd value was previously
being set back to FALSE whenever the window was resized.
2008-06-25 11:24:13 +02:00
Dylan Smith
c8e2552ad9
richedit: Trailing spaces should not affect alignment shift length.
2008-06-25 11:23:45 +02:00
Dylan Smith
308582b4f5
richedit: Allow cursor to move over trailing spaces in wrapped lines.
2008-06-25 11:23:39 +02:00
Alex Villacís Lasso
163e9d1d02
richedit: Revert patch that introduced a test that fails on all platforms.
2008-06-25 11:14:13 +02:00
Alex Villacís Lasso
acec891ac2
richedit: EM_POSFROMCHAR should take into account scrollbar position. With tests.
2008-06-24 11:44:37 +02:00
Alex Villacís Lasso
3cc6e2365a
richedit: When returning position through wParam pointer, EM_POSFROMCHAR must return 0 as LRESULT.
...
Add tests for EM_POSFROMCHAR for 1.0 and 2.0.
2008-06-24 11:43:42 +02:00
Dan Hipschman
9615e2977d
riched20/tests: Add a test for creating ITextDocument.
2008-06-23 12:39:46 +02:00
Dan Hipschman
76ee788afa
riched20/tests: Add tests for OLE interface.
2008-06-23 12:39:41 +02:00
Michael Stefaniuc
bc0acd1ac2
riched20: Remove redundant NULL check before heap_free (Smatch).
2008-06-21 11:17:08 +02:00
Andrew Talbot
11f5909368
riched20: Constify some variables.
2008-06-20 12:22:51 +02:00
Alex Villacís Lasso
0e9ed5c10e
richedit: Empty text should result in a scroll range of 0. Tests for this behavior.
2008-06-19 12:10:21 +02:00
Alex Villacís Lasso
c7873afbb2
richedit: Insertion style must NOT be cleared unless selection actually changed.
2008-06-19 12:10:13 +02:00
Alex Villacís Lasso
d2900a53e1
richedit: Add tests for URL autodetection for EM_REPLACESEL, make them pass under Wine.
2008-06-19 12:10:00 +02:00
Alex Villacís Lasso
892a0b5f1e
richedit: Add tests for URL autodetection for EM_SETTEXTEX, make them pass under Wine.
2008-06-19 12:09:46 +02:00
Alex Villacís Lasso
f213af3795
richedit: Fix for the semantics of the flags for some effects reported by EM_GETCHARFORMAT.
...
Remove workaround put in place by a previous patch, due to buggy flag reporting.
Tests to verify fixed behavior.
2008-06-19 12:08:30 +02:00
Alex Villacís Lasso
4a5d100097
richedit: Add more tests for URL autodetection on WM_CHAR, make them pass under Wine.
2008-06-19 12:07:36 +02:00
Alex Villacís Lasso
38d7ba6eff
richedit: WM_SETTEXT must immediately autodetect URLs, without waiting for a WM_CHAR.
2008-06-19 11:59:04 +02:00
Alex Villacís Lasso
60c42bd3db
richedit: Fix misreporting of match offset for EM_FINDTEXT and EM_FINDTEXTEX.
2008-06-19 11:55:27 +02:00
Francois Gouget
42a61d7ed7
Assorted spelling fixes.
2008-05-06 16:10:20 +02:00
Dylan Smith
76029ee9ec
richedit: The wrong bits were cleared from wBorders in PARAFORMAT2.
2008-05-05 21:18:19 +02:00
Dylan Smith
6f11b1b354
richedit: Removed useless code.
2008-05-05 21:18:13 +02:00
Alexandre Julliard
13ab99b404
richedit: Avoid strlen in traces.
2008-05-02 13:59:06 +02:00
Dylan Smith
10e676ab3e
richedit: Updated editor.h to reflect the contents of source files.
2008-05-01 19:36:50 +02:00
Alex Villacís Lasso
2a4fc97c4c
richedit: Add tests for EM_FINDTEXT in 1.0 emulation, make them pass under Wine.
2008-05-01 10:57:34 +02:00
Alexandre Julliard
dad21bbcbf
makefiles: List the static libraries as normal imports instead of extra libs.
2008-04-30 14:23:55 +02:00
Alex Villacís Lasso
2ab63774f1
richedit: On failure to parse incoming text as RTF, EM_STREAMIN must set dwError to -16.
2008-04-30 10:22:42 +02:00
Alex Villacís Lasso
d2a8461585
richedit: Paragraph may have multiple rows, which should possibly update nHeight.
...
Otherwise, a paragraph with multiple rows might fail to make the
scrollbar appear when displaying text.
2008-04-29 14:57:13 +02:00
Alex Villacís Lasso
829940458f
richedit: Private movement of cursors in text insertion should not cause WM_NOTIFY to be sent.
...
As text is inserted, the cursor is moved to the end, and then back to
offset 0. A reordering of operations prevents a WM_NOTIFY from being
sent on cursor being moved to the end, and another by being moved
back to the beginning. If the cursor was not at offset 0, then
exactly one WM_NOTIFY must be sent, for the movement from previous
position to the beginning. With tests to prove this change and the
previous one (modify flag should be off on WM_SETTEXT-caused
WM_NOTIFY).
2008-04-29 14:57:03 +02:00
Alex Villacís Lasso
c52bc58816
richedit: WM_SETTEXT - Clear modify step flag before any notifications can be sent.
...
Otherwise the app-defined WM_NOTIFY callback might see the modify flag
set, even though WM_SETTEXT is supposed to clear it.
2008-04-29 14:56:46 +02:00
Alex Villacís Lasso
3cad256d54
richedit: Fix modify step setting in EM_SETCHARFORMAT.
...
EM_SETCHARFORMAT with wParam==0 sets default char format and does NOT set modify step flag.
EM_SETCHARFORMAT with wParam==SCF_SELECTION only sets modify step flag when selection is nonempty.
EM_GETMODIFY returns -1, not 1, when modify flag is set.
Tests for the above behavior.
2008-04-29 14:56:23 +02:00
Alex Villacís Lasso
1fa39b50c0
richedit: Only notify selection change when selection has actually changed from previous notification.
...
Otherwise, redundant and early notifications are sent to apps that do not expect them. Fixes crash #1 with Perfect! TextEdit.
2008-04-29 14:56:11 +02:00
Alex Villacís Lasso
cac55008c9
richedit: Implement rule that in 1.0 emulation, a single CR that terminates the text is NOT a line break.
...
Fix riched32 test that now succeed.
2008-04-29 14:55:26 +02:00
Alex Villacís Lasso
4047df0f56
richedit: Flip the big switch and encode actual CR and LF into end-of-paragraph runs.
...
Document remaining uses of bEmulateVersion10 and other checks for CRLF in editor.c.
Make RTF reader emit a \r or a \r\n according to emulation, not a \n, which breaks streaming tests.
Remove todo_wine from a bunch of riched32 tests that now succeed.
2008-04-29 14:55:15 +02:00
Alex Villacís Lasso
3a271386ec
richedit: Remove indication for bCRLF, now that ME_GetTextW() knows how to honor CR and LF counters.
...
EM_GETTEXTRANGE and EM_GETSELTEXT are affected by this, so include tests to ensure no behavior was broken.
2008-04-29 14:54:59 +02:00
Alex Villacís Lasso
e8aa9dee56
richedit: Modify ME_GetTextW() to honor CR and LF encodings.
...
ME_GetTextLengthEx should ignore GTL_USECRLF in 1.0 emulation mode.
2008-04-29 14:54:46 +02:00
Alex Villacís Lasso
d95cbeef67
richedit: EM_LINELENGTH: honor CR and LF counters.
...
Add fixup to ME_FindItemAtOffset(), fixes crash by null-pointer access.
Add tests for EM_LINELENGTH.
2008-04-29 14:54:29 +02:00
Alex Villacís Lasso
3968a67eb9
richedit: EM_GETLINE: honor CR and LF counters.
...
Add richedit 1.0 tests for EM_GETLINE.
2008-04-29 14:54:21 +02:00
Alex Villacís Lasso
fd55773680
richedit: Remove reliance on bEmulateVersion10 for end-of-line handling in ME_InternalDeleteText.
2008-04-29 14:54:12 +02:00
Alex Villacís Lasso
8d37388fe7
richedit: Fixups to move over to reliance on CR and LF counters.
...
Text streamout now honors CR and LF counters.
Tests to pin down required EM_STREAMOUT behavior.
2008-04-29 14:54:05 +02:00
Alex Villacís Lasso
d47f66191e
richedit: Add support for encoding number of CR and LF contained within a line break.
2008-04-29 14:53:46 +02:00
Eric Pouech
046cfcfd22
richedit: Ensure wrapping is done all the time after inserting an RTF stream.
2008-04-25 11:44:00 +02:00
Eric Pouech
60234f8fc4
richedit: Properly handle the background in case of border in paragraph.
2008-04-25 11:43:54 +02:00
Alex Villacís Lasso
4f95cf7072
riched20: Reject RTF that is recognized as invalid.
2008-04-24 22:12:13 +02:00
Alex Villacís Lasso
d10256f309
riched20: Implement ignoring of last \par for EM_STREAMIN - 1.0 emulation.
2008-04-24 22:12:09 +02:00
Alex Villacís Lasso
7148f92c4c
riched20: Implement ignoring of last \par for EM_STREAMIN.
2008-04-24 22:11:58 +02:00
James Hawkins
ead42d7f7f
riched20: Fix a few tests that fail in XP and up.
2008-04-24 11:51:21 +02:00
Andrew Talbot
0ba8677430
riched20: Remove unused variables.
2008-04-24 11:49:53 +02:00
Alex Villacís Lasso
a9caca3eda
riched20: Yet more tests for EM_STREAMIN.
2008-04-24 11:49:14 +02:00
Alex Villacís Lasso
e0af297466
richedit: Accept RTF stream that does not start with {\rtf1 in 1.0 emulation.
2008-04-22 11:56:04 +02:00
Alex Villacís Lasso
2353e1d280
richedit: EM_STREAMIN tests for richedit 2.0.
2008-04-22 11:55:12 +02:00
Alex Villacís Lasso
820de0bd59
riched32: Implement a portion of suggested interpretation of CRLF handling for richedit 1.0 emulation.
...
Fixes a few todos introduced by previous patch.
2008-04-21 20:27:52 +02:00
Alex Villacís Lasso
46ff4a6f16
riched20: EM_SETTEXTEX supports RTF strings, with tests.
2008-04-21 20:27:17 +02:00
Alex Villacís Lasso
dfcebfb22e
riched20: Fix behavior of EM_REPLACESEL with painting disabled.
2008-04-21 20:26:54 +02:00
Austin English
aab8fae59a
Spelling fixes.
2008-04-21 14:25:05 +02:00
Austin English
313a85f163
Spelling fixes.
2008-04-17 12:25:57 +02:00
Eric Pouech
296a59da7e
richedit: Force window update when the word wrap option has changed.
2008-04-14 23:50:12 +02:00
Eric Pouech
91d57af637
richedit: For setting word wrapping, native only uses a null vs non null value.
2008-03-24 12:12:18 +01:00
Eric Pouech
df7ab004ce
richedit: Fixed a bogus computation of paragraph indentation.
2008-03-24 12:12:11 +01:00
Eric Pouech
8b6eea0a63
richedit: Fixed the initialization of the word wrap mode.
2008-03-24 12:12:07 +01:00
Eric Pouech
2870f21d06
richedit: Added missing fields to be reinitialized for the RTF \pard token.
2008-03-24 11:35:53 +01:00
Eric Pouech
4a01ddca25
richedit: Allow reading an enhanced metafile from an RTF stream.
2008-03-17 14:38:57 +01:00
Eric Pouech
984e4167af
richedit: Don't force cursor change when it's not needed.
2008-03-17 14:38:36 +01:00
Eric Pouech
5d36c47e1f
richedit: Fixed object leaks generated by context creation & destruction.
2008-03-17 14:37:58 +01:00
Eric Pouech
33d7cea120
richedit: Added support for EM_SETTARGETDEVICE with a NULL DC.
2008-03-17 14:37:43 +01:00
Eric Pouech
9c6c9d63a2
richedit: Use the FW_ constants instead of the raw values.
2008-03-17 14:36:57 +01:00
Eric Pouech
6e02f5db4b
richedit: In RTF reader, set both bold and weight attributes, so that we don't care about priority between the two.
2008-03-17 14:36:41 +01:00
Eric Pouech
0c2c43d39b
richedit: Correctly set the pitch and family for a font when reading an RTF stream.
2008-03-17 14:36:30 +01:00
Eric Pouech
a86d7bdcea
richedit: Pass left margin around when computing the size of a run, so that a tab will get a correct size.
2008-03-17 14:36:06 +01:00
Eric Pouech
34a4f9227a
richedit: Assign equivalent structures instead of copying them.
2008-03-17 14:35:40 +01:00
Eric Pouech
a64c22c8b1
richedit: Store shift-enter (keyboard) and \line (rtf) as end of row (and emit \line while saving in RTF).
2008-03-17 14:34:44 +01:00
Eric Pouech
4fb2dfc9f0
richedit: Added support for end of line inside paragraphs.
2008-03-17 14:34:24 +01:00
Eric Pouech
513fcfe48f
richedit: Fixed typo in bitmap scaling (for OLE objects).
2008-03-17 14:34:14 +01:00
Eric Pouech
68ccc4aec6
richedit: When handling \pard in RTF stream, really resets all paragraph styles.
2008-03-17 14:34:00 +01:00
Eric Pouech
cb4a41b806
richedit: Fix reading paragraph left & first indentation attributes.
2008-03-17 14:20:16 +01:00
Eric Pouech
f628a1c245
richedit: Added support for reading DI bitmaps in RTF streams.
2008-03-17 14:20:07 +01:00
Eric Pouech
9f5fa9ea45
richedit: Properly set the border width while parsing RTF stream.
2008-03-17 14:18:41 +01:00
Eric Pouech
9b2e552bf4
richedit: Prevent division by zero when 0-width border is used.
2008-03-17 14:18:36 +01:00
Andrew Talbot
612e4c2b17
riched20: Assign to structs instead of using memcpy (with typo fixes).
2008-03-14 11:21:33 +01:00
Rob Shearman
48000893f9
makefiles: Simplify the use of the IMPORTLIB variable in the DLL makefiles.
...
Only specify the root to keep platform-specifics out of the individual
DLL makefiles.
2008-03-04 20:55:01 +01:00
Francois Gouget
1552f22acf
riched20: Fix the name of the lpUsedDefChar field of GETTEXTEX.
2008-02-06 12:43:53 +01:00
Eric Pouech
9c20cdfea8
riched20: Make use of the size info in REOBJECT if present.
2008-02-05 11:13:33 +01:00
Eric Pouech
bcbf9eeb2d
riched20: Start implementing object reading out RTF stream.
2008-02-05 11:13:17 +01:00
Eric Pouech
e5f91bab15
riched20: Added support for image reading from RTF stream.
2008-02-05 11:13:00 +01:00
Eric Pouech
1e62b0e3b0
riched20: Support a couple of paragraphs attributes out of RTF stream reading.
2008-02-05 11:12:43 +01:00
Eric Pouech
251153806d
riched20: Invert graphics when they are under the selection.
2008-02-05 11:12:23 +01:00
Eric Pouech
d014db68d4
riched20: Correctly handle the wrapping when graphics are used.
...
Get rid of infinite loops when run's width was larger than the global
available width.
2008-02-05 11:12:18 +01:00
Eric Pouech
00b48f1d21
riched20: Handle the zoom in OLE objects.
2008-02-05 11:11:44 +01:00
Eric Pouech
00de77517a
riched20: Start handling OLE objects inside richedit.
2008-02-05 11:11:32 +01:00
Bang Jun-young
8e57a41913
riched20: Include wine/port.h for vsnprintf().
2008-02-04 14:18:20 +01:00
Rob Shearman
4bff248783
riched20: Always treat the nCount variable in the EM_GETTEXTEX handler as a character count.
...
Convert ex->cb into a character count before assigning it to nCount.
Remove some dubious minus ones that would result in different character
counts for the Unicode and ANSI paths.
2008-01-21 12:35:18 +01:00
Rob Shearman
374f6ec616
riched20: The wParam parameter to WM_GETTEXT contains the number of characters, not the number of bytes.
...
Fix up some places in the WM_GETTEXT handler where it was assumed that
it was a byte count.
2008-01-21 12:35:05 +01:00
Alexander Nicolaysen Sørnes
9f41a53c2a
riched20: Don't clear CFM_UNDERLINE flag when applying styles where it is set.
2008-01-21 11:51:15 +01:00
Andrew Talbot
5a5a9bcd5d
riched20: Remove unneeded casts.
2008-01-17 13:42:14 +01:00
Alexander Nicolaysen Sørnes
eec14a4de6
riched20: Include selection bar size in POSFROMCHAR.
2008-01-15 11:37:30 +01:00
Eric Pouech
d65daea454
richedit: Uniformly handle the bPitchAndFamily field out of CHARFORMAT.
2008-01-07 12:14:24 +01:00
Eric Pouech
cb4f8a80de
richedit: Check return of GetScrollInfo before accessing the returned structure.
2008-01-07 12:14:10 +01:00
Eric Pouech
f33a27517b
richedit: Initialize all the cursors at editor creation.
2008-01-07 12:14:01 +01:00
Eric Pouech
a3597cbe3b
richedit: Only copy the charset when it's defined.
2008-01-07 12:13:54 +01:00
Austin English
464258b7cd
Spelling fixes.
2008-01-03 13:08:54 +01:00
Eric Pouech
39aa3beaf2
richedit: Simplify first para style handling by creating a context.
2008-01-02 13:58:09 +01:00
Eric Pouech
d5478118a1
richedit: Don't force repaint while the redraw flag is off.
2008-01-02 13:57:53 +01:00
Eric Pouech
f43570cbf0
richedit: Optimizations for the style selection.
...
Use a ME_Context for style selection/unselection.
Store the (x,y) dpi information for a given DC in the corresponding ME_Context structure.
2008-01-02 13:57:37 +01:00
Eric Pouech
475b45d8ab
richedit: Don't recreate the DC all the time, but use uniformely a ME_Context structure where needed.
2008-01-02 13:56:02 +01:00
Eric Pouech
4cecb5dc70
richedit: Move init code after some sanity checks to avoid unneeded computations.
2008-01-02 13:55:53 +01:00
Eric Pouech
d48905cf21
richedit: Small optimisation in ME_GetSelectionInsertStyle.
2008-01-02 13:55:24 +01:00
Eric Pouech
e9be142d78
richedit: Rewrote FindPixelPos so that it always return something.
...
Made the function static as well.
2008-01-02 13:55:14 +01:00
Eric Pouech
d319033a97
richedit: Added support for intra-paragraph line space.
2008-01-02 13:54:49 +01:00
Eric Pouech
f1b029ef6a
richedit: Added support for spaces above & below paragraphs.
2008-01-02 13:54:25 +01:00
Eric Pouech
caa37c749a
richedit: Now drawing the paragraph borders (if any) from paraformat2.
2008-01-02 13:54:01 +01:00
Eric Pouech
28cc0f9e69
richedit: Fix the para computation when zoom is used.
2008-01-02 13:52:52 +01:00
Eric Pouech
f4fd063101
richedit: Enforce usage of paraformat2 fields instead of homegrown ones for paragraphs.
2008-01-02 13:52:10 +01:00
Eric Pouech
0e8c087561
richedit: Properly copying the paraformat2 structure for paragraphs.
2008-01-02 13:51:49 +01:00
Eric Pouech
8f60c8c46e
richedit: Now dumping all fields from the paraformat2 structure.
2008-01-02 13:50:38 +01:00
Eric Pouech
566912dc3b
richedit: Correctly initialize the paraformat structure.
2008-01-02 13:50:04 +01:00
Eric Pouech
0549b9009a
richedit: Simplified handling of background brush while painting.
2008-01-02 13:49:57 +01:00
Eric Pouech
2602a39bd9
richedit: Now painting the newly supported underline types.
2008-01-02 13:48:53 +01:00
Eric Pouech
6b591ef23a
richedit: Extend the usage of underlinetype from charformat2 in richedit.
2008-01-02 13:48:11 +01:00
Eric Pouech
13f86afe1f
richedit: Don't allow recursive EN_REQUESTRESIZE notifications.
2008-01-02 13:47:41 +01:00
Eric Pouech
c2631d8537
richedit: Correctly copy the pitch and family field.
2008-01-02 13:47:06 +01:00
Eric Pouech
8d0799a741
richedit: Fully initialize the first style.
2008-01-02 13:46:53 +01:00
Eric Pouech
be785a295f
richedit: Correctly set the CFM_WEIGHT in charformat2.
2008-01-02 13:46:42 +01:00
Eric Pouech
a607ad316e
richedit: Fixed a couple of charformatXXm structure conversions because of alignment issues.
2008-01-02 13:46:22 +01:00
Eric Pouech
71f52d54bd
richedit: Added support for some message (key, mouse) filtering events.
2008-01-02 13:45:08 +01:00
Dmitry Timoshkov
5a6e0ea46f
riched20: Remove a redundant parameter from trace.
2007-12-20 12:17:26 +01:00
Maarten Lankhorst
8e639ec392
riched20: Fix bugs in EM_SETOPTIONS.
...
Add SELECTIONBAR to mask, and use settings rather then lParam. 2 subtle
bugs that prevent selectionbar from working.
2007-12-18 12:32:55 +01:00
Maarten Lankhorst
b81335501f
riched20: Implement ECO/EM SELECTIONBAR.
2007-12-17 11:34:40 +01:00
Alexandre Julliard
f0c4fdbad9
riched20/tests: Avoid using size_t in traces.
2007-12-14 14:31:35 +01:00
Maarten Lankhorst
4637a4ef49
riched20: Make some functions static.
2007-12-14 12:26:48 +01:00
Alex Villacís Lasso
ae7b2c914b
riched32: Fix regression in WM_GETTEXTLENGTH on richedit 1.0 emulation.
2007-12-12 13:48:19 +01:00
Michael Stefaniuc
0a92e10640
riched20: Remove the RTFAlloc() wrapper around heap_alloc().
2007-12-08 19:55:26 +01:00
Michael Stefaniuc
4210cafc04
riched20: Rename the wrappers around HeapAlloc() &Co to use the new standard naming.
2007-12-08 19:54:58 +01:00
Alex Villacís Lasso
42d6cc7cf5
riched20: Invalidate all the text on bogus last selection.
2007-12-08 19:54:23 +01:00
Alexandre Julliard
c0b12351e0
Avoid size_t types in traces.
2007-12-07 18:49:18 +01:00
Alex Villacís Lasso
f945f16de2
riched20: WM_GETTEXTLENGTH should include CRLF conversions in returned count.
2007-12-07 17:36:01 +01:00
Alex Villacís Lasso
3b636b58ba
riched20: EM_GETTEXTLENGTHEX must not count last paragraph break if GTL_USECRLF.
2007-12-07 17:36:01 +01:00
Alex Villacís Lasso
99f0dc4ff4
riched20: WM_GETTEXT should return 0 on overflow but fill buffer anyway.
2007-12-07 17:06:53 +01:00
Alex Villacís Lasso
4545f1944e
riched20: EM_GETTEXTEX with GT_USECRLF should not leave a single CR when running out of space.
2007-12-07 17:06:45 +01:00
Alexandre Julliard
ad9396302d
Removed some unneeded imports.
2007-12-06 21:24:24 +01:00
Alex Villacís Lasso
8ae0eeafc6
riched20: Fix test failure in test_WM_PASTE.
...
Native riched20 won't obey simple WM_CHAR or WM_KEYDOWN/WM_KEYUP
messages when processing Ctrl-Key keystrokes. Use keybd_event()
instead.
2007-11-08 12:36:35 +01:00
Alex Villacís Lasso
5d8b8cd899
riched20: EM_GETMODIFY should not report modification after WM_SETTEXT (fixes todo_wine).
2007-11-06 13:01:09 +01:00
Alex Villacís Lasso
3cfad1fbf3
riched20: Fix detection of CFE_LINK on WinXP-SP2.
2007-11-05 14:46:35 +01:00
Alex Villacís Lasso
38234fabeb
riched20: Allow for Win98 behavior for return value of EM_REPLACESEL.
2007-10-31 14:06:08 +01:00
Alex Villacís Lasso
e7296eaeaa
riched20: Fix test crash on WinXP-SP2.
2007-10-29 12:08:25 +01:00
Francois Gouget
c4b1195c0c
Assorted spelling fixes.
2007-10-23 18:20:27 +02:00
Alex Villacís Lasso
469669e629
riched20: 2.0 and higher inserts CRCRLF as space (with tests).
2007-10-22 13:50:13 +02:00
Alex Villacís Lasso
f54aa40746
riched20: Single-line control must refuse to insert carriage returns (with tests).
2007-10-19 12:26:25 +02:00
Alex Villacís Lasso
63b12f8602
riched20: Minimal fix for WM_SETTEXT without ES_MULTILINE style.
2007-09-28 10:59:59 +02:00
Francois Gouget
d32d8ac862
riched20/tests: Add '\n's to ok() calls.
2007-09-27 20:12:06 +02:00
Alex Villacís Lasso
03f3a40a03
riched20: EM_SETCHARFORMAT must fail and return 0 with TM_PLAINTEXT and SF_SELECTION.
2007-09-27 11:58:52 +02:00
Alex Villacís Lasso
be5105e894
riched20: EM_SETCHARFORMAT must return 0, not assert, on invalid struct size.
2007-09-27 11:07:54 +02:00
Alex Villacís Lasso
fa5230fb54
riched20: EM_SETCHARFORMAT must return 1 on success, not 0.
2007-09-26 14:40:54 +02:00
Alex Villacís Lasso
00e562735d
riched20: Fix WM_GETTEXT to change \r to \r\n.
2007-09-24 13:44:28 +02:00
Alex Villacís Lasso
47316d62bb
riched20: Tests show WM_GETTEXT change \r to \r\n.
2007-09-24 13:44:19 +02:00
Clinton Stimpson
f34cb461e7
riched20: Only WM_CHAR respects text limit.
2007-09-21 12:05:39 +02:00
Clinton Stimpson
f8f07dfe54
riched20: Adjust event mask when sending EN_CHANGE notification.
2007-09-20 16:47:30 +02:00
Clinton Stimpson
b095ade908
riched20: Add tests for text limit behavior.
2007-09-20 12:04:23 +02:00
Clinton Stimpson
77fe86620c
riched20: Add test for event masks and notifications.
2007-09-19 14:57:56 +02:00
Alex Villacís Lasso
157a0199e9
riched20: Prevent overflow on richedit debug channel.
2007-09-17 13:46:15 +02:00
Lei Zhang
9210defdf7
riched20: Do not pass NULL lParam to ME_ToUnicode for EM_REPLACESEL.
2007-09-11 11:47:54 +02:00
Andrew Talbot
b150ea67a9
riched20: Constify some variables.
2007-08-17 12:01:37 +02:00
Andrew Talbot
291dd7a090
riched20: Constify some variables.
2007-08-16 11:35:06 +02:00
Lei Zhang
13ae5f8e8c
riched20: Add missing scroll bar update.
2007-08-16 11:35:06 +02:00
Lei Zhang
0d4707c284
riched20: Properly calculate control display height.
2007-08-16 11:35:06 +02:00
Huw Davies
0dcebea44d
riched20: Add some test for EM_GETTEXTLENGTHEX and fix the single line edit cases.
2007-08-16 11:10:25 +02:00
Andrew Talbot
da68f3943f
riched20: Constify some variables.
2007-08-15 10:41:21 +02:00
Andrew Talbot
ed93ed9a08
riched20: Constify some variables.
2007-08-14 13:28:05 +02:00
Andrew Talbot
2e2efd448a
riched20: Constify some variables.
2007-08-13 12:24:28 +02:00
Aric Stewart
c03125a1be
riched20: Make richedit control IME aware.
2007-06-28 12:16:12 +02:00
Michael Stefaniuc
0152ec0375
janitorial: Remove superfluous casts of void pointers to other pointer types.
2007-06-27 12:53:50 +02:00
Michael Stefaniuc
df01f67175
riched20: Do not use wide character constants.
2007-06-22 12:18:39 +02:00
Lei Zhang
55771014e1
riched20: Add tests for EM_FORMATRANGE.
2007-06-19 11:33:07 +02:00
Francois Gouget
96c337f0a1
Assorted spelling fixes.
2007-06-07 19:24:32 +02:00
Huw Davies
94dfc0e80e
riched20: Don't mess with the caret if we don't have focus.
2007-06-06 12:09:53 +02:00
Francois Gouget
fa48cb042c
Assorted spelling fixes.
2007-05-29 13:47:18 +02:00
Dmitry Timoshkov
3c9e7a7f33
wine: Switch to using 'long' for INT_PTR type for 64-bit compatibility.
2007-05-25 20:37:56 +02:00
Andrew Talbot
5588233957
riched20: Exclude unused headers.
2007-05-18 14:11:33 +02:00
Marcus Meissner
ec11114c55
riched32: Avoid implicit time().
2007-05-07 14:25:20 +02:00
Dmitry Timoshkov
9bde411087
riched20: Add the tests for EM_SETTEXTEX/EM_GETTEXTEX in addition to WM_SETTEXT/WM_GETTEXT, make them pass under Wine.
2007-05-02 14:58:58 +02:00
Clinton Stimpson
552bc81f1e
riched20: Set modify state when removing text.
2007-04-26 14:24:52 +02:00
Clinton Stimpson
4152c14df4
riched20: Fix text replacement with text limit.
2007-03-29 21:07:52 +02:00
Dmitry Timoshkov
592b53d0a4
riched20: Split unicode and ansi window procs, handle messages depending on the unicode flag.
...
Add a hack for WM_GETTEXT in RichEdit20W class when running in win9x emulation mode.
2007-03-22 15:47:25 +01:00
Dmitry Timoshkov
11e01b17de
riched20: Add a test that shows that under Win9x RichEdit20W windows are not unicode, but always expect to see unicode input.
2007-03-21 15:55:30 +01:00
Jan Zerebecki
58f37a1251
riched20: Add DebugInfo to critical sections.
2007-03-12 13:39:14 +01:00
Jason Green
2aa8463a94
riched20: If outside of the richedit window, return earlier.
...
Prevents a crash when selecting text outside of a richedit control box.
2007-02-15 11:21:45 +01:00
Marcus Meissner
ddb5720118
riched20: Removed more dead code.
2007-02-09 11:48:46 +01:00
Marcus Meissner
886b15e723
riched20: Fixed wrong condition (Coverity).
2007-02-06 14:59:26 +01:00
Matt Finnicum
7eabbec632
riched20: Create undos in StreamIn at the right times. Adds tests for when StreamIn should be undoable.
2007-01-25 11:06:36 +01:00
Matt Finnicum
306013d4e5
riched20: Remove excessive traces from reader.c.
2007-01-25 11:06:28 +01:00
Andrew Talbot
166b3a6cdb
riched20: Declare some functions static.
2007-01-24 12:31:29 +01:00
Matt Finnicum
f12e6232a2
riched20: Use CharFromPos instead of FindPixelPos in LinkNotify so it accounts for scrolling.
2007-01-24 12:14:11 +01:00
Matt Finnicum
dbcf2e391c
riched20: Implement EM_LIMITTEXT and some simple tests.
2007-01-24 12:14:02 +01:00
Joel Parker
2319999a05
Remove redundant semicolons for ANSI compatibility.
2007-01-17 11:58:15 +01:00
Clinton Stimpson
a065d0f68d
riched20: Fix crash undoing a paste.
2007-01-12 11:25:42 +01:00
Clinton Stimpson
bf86302e19
riched20: Fix modification state for several operations.
2007-01-11 12:04:46 +01:00
Lei Zhang
581321d420
riched20: Move EM_EXSETSEL fix into ME_SetSelection.
2006-12-05 11:37:46 +01:00
Lei Zhang
c05bcabe9f
riched20: Fixes and additional conformance tests for EM_EXSETSEL.
2006-12-04 12:23:32 +01:00
Dmitry Timoshkov
a5992939d4
riched20: Make some data const.
2006-11-29 12:44:34 +01:00
Matt Finnicum
e864f2f2c3
riched20: Make EM_SETPARAFORMAT use ME_RewrapRepaint instead of ME_UpdateRepaint.
2006-11-28 12:14:43 +01:00