Recent

Author Topic: Richmemo  (Read 29531 times)

typo

  • Hero Member
  • *****
  • Posts: 3051
Re: Richmemo
« Reply #15 on: December 19, 2014, 05:49:42 pm »
Maybe we can merge the 2 projects, RichMemo and lzRichEdit. Consider this.

skalogryz

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2770
    • havefunsoft.com
Re: Richmemo
« Reply #16 on: December 19, 2014, 06:09:55 pm »
Sure, but only, if agreement on API is reached.

I'm very careful about creating APIs.. that's why Print() is not in RichMemo yet.
As well as some of the methods (i.e. paragraph numbering) is not officially "released" (even though available for win32)
I found my way out of not being compatible with delphi RichEdit, by using helpers.

I don't see the component's API as reflection of WinAPI. Just like you noted - WinAPI might be a bit hostile to a developer :)


typo

  • Hero Member
  • *****
  • Posts: 3051
Re: Richmemo
« Reply #17 on: December 19, 2014, 06:37:38 pm »
What is wrong about Print method? It works quite well in Windows. I think it will be difficult to you making something different from that.

skalogryz

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2770
    • havefunsoft.com
Re: Richmemo
« Reply #18 on: December 19, 2014, 06:53:24 pm »
What is wrong about Print method? It works quite well in Windows. I think it will be difficult to you making something different from that.
well...
There's RichEdit delphi method Print.
Code: [Select]
procedure TRichEdit.Print(const caption: string);...and people were complaining about not being able to setup margins.
I believe that's why lzRichEdit finished with
Code: [Select]
procedure Print(const DocumentTitle: string; Margins :TMargins)
I believe, that giving an option just for margins is still not enough, and the method should be something like this.

Code: [Select]
procedure Print(const PrintOptions: TPrintOptions)
where TPrintOptions looks like this:
Code: [Select]
  TPrintOptions = record
    caption : String;
    margins : TMargins;
    pages   : array of TPageRange;
    pagesCount : integer;
    target : TCanvas; // for preview printing
    targetRect : TRect; // for preview reszing
    ... something else? + any future extension of printing could be consumed.
  end;

With that method, a backward (delphi) compatible method can be easily implemented.

skalogryz

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2770
    • havefunsoft.com
Re: Richmemo
« Reply #19 on: December 19, 2014, 07:19:17 pm »
I'm currently preparing cross-platform apis for low-cost images insertion. See a demo at youtube

typo

  • Hero Member
  • *****
  • Posts: 3051
Re: Richmemo
« Reply #20 on: December 19, 2014, 07:25:09 pm »
Good.

Chat apps will like this.
« Last Edit: December 19, 2014, 07:32:45 pm by typo »

typo

  • Hero Member
  • *****
  • Posts: 3051
Re: Richmemo
« Reply #21 on: December 20, 2014, 12:21:54 pm »
I found my way out of not being compatible with delphi RichEdit, by using helpers.

I think it can be a problem because lzRichEdit is entirely compatible with Delpihi, according to general guidelines of Lazarus.

skalogryz

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2770
    • havefunsoft.com
Re: Richmemo
« Reply #22 on: December 20, 2014, 02:15:54 pm »
yes, being Delphi compatible is certainly a plus. Which is more of a burden for me than a benefit.

A thus, It has never been a priority for RichMemo. Instead a cross-platform functionality. But I'm glad I was able to get avoid sub-classing.
« Last Edit: December 20, 2014, 02:23:46 pm by skalogryz »

typo

  • Hero Member
  • *****
  • Posts: 3051
Re: Richmemo
« Reply #23 on: December 20, 2014, 03:45:42 pm »
The lack of a RichEdit in Lazarus is a great problem for converting projects from Delphi.

Workarounds go from TMemo to IpHtmlPanel.
« Last Edit: December 20, 2014, 03:49:01 pm by typo »

typo

  • Hero Member
  • *****
  • Posts: 3051
Re: Richmemo
« Reply #24 on: December 21, 2014, 05:18:20 pm »
Maybe Lazarus can house the 2 ways, one of Delphi compatibility, and another, with an independent way. I don't consider this (non-compatibility) as a not worthy way, but a Delphi user rages.
« Last Edit: December 21, 2014, 05:41:49 pm by typo »

skalogryz

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2770
    • havefunsoft.com
Re: Richmemo
« Reply #25 on: December 21, 2014, 07:33:04 pm »
Richmemo provides basic richedit properties: SelAttributes and Paragraph through a class helper - just add richmemohelpers unit to uses section. As well as find() method.


arneolav

  • Full Member
  • ***
  • Posts: 195
    • ElTranslador
Re: Richmemo
« Reply #26 on: December 21, 2014, 08:28:50 pm »
Uses ...RichMemo, RichMemoHelpers;

---> unit1.pas(1,1) Fatal: Unit RichMemoHelpers searched but RichMemo found 

 Lazarus 1.2.6 r46529 FPC 2.6.4 i386-win32-win32/win64
Win XP, Win7, Win 10, Win 11, win64 , Lazarus 3.0RC1
Delphi/DevExpress

skalogryz

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2770
    • havefunsoft.com
Re: Richmemo
« Reply #27 on: December 21, 2014, 08:52:16 pm »
what's your RichMemo package revision? The unit has been added with r3752 (19 nov 2014)
The latest richmemo update was with r3847 (20 dec 2014)

arneolav

  • Full Member
  • ***
  • Posts: 195
    • ElTranslador
Re: Richmemo
« Reply #28 on: December 21, 2014, 10:54:01 pm »
Version 1.0.0 , Same as SourceForeget, no update ...?
Win XP, Win7, Win 10, Win 11, win64 , Lazarus 3.0RC1
Delphi/DevExpress

typo

  • Hero Member
  • *****
  • Posts: 3051
Re: Richmemo
« Reply #29 on: December 21, 2014, 11:27:32 pm »
Try my RichMemo revision, only 45KB.

What is special about this revision? Well, it compiles and installs fine on Windows.

 

TinyPortal © 2005-2018