agentleFS
delphicleancodedelphicleancode/delphi-spec-kit/.claude/skills/devexpress-components/SKILL.md

DevExpress/DEXT Components

Skill53 starsChanged 8 months agoMITView on GitHub

Standards for using DevExpress (DEXT) components in Delphi VCL applications

The file

We split this skill into the rules it gives an agent

5 rules. About 0 are common, 2 are distinctive, and 3 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈2

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 3

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use this skill when developing rich interfaces with DevExpress (DEXT) components for Delphi VCL.

    line 8
  2. Very specific:

    When creating advanced grids with TcxGrid

    line 12
  3. Very specific:

    When using TcxDBTreeList for hierarchical structures

    line 13
  4. Very specific:

    When implementing layout managers (TdxLayoutControl)

    line 14
  5. Distinctive:

    When customizing skins and themes

    line 15

≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

DevExpress (DEXT) Components — Skill

Use this skill when developing rich interfaces with DevExpress (DEXT) components for Delphi VCL.

When to Use

  • When creating advanced grids with TcxGrid
  • When using TcxDBTreeList for hierarchical structures
  • When implementing layout managers (TdxLayoutControl)
  • When customizing skins and themes

Main Components

ComponentUsagePrefix
TcxGridAdvanced grid with grouping, filters, summariesgrd
TcxGridDBTableViewData-aware tabular viewtvw
TcxGridDBBandedTableViewView with grouped bands/columnsbtvw
TcxGridDBCardViewCard viewcvw
TcxDBTreeListTreeList data-awaretrl
TdxLayoutControlResponsive layout managerlyt
TdxLayoutGroupGrupo dentro de layoutlgrp
TdxLayoutItemItem within layoutlitm
TcxDBTextEditEdit text data-awareedt
TcxDBComboBoxComboBox data-awarecmb
TcxDBDateEditDate picker data-awaredte
TcxDBCurrencyEditData-aware currency editorcur
TcxDBCheckBoxCheckbox data-awarechk
TcxDBLookupComboBoxLookup combo data-awarelcb
TcxDBMemoMemo data-awaremmo
TdxBarManagerToolbar/ribbonbar
TdxRibbonRibbon UIrbn
TdxNavBarNavigation Barnav
TdxSkinControllerSkin controllerskn
TcxPageControlAdvanced PageControlpgc
TcxGroupBoxStyled GroupBoxgrp

TcxGrid Configuration

//Programmatic column creation
procedure TfrmCustomerList.ConfigureGrid;
var
  LView: TcxGridDBTableView;
begin
  LView := grdCustomers.Views[0] as TcxGridDBTableView;
  LView.DataController.DataSource := dsCustomers;

  //Configure behavior
  LView.OptionsData.Editing := False;        //Read only
  LView.OptionsData.Deleting := False;
  LView.OptionsData.Inserting := False;
  LView.OptionsView.GroupByBox := True;       //Visual grouping
  LView.OptionsView.Footer := True;          //Footer with summaries
  LView.OptionsView.Indicator := True;       //Line indicator
  LView.OptionsCustomize.ColumnFiltering := True;
  LView.OptionsCustomize.ColumnSorting := True;
  LView.OptionsSelection.MultiSelect := True;

  //Configure columns individually
  ConfigureColumn(LView.GetColumnByFieldName('name'), 'Nome', 200);
  ConfigureColumn(LView.GetColumnByFieldName('cpf'), 'CPF', 120);
  ConfigureColumn(LView.GetColumnByFieldName('email'), 'E-mail', 250);
end;

procedure TfrmCustomerList.ConfigureColumn(
  AColumn: TcxGridDBColumn; const ACaption: string; AWidth: Integer);
begin
  if not Assigned(AColumn) then Exit;
  AColumn.Caption := ACaption;
  AColumn.Width := AWidth;
  AColumn.HeaderAlignmentHorz := taCenter;
end;

Summaries in the Grid

//Footer Summary
procedure ConfigureFooterSummary(AView: TcxGridDBTableView);
var
  LSummary: TcxGridDBTableSummaryItem;
begin
  AView.DataController.Summary.FooterSummaryItems.Clear;

  LSummary := AView.DataController.Summary.FooterSummaryItems.Add
    as TcxGridDBTableSummaryItem;
  LSummary.FieldName := 'value';
  LSummary.Kind := skSum;
  LSummary.Format := 'Total: R$ #,##0.00';
  LSummary.Column := AView.GetColumnByFieldName('value');

  LSummary := AView.DataController.Summary.FooterSummaryItems.Add
    as TcxGridDBTableSummaryItem;
  LSummary.FieldName := 'id';
  LSummary.Kind := skCount;
  LSummary.Format := 'Registros: %d';
  LSummary.Column := AView.GetColumnByFieldName('name');
end;

TdxLayoutControl (Responsive Layout)

//Form organization with LayoutControl
//Advantages: responsive, automatically repositions, consistent look

procedure TfrmCustomerEdit.ConfigureLayout;
begin
  lytMain.BeginUpdate;
  try
    //Personal data group
    lgrpPersonal.Caption := 'Dados Pessoais';
    lgrpPersonal.LayoutDirection := ldHorizontal;

    //Address group
    lgrpAddress.Caption := 'Endereço';
    lgrpAddress.LayoutDirection := ldHorizontal;

    //Configure items
    litmName.Control := edtName;
    litmName.CaptionOptions.Text := 'Nome:';
    litmName.CaptionOptions.Width := 80;
  finally
    lytMain.EndUpdate;
  end;
end;

Skinning / Themes

//Apply skin globally
uses
  dxSkinsCore,
  dxSkinOffice2019Colorful;  //Specific skin

procedure TfrmMain.ApplySkin;
begin
  //Via SkinController (recommended)
  sknController.NativeStyle := False;
  sknController.SkinName := 'Office2019Colorful';

  //OR programmatically
  cxLookAndFeelController.NativeStyle := False;
  cxLookAndFeelController.SkinName := 'Office2019Colorful';
end;

//Skins populares: 'Office2019Colorful', 'WXI', 'Metropolis',
//'MetropolisDark', 'TheBezier', 'Fluent', 'Office2019DarkGray'

Filters in the Grid

//Programmatic filter
procedure TfrmCustomerList.ApplyFilter(const AField, AValue: string);
var
  LView: TcxGridDBTableView;
begin
  LView := grdCustomers.Views[0] as TcxGridDBTableView;
  LView.DataController.Filter.Root.Clear;
  LView.DataController.Filter.Root.AddItem(
    LView.GetColumnByFieldName(AField),
    foLike,
    '%' + AValue + '%',
    AValue
  );
  LView.DataController.Filter.Active := True;
end;

//Clean filter
procedure TfrmCustomerList.ClearFilter;
begin
  (grdCustomers.Views[0] as TcxGridDBTableView)
    .DataController.Filter.Root.Clear;
end;

Grid Export

uses
  cxGridExportLink;

//Export to Excel
procedure TfrmCustomerList.ExportToExcel;
begin
  cxGridExportLink.ExportGridToXLSX(
    'customers.xlsx',
    grdCustomers,
    False,   // AExpand
    True,    //AUseNativeFormat
    True     //AShowProgress
  );
end;

//Export to PDF
procedure TfrmCustomerList.ExportToPDF;
begin
  cxGridExportLink.ExportGridToPDF(
    'customers.pdf',
    grdCustomers
  );
end;

DEXT Conventions

AppearanceConvention
PrefixesFollow the table above (grd, tvw, lyt, etc.)
SkinsUse TdxSkinController in the main form
LayoutPrefer TdxLayoutControl to manual positioning
GridConfigure at FormCreate, never at design-time for dynamic columns
FiltersUse DataController.Filter — do not filter via SQL when possible
SummariesConfigure FooterSummaryItems instead of calculating manually
ExportsUse cxGridExportLink — do not redeploy export

Checklist for DEXT Projects

  • TdxSkinController configured in the main form?
  • Grids configured with OptionsData (read-only when appropriate)?
  • Footer summaries configured with BR formats (R$ #,##0.00)?
  • TdxLayoutControl used for editing forms?
  • Grid columns with Caption, Width and Alignment?
  • Filters using DataController.Filter (not SQL)?
  • Export via cxGridExportLink?
  • Component prefixes following the standard table?

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.