Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我的布局有问题,找不到任何解决方案。下面是两张图片。第一个来自 Qt Designer,一切看起来都很棒(但没有 QGraphicsScene,所以它是可以预期的)。第二个是真正的应用程序,左下角的场景太宽了。作为我正在拍摄的场景矩形this->ui->juliaMandelbrot->geometry(),这意味着 QGraphicsView 的几何形状。但这会返回 640x150 而不是 225x150。我究竟做错了什么?
this->ui->juliaMandelbrot->geometry()
谢谢你。
虽然我不喜欢它,但我设置了图形视图的最大宽度,它解决了我的问题。
我不喜欢它,因为我的图形视图的祖父母已经设置了最大宽度,所以我想,孩子们继承了这个属性:-(。