Class TmStrGrid (unit mStrGrid) |
Inherits from
TStringgrid
constructor Create(AOwner: TComponent);
- Public-Deklarationen
rVAL
procedure AddCol(contents:String; delimiter:Char);
procedure AddRow(contents:String; delimiter:Char);
procedure DeleteCols(where,howmuch:Integer);
procedure DeleteRows(where,howmuch:Integer);
function FindFirst(Key:String; RowWise:Boolean; VAR ResultCol,ResultRow:Integer):Boolean;
function FindFirstInCol(Key:String; searchCol:Integer; VAR ResultCol,ResultRow:Integer):Boolean;
function FindFirstInRow(Key:String; searchRow:Integer; VAR ResultCol,ResultRow:Integer):Boolean;
function FindNext(VAR ResultCol,ResultRow:Integer):Boolean;
procedure InsertCols(where,howmuch:Integer);
Published-Deklarationen lf weg
procedure InsertRows(where,howmuch:Integer);
procedure LoadFromFile(FileName,ColSep:string);
function ModifyCol(which:integer; contents,delimiter:string):integer;
function ModifyRow(which:integer; contents,delimiter:string):integer;
procedure ReorderCompleteRows(KeyCol:integer; OrderValues:TStrings);
Tausche Zyklus
procedure SaveToFile(FileName,ColSep:String);
procedure SortAllCols;
Tausche Zyklus
procedure SortAllRows;
Tausche Zyklus
procedure SortCol(ThisCol:integer);
Tausche Zyklus
procedure SortCompleteColumns(KeyRow:integer);
procedure SortCompleteRows(KeyCol:integer);
Tausche Zyklus
procedure SortRow(ThisRow:integer);
Zeilen vertauschen
procedure UndoSort;
Tausche Zyklus
procedure CopyToClipboard;
procedure CutToClipboard;
destructor destroy;
procedure PasteFromClipboard;
Weg damit
procedure KeyPress(var Key:Char);
procedure MouseDown(Button:TMouseButton; Shift:TShiftState; X,Y:Integer);
Protected-Deklarationen This is the only modified procedure from TCustomGrid
procedure MouseUp(Button:TMouseButton; Shift:TShiftState; X,Y:Integer);
This is to get the correct Fixedcols/rows value if the user click procedure calls mStrGrid methods
procedure UndoAllColsSort;
Sortierindizees speichern
procedure UndoAllRowsSort;
Sortierindizees speichern
procedure UndoColSort;
Werte vertauschen
procedure UndoCompColSort;
Spalten vertauschen
procedure UndoCompRowSort;
Zeilen vertauschen
procedure UndoRowSort;
Werte vertauschen
function CalcCoordFromPoint(X, Y: Integer;
const DrawInfo: TGridDrawInfo): TGridCoord;
procedure CalcDrawInfo(var DrawInfo: TGridDrawInfo);
procedure CalcDrawInfoXY(var DrawInfo: TGridDrawInfo;
UseWidth, UseHeight: Integer);
The following procedures/functions are just copied from TCustomGrid
procedure CalcFixedInfo(var DrawInfo: TGridDrawInfo);
procedure CalcSizingState(X, Y: Integer; var State: TGridState;
var Index: Longint; var SizingPos, SizingOfs: Integer;
var FixedInfo: TGridDrawInfo);
function GetColWidths(Index: Longint): Integer;
function GetDateTimeFormat:String;
function GetFixedCols:Integer;
This is to get the correct Fixedcols/rows value if the user click procedure calls mStrGrid methods
function GetFixedRows:Integer;
All following procedures/functions implement a new click behaviour:
MouseDown is heavy modified, MouseUp only a little, and the rest is just copied from the
original GRID.
function GetRowHeights(Index: Longint): Integer;
function GetShortYearBorder:Integer;
function GetShortYearExpand:Boolean;
procedure SetDateTimeFormat(value:String);
procedure SetReverseSearch(value:Boolean);
Suche Passenden
procedure SetShortYearBorder(value:Integer);
procedure SetShortYearExpand(value:Boolean);
property ClickFixed : Boolean
property DateTimeFormat : String
property EnableClipboardShortcuts : Boolean
property KeyLen : Integer
property KeyPos : Integer
property KeyType : TMSortType
property PasteToCursor : Boolean
property ReverseSearch : Boolean
property SavedFixedCols : Integer
property SavedFixedRows : Integer
property SearchExists : Boolean
property SearchSubstring : Boolean
property ShortYearBorder : Integer
property ShortYearExpand : Boolean
property SortDescending : Boolean
property SortIndex : TmStrList
property UseFixed : HandleFixed
event OnKeyPress :
event OnMouseDown :
event OnMouseUp :
ActSearchCol : Integer;
ActSearchRow : Integer;
clicked : boolean;
Sort complete cols: Which row to begin
ColAnfang : integer;
fClickFixed : Boolean;
fDateTimeFormat : String;
... have to remember the actual fixedrows/fixedcols
fEnableClipboardShortcuts : Boolean;
FirstSearchCol : Integer;
FirstSearchRow : Integer;
fKeyLen : Integer;
fKeyPos : Integer;
fKeyType : TMSortType;
Private-Deklarationen
fPasteToCursor : Boolean;
fReverseSearch : Boolean;
fSavedFixedCols : Integer;
... must be set to zero. The mStrGrid methods called in OnClick ...
fSavedFixedRows : Integer;
While in Clicking on fixed cells, the fixed rows/cols .
fSearchExists : Boolean;
fSearchSubstring : Boolean;
fShortYearBorder : Integer;
fShortYearExpand : Boolean;
fSortDescending : Boolean;
fSortIndex : TmStrList;
fUseFixed : HandleFixed;
LastSearchCol : Integer;
LastSearchRow : Integer;
RowAnfang : integer;
Sort complete rows: Which col to begin
SearchIsActive : Boolean;
SearchKey : String;
SearchRowWise : Boolean;
SortArg : integer;
SortState : mSortState;
constructor Create(AOwner: TComponent);
Public-Deklarationen
rVAL
procedure AddCol(contents:String; delimiter:Char);
procedure AddRow(contents:String; delimiter:Char);
procedure DeleteCols(where,howmuch:Integer);
procedure DeleteRows(where,howmuch:Integer);
function FindFirst(Key:String; RowWise:Boolean; VAR ResultCol,ResultRow:Integer):Boolean;
function FindFirstInCol(Key:String; searchCol:Integer; VAR ResultCol,ResultRow:Integer):Boolean;
function FindFirstInRow(Key:String; searchRow:Integer; VAR ResultCol,ResultRow:Integer):Boolean;
function FindNext(VAR ResultCol,ResultRow:Integer):Boolean;
procedure InsertCols(where,howmuch:Integer);
Published-Deklarationen
lf weg
procedure InsertRows(where,howmuch:Integer);
procedure LoadFromFile(FileName,ColSep:string);
function ModifyCol(which:integer; contents,delimiter:string):integer;
function ModifyRow(which:integer; contents,delimiter:string):integer;
procedure ReorderCompleteRows(KeyCol:integer; OrderValues:TStrings);
Tausche Zyklus
procedure SaveToFile(FileName,ColSep:String);
procedure SortAllCols;
Tausche Zyklus
procedure SortAllRows;
Tausche Zyklus
procedure SortCol(ThisCol:integer);
Tausche Zyklus
procedure SortCompleteColumns(KeyRow:integer);
procedure SortCompleteRows(KeyCol:integer);
Tausche Zyklus
procedure SortRow(ThisRow:integer);
Zeilen vertauschen
procedure UndoSort;
Tausche Zyklus
procedure CopyToClipboard;
procedure CutToClipboard;
destructor destroy;
procedure PasteFromClipboard;
Weg damit
procedure KeyPress(var Key:Char);
procedure MouseDown(Button:TMouseButton; Shift:TShiftState; X,Y:Integer);
Protected-Deklarationen
This is the only modified procedure from TCustomGrid
procedure MouseUp(Button:TMouseButton; Shift:TShiftState; X,Y:Integer);
This is to get the correct Fixedcols/rows value if the user click procedure calls mStrGrid methods
procedure UndoAllColsSort;
Sortierindizees speichern
procedure UndoAllRowsSort;
Sortierindizees speichern
procedure UndoColSort;
Werte vertauschen
procedure UndoCompColSort;
Spalten vertauschen
procedure UndoCompRowSort;
Zeilen vertauschen
procedure UndoRowSort;
Werte vertauschen
function CalcCoordFromPoint(X, Y: Integer;
const DrawInfo: TGridDrawInfo): TGridCoord;
procedure CalcDrawInfo(var DrawInfo: TGridDrawInfo);
procedure CalcDrawInfoXY(var DrawInfo: TGridDrawInfo;
UseWidth, UseHeight: Integer);
The following procedures/functions are just copied from TCustomGrid
procedure CalcFixedInfo(var DrawInfo: TGridDrawInfo);
procedure CalcSizingState(X, Y: Integer; var State: TGridState;
var Index: Longint; var SizingPos, SizingOfs: Integer;
var FixedInfo: TGridDrawInfo);
function GetColWidths(Index: Longint): Integer;
function GetDateTimeFormat:String;
function GetFixedCols:Integer;
This is to get the correct Fixedcols/rows value if the user click procedure calls mStrGrid methods
function GetFixedRows:Integer;
All following procedures/functions implement a new click behaviour:
MouseDown is heavy modified, MouseUp only a little, and the rest is just copied from the
original GRID.PAS
function GetRowHeights(Index: Longint): Integer;
function GetShortYearBorder:Integer;
function GetShortYearExpand:Boolean;
procedure SetDateTimeFormat(value:String);
procedure SetReverseSearch(value:Boolean);
Suche Passenden
procedure SetShortYearBorder(value:Integer);
procedure SetShortYearExpand(value:Boolean);
property ClickFixed : Boolean
property DateTimeFormat : String
property EnableClipboardShortcuts : Boolean
property KeyLen : Integer
property KeyPos : Integer
property KeyType : TMSortType
property PasteToCursor : Boolean
property ReverseSearch : Boolean
property SavedFixedCols : Integer
property SavedFixedRows : Integer
property SearchExists : Boolean
property SearchSubstring : Boolean
property ShortYearBorder : Integer
property ShortYearExpand : Boolean
property SortDescending : Boolean
property SortIndex : TmStrList
property UseFixed : HandleFixed
event OnKeyPress :
event OnMouseDown :
event OnMouseUp :
ActSearchCol : Integer;
ActSearchRow : Integer;
clicked : boolean;
Sort complete cols: Which row to begin
ColAnfang : integer;
fClickFixed : Boolean;
fDateTimeFormat : String;
... have to remember the actual fixedrows/fixedcols
fEnableClipboardShortcuts : Boolean;
FirstSearchCol : Integer;
FirstSearchRow : Integer;
fKeyLen : Integer;
fKeyPos : Integer;
fKeyType : TMSortType;
Private-Deklarationen
fPasteToCursor : Boolean;
fReverseSearch : Boolean;
fSavedFixedCols : Integer;
... must be set to zero. The mStrGrid methods called in OnClick ...
fSavedFixedRows : Integer;
While in Clicking on fixed cells, the fixed rows/cols ...
fSearchExists : Boolean;
fSearchSubstring : Boolean;
fShortYearBorder : Integer;
fShortYearExpand : Boolean;
fSortDescending : Boolean;
fSortIndex : TmStrList;
fUseFixed : HandleFixed;
LastSearchCol : Integer;
LastSearchRow : Integer;
RowAnfang : integer;
Sort complete rows: Which col to begin
SearchIsActive : Boolean;
SearchKey : String;
SearchRowWise : Boolean;
SortArg : integer;
SortState : mSortState;