LazReport, methods for preview scrolling, from Alexsey Lagunov

git-svn-id: trunk@44435 -
This commit is contained in:
jesus 2014-03-15 18:21:26 +00:00
parent 9459918ec8
commit 178cdf98b7

View File

@ -71,6 +71,14 @@ type
function Print: boolean;
procedure Edit;
procedure Find;
procedure SmallScrollUp;
procedure SmallScrollDown;
procedure SmallScrollLeft;
procedure SmallScrollRight;
procedure SmallScrollNext;
procedure SmallScrollPrior;
function ExportTo(AFileName: string): boolean;
property AllPages: Integer read GetAllPages;
property Page: Integer read GetPage write SetPage;
@ -382,6 +390,42 @@ begin
FWindow.FindBtnClick(nil);
end;
procedure TfrPreview.SmallScrollUp;
begin
if FWindow.VScrollBar.Enabled then FWindow.VScrollBar.SetFocus;
FWindow.ScrollBarDelta(-FWindow.VScrollBar.SmallChange, 0)
end;
procedure TfrPreview.SmallScrollDown;
begin
if FWindow.VScrollBar.Enabled then FWindow.VScrollBar.SetFocus;
FWindow.ScrollBarDelta(FWindow.VScrollBar.SmallChange, 0)
end;
procedure TfrPreview.SmallScrollLeft;
begin
if FWindow.HScrollBar.Enabled then FWindow.HScrollBar.SetFocus;
FWindow.ScrollBarDelta(-FWindow.HScrollBar.SmallChange, 0)
end;
procedure TfrPreview.SmallScrollRight;
begin
if FWindow.HScrollBar.Enabled then FWindow.HScrollBar.SetFocus;
FWindow.ScrollBarDelta(FWindow.HScrollBar.SmallChange, 0)
end;
procedure TfrPreview.SmallScrollNext;
begin
if FWindow.VScrollBar.Enabled then FWindow.VScrollBar.SetFocus;
FWindow.ScrollBarDelta(FWindow.VScrollBar.LargeChange, 0)
end;
procedure TfrPreview.SmallScrollPrior;
begin
if FWindow.VScrollBar.Enabled then FWindow.VScrollBar.SetFocus;
FWindow.ScrollBarDelta(-FWindow.VScrollBar.LargeChange, 0)
end;
function TfrPreview.ExportTo(AFileName: string): boolean;
var
i: Integer;