// Borland C++ Builder
// Copyright (c) 1995, 2002 by Borland Software Corporation
// All rights reserved

// (DO NOT EDIT: machine generated header) 'EnAnEdit.pas' rev: 6.00

#ifndef EnAnEditHPP
#define EnAnEditHPP

#pragma delphiheader begin
#pragma option push -w-
#pragma option push -Vx
#include <EnCtlRsz.hpp>	// Pascal unit
#include <ExtCtrls.hpp>	// Pascal unit
#include <Menus.hpp>	// Pascal unit
#include <StdCtrls.hpp>	// Pascal unit
#include <Dialogs.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 Enanedit
{
//-- type declarations -------------------------------------------------------
class DELPHICLASS TGenericMark;
class PASCALIMPLEMENTATION TGenericMark : public Controls::TGraphicControl 
{
	typedef Controls::TGraphicControl inherited;
	
private:
	#pragma pack(push, 1)
	Types::TRect FDisplayRect;
	#pragma pack(pop)
	
	int FDisplayResolution;
	#pragma pack(push, 1)
	Types::TRect FMarkRect;
	#pragma pack(pop)
	
	double FZoomFactor;
	Enctlrsz::TControlResizer* FControlResizer;
	bool FEditMode;
	bool FModified;
	Graphics::TColor FColor;
	void __fastcall SetDisplayRect(const Types::TRect &Value);
	void __fastcall SetDisplayResolution(int Value);
	void __fastcall SetZoomFactor(double Value);
	virtual void __fastcall SetMarkRect(const Types::TRect &Value);
	void __fastcall SetEditMode(bool Value);
	void __fastcall MovedOrSized(System::TObject* Sender, const Types::TRect &OldBounds, const Types::TRect &NewBounds);
	HIDESBASE void __fastcall SetColor(Graphics::TColor Value);
	virtual Graphics::TBitmap* __fastcall GetMarkAsBitmap(void);
	void __fastcall SetAllowEdit(bool Value);
	
public:
	__fastcall virtual TGenericMark(Classes::TComponent* AOwner);
	virtual void __fastcall Paint(void);
	virtual void __fastcall DrawMark(Graphics::TCanvas* ACanvas, int X, int Y);
	__property Types::TRect MarkRect = {read=FMarkRect, write=SetMarkRect};
	__property double ZoomFactor = {read=FZoomFactor, write=SetZoomFactor};
	__property bool EditMode = {read=FEditMode, write=SetEditMode, nodefault};
	__property bool Modified = {read=FModified, write=FModified, nodefault};
	__property Graphics::TColor Color = {read=FColor, write=SetColor, nodefault};
	__property Types::TRect DisplayRect = {read=FDisplayRect, write=SetDisplayRect};
	__property int DisplayResolution = {read=FDisplayResolution, write=SetDisplayResolution, nodefault};
	__property bool AllowEdit = {write=SetAllowEdit, nodefault};
public:
	#pragma option push -w-inl
	/* TGraphicControl.Destroy */ inline __fastcall virtual ~TGenericMark(void) { }
	#pragma option pop
	
};


class DELPHICLASS TStickNoteMark;
class PASCALIMPLEMENTATION TStickNoteMark : public TGenericMark 
{
	typedef TGenericMark inherited;
	
private:
	AnsiString FText;
	Graphics::TFont* FFont;
	HIDESBASE void __fastcall SetText(AnsiString Value);
	HIDESBASE void __fastcall FontChanged(System::TObject* AFont);
	virtual Graphics::TBitmap* __fastcall GetMarkAsBitmap(void);
	
public:
	__fastcall virtual TStickNoteMark(Classes::TComponent* AOWner);
	__property AnsiString Text = {read=FText, write=SetText};
	__property Graphics::TFont* Font = {read=FFont};
public:
	#pragma option push -w-inl
	/* TGraphicControl.Destroy */ inline __fastcall virtual ~TStickNoteMark(void) { }
	#pragma option pop
	
};


class DELPHICLASS TRectangleMark;
class PASCALIMPLEMENTATION TRectangleMark : public TGenericMark 
{
	typedef TGenericMark inherited;
	
private:
	int FLineSize;
	bool FHightLight;
	bool FFilled;
	void __fastcall SetLineSize(int Value);
	void __fastcall SetHightLight(bool Value);
	void __fastcall SetFilled(bool Value);
	virtual Graphics::TBitmap* __fastcall GetMarkAsBitmap(void);
	
public:
	__fastcall virtual TRectangleMark(Classes::TComponent* AOWner);
	virtual void __fastcall DrawMark(Graphics::TCanvas* ACanvas, int X, int Y);
	__property bool HightLight = {read=FHightLight, write=SetHightLight, nodefault};
	__property bool Filled = {read=FFilled, write=SetFilled, nodefault};
	__property int LineSize = {read=FLineSize, write=SetLineSize, nodefault};
public:
	#pragma option push -w-inl
	/* TGraphicControl.Destroy */ inline __fastcall virtual ~TRectangleMark(void) { }
	#pragma option pop
	
};


class DELPHICLASS TTextMark;
class PASCALIMPLEMENTATION TTextMark : public TGenericMark 
{
	typedef TGenericMark inherited;
	
private:
	AnsiString FText;
	Graphics::TFont* FFont;
	HIDESBASE void __fastcall SetText(AnsiString Value);
	HIDESBASE void __fastcall FontChanged(System::TObject* AFont);
	virtual Graphics::TBitmap* __fastcall GetMarkAsBitmap(void);
	
public:
	__fastcall virtual TTextMark(Classes::TComponent* AOWner);
	__property AnsiString Text = {read=FText, write=SetText};
	__property Graphics::TFont* Font = {read=FFont};
public:
	#pragma option push -w-inl
	/* TGraphicControl.Destroy */ inline __fastcall virtual ~TTextMark(void) { }
	#pragma option pop
	
};


#pragma option push -b-
enum TLineOrientation { loTop, loRight, loTLBR, loBLTR };
#pragma option pop

class DELPHICLASS TLineMark;
class PASCALIMPLEMENTATION TLineMark : public TGenericMark 
{
	typedef TGenericMark inherited;
	
private:
	int FLineSize;
	TLineOrientation FOrientation;
	void __fastcall SetLineSize(int Value);
	void __fastcall SetOrientation(const TLineOrientation Value);
	virtual Graphics::TBitmap* __fastcall GetMarkAsBitmap(void);
	
public:
	__fastcall virtual TLineMark(Classes::TComponent* AOWner);
	__fastcall virtual ~TLineMark(void);
	__property int LineSize = {read=FLineSize, write=SetLineSize, nodefault};
	__property TLineOrientation Orientation = {read=FOrientation, write=SetOrientation, nodefault};
};


class DELPHICLASS TMultiLineMark;
class PASCALIMPLEMENTATION TMultiLineMark : public TGenericMark 
{
	typedef TGenericMark inherited;
	
private:
	int FLineSize;
	Classes::TList* FPoints;
	void __fastcall SetLineSize(int Value);
	Types::PPoint __fastcall GetPoint(int Index);
	int __fastcall GetPointsCount(void);
	virtual void __fastcall SetMarkRect(const Types::TRect &Value);
	virtual Graphics::TBitmap* __fastcall GetMarkAsBitmap(void);
	
public:
	__fastcall virtual TMultiLineMark(Classes::TComponent* AOWner);
	__fastcall virtual ~TMultiLineMark(void);
	void __fastcall AddPoint(const Types::TPoint &Point);
	void __fastcall DeletePoint(int Index);
	void __fastcall ClearPoints(void);
	__property int LineSize = {read=FLineSize, write=SetLineSize, nodefault};
	__property Types::PPoint Points[int Index] = {read=GetPoint};
	__property int PointsCount = {read=GetPointsCount, nodefault};
};


class DELPHICLASS TImageMark;
class PASCALIMPLEMENTATION TImageMark : public TGenericMark 
{
	typedef TGenericMark inherited;
	
private:
	unsigned FDIBHandle;
	bool FTransparent;
	void __fastcall SetDIBHandle(unsigned Value);
	virtual Graphics::TBitmap* __fastcall GetMarkAsBitmap(void);
	
public:
	__fastcall virtual TImageMark(Classes::TComponent* AOWner);
	__fastcall virtual ~TImageMark(void);
	__property unsigned DIBHandle = {read=FDIBHandle, write=SetDIBHandle, nodefault};
	__property bool Transparent = {read=FTransparent, write=FTransparent, nodefault};
};


class DELPHICLASS TAnnotationsEditor;
class PASCALIMPLEMENTATION TAnnotationsEditor : public Classes::TComponent 
{
	typedef Classes::TComponent inherited;
	
public:
	TGenericMark* operator[](int Index) { return Items[Index]; }
	
private:
	Controls::TWinControl* FDisplaySurface;
	int FDisplayResolution;
	#pragma pack(push, 1)
	Types::TRect FDisplayRect;
	#pragma pack(pop)
	
	Forms::TControlScrollBar* FDisplayHorzScrollBar;
	Forms::TControlScrollBar* FDisplayVertScrollBar;
	bool FVisible;
	Classes::TList* FMarks;
	double FZoomFactor;
	bool FEditMode;
	bool FChanged;
	Classes::TNotifyEvent FOnAnnotationClick;
	Classes::TNotifyEvent FOnAnnotationDblClick;
	Controls::TMouseEvent FOnAnnotationMouseDown;
	Controls::TMouseMoveEvent FOnAnnotationMouseMove;
	Controls::TMouseEvent FOnAnnotationMouseUp;
	Menus::TPopupMenu* FPopupMenu;
	void __fastcall SetDisplaySurface(Controls::TWinControl* DS);
	void __fastcall SetDisplayRect(const Types::TRect &Value);
	void __fastcall SetDisplayResolution(int Value);
	TGenericMark* __fastcall GetVisualMark(int Index);
	void __fastcall SetZoomFactor(double Value);
	void __fastcall SetEditMode(bool Value);
	bool __fastcall GetChanged(void);
	void __fastcall ClickPerformed(System::TObject* Sender);
	void __fastcall DblClickPerformed(System::TObject* Sender);
	void __fastcall MouseDownPerformed(System::TObject* Sender, Controls::TMouseButton Button, Classes::TShiftState Shift, int X, int Y);
	void __fastcall MouseMovePerformed(System::TObject* Sender, Classes::TShiftState Shift, int X, int Y);
	void __fastcall MouseUpPerformed(System::TObject* Sender, Controls::TMouseButton Button, Classes::TShiftState Shift, int X, int Y);
	void __fastcall SetPopupMenu(Menus::TPopupMenu* Value);
	void __fastcall SetVisible(bool Value);
	int __fastcall GetCount(void);
	void __fastcall SetAllowEdit(bool Value);
	
public:
	__fastcall virtual TAnnotationsEditor(Classes::TComponent* AOwner);
	__fastcall virtual ~TAnnotationsEditor(void);
	TStickNoteMark* __fastcall AddStickNote(void);
	TRectangleMark* __fastcall AddRectangle(void);
	TTextMark* __fastcall AddText(void);
	TMultiLineMark* __fastcall AddMultiLine(void);
	TLineMark* __fastcall AddLine(void);
	TImageMark* __fastcall AddImage(void);
	void __fastcall Clear(void);
	void __fastcall Delete(int Index);
	int __fastcall FindIndex(TGenericMark* Mark);
	void __fastcall BurnIn(Graphics::TCanvas* Canvas);
	void __fastcall LoadFromString(const AnsiString Str);
	AnsiString __fastcall SaveToString();
	__property Controls::TWinControl* DisplaySurface = {read=FDisplaySurface, write=SetDisplaySurface};
	__property Types::TRect DisplayRect = {read=FDisplayRect, write=SetDisplayRect};
	__property int DisplayResolution = {read=FDisplayResolution, write=SetDisplayResolution, nodefault};
	__property Forms::TControlScrollBar* DisplayVertScrollBar = {read=FDisplayVertScrollBar, write=FDisplayVertScrollBar};
	__property Forms::TControlScrollBar* DisplayHorzScrollBar = {read=FDisplayHorzScrollBar, write=FDisplayHorzScrollBar};
	__property TGenericMark* Items[int Index] = {read=GetVisualMark/*, default*/};
	__property double ZoomFactor = {read=FZoomFactor, write=SetZoomFactor};
	__property bool EditMode = {read=FEditMode, write=SetEditMode, nodefault};
	__property bool Changed = {read=GetChanged, nodefault};
	__property Classes::TNotifyEvent OnAnnotationClick = {read=FOnAnnotationClick, write=FOnAnnotationClick};
	__property Classes::TNotifyEvent OnAnnotationDblClick = {read=FOnAnnotationDblClick, write=FOnAnnotationDblClick};
	__property Menus::TPopupMenu* PopupMenu = {read=FPopupMenu, write=SetPopupMenu};
	__property bool Visible = {read=FVisible, write=SetVisible, nodefault};
	__property int Count = {read=GetCount, nodefault};
	__property bool AllowEdit = {write=SetAllowEdit, nodefault};
};


//-- var, const, procedure ---------------------------------------------------
extern PACKAGE void __fastcall DIBToBitmap(unsigned DIBHandle, Graphics::TBitmap* Bitmap);
extern PACKAGE int __fastcall BitmapToDIB(Graphics::TBitmap* Bitmap);

}	/* namespace Enanedit */
using namespace Enanedit;
#pragma option pop	// -w-
#pragma option pop	// -Vx

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