virtual int GetCaptionHeight() const{ return 0; }
我用它可以将标题栏隐藏在对接状态,但是当它浮动时,标题就存在了。
The caption is drawn from the Pane only when it is not floating. Just look into the default implementation for GetCaptionHeight
!
The pane is inside a CPaneFrameWnd
when it is floating.
AFAIK you have to control over the outer frame window. It is created by CreateDefaultMiniframe
. It should usually create a CPaneFrameWnd
.
Derive your own class from the default mini frame class. (should be CPaneFrameWnd
, but better recheck it). There is a virtual function CPaneFrameWnd::GetCaptionRect
.
Use SetMiniFrameRTC
in your CDockablePane
class to set this new class frame to be used for your pane.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.