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

下拉菜单错位(Linux平台) #4

Open
MoYingJi opened this issue Jun 22, 2024 · 4 comments
Open

下拉菜单错位(Linux平台) #4

MoYingJi opened this issue Jun 22, 2024 · 4 comments
Labels
bug Something isn't working help wanted Extra attention is needed

Comments

@MoYingJi
Copy link

点击下拉菜单有概率错位,收回后再次点击则正常,控制台除了可能是系统原因引发的错误没有任何其他输出
图片

运行环境: Arch Linux 6.9.4, KDE Plasma 6.0.5, Wayland 1.23.0, Qt 6.7.1, Python 3.12.4
Python模块版本: pyqt5 5.15.10, pyside6 6.7.1
不会是因为系统吧(

@ChinaIceF
Copy link
Owner

试试在SiMenu.py中print这两个函数的传入值,如图1
popup函数是SiComboBox.py中SiComboBox类的popup方法调用的,其传入了下拉菜单的全局坐标相关值,即self.label.mapToGlobal(self.label.pos()),这个很有可能是不同平台的版本或者是系统处理mapToGlobal的方式不同导致的,或许和系统问题有关
image

@MoYingJi
Copy link
Author

对不起我似乎print不出来,build和SiliconUI文件夹下两个我都加了print但控制台似乎还是没有输出
屏幕截图_20240623_130402
屏幕截图_20240623_130215

@ChinaIceF
Copy link
Owner

你可以将修改后.py所在的SiliconUI文件夹整个复制到Gallery的工作目录下,这时应该优先加载工作目录里的库,就可以print出来了

@MoYingJi
Copy link
Author

无论是否错位,两次打印结果相同
屏幕截图_20240623_190415
第一次是错位的,第二次是收回后再次点击没有出现错位的

@ChinaIceF ChinaIceF added the help wanted Extra attention is needed label Jun 30, 2024
@ChinaIceF ChinaIceF changed the title 下拉菜单错位 下拉菜单错位(Linux平台) Jun 30, 2024
@ChinaIceF ChinaIceF added the bug Something isn't working label Jun 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants