Open GoogleCodeExporter opened 9 years ago
OK. It's the line I changed in RichOle that throws the SIGSEGV error.
From http://www.freepascal.org/docs-html/user/userse63.html
Hint: Conversion between ordinals and pointers is not portable
If you typecast a pointer to a longint (or vice-versa), this code will not compile on a machine using 64 bits addressing.
So I've modified these two functions in RichOle:
function RichEdit_SetOleCallback(RichEdit: HWnd; OleInterface:
IRichEditOleCallback): BOOL;
begin
Result:= BOOL(SendMessage(RichEdit, EM_SETOLECALLBACK, 0, Int64(OleInterface)));
end;
function RichEdit_GetOleInterface(RichEdit: HWnd; out OleInterface:
IRichEditOle): BOOL;
begin
Result:= BOOL(SendMessage(RichEdit, EM_GETOLEINTERFACE, 0, Int64(OleInterface)));
end;
It built and executed OK. I haven't done much testing yet, but it's a big step
forward. :o)
Original comment by martin.x...@gmail.com
on 16 Jun 2012 at 6:07
Hi,
and tx to reply me.
I desinstalled the win64 version, and with the win32 version, I could install
the lzRichEdit component.
I got a lot of warnings, about the conversion of Dword, but it's installed.
Otherwise, how can I get the first visible line with this component ?
Original comment by neshiqot...@gmail.com
on 17 Jun 2012 at 3:29
I think if you Google RichEdit+"get first visible line", you will find lots of
hints.
https://www.google.com/search?q=RichEdit+%22get+first+visible+line%22&ie=utf-8&o
e=utf-8&aq=t&rls=org.mozilla:en-US:official&client=firefox-beta
It's not something I've done myself.
Original comment by martin.x...@gmail.com
on 17 Jun 2012 at 5:46
Stumbled on this while searching for something else:
http://forums.codeguru.com/archive/index.php/t-344721.html
Sounds like what you want.
Note: when the owner comes back here, we will get busted for thread drift.
This is not an all-purpose forum, but a place for him to get notes about bugs.
:o)
Original comment by martin.x...@gmail.com
on 17 Jun 2012 at 5:58
OK, TX
Of course, I googled before posting, just adding also Lazarus+RichEdit.
Then the search is much smaller.
Btw, this code FirstLine := RichEdit.Perform(EM_GETFIRSTVISIBLELINE, 0, 0);
was working with a Delphi2005 TRE, and don't work with the present Lazarus RE.
EM_GETFIRSTVISIBLELINE isn't found by Laz compiler, like in the code you give
me, since it's a C++ code.
Original comment by sagnot.m...@gmail.com
on 17 Jun 2012 at 6:54
Oops. Sorry about the C++ reference.
If you think it's a bug in LazRichEdit, it's time to punch the "New Issue"
button in the upper-left corner of this page. (I'm frazzled right now with
trying to get some old RichEditURL routines to work. As with your case, they
worked with Delphi x32, but fail now with Lazarus x64. I'm not convinced it is
a LazRichEdit bug. I seem to be all alone in my frustration. I'm not ready to
pose the question in a forum because I don't have it well-defined ...).
Original comment by martin.x...@gmail.com
on 17 Jun 2012 at 8:25
Adding windows in the uses, that works good.
But a topline property, like in the Synedit, would be great.
Original comment by sagnot.m...@gmail.com
on 17 Jun 2012 at 10:06
Original issue reported on code.google.com by
martin.x...@gmail.com
on 16 Jun 2012 at 5:07