0
I am programming a virtual keyboard, where I will type by clicking the mouse. In python2.7 interface Qt4 I’ve been able to solve the idea enough, I’ve been able to make him keep showing up, and also make him type in any other window.. The problem is that it is only typing when I click on an input from another window, only after typing. I need it to keep the Focus false, even if you click it and the other windows have the Focus control. That is possible?
PS the code
from PyQt4 import QtGui, uic, QtCore
from PyQt4.QtCore import *
import pyautogui
import time
form_class = uic.loadUiType("Form1.ui")[0]
class MyWindowClass(QtGui.QMainWindow, form_class):
def __init__(self, parent=None):
QtGui.QMainWindow.__init__(self, parent, QtCore.Qt.WindowStaysOnTopHint)
self.setupUi(self)
#
self.btn1.clicked.connect(self.btn1_clicked)
#self.btnEntrar.clicked.connect(self.btnEntrar_clicked)
#self.btnEntrar2.clicked.connect(self.btnEntrar2_clicked)
def btn1_clicked(self):
#print "teste"
time.sleep(5)
pyautogui.typewrite("Teste 1, 2, 3...")
Show current code so it can be checked where the problem is.
– Denis Callau
Okay, I put the code there
– Mega Anim