How to add controls to a Tab control

后端 未结 2 1008
青春惊慌失措
青春惊慌失措 2021-01-14 01:48

I am using a Tab control in my GUI app and I know how to add and remove tabs from it (TCM_INSERTITEM, etc.) but I cannot figure out how to add other controls to a tab like B

2条回答
  •  终归单人心
    2021-01-14 01:56

    While you can certainly specify a tab control as the parent of another control, this isn't going to help you. The tab control will not be aware of its (newly added) children and so it cannot arrange itself to accomodate them.

    So the short answer is: You cannot.

    The long answer is that you have two choices:

    1) Build your own tab control which can support children.

    2) Arrange the other controls along with the tab control such that they fit together, but do not overlap.

提交回复
热议问题