如何在情节提要的触摸栏中添加滚动视图? [英] How to add a scrollview in Touch Bar in Storyboard?

查看:81
本文介绍了如何在情节提要的触摸栏中添加滚动视图?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在情节提要中的触摸栏上添加了几个按钮,除了我只能在我的教育应用程序中容纳大约4个按钮(因为这些按钮同时包含图像和文字)之外,其他所有功能都正常运行.

I am adding a few buttons to the Touch Bar in storyboard, everything works fine except that I can only fit about 4 buttons in there (since the buttons contain both image and text) in my education app.

我想添加一个滚动视图以包含所有按钮,但是似乎无法将ScrollView拖动到触摸栏中.在触摸栏中拥有一组可滚动按钮的最佳方法是什么?

I would like to add a scrollview to contains all the buttons, but does not seem to be able to drag a ScrollView into the Touch Bar. What is the best way to have a scrollable set of buttons in Touch Bar?

推荐答案

您首先需要插入触摸栏视图,然后可以包含 NSScrollView .

You firstly need to insert Touch Bar View which can then contian NSScrollView.

它应该看起来像这样:

然后,最终输出如下所示:

Then the final output looks like this:

这篇关于如何在情节提要的触摸栏中添加滚动视图?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆