Recent

Author Topic: RichMemo - more detailed doc?  (Read 20439 times)

skalogryz

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2285
    • havefunsoft.com
Re: RichMemo - more detailed doc?
« Reply #45 on: March 18, 2015, 03:10:38 am »
r4047 fixes the issue with wordwrap.
Patron Cocoa Widgetset development https://www.patreon.com/skalogryz

dsw1

  • Newbie
  • Posts: 3
Re: RichMemo - more detailed doc?
« Reply #46 on: August 31, 2015, 08:19:44 pm »
I new to Lazarus and trying to convert a Delphi project to Lazarus. I have a problem setting up tabs in RichMemo

I have a procedure like this:
Procedure ShowList(FileName: string; HeaderText: string;
  RealInt: boolean; Decimals: integer);
var
  TabPositions: TTabStopList;
begin
  TabPositions.Count:=3;
  TabPositions.Tabs[0].Offset:= 30;
  TabPositions.Tabs[1].Offset:= 140;
  TabPositions.Tabs[2].Offset:= 200;
  ShowList.Editor.SetParaTabs(0, 363, TabPositions);

When I run my application I get Project ... raised exception class ''External: SIGSEGV'
How to be solved?

skalogryz

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2285
    • havefunsoft.com
Re: RichMemo - more detailed doc?
« Reply #47 on: August 31, 2015, 09:00:51 pm »
try this:
Code: [Select]
var
  TabPositions: TTabStopList;
begin
  TabPositions.Count:=3;
  SetLength(TabPositions.Tabs, TabPositions.Count);
  TabPositions.Tabs[0].Offset:= 30;
  TabPositions.Tabs[1].Offset:= 140;
  TabPositions.Tabs[2].Offset:= 200;
  ShowList.Editor.SetParaTabs(0, 363, TabPositions);
or this:
Code: [Select]
var
  TabPositions: TTabStopList;
begin
  InitTabStopList(TabPosistions, [30,140,200]);
  ShowList.Editor.SetParaTabs(0, 363, TabPositions);
Patron Cocoa Widgetset development https://www.patreon.com/skalogryz