Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

没搞懂.ui怎么编辑来改大小 #6

Closed
Wongboo opened this issue Jul 9, 2020 · 3 comments
Closed

没搞懂.ui怎么编辑来改大小 #6

Wongboo opened this issue Jul 9, 2020 · 3 comments

Comments

@Wongboo
Copy link

Wongboo commented Jul 9, 2020

image
image
image
图二是我原来的构思,图一是做出来的效果(菜单栏右对齐有三个点,打开是关于和帮助),但——正如图三所指出的,它的状态栏和菜单栏都太小了。
于是我尝试在MiniDraw.ui里调整大小,对象Minidraw里面有三个子对象centralWidget、menuBar、statusBar,但遗憾的是centralWidget好像怎么也调不小,无论是调整geometry还是sizepolicy都不行,即使在viewwidget.ui里也不行,直接导致了状态栏和菜单栏都放不大,最后看起来比例失调。
望赐教!

@Ubpa
Copy link
Owner

Ubpa commented Jul 13, 2020

我也不是 Qt 专家,这种事情主要看文档。我查到的资料是菜单栏会根据内部的内容调整大小,尝试扩大 icon 的大小看看?

@Wongboo
Copy link
Author

Wongboo commented Jul 16, 2020

我也不是 Qt 专家,这种事情主要看文档。我查到的资料是菜单栏会根据内部的内容调整大小,尝试扩大 icon 的大小看看?

没用啊,这个操作的目的是让n个字符的按钮宽度能更大(而不是只适应n个字符的大小,例如适应(n+2)个字符的大小),也就是说让按钮横向更大,无法让菜单栏(或者说按钮)竖向更大

@Wongboo
Copy link
Author

Wongboo commented Jul 18, 2020 via email

@Wongboo Wongboo closed this as completed Oct 13, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants