[分享] Line视窗边框置顶的解决方法

楼主: macarthur628 (macarthur628)   2022-01-29 12:19:20
* 问题
https://zhuanlan.zhihu.com/p/106926984
* 解决方法
我发现 line四个边框分别属于四个不同的视窗,
这四个边框的 window ID分别是主视窗 ID + 10, ID + 14, ID + 18, ID + 22.
登入桌面环境后, 执行下列 script就可以解决这个问题
#!/usr/bin/python3
import time
import os
while True:
time.sleep(5)
exist = os.popen("ps -ef | grep LINE.exe")
e = exist.readlines()
if len(e) < 3:
print(e)
print("Line not started.")
exist.close()
continue
exist.close()
output = os.popen("wmctrl -l -G -p -x")
s = output.readlines()
id = ''
for item in s:
print(item)
if item.find("line.exe.line.exe") != -1:
id = item.split()[0]
break
output.close()
print(id)
if id != '':
sequences = [10, 14, 18, 22]
for i in sequences:
shadow = int(id, base=16)
shadow += i
shadow = "0x" + f"{shadow:x}"
print(shadow)
os.system("xdotool windowunmap " + shadow)
else:
print("Line not display yet.")
作者: Fortis931 (吾手发炎 其形微贱)   2022-01-29 15:20:00
这是wine下的line?
楼主: macarthur628 (macarthur628)   2022-01-29 16:16:00
对啊,用wine执行line
作者: rexct (rexct)   2022-01-29 21:29:00
借问原po或有人用wine执行line 7.0以上成功的吗?
楼主: macarthur628 (macarthur628)   2022-01-30 11:12:00
我用的line版本是6.7.4.2508
作者: holishing   2022-01-30 20:56:00
没有, wine 怎样弄都绕不过新版限制

Links booklink

Contact Us: admin [ a t ] ucptt.com