ehlibreg.pas

来自「Delphi控件源码」· PAS 代码 · 共 55 行

PAS
55
字号
{*******************************************************}
{                                                       }
{                       EhLib v1.56                     }
{                    Registration unit                  }
{                                                       }
{   Copyright (c) 1998, 2000 by Dmitry V. Bolshakov     }
{                                                       }
{*******************************************************}

unit EhLibReg;

{$I EhLib.Inc}

interface

procedure Register;

implementation

uses Classes, TypInfo, DsgnIntf, DBGridEh, GridEhEd, DBSumLst, PrViewEh,
     PrnDbgEh {$IFNDEF EH_LIB_35} ,ColnEdit{$ENDIF};

procedure Register;
begin
  RegisterComponents('Data Controls', [TDBGridEh]);
  RegisterComponentEditor(TDBGridEh, TDBGridEhEditor);
  RegisterPropertyEditor(TypeInfo(TCollection), TDBGridEh, 'Columns', TDBGridEhColumnsProperty);

{$IFNDEF EH_LIB_35}
  RegisterPropertyEditor(TypeInfo(TCollection), TColumnEh, 'Footers', TColumnsEhFootersProperty);
{$ENDIF}

  RegisterPropertyEditor(TypeInfo(string), TColumnEh, 'FieldName', TDBGridEhFieldProperty);
  RegisterPropertyEditor(TypeInfo(string), TColumnFooterEh, 'FieldName', TDBGridEhFieldProperty);

  RegisterPropertyEditor(TypeInfo(string), TPrintDBGridEh, 'PrintFontName', TFontNameProperty);

  RegisterComponents('Data Controls', [TDBSumList]);
  RegisterComponents('Data Controls', [TPrintDBGridEh]);
  RegisterComponents('System', [TPreviewBox]);

{$IFDEF EH_LIB_5}
  { Property Category registration }
  RegisterPropertiesInCategory(TDatabaseCategory,[TypeInfo(TDBGridColumnsEh)]);
  RegisterPropertyInCategory(TDatabaseCategory, TColumnEh, 'FieldName');
  RegisterPropertiesInCategory(TLocalizableCategory, TColumnEh, ['Picklist','KeyList']); { Do not localize }
  RegisterPropertiesInCategory(TLocalizableCategory, [TypeInfo(TColumnTitleEh)]);
  RegisterPropertiesInCategory(TVisualCategory, TColumnEh,['AlwaysShowEditButton',
    'AutoFitColWidth','WordWrap','EndEllipsis','Checkboxes']);
{$ENDIF}

end;

end.

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?