VoyForums

VoyUser Login optional ] [ Contact Forum Admin ] [ Main index ] [ Post a new message ] [ Search | Check update time | Archives: 1234[5]678910 ]


[ Next Thread | Previous Thread | Next Message | Previous Message ]

Date Posted: 06:34:29 10/11/02 Fri
Author: Michel
Subject: Re: OnKey Events & Print Preview
In reply to: Brian Orme 's message, "OnKey Events & Print Preview" on 14:56:39 10/10/02 Thu


Hi Brian,

For some reason I did not publish these events. I don't see why not. In the published section of TImageScroll box add,

property OnKeyDown;
property OnKeyUp;
property OnKeyPress;


Then recompile the En_Dn (where n is your delphi version).

To obtain the visible content in a TImageScrollBox, you can use the CopyRect function of TCanvas. To acess the visible image, use ImageScrollBox.DisplayedGraphic.Canvas, and use the ImageScrollBox.Horz/VertScrollBar.Position to determine which section is selected.

Best regards,

Michel

>Michel
>
>Two questions
>
>1)I would like to use key press events with
>TImageScrollBox
>is this possible since the OnKeyPress, OnKeyUp and
>OnKeyDown
>events are not available?, how can this be achieved.
>
>2) I am using a large image and am trying to select
>the visible content in the scroll window to use as a
>print preview on another form, can you advise the best
>way of doing this.

[ Next Thread | Previous Thread | Next Message | Previous Message ]

[ Contact Forum Admin ]


Forum timezone: GMT-5
VF Version: 2.94, ConfDB:
Before posting please read our privacy policy.
VoyForums(tm) is a Free Service from Voyager Info-Systems.
Copyright © 1998-2008 Voyager Info-Systems. All Rights Reserved.