{"id":267596,"date":"2015-11-06T01:56:02","date_gmt":"2015-11-05T22:56:02","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=267596"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=267596","title":{"rendered":"SWAPY \u0441 \u043d\u043e\u0432\u044b\u043c \u0433\u0435\u043d\u0435\u0440\u0430\u0442\u043e\u0440\u043e\u043c \u043a\u043e\u0434\u0430"},"content":{"rendered":"<p>       <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/97b\/a96\/d4c\/97ba96d4c55d4e73a6205689cfb98604.png\" alt=\"SWAPY\" align=\"left\"\/><br \/>  SWAPY \u2013 \u0433\u0440\u0430\u0444\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0443\u0442\u0438\u043b\u0438\u0442\u0430 \u0434\u043b\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438 UI \u0434\u043b\u044f pywinauto (Python).<br \/>  \u0412 \u0432\u0435\u0440\u0441\u0438\u0438 <a href=\"https:\/\/github.com\/pywinauto\/SWAPY\/releases\">0.4.7<\/a> \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u043f\u0435\u0440\u0435\u0440\u0430\u0431\u043e\u0442\u0430\u043d \u0433\u0435\u043d\u0435\u0440\u0430\u0442\u043e\u0440 \u043a\u043e\u0434\u0430.<br \/>  \u041e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438, \u0430 \u0442\u0430\u043a\u0436\u0435 \u043f\u0440\u0438\u043c\u0435\u0440\u044b \u043a\u0430\u043a \u0431\u044b\u0441\u0442\u0440\u043e \u0438 \u043f\u0440\u043e\u0441\u0442\u043e \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u0441\u043a\u0440\u0438\u043f\u0442\u044b \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f UI, \u0441\u043c\u043e\u0442\u0440\u0438\u0442\u0435 \u043f\u043e\u0434 \u043a\u0430\u0442\u043e\u043c.<br \/>  <a name=\"habracut\"><\/a><\/p>\n<p>  <\/p>\n<h3>\u041e\u043f\u0438\u0441\u0430\u043d\u0438\u0435<\/h3>\n<p>  SWAPY \u2013 \u0433\u0440\u0430\u0444\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0443\u0442\u0438\u043b\u0438\u0442\u0430 \u0434\u043b\u044f \u043f\u0440\u043e\u0441\u043c\u043e\u0442\u0440\u0430 \u0438\u0435\u0440\u0430\u0440\u0445\u0438\u0438 \u043e\u043a\u043e\u043d \u0438 \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0438 \u043a\u043e\u0434\u0430 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438 UI \u0434\u043b\u044f \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 pywinauto.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/002\/1c8\/f76\/0021c8f76d3d45408739bea0c26d1002.png\" alt=\"Interface\"\/><\/p>\n<p>  \u0421\u0430\u043c\u043e \u043d\u0430\u0437\u0432\u0430\u043d\u0438\u0435 \u044d\u0442\u043e \u0430\u043a\u0440\u043e\u043d\u0438\u043c, \u043e\u0442\u0440\u0430\u0436\u0430\u044e\u0449\u0438\u0439 \u043e\u0441\u043d\u043e\u0432\u043d\u0443\u044e \u0438\u0434\u0435\u044e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u2014 Simple Windows Automation on PYthon. \u0423\u0442\u0438\u043b\u0438\u0442\u0430 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0441\u043e\u0431\u043e\u0439 \u043f\u043e\u043b\u043d\u043e\u0446\u0435\u043d\u043d\u044b\u0439 exe \u0444\u0430\u0439\u043b, \u0441\u043e\u0431\u0440\u0430\u043d\u043d\u044b\u0439 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e PyInstaller. SWAPY \u043d\u0435 \u0442\u0440\u0435\u0431\u0443\u0435\u0442 \u043d\u0438\u043a\u0430\u043a\u0438\u0445 \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0445 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043e\u043a \u0434\u043b\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438 \u0438 \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0438 \u043a\u043e\u0434\u0430. \u041a\u043e\u043d\u0435\u0447\u043d\u043e, \u0434\u043b\u044f \u0434\u0430\u043b\u044c\u043d\u0435\u0439\u0448\u0435\u0433\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u043a\u043e\u0434\u0430 \u0432\u0430\u043c \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u0442\u0441\u044f \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u043a\u0430\u043a \u043c\u0438\u043d\u0438\u043c\u0443\u043c Python \u0438 pywinauto. \u041d\u043e \u0434\u043b\u044f \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0435\u0439 \u0438, \u0441\u0430\u043c\u043e\u0435 \u0433\u043b\u0430\u0432\u043d\u043e\u0435, \u043f\u043e\u0434\u043e\u0439\u0434\u0435\u0442 \u043b\u0438 \u0442\u0430\u043a\u0430\u044f \u0441\u0432\u044f\u0437\u043a\u0430 \u0434\u043b\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438 \u0412\u0430\u0448\u0435\u0433\u043e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f, SWAPY \u0432\u043f\u043e\u043b\u043d\u0435 \u0441\u0430\u043c\u043e\u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u0430.<\/p>\n<p>  \u0423\u0442\u0438\u043b\u0438\u0442\u0430 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0442\u0440\u0438 \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0445 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u0430, \u044d\u0442\u043e:  <\/p>\n<ul>\n<li>\u0434\u0435\u0440\u0435\u0432\u043e \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u0432<\/li>\n<li>\u0442\u0430\u0431\u043b\u0438\u0446\u0430 \u0441\u0432\u043e\u0439\u0441\u0442\u0432 \u0432\u044b\u0431\u0440\u0430\u043d\u043d\u043e\u0433\u043e \u043e\u0431\u044a\u0435\u043a\u0442\u0430<\/li>\n<li>\u043f\u043e\u043b\u0435 \u0441 \u043a\u043e\u0434\u043e\u043c<\/li>\n<\/ul>\n<p>  \u0427\u0442\u043e\u0431\u044b \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u0441\u043a\u0440\u0438\u043f\u0442, \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043d\u0430\u0439\u0442\u0438 \u044d\u043b\u0435\u043c\u0435\u043d\u0442 \u0432 \u0434\u0435\u0440\u0435\u0432\u0435 \u0432\u0441\u0435\u0445 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043e\u0432 \u0438 \u0437\u0430\u0442\u0435\u043c \u0432\u044b\u0437\u0432\u0430\u0442\u044c \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, Click. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u0441\u044f \u043a\u0430\u043a \u0441\u0430\u043c\u043e \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 \u043d\u0430\u0434 \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u043c, \u0442\u0430\u043a \u0438 \u043e\u0431\u043d\u043e\u0432\u0438\u0442\u0441\u044f \u043f\u043e\u043b\u0435 \u0441 \u043a\u043e\u0434\u043e\u043c.<\/p>\n<p>  \u0420\u0430\u043d\u044c\u0448\u0435 \u0433\u0435\u043d\u0435\u0440\u0430\u0442\u043e\u0440\u0443 \u043a\u043e\u0434\u0430 \u0443\u0434\u0435\u043b\u044f\u043b\u043e\u0441\u044c \u043c\u0430\u043b\u043e \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u044f. \u0427\u0430\u0449\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b\u0438\u0441\u044c \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u043f\u043e\u0438\u0441\u043a\u0430 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430 \u0438 \u043f\u0440\u043e\u0441\u043c\u043e\u0442\u0440\u0430 \u0435\u0433\u043e \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432. \u0412\u0441\u0435 \u0444\u0438\u043a\u0441\u044b \u0438 \u0444\u0438\u0447\u0438 \u0434\u043b\u044f \u0433\u0435\u043d\u0435\u0440\u0430\u0442\u043e\u0440\u0430 \u043a\u043e\u0434\u0430 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u043b\u0438\u0441\u044c \u043f\u043e \u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e\u043c\u0443 \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0443. \u0412 \u0438\u0442\u043e\u0433\u0435, \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0440\u0430\u0431\u043e\u0447\u0438\u0439 \u043a\u043e\u0434, \u043d\u0443\u0436\u043d\u044b \u0431\u044b\u043b\u0438 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u044b\u0435 \u0443\u0441\u0438\u043b\u0438\u044f \u0441\u043e \u0441\u0442\u043e\u0440\u043e\u043d\u044b \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u2014 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0431\u044b\u043b\u043e \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u043f\u0440\u043e\u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0432\u0441\u0435\u0445 \u043f\u0440\u0435\u0434\u043a\u043e\u0432.<\/p>\n<p>  \u041d\u043e\u0432\u044b\u0439 \u0433\u0435\u043d\u0435\u0440\u0430\u0442\u043e\u0440 \u043a\u043e\u0434\u0430, \u0432 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u043c, \u043b\u0438\u0448\u0435\u043d \u043f\u0440\u0435\u0436\u043d\u0438\u0445 \u043d\u0435\u0434\u043e\u0441\u0442\u0430\u0442\u043a\u043e\u0432.<\/p>\n<h3>\u0418\u0441\u0442\u043e\u0440\u0438\u044f \u0440\u0430\u0437\u0432\u0438\u0442\u0438\u044f<\/h3>\n<p>  \u0412 \u043d\u0430\u0447\u0430\u043b\u0435 2011 \u0433\u043e\u0434\u0430, \u0431\u0443\u0434\u0443\u0447\u0438 \u043d\u0430 \u0434\u043e\u043b\u0436\u043d\u043e\u0441\u0442\u0438 \u00abAutomation QA Engineer\u00bb, \u043e\u0442\u043a\u0440\u044b\u043b \u0434\u043b\u044f \u0441\u0435\u0431\u044f \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 \u0434\u043b\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438 UI \u2013 pywinauto. \u041e\u0431 \u0438\u0441\u0442\u043e\u0440\u0438\u0438 \u0440\u0430\u0437\u0432\u0438\u0442\u0438\u044f \u0441\u0430\u043c\u043e\u0439 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 \u043c\u043e\u0436\u043d\u043e \u043a\u043e\u0435-\u0447\u0442\u043e \u0443\u0437\u043d\u0430\u0442\u044c \u0432 \u0441\u0442\u0430\u0442\u044c\u0435 <a href=\"http:\/\/habrahabr.ru\/company\/intel\/blog\/266459\/\">\u00ab\u0421\u0442\u0430\u0440\u044b\u0439 \u043d\u043e\u0432\u044b\u0439 pywinauto\u00bb<\/a>. \u041d\u0430 \u0442\u043e\u0442 \u043c\u043e\u043c\u0435\u043d\u0442 \u043e\u043d\u0430 \u043f\u0440\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u043d\u0435 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u043b\u0430\u0441\u044c. \u0422\u0435\u043c \u043d\u0435 \u043c\u0435\u043d\u0435\u0435 Pywinauto \u043f\u043e\u0431\u0435\u0434\u0438\u043b\u0430 \u0432\u0441\u0435\u0445 \u0441\u0432\u043e\u0438\u0445 \u043a\u043e\u043d\u043a\u0443\u0440\u0435\u043d\u0442\u043e\u0432 \u0438 \u0431\u044b\u043b\u0430 \u0432\u044b\u0431\u0440\u0430\u043d\u0430 \u0434\u043b\u044f \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0440\u044f\u0434\u0430 \u043f\u0440\u043e\u0434\u0443\u043a\u0442\u043e\u0432 \u0441\u043e \u0441\u0440\u0435\u0434\u043d\u0435\u0439 \u0441\u043b\u043e\u0436\u043d\u043e\u0441\u0442\u044c\u044e \u0433\u0440\u0430\u0444\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430.<\/p>\n<p>  \u041e\u0442\u043c\u0435\u0447\u0443 \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u0430, \u0431\u043b\u0430\u0433\u043e\u0434\u0430\u0440\u044f \u043a\u043e\u0442\u043e\u0440\u044b\u043c \u0432\u044b\u0431\u043e\u0440 \u043f\u0430\u043b \u0438\u043c\u0435\u043d\u043d\u043e \u043d\u0430 \u044d\u0442\u043e\u0442 \u0432\u0430\u0440\u0438\u0430\u043d\u0442:  <\/p>\n<ol>\n<li>\u0426\u0435\u043d\u0430 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u0430. Pywinauto \u0431\u0435\u0441\u043f\u043b\u0430\u0442\u043d\u0430, \u0440\u0430\u0441\u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u044f\u0435\u0442\u0441\u044f \u043f\u043e\u0434 \u043b\u0438\u0446\u0435\u043d\u0437\u0438\u0435\u0439 GNU LGPL v.2.1<\/li>\n<li>\u042d\u0442\u043e \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 Python. \u0421\u043e \u0432\u0441\u0435\u043c\u0438 \u0435\u0433\u043e \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044f\u043c\u0438, \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430\u043c\u0438, \u0438 \u0442.\u0434.<\/li>\n<li>\u041f\u0440\u043e\u0441\u0442\u0430\u044f \u043f\u043e\u0434\u0433\u043e\u0442\u043e\u0432\u043a\u0430 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f. \u041f\u043e\u0434\u0433\u043e\u0442\u043e\u0432\u0438\u0442\u044c \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u0443\u044e \u043c\u0430\u0448\u0438\u043d\u0443 \u0434\u043b\u044f \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0432 Python + pywinauto \u0441\u0438\u043b\u044c\u043d\u043e \u043f\u0440\u043e\u0449\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0442\u0430\u043a\u043e\u0433\u043e \u043c\u043e\u043d\u0441\u0442\u0440\u0430 \u043a\u0430\u043a TestComplete. \u042d\u0442\u043e \u0432\u0435\u0441\u044c\u043c\u0430 \u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u043e \u0432 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f Continuous Integration.<\/li>\n<\/ol>\n<p>  \u0412\u0441\u043a\u043e\u0440\u0435 \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0438\u043b\u0441\u044f \u043e\u0434\u0438\u043d \u043d\u0435\u0434\u043e\u0441\u0442\u0430\u0442\u043e\u043a \u2014 \u0442\u0440\u0430\u0442\u0438\u0442\u0441\u044f \u043c\u043d\u043e\u0433\u043e \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u043d\u0430 \u043f\u043e\u0438\u0441\u043a \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0433\u043e \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430 \u0438 \u0430\u043d\u0430\u043b\u0438\u0437 \u0435\u0433\u043e \u0441\u0432\u043e\u0439\u0441\u0442\u0432. \u041e\u0447\u0435\u043d\u044c \u043d\u0435 \u0445\u0432\u0430\u0442\u0430\u043b\u043e \u0433\u0440\u0430\u0444\u0438\u0447\u0435\u0441\u043a\u043e\u0439 \u0443\u0442\u0438\u043b\u0438\u0442\u044b \u0434\u043b\u044f \u043f\u0440\u043e\u0441\u043c\u043e\u0442\u0440\u0430 \u0434\u0435\u0440\u0435\u0432\u0430 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u0432 \u0438 \u0438\u0445 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432. \u0411\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0435 \u0434\u043b\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438 \u0433\u0440\u0430\u0444\u0438\u0447\u0435\u0441\u043a\u0438\u0445 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u043e\u0432 \u0431\u044b\u043b\u043e \u0431\u044b \u043d\u0435 \u043f\u043b\u043e\u0445\u043e \u0438\u043c\u0435\u0442\u044c \u0433\u0440\u0430\u0444\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441.<\/p>\n<p>  \u0411\u044b\u043b\u043e \u0440\u0435\u0448\u0435\u043d\u043e \u0438\u0441\u043f\u0440\u0430\u0432\u0438\u0442\u044c \u044d\u0442\u0443 \u043d\u0435\u0441\u043f\u0440\u0430\u0432\u0435\u0434\u043b\u0438\u0432\u043e\u0441\u0442\u044c.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/679\/9d0\/d20\/6799d0d20afc480494f020705c9f7bde.png\" alt=\"logo-head\" align=\"left\"\/><br \/>  \u0412 \u0430\u043f\u0440\u0435\u043b\u0435 2011 \u0433\u043e\u0434\u0430 \u044f \u043d\u0430\u0447\u0430\u043b \u0440\u0430\u0431\u043e\u0442\u0443 \u043d\u0430\u0434 \u0443\u0442\u0438\u043b\u0438\u0442\u043e\u0439, \u043a \u043a\u043e\u043d\u0446\u0443 \u0433\u043e\u0434\u0430 \u0432\u0435\u0440\u0441\u0438\u044f \u0441\u0442\u0440\u0435\u043c\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0432\u044b\u0440\u043e\u0441\u043b\u0430 \u0434\u043e 0.3.0, \u0430 \u0443\u0442\u0438\u043b\u0438\u0442\u0430 \u0443\u0436\u0435 \u0438\u043c\u0435\u043b\u0430 \u0432\u0441\u0435 \u043a\u043b\u044e\u0447\u0435\u0432\u044b\u0435 \u0441\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u044e\u0449\u0438\u0435 \u0438\u2026 \u043c\u043d\u043e\u0436\u0435\u0441\u0442\u0432\u043e \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u2026<\/p>\n<p>  \u0412 \u0442\u0435\u0447\u0435\u043d\u0438\u0435 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0433\u043e \u0433\u043e\u0434\u0430 \u043f\u043e\u0442\u0438\u0445\u043e\u043d\u044c\u043a\u0443 \u0438\u0441\u043f\u0440\u0430\u0432\u043b\u044f\u043b\u0438\u0441\u044c \u043e\u0448\u0438\u0431\u043a\u0438 \u0438 \u0447\u0442\u043e-\u0442\u043e \u043d\u0435\u0437\u043d\u0430\u0447\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0435 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u043b\u043e\u0441\u044c. \u0410 \u043f\u043e\u0442\u043e\u043c \u044f \u0441\u043c\u0435\u043d\u0438\u043b \u0440\u0430\u0431\u043e\u0442\u0443 \u0438 \u0438\u043d\u0442\u0435\u0440\u0435\u0441 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0442\u044c \u0443\u0442\u0438\u043b\u0438\u0442\u0443, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u0441\u0430\u043c \u043d\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e, \u0434\u0430 \u0435\u0449\u0435 \u0438 \u0432 \u043e\u0434\u0438\u043d\u043e\u0447\u043a\u0443, \u043f\u0440\u043e\u043f\u0430\u043b.<\/p>\n<p>  \u0412\u0442\u043e\u0440\u043e\u0435 \u0434\u044b\u0445\u0430\u043d\u0438\u0435 SWAPY \u043f\u043e\u043b\u0443\u0447\u0438\u043b \u0432 \u0441\u0435\u043d\u0442\u044f\u0431\u0440\u0435 2015, \u043a\u043e\u0433\u0434\u0430 \u0440\u0435\u0431\u044f\u0442\u0430 \u0438\u0437 pywinauto \u043f\u043e\u0437\u0432\u0430\u043b\u0438 \u043a \u0441\u0435\u0431\u0435.<\/p>\n<p>  \u0421 \u0442\u0435\u0445 \u043f\u043e\u0440 \u0441\u0442\u0430\u043b \u0441\u043d\u043e\u0432\u0430 \u0430\u043a\u0442\u0438\u0432\u043d\u043e \u0440\u0430\u0437\u0432\u0438\u0432\u0430\u0442\u044c \u0443\u0442\u0438\u043b\u0438\u0442\u0443. \u041a\u043b\u044e\u0447\u0435\u0432\u044b\u043c \u0443\u043b\u0443\u0447\u0448\u0435\u043d\u0438\u0435\u043c \u043c\u043e\u0436\u043d\u043e \u043d\u0430\u0437\u0432\u0430\u0442\u044c \u043d\u043e\u0432\u044b\u0439 \u0433\u0435\u043d\u0435\u0440\u0430\u0442\u043e\u0440 \u043a\u043e\u0434\u0430.<\/p>\n<p>  \u042f \u043f\u0435\u0440\u0435\u0441\u043c\u043e\u0442\u0440\u0435\u043b \u0441\u0432\u043e\u0435 \u043e\u0442\u043d\u043e\u0448\u0435\u043d\u0438\u0435 \u043a \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0438 \u043a\u043e\u0434\u0430 \u043a\u0430\u043a \u043a \u043e\u0434\u043d\u043e\u0439 \u0438\u0437 \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0445 \u0444\u0443\u043d\u043a\u0446\u0438\u0439. \u0418\u043c\u0435\u043d\u043d\u043e \u0447\u0435\u0440\u0435\u0437 \u0433\u0435\u043d\u0435\u0440\u0430\u0442\u043e\u0440 \u043a\u043e\u0434\u0430 \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0437\u043d\u0430\u043a\u043e\u043c\u0438\u0442\u044c \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0430 \u0441 \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u043c\u0438 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044f\u043c\u0438 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438, \u0430 \u0442\u0430\u043a\u0436\u0435 \u0441\u043f\u0430\u0441\u0442\u0438 \u0434\u0430\u0436\u0435 \u043e\u043f\u044b\u0442\u043d\u043e\u0433\u043e \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0430 \u043e\u0442 \u0440\u0443\u0442\u0438\u043d\u044b.<\/p>\n<h3>\u041d\u043e\u0432\u044b\u0435 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438<\/h3>\n<p>  <\/p>\n<ul>\n<li>\u0413\u0435\u043d\u0435\u0440\u0430\u0442\u043e\u0440 \u043a\u043e\u0434\u0430 \u0442\u0435\u043f\u0435\u0440\u044c \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u043d\u043e\u0440\u043c\u0430\u043b\u044c\u043d\u043e. \u0418\u043c\u0435\u0435\u0442\u0441\u044f \u0432\u0432\u0438\u0434\u0443 \u0447\u0442\u043e \u043d\u0435 \u043d\u0443\u0436\u043d\u043e \u043a\u043b\u0438\u043a\u0430\u0442\u044c \u043f\u043e \u0432\u0441\u0435\u043c \u043f\u0440\u0435\u0434\u043a\u0430\u043c \u0432 \u0434\u0435\u0440\u0435\u0432\u0435 \u043e\u0431\u044a\u0435\u043a\u0442\u0430, \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u0441\u044f \u0440\u0430\u0431\u043e\u0447\u0438\u0439 \u043a\u043e\u0434. \u0421\u0435\u0439\u0447\u0430\u0441 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u043e\u0442\u044b\u0441\u043a\u0430\u0442\u044c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b\u0439 \u044d\u043b\u0435\u043c\u0435\u043d\u0442 \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u043d\u0430\u0434 \u043d\u0438\u043c \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435, \u043a\u043e\u0434 \u0431\u0443\u0434\u0435\u0442 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u043f\u043e\u0441\u0442\u0440\u043e\u0435\u043d \u0432\u043f\u043b\u043e\u0442\u044c \u0434\u043e \u0438\u043c\u043f\u043e\u0440\u0442\u0430. \u041e\u0434\u0438\u043d \u043a\u043b\u0438\u043a \u0432 \u043d\u043e\u0432\u043e\u0439 \u0432\u0435\u0440\u0441\u0438\u0438:\n<pre><code class=\"python\">from pywinauto.application import Application  app = Application().Start(cmd_line=u'&quot;C:\\\\Program Files (x86)\\\\Notepad++\\\\notepad++.exe&quot; ') notepad = app[u'Notepad++'] notepad.Wait('ready') systabcontrol = notepad.Tab systabcontrol.Select(u'new 1')  app.Kill_() <\/code><\/pre>\n<p>  \u0412 \u0441\u0442\u0430\u0440\u043e\u0439 \u0432\u0435\u0440\u0441\u0438\u0438 \u0430\u043d\u0430\u043b\u043e\u0433\u0438\u0447\u043d\u043e\u0435 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442 \u043a \u0442\u0430\u043a\u043e\u043c\u0443 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0443:  <\/p>\n<pre><code class=\"python\">import pywinauto  pwa_app = pywinauto.application.Application() ctrl.Select(0) <\/code><\/pre>\n<p>  \u041e\u0447\u0435\u0432\u0438\u0434\u043d\u043e \u0447\u0442\u043e \u0442\u0430\u043a\u043e\u0439 \u043a\u043e\u0434 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u043d\u0435 \u0431\u0443\u0434\u0435\u0442.<\/li>\n<li>\u041f\u043e\u043d\u044f\u0442\u043d\u044b\u0435 \u0438\u043c\u0435\u043d\u0430 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445. \u0421\u043e\u0433\u043b\u0430\u0441\u0438\u0442\u0435\u0441\u044c, <code>systabcontrol<\/code> \u043d\u0430\u043c\u043d\u043e\u0433\u043e \u043f\u043e\u043d\u044f\u0442\u043d\u0435\u0435 \u043a\u0430\u043a\u043e\u0433\u043e \u0442\u043e <code>ctrl<\/code>. \u0418\u043c\u0435\u043d\u0430 \u0444\u043e\u0440\u043c\u0438\u0440\u0443\u044e\u0442\u0441\u044f \u043d\u0430 \u0431\u0430\u0437\u0435 \u0438\u043c\u0435\u043d\u0438 \u043a\u043b\u0430\u0441\u0441\u0430 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u0430, \u043b\u0438\u0431\u043e \u0438\u0437 \u0441\u0430\u043c\u043e\u0433\u043e \u043a\u043e\u0440\u043e\u0442\u043a\u043e\u0433\u043e \u0438\u043c\u0435\u043d\u0438 \u0434\u043b\u044f \u0434\u043e\u0441\u0442\u0443\u043f\u0430 (\u0438\u0437 pywinauto). \u0422\u043e\u043b\u044c\u043a\u043e \u0435\u0441\u043b\u0438 \u043e\u0431\u0430 \u044d\u0442\u0438 \u0441\u043b\u0443\u0447\u0430\u044f \u0431\u044b\u043b\u0438 \u0431\u0435\u0437\u0443\u0441\u043f\u0435\u0448\u043d\u044b\u043c\u0438, \u0442\u043e \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u043e \u0431\u0435\u0437\u043b\u0438\u043a\u043e\u0435 \u2014 <code>control<\/code>.<\/li>\n<li>\u041a\u043e\u043d\u0442\u0440\u043e\u043b\u044c \u043d\u0430\u0434 \u043e\u0434\u0438\u043d\u0430\u043a\u043e\u0432\u044b\u043c\u0438 \u0438\u043c\u0435\u043d\u0430\u043c\u0438 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445. \u0415\u0441\u043b\u0438 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 \u0440\u0430\u0437\u043d\u044b\u043c\u0438 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u0430\u043c\u0438, \u0438\u043c\u0435\u044e\u0449\u0438\u043c\u0438 \u043e\u0434\u0438\u043d\u0430\u043a\u043e\u0432\u044b\u0435 \u0438\u043c\u0435\u043d\u0430, SWAPY \u0441\u043b\u0435\u0434\u0438\u0442 \u0447\u0442\u043e \u0431\u044b \u043e\u043d\u0438 \u043e\u0441\u0442\u0430\u0432\u0430\u043b\u0438\u0441\u044c \u0443\u043d\u0438\u043a\u0430\u043b\u044c\u043d\u044b\u043c\u0438.<br \/> \n<pre><code class=\"python\">button = calcframe.Button19 button.Click() button2 = calcframe.Button20 button2.Click() <\/code><\/pre>\n<p>  \u042d\u0442\u043e \u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u043e \u0434\u043b\u044f \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0433\u043e \u043f\u0443\u043d\u043a\u0442\u0430.<\/li>\n<li>\u041f\u043e\u0432\u0442\u043e\u0440\u043d\u043e\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435. \u041a\u0430\u043a \u043f\u0440\u0430\u0432\u0438\u043b\u043e, \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 \u0441\u043e\u0441\u0442\u043e\u0438\u0442 \u0438\u0437 \u0434\u0432\u0443\u0445 \u0441\u0442\u0440\u043e\u043a. \u0412 \u043f\u0435\u0440\u0432\u043e\u0439 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442 \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u043a \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u0443, \u0432\u043e \u0432\u0442\u043e\u0440\u043e\u0439 \u2014 \u043d\u0435\u043f\u043e\u0441\u0440\u0435\u0434\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435. \u0422\u0430\u043a \u0432\u043e\u0442, \u0435\u0441\u043b\u0438 \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u043b\u043e\u0441\u044c \u0432 \u043a\u0430\u043a\u043e\u0439 \u0442\u043e \u043c\u043e\u043c\u0435\u043d\u0442 \u043f\u043e\u0432\u0442\u043e\u0440\u0438\u0442\u044c \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 \u043d\u0430\u0434 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043e\u043c, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0443\u0436\u0435 \u0431\u044b\u043b \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u043d, \u0442\u043e \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043f\u0440\u043e\u0441\u0442\u043e \u043a\u043e\u0434 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f.\n<pre><code class=\"python\">button = calcframe.Button19 button.Click() button2 = calcframe.Button20 button2.Click() button.Click()  # \u041f\u043e\u0432\u0442\u043e\u0440\u043d\u044b\u0439 Click \u043f\u043e Button19 <\/code><\/pre>\n<\/li>\n<li><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/c43\/462\/0b1\/c434620b114b4674a87fa35f1db4cae6.png\" alt=\"clear_last_command\" align=\"right\"\/><br \/>  \u041e\u0442\u043c\u0435\u043d\u0430 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0435\u0439 \u043a\u043e\u043c\u0430\u043d\u0434\u044b. \u0427\u0430\u0441\u0442\u0435\u043d\u044c\u043a\u043e \u0432\u043e\u0437\u043d\u0438\u043a\u0430\u0435\u0442 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u044c \u0443\u0434\u0430\u043b\u0438\u0442\u044c \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u044e\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u0443, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u043f\u043e\u0441\u043b\u0435 \u043d\u0435\u0443\u0434\u0430\u0447\u043d\u044b\u0445 \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u043e\u0432. \u0422\u0435\u043f\u0435\u0440\u044c \u0435\u0441\u0442\u044c \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u044d\u0442\u043e \u0447\u0435\u0440\u0435\u0437 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u043d\u043e\u0435 \u043c\u0435\u043d\u044e \u0440\u0435\u0434\u0430\u043a\u0442\u043e\u0440\u0430. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u0438\u043c\u044f \u0438\u0441\u0447\u0435\u0437\u043d\u0443\u0432\u0448\u0435\u0439 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439 \u043e\u0441\u0432\u043e\u0431\u043e\u0434\u0438\u0442\u0441\u044f \u0438 \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u043e \u0432 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u0440\u0430\u0437. \u041e\u0442\u043c\u0435\u043d\u044f\u0442\u044c \u043c\u043e\u0436\u043d\u043e \u043b\u044e\u0431\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0448\u0430\u0433\u043e\u0432. \u041d\u0443\u0436\u043d\u043e \u043f\u043e\u043d\u0438\u043c\u0430\u0442\u044c, \u0447\u0442\u043e \u043e\u0442\u043c\u0435\u043d\u0430 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0435\u0439 \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u043b\u0438\u0448\u044c \u043e\u0447\u0438\u0441\u0442\u0438\u0442 \u043a\u043e\u0434, \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 \u0432 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0438 \u043d\u0435 \u0431\u0443\u0434\u0435\u0442 \u043e\u0442\u043c\u0435\u043d\u0435\u043d\u043e.<br \/>  \u0422\u0430\u043a\u0436\u0435 \u0435\u0441\u0442\u044c \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u043e\u0447\u0438\u0441\u0442\u0438\u0442\u044c \u0441\u0440\u0430\u0437\u0443 \u0432\u0435\u0441\u044c \u043a\u043e\u0434, \u0430 \u0435\u0449\u0435 \u043c\u043e\u0436\u043d\u043e \u0441\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u044c \u0432\u0435\u0441\u044c \u043a\u043e\u0434 \u0432 \u0444\u0430\u0439\u043b.  <\/li>\n<li><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/fa1\/5f5\/e12\/fa15f5e1252e40b2b2a606b2423607b8.png\" alt=\"image\" align=\"left\"\/><br \/>  \u0418\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0435 \u043a\u043e\u0434\u0430 \u00ab\u043d\u0430 \u043b\u0435\u0442\u0443\u00bb. \u041f\u043e\u043a\u0430 \u044d\u0442\u0430 \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0432 \u043e\u043a\u043d\u0430\u0445 \u0432\u0435\u0440\u0445\u043d\u0435\u0433\u043e \u0443\u0440\u043e\u0432\u043d\u044f \u0434\u043b\u044f \u043f\u0435\u0440\u0435\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043c\u0435\u0436\u0434\u0443 <code>app = Application().Start(cmd_line=...<\/code> \u0438 <code>app = Application().Connect(title=...<\/code>. \u0412 \u0431\u043e\u043b\u044c\u0448\u0438\u043d\u0441\u0442\u0432\u0435 \u0441\u043b\u0443\u0447\u0430\u0435\u0432 \u0431\u0443\u0434\u0435\u0442 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e <code>Start<\/code>, \u043d\u043e \u0435\u0441\u043b\u0438 \u043d\u0435 \u043d\u0443\u0436\u043d\u043e \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435, \u0442\u043e \u0441\u043b\u0435\u0434\u0443\u0435\u0442 \u0432\u044b\u0431\u0440\u0430\u0442\u044c <code>Application.Connect<\/code> \u0432 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u043d\u043e\u043c \u043c\u0435\u043d\u044e \u0434\u0435\u0440\u0435\u0432\u0430 \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u0432, \u043a\u043b\u0438\u043a\u043d\u0443\u0432 \u043d\u0430 \u0438\u043c\u0435\u043d\u0438 \u043e\u043a\u043d\u0430. \u041a\u043e\u0434 \u0432 \u0440\u0435\u0434\u0430\u043a\u0442\u043e\u0440\u0435 \u043e\u0431\u043d\u043e\u0432\u0438\u0442\u0441\u044f, \u0438\u0441\u0447\u0435\u0437\u043d\u0443\u0442 \u043f\u0440\u0438\u0432\u044f\u0437\u0430\u043d\u043d\u044b\u0435 \u043a \u043c\u0435\u0442\u043e\u0434\u0443 <code>Application().Start<\/code> \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u2014 <code>calcframe.Wait('ready')<\/code> \u0432 \u043d\u0430\u0447\u0430\u043b\u0435 \u0438 <code>app.Kill_()<\/code> \u0432 \u043a\u043e\u043d\u0446\u0435.<br \/>  \u041f\u0440\u0438\u043c\u0435\u0440 \u043a\u043e\u0434\u0430 \u0441\u043e \u0441\u0442\u0430\u0440\u0442\u043e\u043c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f.<br \/> \n<pre><code class=\"python\">from pywinauto.application import Application  app = Application().Start(cmd_line=u'&quot;C:\\\\Program Files (x86)\\\\Notepad++\\\\notepad++.exe&quot; ') notepad = app[u'Notepad++'] notepad.Wait('ready')  app.Kill_() <\/code><\/pre>\n<p>  \u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0435\u0442\u0441\u044f \u043a \u0443\u0436\u0435 \u0437\u0430\u043f\u0443\u0449\u0435\u043d\u043d\u043e\u043c\u0443 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044e.  <\/p>\n<pre><code class=\"python\">from pywinauto.application import Application  app = Application().Connect(title=u'new 1 - Notepad++', class_name='Notepad++') notepad = app[u'Notepad++'] <\/code><\/pre>\n<p>  <\/li>\n<\/ul>\n<p>  <\/p>\n<h3>\u041f\u0440\u0438\u043c\u0435\u0440 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f<\/h3>\n<p>  \u0422\u0435\u043f\u0435\u0440\u044c \u0434\u0430\u0432\u0430\u0439\u0442\u0435 \u0441\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0432 \u0434\u043b\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438 \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f. \u042f \u043f\u043e\u0441\u0442\u0430\u0440\u0430\u043b\u0441\u044f \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0436\u0438\u0437\u043d\u0435\u043d\u043d\u044b\u0435 \u043f\u0440\u0438\u043c\u0435\u0440\u044b \u0438 \u043e\u0434\u043d\u043e\u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e \u043f\u0440\u043e\u0434\u0435\u043c\u043e\u043d\u0441\u0442\u0440\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043d\u043e\u0432\u044b\u0435 \u0444\u0438\u0447\u0438 \u043a\u043e\u0434\u043e\u0433\u0435\u043d\u0435\u0440\u0430\u0442\u043e\u0440\u0430.<\/p>\n<h4>\u0422\u0435\u043a\u0441\u0442 \u043b\u0438\u0446\u0435\u043d\u0437\u0438\u0438<\/h4>\n<p>  \u0412 \u044d\u0442\u043e\u043c \u0442\u0435\u0441\u0442\u0435 \u043c\u044b \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u043c \u0447\u0442\u043e \u0442\u0435\u043a\u0441\u0442 \u043b\u0438\u0446\u0435\u043d\u0437\u0438\u0438 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442\u0441\u044f \u043d\u0430 \u0434\u0438\u0430\u043b\u043e\u0433\u0435 About. \u041e\u0434\u043d\u043e\u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e \u0443\u0431\u0435\u0434\u0438\u043c\u0441\u044f \u0447\u0442\u043e SWAPY \u043f\u043e\u043d\u0438\u043c\u0430\u0435\u0442, \u0447\u0442\u043e \u043d\u043e\u0432\u043e\u0435 \u043e\u043a\u043d\u043e \u043f\u0440\u0438\u043d\u0430\u0434\u043b\u0435\u0436\u0438\u0442 \u0441\u0442\u0430\u0440\u043e\u043c\u0443 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044e \u0438 \u043d\u0435 \u0431\u0443\u0434\u0435\u0442 \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c \u043b\u0438\u0448\u043d\u0438\u0445 \u0432\u044b\u0437\u043e\u0432\u043e\u0432 <code>app = Application().Start(...)<\/code>  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">\u041f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u0442\u0435\u043a\u0441\u0442\u0430 \u043b\u0438\u0446\u0435\u043d\u0437\u0438\u0438<\/b><\/p>\n<div class=\"spoiler_text\">\n<ol>\n<li>\u0417\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c \u0432\u0440\u0443\u0447\u043d\u0443\u044e Notepad++.<\/li>\n<li>\u041d\u0430\u0445\u043e\u0434\u0438\u043c \u0432 \u0434\u0435\u0440\u0435\u0432\u0435 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u0432 SWAPY \u043d\u0443\u0436\u043d\u044b\u0439 \u044d\u043b\u0435\u043c\u0435\u043d\u0442 \u043c\u0435\u043d\u044e \u0438 \u043a\u043b\u0438\u043a\u0430\u0435\u043c \u043d\u0430 \u043d\u0435\u0433\u043e.<br \/>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/7df\/ce7\/315\/7dfce73159db4151867d00a73ece02e1.png\" alt=\"click_menu\"\/><\/li>\n<li>\u0427\u0442\u043e\u0431\u044b \u043e\u0431\u043d\u043e\u0432\u0438\u0442\u044c \u0434\u0435\u0440\u0435\u0432\u043e \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u0432 \u0434\u043b\u044f \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0432\u043d\u043e\u0432\u044c \u043e\u0442\u043a\u0440\u044b\u0442\u043e\u0433\u043e \u043e\u043a\u043d\u0430, \u043d\u0443\u0436\u043d\u043e \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0432\u044b\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u043d\u0430 <code>root<\/code> \u044d\u043b\u0435\u043c\u0435\u043d\u0442 \u0432 \u0434\u0435\u0440\u0435\u0432\u0435. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u0432\u0441\u0435 \u0434\u043e\u0447\u0435\u0440\u043d\u0438\u0435 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u044b \u043e\u0431\u043d\u043e\u0432\u044f\u0442\u0441\u044f.<\/li>\n<li>\u041d\u0430\u0445\u043e\u0434\u0438\u043c About \u0434\u0438\u0430\u043b\u043e\u0433, \u043e\u043d \u0443 \u043c\u0435\u043d\u044f \u043d\u0430\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f <code>Window#657198<\/code>, \u044d\u0442\u043e SWAPY \u0441\u0430\u043c\u0430 \u0441\u0444\u043e\u0440\u043c\u0438\u0440\u043e\u0432\u0430\u043b\u0430 \u043d\u0430\u0437\u0432\u0430\u043d\u0438\u0435 \u0438\u0437 handle \u043e\u043a\u043d\u0430, \u0442\u0430\u043a \u043a\u0430\u043a \u043e\u0431\u044b\u0447\u043d\u044b\u043c \u0441\u043f\u043e\u0441\u043e\u0431\u043e\u043c(<code>window.Texts()<\/code>) \u0438\u043c\u044f \u043d\u0435 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u043b\u043e\u0441\u044c.<\/li>\n<li>\u0412 \u0438\u0435\u0440\u0430\u0440\u0445\u0438\u0438 About \u0434\u0438\u0430\u043b\u043e\u0433\u0430 \u043d\u0430\u0445\u043e\u0434\u0438\u043c \u0442\u0435\u043a\u0441\u0442 \u043b\u0438\u0446\u0435\u043d\u0437\u0438\u0438 \u0438 \u043a\u043b\u0438\u043a\u0430\u0435\u043c \u043d\u0430 \u043d\u0435\u0433\u043e.<br \/>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/d87\/447\/ac0\/d87447ac094945aa8aea7a3aa2648457.png\" alt=\"About\"\/><br \/>  \u0414\u043e\u0431\u0430\u0432\u0438\u043b\u0438\u0441\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u0441\u0442\u0440\u043e\u0447\u043a\u0438:<br \/> \n<pre><code class=\"python\">window = app.Dialog edit = window.Edit2 edit.Click()  # \u0418\u0437\u043c\u0435\u043d\u0438\u043c \u043d\u0430 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0442\u0435\u043a\u0441\u0442\u0430 <\/code><\/pre>\n<p>  \u0422.\u0435. SWAPY \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b\u0430 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0443\u044e \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u0443\u044e <code>app<\/code>.<br \/>  \u0421 \u0430\u0432\u0442\u043e\u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0435\u0439 \u043a\u043e\u0434\u0430 \u0434\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u0442\u0435\u0441\u0442\u0430 \u043c\u044b \u0437\u0430\u043a\u043e\u043d\u0447\u0438\u043b\u0438. \u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 \u0447\u0442\u043e Notepad++ \u0431\u0443\u0434\u0435\u0442 \u0437\u0430\u043f\u0443\u0449\u0435\u043d \u0438 \u0437\u0430\u043a\u0440\u044b\u0442 \u043f\u043e\u0441\u043b\u0435 \u0442\u0435\u0441\u0442\u0430, \u0437\u0430 \u044d\u0442\u043e \u043e\u0442\u0432\u0435\u0447\u0430\u0435\u0442 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u044f\u044f \u0441\u0442\u0440\u043e\u043a\u0430 <code>app.Kill_()<\/code>.<\/li>\n<\/ol>\n<p>  \u0424\u0438\u043d\u0430\u043b\u044c\u043d\u044b\u0439 \u043a\u043e\u0434 \u0442\u0435\u0441\u0442\u0430 \u043c\u043e\u0436\u0435\u0442 \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:  <\/p>\n<pre><code class=\"python\">from pywinauto.application import Application expected_text = \u201c...\u201d  app = Application().Start(cmd_line=u'&quot;C:\\\\Program Files (x86)\\\\Notepad++\\\\notepad++.exe&quot; ') notepad = app[u'Notepad++'] notepad.Wait('ready') menu_item = notepad.MenuItem(u'&?-&gt;\\u041e \\u043f\\u0440\\u043e\\u0433\\u0440\\u0430\\u043c\\u043c\\u0435...\\tF1') menu_item.Click() window = app.Dialog edit = window.Edit2 actual_text = edit.Texts()  app.Kill_()  assertEqual(expected_text, actual_text) <\/code><\/pre>\n<p>  \u041a\u0430\u043a \u0432\u0438\u0434\u0438\u0442\u0435, \u043c\u0438\u043d\u0438\u043c\u0443\u043c \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0433\u043e \u043a\u043e\u0434\u0430.  <\/div>\n<\/div>\n<h4>\u041f\u043e\u0440\u044f\u0434\u043e\u043a \u0432\u043a\u043b\u0430\u0434\u043e\u043a<\/h4>\n<p>  \u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u043c \u043f\u0435\u0440\u0435\u043c\u0435\u0449\u0435\u043d\u0438\u0435 \u0432\u043a\u043b\u0430\u0434\u043e\u043a. \u041d\u0430\u0440\u043e\u0447\u043d\u043e \u0434\u043e\u043f\u0443\u0441\u0442\u0438\u043c \u043e\u0448\u0438\u0431\u043a\u0443 \u043f\u0440\u0438 \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0438 \u043a\u043e\u0434\u0430 \u0438 \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043a\u0430\u043a SWAPY \u043f\u043e\u0437\u0432\u043e\u043b\u0438\u0442 \u0435\u0451 \u0443\u0431\u0440\u0430\u0442\u044c.  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">\u041f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f \u043f\u043e\u0440\u044f\u0434\u043a\u0430 \u0432\u043a\u043b\u0430\u0434\u043e\u043a<\/b><\/p>\n<div class=\"spoiler_text\">\n<ol>\n<li>\u0417\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c \u0432\u0440\u0443\u0447\u043d\u0443\u044e Notepad++.<\/li>\n<li>\u041e\u0442\u043a\u0440\u043e\u0435\u043c \u0434\u0432\u0435 \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u0432\u043a\u043b\u0430\u0434\u043a\u0438. \u041d\u0430\u0445\u043e\u0434\u0438\u043c \u0432 \u0434\u0435\u0440\u0435\u0432\u0435 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u0432 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b\u0439 <code>ToolBar<\/code> \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u043c \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 <code>Click<\/code> \u043d\u0430 \u043a\u043d\u043e\u043f\u043a\u0435 \u0441 \u0438\u043d\u0434\u0435\u043a\u0441\u043e\u043c 0. \u0412\u0441\u043b\u0435\u0434\u0441\u0442\u0432\u0438\u0435 \u0447\u0435\u0433\u043e \u043f\u043e\u044f\u0432\u0438\u0442\u0441\u044f \u043a\u043e\u0434 \u0438 \u043e\u0442\u043a\u0440\u043e\u0435\u0442\u0441\u044f \u043e\u0434\u043d\u0430 \u043d\u043e\u0432\u0430\u044f \u0432\u043a\u043b\u0430\u0434\u043a\u0430.<br \/>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/0ce\/b0b\/8de\/0ceb0b8ded80448ab864def21c626698.png\" alt=\"add_tab\"\/><br \/>  \u041d\u0430\u043c \u043d\u0443\u0436\u043d\u0430 \u0435\u0449\u0435 \u043e\u0434\u043d\u0430 \u0432\u043a\u043b\u0430\u0434\u043a\u0430, \u043f\u043e\u0432\u0442\u043e\u0440\u0438\u043c \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 \u0435\u0449\u0435 \u0440\u0430\u0437. \u041f\u043e\u0441\u043a\u043e\u043b\u044c\u043a\u0443 \u0442\u0435\u043a\u0441\u0442 \u043a\u043d\u043e\u043f\u043e\u043a \u043d\u0435\u0434\u043e\u0441\u0442\u0443\u043f\u0435\u043d, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0430\u0434\u0440\u0435\u0441\u0430\u0446\u0438\u044f \u043f\u043e \u0438\u043d\u0434\u0435\u043a\u0441\u0443. \u041c\u044b \u043d\u0435 \u0437\u0430\u043c\u0435\u0442\u0438\u043b\u0438 \u0438 \u043d\u0435\u0447\u0430\u044f\u043d\u043d\u043e \u043a\u043b\u0438\u043a\u043d\u0443\u043b\u0438 \u043d\u0430 \u043a\u043d\u043e\u043f\u043a\u0443 \u0441 \u0438\u043d\u0434\u0435\u043a\u0441\u043e\u043c 1.<br \/>  \u0414\u043e\u0431\u0430\u0432\u0438\u043b\u0441\u044f \u043a\u043e\u0434:<br \/>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/b72\/82b\/87a\/b7282b87a36f44b198fb46c32a2c0476.png\" alt=\"fix_code\" align=\"right\"\/><br \/> \n<pre><code class=\"python\">toolbar_button2 = toolbarwindow.Button(1) toolbar_button2.Click() <\/code><\/pre>\n<p>  \u041d\u0443\u0436\u043d\u043e \u0438\u0441\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c\u0441\u044f. \u0427\u0442\u043e\u0431\u044b \u043d\u0435 \u043f\u043e\u0432\u0442\u043e\u0440\u044f\u0442\u044c \u0432\u0441\u0435 \u0441\u043d\u0430\u0447\u0430\u043b\u0430, SWAPY \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u043e\u0442\u043c\u0435\u043d\u0438\u0442\u044c \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u044e\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u0443 (\u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u043e\u0442\u043c\u0435\u043d\u0438\u0442\u044c \u0445\u043e\u0442\u044c \u0432\u0435\u0441\u044c \u043a\u043e\u0434).<br \/>  <code>Clear last command<\/code> \u043e\u0442\u043c\u0435\u043d\u0438\u0442 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u044e\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u0443 (\u0432\u044b\u0434\u0435\u043b\u0435\u043d\u043d\u044b\u0439 \u0444\u0440\u0430\u0433\u043c\u0435\u043d\u0442) \u2014 \u043a\u0430\u043a \u0440\u0430\u0437 \u0442\u043e, \u0447\u0442\u043e \u043d\u0430\u043c \u0438 \u043d\u0443\u0436\u043d\u043e. \u0427\u0442\u043e\u0431\u044b \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u043e\u0447\u0438\u0441\u0442\u0438\u0442\u044c \u043a\u043e\u0434, \u0435\u0441\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434\u0430 <code>Clear the code<\/code>. \u041f\u043e\u043b\u043d\u0430\u044f \u043e\u0447\u0438\u0441\u0442\u043a\u0430 \u0441\u043f\u0440\u044f\u0442\u0430\u043d\u0430 \u0437\u0430 \u0434\u0438\u0430\u043b\u043e\u0433\u043e\u043c \u0441 \u043f\u043e\u0434\u0442\u0432\u0435\u0440\u0436\u0434\u0435\u043d\u0438\u0435\u043c, \u0432\u043e \u0438\u0437\u0431\u0435\u0436\u0430\u043d\u0438\u0435 \u043d\u0435\u0441\u0447\u0430\u0441\u0442\u043d\u044b\u0445 \u0441\u043b\u0443\u0447\u0430\u0435\u0432 \u043d\u0430 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0441\u0442\u0432\u0435.<br \/>  \u0422\u0435\u043f\u0435\u0440\u044c \u043c\u044b \u0441\u0434\u0435\u043b\u0430\u0435\u043c \u0432\u0441\u0435 \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u043e \u0438 \u043a\u043b\u0438\u043a\u043d\u0435\u043c \u043f\u043e \u043a\u043d\u043e\u043f\u043a\u0435 \u0441 \u0438\u043d\u0434\u0435\u043a\u0441\u043e\u043c 0.<br \/>  \u0414\u043e\u0431\u0430\u0432\u0438\u0442\u0441\u044f \u043a\u043e\u0434:  <\/p>\n<pre><code class=\"python\">toolbar_button.Click() <\/code><\/pre>\n<p>  SWAPY \u043f\u043e\u043c\u043d\u0438\u0442 \u0447\u0442\u043e \u0443\u0436\u0435 \u0435\u0441\u0442\u044c <code>toolbar_button = toolbarwindow.Button(0)<\/code> \u0438 \u0434\u043b\u044f \u043f\u043e\u0432\u0442\u043e\u0440\u043d\u043e\u0433\u043e \u043a\u043b\u0438\u043a\u0430 \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0435\u0433\u043e \u0443\u0436\u0435 \u043d\u0435 \u043d\u0443\u0436\u043d\u043e.  <\/li>\n<li>\u0414\u043b\u044f drug-n-drop \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u0441\u044f \u043c\u0435\u0442\u043e\u0434\u043e\u043c <code>toolbarwindow.DragMouseInput<\/code>. \u0414\u0435\u0442\u0430\u043b\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0434\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0432 <a href=\"http:\/\/pywinauto.github.io\/docs\/code\/pywinauto.controls.HwndWrapper.html?highlight=dragmouseinput#pywinauto.controls.HwndWrapper.HwndWrapper.DragMouseInput\">\u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438<\/a>.<br \/>  \u041a\u043e\u043e\u0440\u0434\u0438\u043d\u0430\u0442\u044b \u0432\u043a\u043b\u0430\u0434\u043e\u043a \u043c\u043e\u0436\u043d\u043e \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e <code>systabcontrol.GetTabRect(0).mid_point()<\/code><\/li>\n<\/ol>\n<p>  \u0422\u0435\u0441\u0442 \u043c\u043e\u0436\u0435\u0442 \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u0442\u044c \u0442\u0430\u043a:  <\/p>\n<pre><code class=\"python\"># automatically generated by SWAPY from pywinauto.application import Application  app = Application().Start(cmd_line=u'&quot;C:\\\\Program Files (x86)\\\\'                                    u'Notepad++\\\\notepad++.exe&quot; ') notepad = app[u'Notepad++'] notepad.Wait('ready') systabcontrol = notepad.Tab assertEqual([u'Tab', u'new 1'], systabcontrol.Texts())  toolbarwindow = notepad[u'3'] toolbar_button = toolbarwindow.Button(0) toolbar_button.Click() toolbar_button.Click()  assertEqual([u'Tab', u'new 1', u'new 2', u'new 3'], systabcontrol.Texts())  systabcontrol.DragMouseInput(     press_coords=systabcontrol.GetTabRect(0).mid_point(),     release_coords=systabcontrol.GetTabRect(2).mid_point())  assertEqual([u'Tab', u'new 2', u'new 3', u'new 1'], systabcontrol.Texts())  app.Kill_() <\/code><\/pre>\n<p>  \u0422\u0443\u0442 \u043f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u043f\u043e\u0447\u0438\u0442\u0430\u0442\u044c \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u044e \u0438 \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u043f\u043e\u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u043c \u043a\u043e\u0434\u043e\u043c.  <\/div>\n<\/div>\n<h4>\u0412\u0441\u0442\u0430\u0432\u043a\u0430 \u0438 \u0441\u043e\u0445\u0440\u0430\u043d\u0435\u043d\u0438\u0435 \u0442\u0435\u043a\u0441\u0442\u0430<\/h4>\n<p>  \u0422\u0435\u0441\u0442 \u0442\u0440\u0435\u0431\u0443\u0435\u0442 \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0438 \u0432\u0441\u0442\u0430\u0432\u043a\u0443 \u0442\u0435\u043a\u0441\u0442\u0430 \u0441 \u043f\u043e\u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u0441\u043e\u0445\u0440\u0430\u043d\u0435\u043d\u0438\u0435\u043c. \u0423\u0441\u043b\u043e\u0436\u043d\u0438\u043c \u0437\u0430\u0434\u0430\u0447\u0443 \u2014 Notepad++ \u0443\u0436\u0435 \u0437\u0430\u043f\u0443\u0449\u0435\u043d \u0438 \u0441\u0432\u0435\u0440\u043d\u0443\u0442 (Minimize), \u0430 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0439 notepad (\u0438\u0437 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0431\u0443\u0434\u0435\u0442 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0441\u044f \u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435) \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u0440\u0435\u0434\u0441\u0442\u043e\u0438\u0442 \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c.  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">\u0420\u0430\u0431\u043e\u0442\u0430 \u0441 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u043c\u0438 \u043e\u043a\u043d\u0430\u043c\u0438<\/b><\/p>\n<div class=\"spoiler_text\">\n<ol>\n<li>\u041f\u043e\u0434\u0433\u043e\u0442\u043e\u0432\u0438\u043c \u0442\u0435\u0441\u0442\u043e\u0432\u044b\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f. \u0417\u0430\u043f\u0443\u0441\u0442\u0438\u043c \u0438 \u0441\u0432\u0435\u0440\u043d\u0435\u043c Notepad++, \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u043c \u043e\u0431\u044b\u0447\u043d\u044b\u0439 notepad \u0441 \u0442\u0435\u0441\u0442\u043e\u0432\u044b\u043c \u0444\u0430\u0439\u043b\u043e\u043c = \u00abnotepad check.txt\u00bb.<\/li>\n<li>\u0412 \u0434\u0435\u0440\u0435\u0432\u0435 \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u0432 \u043d\u0430\u0439\u0434\u0435\u043c \u0431\u043b\u043e\u043a\u043d\u043e\u0442 \u0438 \u043a\u043b\u0438\u043a\u043d\u0435\u043c \u043f\u043e \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u043c\u0443 \u0440\u0435\u0434\u0430\u043a\u0442\u043e\u0440\u0430.<br \/>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/a84\/965\/d16\/a84965d16a2d4cd99fb8201efc40d51a.png\" alt=\"notepad\"\/><br \/>  \u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435, \u0447\u0442\u043e notepad \u0431\u0443\u0434\u0435\u0442 \u0437\u0430\u043f\u0443\u0449\u0435\u043d \u0441 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b\u044c\u043d\u044b\u043c\u0438 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u0430\u043c\u0438.<\/li>\n<li>\u0422\u0435\u043f\u0435\u0440\u044c \u043e\u0442\u044b\u0449\u0435\u043c Notepad++ \u0438 \u0435\u0433\u043e \u0442\u0435\u043a\u0441\u0442\u043e\u0432\u043e\u0435 \u043f\u043e\u043b\u0435. \u041d\u0443\u0436\u043d\u043e \u043d\u0435 \u0437\u0430\u0431\u044b\u0442\u044c \u0435\u0433\u043e \u0441\u043d\u0430\u0447\u0430\u043b\u0430 \u0440\u0430\u0437\u0432\u0435\u0440\u043d\u0443\u0442\u044c (Restore).<br \/>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/987\/82d\/a5c\/98782da5c5884168bf636da9d47ce704.png\" alt=\"restore\"\/>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/1cd\/654\/b50\/1cd654b5058c4ccd9fc2ae7cf2b48ad8.png\" alt=\"editor\"\/><br \/>  \u0412\u0441\u0435 \u0438\u0434\u0435\u0442 \u043f\u043e \u043f\u043b\u0430\u043d\u0443, \u043d\u043e \u0442\u0443\u0442 \u0432\u043d\u0435\u0437\u0430\u043f\u043d\u043e \u043c\u044b \u0432\u0441\u043f\u043e\u043c\u043d\u0438\u043b\u0438, \u0447\u0442\u043e \u043f\u043e \u0443\u0441\u043b\u043e\u0432\u0438\u044e \u0437\u0430\u0434\u0430\u0447\u0438 Notepad++ \u0443\u0436\u0435 \u0437\u0430\u043f\u0443\u0449\u0435\u043d, \u0430 \u043d\u0430\u0448 \u043a\u043e\u0434 \u043f\u043e\u043f\u044b\u0442\u0430\u0435\u0442\u0441\u044f \u0435\u0433\u043e \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c. <br \/>  SWAPY \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u0435\u0442 \u0441\u0432\u044f\u0437\u043a\u0443 <code>app = Application().Start ... app.Kill_()<\/code>. \u041d\u043e \u0432 \u043d\u0430\u0448\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043d\u0430\u043c \u043d\u0435 \u043d\u0443\u0436\u043d\u043e \u0435\u0449\u0435 \u0440\u0430\u0437 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c Notepad++.<br \/>  \u041d\u043e\u0432\u044b\u0439 \u0433\u0435\u043d\u0435\u0440\u0430\u0442\u043e\u0440 \u043a\u043e\u0434\u0430 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0438\u0437\u043c\u0435\u043d\u044f\u0442\u044c \u00ab\u043f\u043e\u0434\u0445\u043e\u0434\u00bb \u0434\u043b\u044f \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0438 \u043a\u043e\u0434\u0430, \u043f\u0440\u0438\u0447\u0435\u043c \u044d\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u0434\u0435\u043b\u0430\u0442\u044c \u0434\u0430\u0436\u0435 \u043f\u043e\u0441\u0442\u0444\u0430\u043a\u0442\u0443\u043c.<\/li>\n<li>\u0414\u043b\u044f \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f <code>Application().Start<\/code> \u043d\u0430 <code>Application().Connect<\/code> \u043d\u0443\u0436\u043d\u043e \u0432\u044b\u0437\u0432\u0430\u0442\u044c \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u043d\u043e\u0435 \u043c\u0435\u043d\u044e \u0434\u043b\u044f \u043e\u043a\u043d\u0430 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f Notepad++ \u0438 \u0432\u044b\u0431\u0440\u0430\u0442\u044c <code>Application().Connect<\/code>.<br \/>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/6e9\/672\/6a5\/6e96726a5dc4479480d1f9343bc940f0.png\" alt=\"Connect\"\/><\/li>\n<li>\u041a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0438 \u0432\u0441\u0442\u0430\u0432\u043a\u0443 \u0442\u0435\u043a\u0441\u0442\u0430 \u043c\u044b \u043e\u0444\u043e\u0440\u043c\u0438\u043c \u043f\u043e\u0437\u0436\u0435, \u0430 \u0441\u0435\u0439\u0447\u0430\u0441 \u043f\u0440\u0435\u0434\u043f\u043e\u043b\u043e\u0436\u0438\u043c \u0447\u0442\u043e \u0442\u0435\u043a\u0441\u0442 \u0435\u0441\u0442\u044c \u0438 \u0435\u0433\u043e \u043d\u0443\u0436\u043d\u043e \u0441\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u044c.<br \/>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/f61\/c70\/2ef\/f61c702effff42bbb714c477d87c2726.png\" alt=\"save_as\"\/><\/li>\n<li>\u041e\u0442\u043a\u0440\u044b\u043b\u043e\u0441\u044c \u043e\u043a\u043d\u043e \u00abSave as\u00bb, \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043e\u0431\u043d\u043e\u0432\u0438\u0442\u044c \u0434\u0435\u0440\u0435\u0432\u043e \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u0432 \u0447\u0442\u043e \u0431\u044b \u0435\u0433\u043e \u0443\u0432\u0438\u0434\u0435\u0442\u044c. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043d\u0443\u0436\u043d\u043e \u0432\u044b\u0434\u0435\u043b\u0438\u0442\u044c root \u044d\u043b\u0435\u043c\u0435\u043d\u0442 \u0434\u0435\u0440\u0435\u0432\u0430. \u041f\u043e\u0441\u043b\u0435 \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f \u0434\u0435\u0440\u0435\u0432\u0430, \u043a\u043b\u0438\u043a\u043d\u0435\u043c \u043d\u0430 \u043f\u043e\u043b\u0435 \u0441 \u0438\u043c\u0435\u043d\u0435\u043c \u0441\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u043c\u043e\u0433\u043e \u0444\u0430\u0439\u043b\u0430 (\u0447\u0442\u043e\u0431\u044b \u043f\u043e\u0442\u043e\u043c \u043f\u043e\u043c\u0435\u043d\u044f\u0442\u044c) \u0438 \u043d\u0430 \u043a\u043d\u043e\u043f\u043a\u0443 \u0434\u043b\u044f \u0441\u043e\u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f.<br \/>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/7c8\/2ae\/50c\/7c82ae50ce494bb6a8637d94f3d5ffaa.png\" alt=\"accept\"\/><\/li>\n<\/ol>\n<p>  \u0412\u0441\u0435 \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u0435\u0441\u0442\u044c, \u0442\u0435\u043f\u0435\u0440\u044c \u043e\u0441\u0442\u0430\u043b\u043e\u0441\u044c \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043e\u0442\u043f\u0440\u0430\u0432\u043a\u0443 \u043a\u043e\u043c\u0430\u043d\u0434 CTRL+C, CTRL+V \u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0438 \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u0441\u044f \u043d\u0430\u0441\u0442\u043e\u044f\u0449\u0438\u0439 \u0442\u0435\u0441\u0442.<br \/>  \u0414\u043b\u044f \u043e\u0442\u043f\u0440\u0430\u0432\u043a\u0438 \u043a\u043e\u043c\u0430\u043d\u0434, \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u0441\u044f \u0432\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u044b\u043c \u043c\u0435\u0442\u043e\u0434\u043e\u043c <a href=\"http:\/\/pywinauto.github.io\/docs\/code\/pywinauto.controls.HwndWrapper.html?highlight=type#pywinauto.controls.HwndWrapper.HwndWrapper.TypeKeys\">TypeKeys<\/a>.<br \/>  \u041f\u043e\u043b\u043d\u044b\u0439 \u0442\u0435\u043a\u0441\u0442 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d \u043d\u0438\u0436\u0435:  <\/p>\n<pre><code class=\"python\"># automatically generated by SWAPY from pywinauto.application import Application import time import os  SAVE_PATH = r&quot;Notepad_default_path&quot;  app = Application().Start(cmd_line=u'&quot;C:\\\\Windows\\\\system32\\\\notepad.exe&quot; check.txt') notepad = app.Notepad notepad.Wait('ready') edit = notepad.Edit edit.TypeKeys(&quot;^a^c&quot;)  # Copy all the text  app2 = Application().Connect(title=u'new 1 - Notepad++', class_name='Notepad++') notepad2 = app2[u'Notepad++'] notepad2.Restore() scintilla = notepad2[u'1'] scintilla.TypeKeys(&quot;^a^v&quot;)  # Paste the text  #Save a file menu_item = notepad2.MenuItem(u'&\\u0424\\u0430\\u0439\\u043b-&gt;\\u0421\\u043e\\u0445\\u0440\\u0430\\u043d\\u0438\\u0442\\u044c \\u043a\\u0430\\u043a...\\tCtrl+Alt+S') menu_item.Click() window = app2.Dialog edit2 = window.Edit filename = &quot;checked_at_%s&quot; % time.time()  # Compose a filename edit2.TypeKeys(filename) button = window.Button button.Click()  with open(os.path.join(SAVE_PATH, filename)) as f:     assertEqual(\u201cexpected_text\u201d, f.read())  app.Kill_() <\/code><\/pre>\n<p>  <\/div>\n<\/div>\n<p>  <\/p>\n<h3>\u0410 \u043c\u043e\u0436\u043d\u043e \u0435\u0449\u0435 \u043b\u0443\u0447\u0448\u0435?<\/h3>\n<p>  \u0411\u0435\u0437\u0443\u0441\u043b\u043e\u0432\u043d\u043e \u2014 \u0414\u0430!<br \/>  \u0414\u0430\u0436\u0435 \u0432 \u043e\u043f\u0438\u0441\u0430\u043d\u043d\u044b\u0445 \u043f\u0440\u0438\u043c\u0435\u0440\u0430\u0445 \u043c\u044b \u0432\u044b\u043d\u0443\u0436\u0434\u0435\u043d\u044b \u0431\u044b\u043b\u0438 \u0434\u0435\u043b\u0430\u0442\u044c <code>Click()<\/code> \u0430 \u043f\u043e\u0442\u043e\u043c \u0443\u0436\u0435 \u0432\u0440\u0443\u0447\u043d\u0443\u044e \u043c\u0435\u043d\u044f\u0442\u044c \u043d\u0430 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0442\u0435\u043a\u0441\u0442\u0430 \u2014 <code>Texts()<\/code>. \u0418\u043b\u0438 \u0436\u0435 \u0432\u0440\u0443\u0447\u043d\u0443\u044e \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u043b\u0438 <code>TypeKeys<\/code>. \u0412 \u0431\u0443\u0434\u0443\u0449\u0438\u0445 \u0440\u0435\u043b\u0438\u0437\u0430\u0445 \u0435\u0449\u0435 \u043f\u0440\u0435\u0434\u0441\u0442\u043e\u0438\u0442 \u0443\u043f\u0440\u043e\u0441\u0442\u0438\u0442\u044c \u0442\u0430\u043a\u0438\u0435 \u043f\u043e\u043f\u0443\u043b\u044f\u0440\u043d\u044b\u0435 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f, \u0434\u043e\u0431\u0430\u0432\u0438\u0432 \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u043f\u0443\u043d\u043a\u0442\u044b \u0432 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u043d\u043e\u0435 \u043c\u0435\u043d\u044e.<\/p>\n<p>  \u041f\u043e\u043a\u0430 \u043d\u0435\u043b\u044c\u0437\u044f \u0443\u043f\u0440\u0430\u0432\u043b\u044f\u0442\u044c \u0444\u043e\u0440\u043c\u0430\u0442\u043e\u043c \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u043a \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430\u043c. Pywinauto \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430\u043c \u0447\u0435\u0440\u0435\u0437 \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u044b \u2014 <code>window.Edit<\/code>, \u0430 \u0435\u0441\u043b\u0438 \u044d\u0442\u043e \u043d\u0435\u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e (\u043d\u0435\u0434\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u043e\u0435 \u0438\u043c\u044f \u0434\u043b\u044f \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439 Python), \u0442\u043e \u0447\u0435\u0440\u0435\u0437 <code>__getitem__<\/code> \u2014 <code>window[u'0']<\/code>.<br \/>  SWAPY \u043d\u0430\u0445\u043e\u0434\u0438\u0442 \u0441\u0430\u043c\u043e\u0435 \u043a\u043e\u0440\u043e\u0442\u043a\u043e\u0435 \u0438\u043c\u044f \u0434\u043b\u044f \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u0438 \u043f\u0440\u043e\u0431\u0443\u0435\u0442 \u0435\u0433\u043e \u043f\u0440\u0438\u043c\u0435\u043d\u0438\u0442\u044c \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u0430. \u0415\u0441\u043b\u0438 \u043d\u0435 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442\u0441\u044f, \u0442\u043e \u0447\u0435\u0440\u0435\u0437 <code>__getitem__<\/code>. \u0418\u0434\u0435\u044f \u043f\u043e\u043a\u0430 \u0441\u0430\u043c\u0430\u044f \u043f\u0440\u043e\u0441\u0442\u0430\u044f \u2014 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u043a\u043e\u0440\u043e\u0442\u043a\u0438\u0439 \u043a\u043e\u0434.<\/p>\n<p>  \u041d\u043e, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432 \u0442\u0435\u0441\u0442\u0435 \u00ab\u041f\u043e\u0440\u044f\u0434\u043e\u043a \u0432\u043a\u043b\u0430\u0434\u043e\u043a\u00bb \u0435\u0441\u0442\u044c \u0442\u0430\u043a\u0430\u044f \u0441\u0442\u0440\u043e\u0447\u043a\u0430 <code>toolbarwindow = notepad[u'3']<\/code>. \u0412\u0441\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442, \u0432\u0441\u0435 \u041e\u041a. \u041d\u043e, \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u044c\u0442\u0435, \u0432\u044b \u043e\u0442\u043a\u0440\u044b\u043b\u0438 \u044d\u0442\u043e\u0442 \u0442\u0435\u0441\u0442 \u0447\u0435\u0440\u0435\u0437 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0432\u0440\u0435\u043c\u044f, \u0430 \u0442\u0430\u043c \u0442\u0430\u043a\u043e\u0439 magic number. \u0412\u043c\u0435\u0441\u0442\u043e \u0442\u0440\u043e\u0439\u043a\u0438 \u043c\u043e\u0433\u043b\u043e \u0431\u044b \u0431\u044b\u0442\u044c <code>Toolbar<\/code> \u2014 \u0441\u0430\u043c\u043e\u0435 \u043f\u043e\u043d\u044f\u0442\u043d\u043e\u0435, \u0430 \u043d\u0435 \u0441\u0430\u043c\u043e\u0435 \u043a\u043e\u0440\u043e\u0442\u043a\u043e\u0435 \u0438\u043c\u044f. \u0412 \u043f\u043b\u0430\u043d\u0430\u0445 \u2014 \u0434\u0430\u0442\u044c \u044e\u0437\u0435\u0440\u0443 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0432\u044b\u0431\u0438\u0440\u0430\u0442\u044c \u0438\u043c\u044f (\u201c\u0418\u043c\u044f! \u0418\u043c\u044f, \u0441\u0435\u0441\u0442\u0440\u0430!\u201d).<\/p>\n<p>  \u0422\u0430\u043a\u0436\u0435 \u043f\u043e\u043a\u0430 \u043d\u0443\u0436\u043d\u043e \u043e\u0431\u043d\u043e\u0432\u043b\u044f\u0442\u044c \u0434\u0435\u0440\u0435\u0432\u043e \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u0432 \u0432\u0440\u0443\u0447\u043d\u0443\u044e. \u0410\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0439 refresh \u044f\u0432\u043d\u043e \u0434\u043e\u0431\u0430\u0432\u0438\u0442 \u0443\u0434\u043e\u0431\u0441\u0442\u0432\u0430.<\/p>\n<h3>\u041f\u043e\u043b\u0435\u0437\u043d\u044b\u0435 \u0441\u0441\u044b\u043b\u043a\u0438<\/h3>\n<p>  <\/p>\n<ul>\n<li><a href=\"http:\/\/pywinauto.github.io\/\">pywinauto<\/a><\/li>\n<li><a href=\"https:\/\/github.com\/pywinauto\/SWAPY\">SWAPY<\/a><\/li>\n<li><a href=\"http:\/\/habrahabr.ru\/company\/intel\/blog\/266459\/\">\u0421\u0442\u0430\u0440\u044b\u0439 \u043d\u043e\u0432\u044b\u0439 pywinauto<\/a><\/li>\n<li><a href=\"http:\/\/habrahabr.ru\/post\/138963\/\">\u0414\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u043e\u0435 (\u043d\u0435\u043b\u0438\u043d\u0435\u0439\u043d\u043e\u0435) \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 GUI<\/a><\/li>\n<li><a href=\"http:\/\/habrahabr.ru\/post\/37153\/\">Win32 GUI Automation \u043f\u0440\u0438 \u043f\u043e\u043c\u043e\u0449\u0438 pywinauto<\/a><\/li>\n<\/ul>\n<p>  <\/p>\n<h3>P.S.<\/h3>\n<p>  \u0425\u043e\u0442\u0435\u043b \u0431\u044b \u043f\u043e\u0431\u043b\u0430\u0433\u043e\u0434\u0430\u0440\u0438\u0442\u044c \u043a\u0430\u043c\u0440\u0430\u0434\u043e\u0432 <a href=\"https:\/\/github.com\/vasily-v-ryabov\">vasily-v-ryabov<\/a> \u0438 <a href=\"https:\/\/github.com\/airelil\">airelil<\/a> \u0437\u0430 \u0430\u043a\u0442\u0438\u0432\u043d\u043e\u0435 \u0443\u0447\u0430\u0441\u0442\u0438\u0435 \u0432 \u043e\u0431\u0441\u0443\u0436\u0434\u0435\u043d\u0438\u0438 \u0444\u0438\u0447 \u0434\u043b\u044f \u043d\u043e\u0432\u043e\u0433\u043e \u0433\u0435\u043d\u0435\u0440\u0430\u0442\u043e\u0440\u0430 \u043a\u043e\u0434\u0430.               <\/p>\n<div class=\"clear\"><\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"http:\/\/habrahabr.ru\/post\/270247\/\"> http:\/\/habrahabr.ru\/post\/270247\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>       <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/97b\/a96\/d4c\/97ba96d4c55d4e73a6205689cfb98604.png\" alt=\"SWAPY\" align=\"left\"\/><br \/>  SWAPY \u2013 \u0433\u0440\u0430\u0444\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0443\u0442\u0438\u043b\u0438\u0442\u0430 \u0434\u043b\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438 UI \u0434\u043b\u044f pywinauto (Python).<br \/>  \u0412 \u0432\u0435\u0440\u0441\u0438\u0438 <a href=\"https:\/\/github.com\/pywinauto\/SWAPY\/releases\">0.4.7<\/a> \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u043f\u0435\u0440\u0435\u0440\u0430\u0431\u043e\u0442\u0430\u043d \u0433\u0435\u043d\u0435\u0440\u0430\u0442\u043e\u0440 \u043a\u043e\u0434\u0430.<br \/>  \u041e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438, \u0430 \u0442\u0430\u043a\u0436\u0435 \u043f\u0440\u0438\u043c\u0435\u0440\u044b \u043a\u0430\u043a \u0431\u044b\u0441\u0442\u0440\u043e \u0438 \u043f\u0440\u043e\u0441\u0442\u043e \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u0441\u043a\u0440\u0438\u043f\u0442\u044b \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f UI, \u0441\u043c\u043e\u0442\u0440\u0438\u0442\u0435 \u043f\u043e\u0434 \u043a\u0430\u0442\u043e\u043c.  <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-267596","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/267596","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=267596"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/267596\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=267596"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=267596"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=267596"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}