{*******************************************************}
{                                                       }
{      TBitDBGrid  - Extended of standart TDBGrid       }
{    (Multiline columns titles, auto-resize columns,    }
{ inplace incremental search, titles like speedbuttons  }
{                  and more, more...)                   }
{                     Version 2.15			}
{                                                       }
{    Copyright (c) 1997, 98 by Ilya Andreev AKA Andre   }
{                                                       }
{                     SPb, Russia.                      }
{                                                       }
{                       Shareware.                      }
{                                                       }
{        e-mail: ilya_andreev@geocities.com             }
{							}
{        www.geocities.com/Athens/Delphi/8862/		}
{                                                       }
{           Please, send me bug reports :)              }
{                                                       }
{*******************************************************}
 
1. TBitDBGrid is extension of TDBGrid,
  with additional features:

  - Multiline titles
  - Incremental search
  - Columns footers or total grid footer
  - Minimize column to smalled data (as M$ Excel) 
  - Cells Hints
  - Columns titles hints
  - Attached ImageList and event for draw images in cells
  - Fill clientreact by columns
  - Long title (as ListView)
  - Grid Editor in run-time:
     for set colors, fonts, captions to columns
     and hidden/showing columns
  - Saving settings to registry
  - Sorting DataSet'a
  - Few titles styles
  - Some RX features:
     Event OnGetCellParams, property IniStorage
  - Copy data to clipboard, paste from clipboard
  - Drawing ellipse in end of cell's text
  - More ... :)
  

2. Install.
  
    Add bdbgrid.pas in any package.
    Attention! 

    If you have't Delphi C/S,
      remove {$DEFINE D_CS} in bdbgrid.pas 

    If you have't Delphi C/S RX lib, remove {$DEFINE RX} in bdbgrid.pas 


 3. Short help from interface section

  TEnterKeyDown = (ekNone, ekDouble, ekTab);
//  Key "Enter" reaction (None, call Dblclick event, as Tab Key)

  TTitleBtnStyle = (tbNone, tbFix, tbDownUp, tbOneFix, tbDisallowAllUp,
   tbTraceSelect, tbSorted);
// Title button's style (none, fix, ordinal button, grouped,
  Grouped with not AllowAllUp, Trace selected fileds, Sort)

  TBitColumn = class(TColumn)
  published
    property FooterValue : TStrings read GetFooterValue write SetFooterValue;
// footer's value
   property FooterFont : TFont read FFooterFont write SetFooterFont;
// footer font
    property Hint : string read FHint write FHint;
// Title hint
  end;

  protected
   procedure UpdateTitlesHeight; // Redraw caption
  public
    property TitlesState[Index : integer] : Variant read GetTitlesState
    // Is title down?
    function SelectCell(ACol, ARow: Longint): Boolean; override;
    // move to public
    function MouseCoord(X, Y: Integer): TGridCoord;
   // Same
    procedure MouseToCell(X, Y: Integer; var ACol, ARow: Longint);
   // Same
    procedure CopyToClipboard(OnlyColumns : boolean);
     // Copy to clipboard (OnlyColumns  - copy only visible columns or
     //  all data
    procedure PasteFromClipboard;
    procedure RunOptionsEditor;
    function HasRecord : boolean;
    //  Return true, if DataLink is active and RecordCount > 0
    function ColumnByField(FieldName : string) : TColumn;
    // find _first_ column with this file
    procedure SetColumnFooter(Column : TColumn; Value : Variant);
    // Set first string of footer in Value;  

    property DefColumns : TDBGridColumns read FDefColumns write FDefColumns;
    // Default columns (Design-time columns)
    property RowHeights; //move to public
    property RowCount;   
    property DataLink;
  published
    property AllowIncSearch:Boolean read FAllowIncSearch write FAllowIncSearch;
     // Allow incremental search.
     // if Grid is ReadOnly, search started, when you press any key,
     // else you must press Ctr-s for start search
    property MultiCaption : boolean read FMultiCaption write SetMultiCaption;
    // Multiline title
    property FillFields : boolean read FFillFields write FFillFields;
    // Fill ClientArea by columns
    property LongCaption : boolean read FLongCaption write SetLongCaption;
    property RealTitleFont : TFont read FRealTitleFont write SetRealTitleFont;
    // Title font  (property Font  reserved for internal use, sorry.
    property EnterKey : TEnterKeyDown read FEnterKey write FEnterKey;
    //  Enter key reaction
    property InternalDrag : boolean read FIntDrag write FIntDrag;
    // Support Drug'n'Drop for multiselect
    property SortFieldName : string read FSortFieldName write SetSortFieldName;
    property RunTimePropEditor : boolean read FShowPropEditor
      write SetPropEditor;  
    property ColumnVersion : integer read FColumnVersion write FColumnVersion;
     // if you increment this property, grid does't loadind settings from 
    // registry first time
    { RX } property IniStorage: TFormPlacement read GetStorage write SetStorage;
    { RX }  property OnGetCellParams : TGetCellParamsEvent read FOnGetCellParams write FOnGetCellParams;
    property DrawingEllipse : boolean read FDrawEllipse write SetDrawEllipse;
    property OnShowEditor : TOnShowEditorEvent read FOnShowEditorEvent write FOnShowEditorEvent ;
  end;

4. Limited
   - Settings saving in registry only
   - Sort not working for local tables
   - DefaultColumn  - set this in false with very care!
     When its set in false, grid create new class - TBitColumn,
     and you must have even though column.
     In run-time, call BeginLayout /EndLayout

   - When you sort TQuery, Grid search "Order by " - be carefuly


5. Info.
    ShareWare. AS IS. 
         -   10$ 
     else - 20$ 

                   Ilya Andreev AKA Andre
                     ilya_andreev@geocities.com    

