// Borland C++ Builder
// Copyright (c) 1995, 1999 by Borland International
// All rights reserved

// (DO NOT EDIT: machine generated header) 'CRVPP.pas' rev: 4.00

#ifndef CRVPPHPP
#define CRVPPHPP

#pragma delphiheader begin
#pragma option push -w-
#include <Printers.hpp>	// Pascal unit
#include <RVScroll.hpp>	// Pascal unit
#include <Forms.hpp>	// Pascal unit
#include <Controls.hpp>	// Pascal unit
#include <Graphics.hpp>	// Pascal unit
#include <Classes.hpp>	// Pascal unit
#include <SysUtils.hpp>	// Pascal unit
#include <Messages.hpp>	// Pascal unit
#include <Windows.hpp>	// Pascal unit
#include <SysInit.hpp>	// Pascal unit
#include <System.hpp>	// Pascal unit

//-- user supplied -----------------------------------------------------------

namespace Crvpp
{
//-- type declarations -------------------------------------------------------
#pragma option push -b-
enum TRVZoomMode { rvzmFullPage, rvzmPageWidth, rvzmCustom };
#pragma option pop

class DELPHICLASS TRVMarginsPen;
#pragma pack(push, 4)
class PASCALIMPLEMENTATION TRVMarginsPen : public Graphics::TPen 
{
	typedef Graphics::TPen inherited;
	
__published:
	__property Style ;
	__property Color ;
public:
	#pragma option push -w-inl
	/* TPen.Create */ inline __fastcall TRVMarginsPen(void) : Graphics::TPen() { }
	#pragma option pop
	#pragma option push -w-inl
	/* TPen.Destroy */ inline __fastcall virtual ~TRVMarginsPen(void) { }
	#pragma option pop
	
};

#pragma pack(pop)

class DELPHICLASS TCustomRVPrintPreview;
#pragma pack(push, 4)
class PASCALIMPLEMENTATION TCustomRVPrintPreview : public Rvscroll::TRVScroller 
{
	typedef Rvscroll::TRVScroller inherited;
	
private:
	int SavedZoomPercent;
	int FPageNo;
	int FZoomPercent;
	TRVZoomMode FZoomMode;
	int FPageWidth;
	int FPageHeight;
	Controls::TCursor FZoomInCursor;
	Controls::TCursor FZoomOutCursor;
	Classes::TNotifyEvent FZoomChanged;
	TRVMarginsPen* FMarginsPen;
	void __fastcall SetZoomPercent(const int Value);
	void __fastcall SetZoomMode(const TRVZoomMode Value);
	HIDESBASE MESSAGE void __fastcall WMEraseBkgnd(Messages::TWMEraseBkgnd &Message);
	HIDESBASE MESSAGE void __fastcall WMSize(Messages::TWMSize &Message);
	void __fastcall SetZoomInCursor(const Controls::TCursor Value);
	void __fastcall SetZoomOutCursor(const Controls::TCursor Value);
	void __fastcall SetMarginsPen(const TRVMarginsPen* Value);
	
protected:
	DYNAMIC bool __fastcall CanDrawContents(void);
	DYNAMIC void __fastcall DrawContents(Graphics::TCanvas* Canvas, const Windows::TRect &R);
	virtual void __fastcall DrawMargins(Graphics::TCanvas* Canvas, const Windows::TRect &R, int PageNo)
		;
	DYNAMIC int __fastcall GetPreview100PercentWidth(void);
	DYNAMIC int __fastcall GetPreview100PercentHeight(void);
	DYNAMIC int __fastcall GetPageCount(void);
	virtual void __fastcall Paint(void);
	virtual void __fastcall Loaded(void);
	DYNAMIC void __fastcall Click(void);
	DYNAMIC int __fastcall GetDefSmallStep(void);
	void __fastcall UpdateCursor(void);
	virtual void __fastcall SetPageNo(const int Value);
	__property Controls::TCursor ZoomInCursor = {read=FZoomInCursor, write=SetZoomInCursor, default=102
		};
	__property Controls::TCursor ZoomOutCursor = {read=FZoomOutCursor, write=SetZoomOutCursor, default=103
		};
	__property Classes::TNotifyEvent OnZoomChanged = {read=FZoomChanged, write=FZoomChanged};
	__property TRVMarginsPen* MarginsPen = {read=FMarginsPen, write=SetMarginsPen};
	
public:
	__fastcall virtual TCustomRVPrintPreview(Classes::TComponent* AOwner);
	__fastcall virtual ~TCustomRVPrintPreview(void);
	void __fastcall SetZoom(int Percent);
	void __fastcall First(void);
	void __fastcall Last(void);
	void __fastcall Next(void);
	void __fastcall Prev(void);
	void __fastcall UpdateView(void);
	__property int PageNo = {read=FPageNo, write=SetPageNo, nodefault};
	__property int ZoomPercent = {read=FZoomPercent, write=SetZoomPercent, nodefault};
	__property TRVZoomMode ZoomMode = {read=FZoomMode, write=SetZoomMode, nodefault};
public:
	#pragma option push -w-inl
	/* TWinControl.CreateParented */ inline __fastcall TCustomRVPrintPreview(HWND ParentWindow) : Rvscroll::TRVScroller(
		ParentWindow) { }
	#pragma option pop
	
};

#pragma pack(pop)

//-- var, const, procedure ---------------------------------------------------
static const Shortint crRVZoomIn = 0x66;
static const Shortint crRVZoomOut = 0x67;

}	/* namespace Crvpp */
#if !defined(NO_IMPLICIT_NAMESPACE_USE)
using namespace Crvpp;
#endif
#pragma option pop	// -w-

#pragma delphiheader end.
//-- end unit ----------------------------------------------------------------
#endif	// CRVPP
