Giter Site home page Giter Site logo

Comments (7)

wangwenx190 avatar wangwenx190 commented on June 13, 2024

手动resize一下就好了,可能是qt的bug

from framelesshelper.

XwAdmin avatar XwAdmin commented on June 13, 2024

刚刚尝试了一下,在moveEvent中使用resize
resize(size()); 没有效果
resize(width(), height() + 1); 才可以
但是每次移动,都会设置一下大小,就有点疑惑,这是目前的最优方案嘛,还是我操作有误呢。不吝赐教。

from framelesshelper.

wangwenx190 avatar wangwenx190 commented on June 13, 2024

我测试得到的结论是这样的,单个显示器不存在这个问题,多个显示器,跨显示器移动窗口时大概率会遇到这个问题,但也不是必现的。这个问题跟自定义边框没什么关系,你可以用一个正常的qt窗口试试,也会遇到这个问题。我看了很多开源项目的源码,发现基本没有处理这个问题的,所以我建议你也不用去管。如果你想解决,可以监听qt的screenChanged信号,当屏幕发生改变时手动触发一次resize,和原来大小相同肯定没用,但为了尽可能减小用户的感知,可以只改变一个像素。这也是临时的解决方案,最终的解决方案还是要qt自身做出修改。

from framelesshelper.

XwAdmin avatar XwAdmin commented on June 13, 2024

辛苦,thanks.

from framelesshelper.

wangwenx190 avatar wangwenx190 commented on June 13, 2024

这个问题我去年就发现了,不过这是个普遍问题,qt程序都存在,也没见有去解决的,你可以不用管

from framelesshelper.

JulienMaille avatar JulienMaille commented on June 13, 2024

FYI @wangwenx190 this bug is back when using code from latest commit (with the "widget" example)

from framelesshelper.

wangwenx190 avatar wangwenx190 commented on June 13, 2024

FYI @wangwenx190 this bug is back when using code from latest commit (with the "widget" example)

The word "back" may not be accurate. The issue always exists. We indeed fixed this issue long time ago. But I was wondering the performance and reliability of our workaround, so I removed it some time ago, last year some day. I think we may just live with it because most frameless Qt applications have this issue.

from framelesshelper.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.