删除tcategorypanel边框 [英] Remove tcategorypanel border
本文介绍了删除tcategorypanel边框的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何从XE3中的TCategoryPanel和TCategoryPanelGroup中删除边框?
How can you remove the border from TCategoryPanel and TCategoryPanelGroup in XE3?
尝试此操作并且不起作用:
Tried this and didn't work:
type
TCategoryPanel = class (Vcl.ExtCtrls.TCategoryPanel)
protected
procedure CreateParams ( var Params: TCreateParams); override ;
end ;
procedure TCategoryPanel.CreateParams ( var Params: TCreateParams);
begin
Inherited ;
Params.Style:= Params.Style and not WS_BORDER;
end ;
推荐答案
对于 TCategoryPanel
您需要将受保护的属性 BevelOuter
设置为 bvNone
。
For TCategoryPanel
you need to set the protected property BevelOuter
to bvNone
.
对于 TCategoryPanelGroup
,您确实可以删除 CreateParams
中的边框。像这样:
For TCategoryPanelGroup
you can indeed remove the border in CreateParams
. Like so:
Params.Style := Params.Style and (not WS_BORDER);
看起来像这样:
< img src =https://i.stack.imgur.com/gHNyj.pngalt =在此输入图像说明>
这篇关于删除tcategorypanel边框的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文