                   TMagmaEdit component for Delphi
                   --------------------------------------

(C) Copyright 1995 Magma Systems  All Rights Reserved

CompuBridge
9423 Fontainebleau Blvd.  #108
Miami, FL 33172
USA

Compuserve : 76223,2060
Internet   : 76223,2060@compuserve.com


(The following is rough documentation for the TMagmaEdit Component.)

Introduction
------------
The TMagmaEdit component is a wrap around The magma Editor DLL.  
It provides an powerful alternative to the TMemo component.  TMemo
component is a wrap around standard window Edit control.  So the 
real work is done the magma editor DLL.  To learn more about Magma 
editor DLL, read the editor.doc and GO Magma on compuserve, download 
the demo. 


What feature does TMagmaEdit support. 
	TMagmaEdit support all the property, method, event that TMemo supports 
and more.  The most important new feature TMagmaEdit support is the Owndraw
style.  To see how the ownerdraw works, run demo program, right mouse to bring
up the popup menu, choose change font from the menu.  You can see the font change 
for each line. The full source code for demo are enclosed.

When load data from file,  LoadFromFile, or LoadFromHandle should be used instead 
of Lines.LoadFromstream. Lines is derived from TString, it can not handle more 
than 32K of data.  

How to use TMagmaEdit.  
	You can use it just like you use TMemo component.   The TMemo can be replace
with TMagmaEdit without changing single line of code.  

How to derive new component.  You can derive new component from TCustomMagmaEdit.
and hide the property you do not want.  All the new property are protected in TCustomMagmaEdit.  
In fact TMagmaEdit is derived from  TCustomMagmaEdit.  


Ordering Information
--------------------

Single developer's license      $30 US

Please include $5.00 for shipping and handling within the United States,
$10 Canada, $30 Europe, and $40 Asia and Pacific. $5 UPS COD charge.

Licensing/Registration

        If you going to be releasing programs with TMagmaEdit you must register
it with CompuBridge Inc prior to releasing your program.

By registering for $30, you will receive:

	Permission to use TMagmaEdit component with your executable file.

	You may NOT release TMagmaEdit as a stand alone Component or any component derived 
from TCustomMagmaEdit or TMagmaEdit.  It must be used with your own program.

Payment Terms :
  Visa or Mastercard, personal or company check accepted. 
Payment must be made in US dollars and the check must be drawn on a US bank.


Following are the new property and method and event 

new property
LineIndex:integer;   
	run time only, the current line under the cursor
LineColumeIndex:integer;
	run time only, the current row under the cursoe
CurChar: char 
    read only, the current charactor under the cursor
CurWord: string 
    read only, the current word under the cursor
	
Style: TCustomMagmaStyle;
	can be MMStandard, MMOwnerDraw;

ItemHeight: Integer;
OnDrawItem: TMEDrawItemEvent;
OnMeasureItem: TMEMeasureItemEvent;
	see combobox help about those property	

AutoIndent:Boolean;
EntabLine:Boolean;
GoFreeSpace:Boolean;
HighBitsOff:Boolean;
IndentAmount: Integer;
InsertMode:Boolean;
RightMargin: Integer;
TabFill: Integer;
TabIncrement: Integer;
UndoEnabled:Boolean;
UseRealTabs:Boolean;
WrapWord: Boolean;

TextColor: TColor;
BKColor: TColor;
	about those property, see magma editor.doc


SearchOptions: TSearchOptions;
  a set of (sfPromptUser, sfCaseInsensitive, sfNoRegExp, sfSelectMatch, sfWholeWordOnly,sfPromptOnReplace,sfReplaceAll);



new method
	function Moveup:integer;
    function MoveDown:integer;
    function MoveLeft:integer;
    function MoveRight:integer;
    function MoveBeginofLine:integer;
    function MoveEndofLine:integer;
    function MoveNextWord:integer;
    function MovePrevWord:integer;
    function MoveNextPara:integer;
    function MovePrevPara:integer;
    function MoveTopofWindow:integer;
    function MoveBottomofWindow:integer;
    function MoveNextPage:integer;
    function MovePrevPage:integer;
    function MoveTopofBuffer:integer;
    function MoveBottomofBuffer:integer;
    function MoveToLastLine:integer;

    function MoveGoTo(LineNum:longint; option:TCustomMagmaGoto):integer;
    function MatchBrace:integer;

	{book mark}
    function GotoBookMark(c: char):integer;
    function SetBookMark(c: char):integer;
    function RemoveBookMark(c: char):integer;
    function RemoveAllBookMark:integer;

	{charactor insertion and deletion}
    function BackSpace:integer;
    function DelChar:integer;
    function DelEndofLine:integer;
    function DelWord:integer;
    function InsertChar(c:char):integer;
    function InsertString(data:string; OverStrike:boolean):integer;

    function  LoadFromFile(FileName:string):integer;
    function  LoadFromHandle(FileHandle:THandle):integer;
    function  SaveToFile(FileName:string):integer;
    function  SaveToHandle(FileHandle:THandle):integer;

	{search and substitute}
	function Search(strFind:string; backward:boolean):boolean;
	function Replace(strFind:string; strReplace:string; backward:boolean):boolean;
    function SearchAgain:boolean;
    function ReplaceAgain:boolean;
    function QuerySearchString:string;

    function HelpOnWord(helpfile:pchar):integer;

	{Selecting , cutting, copying and pasting}
    function AppendLine:integer;
    function CaseLower:integer; 
    function CaseUpper:integer;
	function Copy:integer;
	function Cut:integer;
	function CutAppend:integer;

    function DelLine:integer;
    function DupLine:integer;
    function InsertLine:integer; 
    function MarkLine:integer; 
    function MarkLineRange:integer; 
    function PasteBuf:integer;  
    function RectMark:integer; 
    function ResetMark:integer;
    function StreamMark:integer;
    function RightIndent:integer; 
    function LeftIndent:integer;

    function Redo:integer;
    function Undo:integer;

	{option}
    function OptionDlg:integer; 
    {SetOption is change to use property}
    {QueryOption is change to use property}
    {SetTextColor is change to use property}
    {SetBkColor is change to use property}

    function QueryStatus(info:PMAGMAED_STATUS):integer; 
    function KeyMacDefine:integer;
    function KeyMacPlay:integer;


new event
    OnDrawItem: TMEDrawItemEvent;
    OnMeasureItem: TMEMeasureItemEvent;
	

