* * *

Author Topic: Get and Restore scroll position  (Read 369 times)

AndyJonson

  • New member
  • *
  • Posts: 10
Get and Restore scroll position
« on: May 15, 2017, 10:55:03 pm »
Can I do this?

GET: (in timer)
RichMemo1.VertScrollBar.Smooth:=true;
vs:=RichMemo1.VertScrollBar.Position;

Result:
vs=25 at 2nd line.

RichMemo1.VertScrollBar.Smooth:=false;
vs:=RichMemo1.VertScrollBar.Position;

Result:
vs=25 at 2nd line.


SET:
RichMemo1.VertScrollBar.Smooth:=false;
RichMemo1.VertScrollBar.Position:=25;

Result:
Jump to line 25!

Can I get scroll position in line ID and set/restore line ID? OR get scroll position in pixels and set/restore in pixels?

skalogryz

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1812
Re: Get and Restore scroll position
« Reply #1 on: July 06, 2017, 10:20:35 pm »
The scrolling positioning has been fixed with r5969.


 

Recent

Get Lazarus at SourceForge.net. Fast, secure and Free Open Source software downloads Open Hub project report for Lazarus