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.
我想知道是否可以覆盖诸如paintEvent或mousePressEvent之类的方法,例如,对于不是以编程方式创建但在UI编辑器中创建的小部件。
以编程方式创建的小部件与使用 UI 编辑器创建的小部件之间没有区别。如果要在编辑器中添加从基本小部件派生的自定义小部件,请执行以下操作: