请问cxgrid怎么凸显多个筛选列表头,像excel一样,筛选一列,这列表头有个标记,多列同时筛选则多列都有一个标记
谢谢
谢谢
解决方案 »
- idTCPserver 如何向客戶端發送定長二進制防數據?
- 如何对库里的记录进行完全匹配的查找?
- delphi做c/s结构的系统,需共享一些文件,用ftp实现嘛?
- 高分请教,如何做一个有焦点的超链接控件?
- 重大问题解决不了。up有分+++++++++++;
- 我用的第三方控件swflash.ocx,我的机器能显示flash,其他机器不能
- 请问如何ActiveForm、WebSnap、IntraWeb、WebService等等这些技术哪些更有前途?如何更快地学习这些技术呢?困惑中!
- 新手提问!!!
- 这里月明虾稀!高手不要不理我
- 有没有人用esc/pos指令打印过二维码
- 急求面试经验
- 怎么实现把程序做成IDE样。可实现自动添加按钮。
Sender: TcxGridTableView; ACanvas: TcxCanvas;
AViewInfo: TcxGridColumnHeaderViewInfo; var ADone: Boolean);
var
AButtonState: TcxButtonState;
ARect: TRect;
begin
if AViewInfo.Column.Selected then begin
AButtonState := cxbsHot;
ARect := AViewInfo.Bounds;
Sender.LookAndFeelPainter.DrawHeader(ACanvas, ARect, AViewInfo.TextAreaBounds
, [], cxBordersAll, AButtonState, AViewInfo.Column.HeaderAlignmentHorz
, AViewInfo.Column.HeaderAlignmentVert, False, False
, AViewInfo.Column.Caption, ACanvas.Font, Sender.Styles.Selection.TextColor
, Sender.Styles.Selection.Color);
ARect.Left := ARect.Right - 19;
ARect.Right := ARect.Right - 1;
InflateRect(ARect, -1, -3);
if AViewInfo.Column.Options.Filtering then begin
Sender.LookAndFeelPainter.DrawFilterDropDownButton(ACanvas, ARect
, cxbsNormal, AViewInfo.Column.Filtered);
OffsetRect(ARect, -16, 0);
end;
if AViewInfo.Column.SortIndex <> -1 then
Sender.LookAndFeelPainter.DrawSortingMark(ACanvas, ARect
, AViewInfo.Column.SortOrder=soAscending);
ADone := true;
end;
end;
Sender: TcxGridTableView; ACanvas: TcxCanvas;
AViewInfo: TcxCustomGridIndicatorItemViewInfo; var ADone: Boolean);
var
AButtonState: TcxButtonState;
clFont, clBrush: TColor;
begin
if not (AViewInfo is TcxGridIndicatorRowItemViewInfo) then Exit; if TcxGridIndicatorRowItemViewInfo(AViewInfo).GridRecord.Selected then begin
AButtonState := cxbsHot;
if Sender.LookAndFeelPainter.LookAndFeelStyle = lfsOffice11 then begin
clFont := ACanvas.Font.Color;
clBrush := ACanvas.Brush.Color;
end else begin
clFont := Sender.Styles.Selection.TextColor;
clBrush := Sender.Styles.Selection.Color;
end;
end else begin
AButtonState := cxbsNormal;
clFont := ACanvas.Font.Color;
clBrush := ACanvas.Brush.Color;
end;
Sender.LookAndFeelPainter.DrawHeader(ACanvas, AViewInfo.ContentBounds,
AViewInfo.ContentBounds, [], [bLeft, bRight, bBottom], AButtonState, taCenter
, vaCenter, False, False, IntToStr(TcxGridIndicatorRowItemViewInfo(AViewInfo).GridRecord.Index + 1)
, ACanvas.Font, clFont, clBrush);
ADone := True;
end;