1

我创建了一个自定义的 SplitView 类,它是 NSSplitView 的子类。一切对我来说都是正确的,并且工作正常,除了分隔线。出于某种原因,它不想出现在我的 SplitView 视图之间。

任何形式的提示或帮助都非常感谢!

这是我在笔尖中的设置:

在此处输入图像描述

以及我运行它时的外观

在此处输入图像描述

有趣的是,当我将鼠标移动到分隔线应该在的位置时,光标会发生变化,我可以拖动它......但由于某种原因它看起来不正确

4

1 回答 1

1

You can change the color of the divider using the 'drawDividerInRect:' function to change the color of the divider by passing your own rectangle. It is also possible you moved one of the custom views in the split view and can't see the divider anymore. You could try selecting the different views using the object hierarchy.

I've found that apple doesn't like to make it easy to modify a lot of their different views and controllers, probably because they are trying to maintain some uniformity in the apps that are run on their system.

Is the hidden check box checked?

enter image description here

于 2013-07-18T19:50:07.833 回答