Unit DBGridPlus

****************************************************************************** * Extended DBGrid * * Copyright (c) 1997, Javier Tari Agullo * * Author: Javier Tari Agullo E-MAIL: cyber@ctv.es * ******************************************************************************** * Class: TDBGridPlus Data Bound: YES * * Ancestor: TDBGrid * ******************************************************************************** * Enhancements: * * - Cand display memos and graphics (whithout deforming them) * * - Event for detecting the clicking of a column * * - Capable of row height adjustment with the mouse (better memo reading) * * - Event for selecting any brush and font for any cell, selected or not. * * (in short: select the colors *without* having to draw the cell) * ******************************************************************************** * Revision History * * Version 1.0 * * - Implemented One-Line Memo drawing, and adjusted Graphic drawing * * - Implemented OnColumnClick Event * * Version 1.1 * * - Corrected bug with empty graphic fields * * - Implemented Multi-Line Memo drawing * * - Surfaced DefaultRowHeight property, and implemented accordingly * * Version 1.2 * * - Event for changing the brush and font of any cell * * - Implemented Multi-Line Memo drawing * * - Surfaced DefaultRowHeight property, and implemented accordingly * * Delayed enhancements/fixes: Edition of Memo and Graphic, fix to RowSizing * * Version 2.0 (not freeware) * * - Any control in any column, including populated panels * ******************************************************************************** * Based upon works and ideas from everywhere on the 'net, books and magazines * ******************************************************************************** * It's freeware, and you know all the legal things about it... * ******************************************************************************** * Please, if you enhance the component, send me a copy,and I'll try to include* * it in future versions (if any). By the way, it's better NOT to modify * * the component, but inherit it and modify the inherited, so you don't need to* * modify anything with future enhanced versions (if any). * ******************************************************************************** * I'm developed it for contributing to the Delphi Freeware Community, as I've * * obtained good components and ideas from others, and it's time to return *

Classes

TDBGridPlus - new DBGrid class

Functions

Register -

Types

TChangeDrawingEvent
TColumnClickEvent
TColumnClickSimpleEvent
TdbeNativeClick
TgedmGraphic
TgedmMemo

Constants

Variables


Functions


procedure Register;


Types


TChangeDrawingEvent = procedure(Sender: TObject;DataCol,DataRow:Integer;
                           AState: TGridDrawState;var Highlighted:Boolean)
                           of object

TColumnClickEvent = procedure(Sender: TObject; Index: Integer;
                               Button: TMouseButton; ShiftState: TShiftState;X,Y:Integer) of object
new event type for column header click with mouse state & column index
TColumnClickSimpleEvent = procedure(Sender: TObject; Index: Integer;
                               ShiftState: TShiftState;X,Y:Integer) of object

TdbeNativeClick = Set Of (ncssShift, ncssCtrl, ncssAlt)

TgedmGraphic = (gedgNo,gedgStretch,gedgAdjust);

TgedmMemo = (gedmNo,gedmYes);

Constants


Variables