{"id":280337,"date":"2016-11-02T12:00:03","date_gmt":"2016-11-02T09:00:03","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=280337"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=280337","title":{"rendered":"Kivy. \u041e\u0442 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u0434\u043e production \u043e\u0434\u0438\u043d \u0448\u0430\u0433. \u0427\u0430\u0441\u0442\u044c 1"},"content":{"rendered":"<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/33d\/628\/491\/33d6284916964a4a81ff15ac7ac0ed0d.png\" align=\"left\"\/>  <\/p>\n<p>\u0411\u0443\u043a\u0432\u0430\u043b\u044c\u043d\u043e <a href=\"https:\/\/habrahabr.ru\/post\/313160\/\">\u0441\u0442\u0430\u0442\u044c\u044e<\/a> \u0442\u043e\u043c\u0443 \u043d\u0430\u0437\u0430\u0434, \u0431\u043e\u043b\u044c\u0448\u0438\u043d\u0441\u0442\u0432\u043e\u043c \u0433\u043e\u043b\u043e\u0441\u043e\u0432, \u0431\u044b\u043b\u043e \u0440\u0435\u0448\u0435\u043d\u043e \u043d\u0430\u0447\u0430\u0442\u044c \u0441\u0435\u0440\u0438\u044e \u0443\u0440\u043e\u043a\u043e\u0432 \u043f\u043e \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044e \u0430\u043d\u0430\u043b\u043e\u0433\u0430 \u043d\u0430\u0442\u0438\u0432\u043d\u043e\u0433\u043e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f, \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u043d\u043e\u0433\u043e \u0434\u043b\u044f Android \u043d\u0430 Java, \u043d\u043e \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u0430 Kivy + Python. \u0411\u0443\u0434\u0435\u0442 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043d\u043e: \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0438 \u043a\u043e\u043c\u043f\u043e\u043d\u043e\u0432\u043a\u0430 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u043e\u0432 \u0438 \u0432\u0438\u0434\u0436\u0435\u0442\u043e\u0432, \u0443\u0433\u043b\u0443\u0431\u043b\u0435\u043d\u043d\u043e\u0435 \u0438\u0441\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d\u0438\u0435 \u0442\u0435\u0445\u043d\u0438\u043a\u0438 \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0438 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u0433\u043e \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430 \u0432 Kv-Language, \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430\u043c\u0438 \u044d\u043a\u0440\u0430\u043d\u043e\u0432, \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430, \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u044e\u0449\u0430\u044f \u0434\u043e\u0441\u0442\u0443\u043f \u043a Android Material Design, \u0438 \u043c\u043d\u043e\u0433\u043e\u0435 \u0434\u0440\u0443\u0433\u043e\u0435\u2026<br \/>  \u0417\u0430\u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043e\u0432\u0430\u0432\u0448\u0438\u0445\u0441\u044f, \u043f\u0440\u043e\u0448\u0443 \u043f\u043e\u0434 \u043a\u0430\u0442!<\/p>\n<p><a name=\"habracut\"><\/a>  <\/p>\n<p>\u0418\u0442\u0430\u043a, \u043f\u043e\u0441\u043b\u0435 \u0431\u0435\u0437\u0443\u0441\u043f\u0435\u0448\u043d\u044b\u0445 \u043f\u043e\u0438\u0441\u043a\u043e\u0432 <s>\u043f\u043e\u0434\u043e\u043f\u044b\u0442\u043d\u043e\u0433\u043e \u043a\u0440\u043e\u043b\u0438\u043a\u0430<\/s> \u043f\u043e\u0434\u0445\u043e\u0434\u044f\u0449\u0435\u0433\u043e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f, \u0432 \u043c\u0435\u0440\u0443 \u0441\u043b\u043e\u0436\u043d\u043e\u0433\u043e (\u0447\u0442\u043e\u0431\u044b \u043d\u0435 \u0440\u0430\u0441\u0442\u044f\u0433\u0438\u0432\u0430\u0442\u044c \u043d\u0430\u0448 \u0442\u0443\u0442\u043e\u0440\u0438\u0430\u043b \u0434\u043e \u043c\u0430\u0441\u0448\u0442\u0430\u0431\u043e\u0432 \u0421\u0430\u043d\u0442\u044b \u0411\u0430\u0440\u0431\u0430\u0440\u044b) \u0438 \u043d\u0435 \u0441\u043b\u0438\u0448\u043a\u043e\u043c \u043f\u0440\u043e\u0441\u0442\u043e\u0433\u043e (\u0434\u0430\u0431\u044b \u043e\u0441\u0432\u0435\u0442\u0438\u0442\u044c \u043a\u0430\u043a \u043c\u043e\u0436\u043d\u043e \u0431\u043e\u043b\u044c\u0448\u0435 \u0442\u0435\u0445\u043d\u0438\u0447\u0435\u0441\u043a\u0438\u0445 \u0430\u0441\u043f\u0435\u043a\u0442\u043e\u0432 Kivy \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0438), \u043f\u043e \u0441\u043e\u0432\u0435\u0442\u0443 \u0445\u0430\u0431\u0440\u043e\u0432\u0447\u0430\u043d\u0438\u043d\u0430 <a href=\"https:\/\/habrahabr.ru\/users\/t0h6by\/\">Roman Hvashchevsky<\/a>, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0441\u043e\u0433\u043b\u0430\u0441\u0438\u043b\u0441\u044f \u0432\u044b\u0441\u0442\u0443\u043f\u0438\u0442\u044c Java \u043a\u043e\u043d\u0441\u0443\u043b\u044c\u0442\u0430\u043d\u0442\u043e\u043c \u043d\u0430\u0448\u0438\u0445 \u0443\u0440\u043e\u043a\u043e\u0432 (\u0438\u043d\u043e\u0433\u0434\u0430 \u0432 \u0441\u0442\u0430\u0442\u044c\u044f\u0445 \u044f \u0431\u0443\u0434\u0443 \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442\u044c \u043b\u0438\u0441\u0442\u0438\u043d\u0433\u0438 \u043a\u043e\u0434\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b\u0430, \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u043d\u043e\u0433\u043e \u043d\u0430 Java), \u044f \u0431\u044b\u043b \u043f\u0435\u0440\u0435\u0430\u0434\u0440\u0435\u0441\u043e\u0432\u0430\u043d <a href=\"https:\/\/github.com\/siacs\/Conversations\">\u0432\u043e\u0442 \u0441\u044e\u0434\u0430<\/a> \u2014 \u0438 \u0432\u044b\u0431\u043e\u0440 \u0431\u044b\u043b \u0441\u0434\u0435\u043b\u0430\u043d:<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/464\/9bb\/560\/4649bb5607fa43b1a70f3ebcc2c67262.jpg\" \/><\/div>\n<p>  <\/p>\n<table>\n<tr>\n<td>Conversations \u2014 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u0434\u043b\u044f \u043e\u0431\u043c\u0435\u043d\u0430 \u043c\u0433\u043d\u043e\u0432\u0435\u043d\u043d\u044b\u043c\u0438 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u044f\u043c\u0438 \u0434\u043b\u044f Android, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0449\u0435\u0435 XMPP\/Jabber \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b. \u0410\u043b\u044c\u0442\u0435\u0440\u043d\u0430\u0442\u0438\u0432\u0430 \u0442\u0430\u043a\u0438\u043c \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0430\u043c, \u043a\u0430\u043a WhatsApp, WeChat, Line, Facebook Messenger, Google Hangouts \u0438 Threema.  <\/td>\n<\/tr>\n<\/table>\n<p>  <\/p>\n<p>\u0418\u043c\u0435\u043d\u043d\u043e \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0435 \u0434\u0430\u043d\u043d\u043e\u0433\u043e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u0431\u0443\u0434\u0443\u0442 \u043f\u043e\u0441\u0442\u0440\u043e\u0435\u043d\u044b \u043d\u0430\u0448\u0438 \u0443\u0440\u043e\u043a\u0438, \u0430 <s>\u0431\u043b\u0438\u0436\u0435 \u043a \u0440\u0435\u043b\u0438\u0437\u0443<\/s> \u043a \u043a\u043e\u043d\u0446\u0443 \u0444\u0438\u043d\u0430\u043b\u044c\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0438 \u0443 \u043d\u0430\u0441 \u0431\u0443\u0434\u0435\u0442 \u0441\u0432\u043e\u0439 \u043f\u0440\u0435\u0441\u043c\u044b\u043a\u0430\u044e\u0449\u0438\u0439\u0441\u044f \u0437\u0435\u043c\u043d\u043e\u0432\u043e\u0434\u043d\u043e-\u0444\u0440\u0443\u043a\u0442\u043e\u0432\u044b\u0439 \u0442\u043e\u043d\u0434\u0435\u043c <s>\u043f\u0438\u0442\u043e\u043d\u0430, \u0436\u0430\u0431\u044b \u0438 \u0444\u0440\u0443\u043a\u0442\u0430<\/s> Jabber-Python-Kivy \u2014 PyConversations \u0438 \u0437\u0430\u0432\u0435\u0442\u043d\u0430\u044f apk-\u0448\u0435\u0447\u043a\u0430, \u0441\u043e\u0431\u0440\u0430\u043d\u043d\u0430\u044f \u0441 Python3!<\/p>\n<p>  <\/p>\n<p>\u041d\u0430\u0434\u0435\u044e\u0441\u044c, \u0447\u0430\u0435\u043c \u0438 \u0441\u0438\u0433\u0430\u0440\u0435\u0442\u0430\u043c\u0438 \u0432\u044b \u0437\u0430\u043f\u0430\u0441\u043b\u0438\u0441\u044c, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u043c\u044b \u043d\u0430\u0447\u0438\u043d\u0430\u0435\u043c! \u041a\u0430\u043a \u0432\u0441\u0435\u0433\u0434\u0430, \u0432\u0430\u043c \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u0442\u044c\u0441\u044f, \u0435\u0441\u043b\u0438 \u0435\u0449\u0435 \u043d\u0435 \u043e\u0431\u0437\u0430\u0432\u0435\u043b\u0438\u0441\u044c, <a href=\"https:\/\/github.com\/HeaTTheatR\/CreatorKivyProject\">\u041c\u0430\u0441\u0442\u0435\u0440 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u043d\u043e\u0432\u043e\u0433\u043e \u043f\u0440\u043e\u0435\u043a\u0442\u0430<\/a> \u0434\u043b\u044f Kivy \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439. \u041a\u043b\u043e\u043d\u0438\u0440\u0443\u0439\u0442\u0435 \u0435\u0433\u043e \u0432 \u0441\u0432\u043e\u0438\u0445 \u043b\u0430\u0431\u043e\u0440\u0430\u0442\u043e\u0440\u0438\u044f\u0445, \u043e\u0442\u043a\u0440\u043e\u0439\u0442\u0435 \u043a\u043e\u0440\u043d\u0435\u0432\u0443\u044e \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u044e \u043c\u0430\u0441\u0442\u0435\u0440\u0430 \u0432 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u0435 \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u0443:<\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">python3 main.py PyConversations \u043f\u0443\u0442\u044c\/\u043a\/\u043c\u0435\u0441\u0442\u0443\/\u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d\u0438\u044f\/\u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0435\u043c\u043e\u0433\u043e\/\u043f\u0440\u043e\u0435\u043a\u0442\u0430 -repo https:\/\/github.com\/User\/PyConversations -autor Easy -mail gorodage@gmail.com<\/code><\/pre>\n<p>  <\/p>\n<p>\u0415\u0441\u0442\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u043e, \u0441\u0430\u043c \u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a Kivy, \u043e\u0431 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0435 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u043c\u043e\u0436\u043d\u043e \u043f\u0440\u043e\u0447\u0438\u0442\u0430\u0442\u044c <a href=\"https:\/\/kivy.org\/#download\">\u0437\u0434\u0435\u0441\u044c<\/a>. \u041d\u0443, \u0430 \u0437\u0430\u043c\u0435\u0447\u0430\u0442\u0435\u043b\u044c\u043d\u0443\u044e \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 KivyMD \u0434\u043b\u044f \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u043d\u0430\u0442\u0438\u0432\u043d\u043e\u0433\u043e \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430 \u0432 \u0441\u0442\u0438\u043b\u0435 Android Material Design \u0432\u044b, \u043a\u043e\u043d\u0435\u0447\u043d\u043e \u0436\u0435, \u0443\u0436\u0435 \u043d\u0430\u0448\u043b\u0438 \u043f\u043e \u0441\u0441\u044b\u043b\u043a\u0435 \u0432 \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u0438 \u041c\u0430\u0441\u0442\u0435\u0440\u0430 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u043d\u043e\u0432\u043e\u0433\u043e \u043f\u0440\u043e\u0435\u043a\u0442\u0430.<\/p>\n<p>  <\/p>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0439\u0442\u0435\u0441\u044c \u043d\u0430 <s>PornHub<\/s> <a href=\"https:\/\/github.com\">github<\/a> \u0438 \u0444\u043e\u0440\u043a\u043d\u0438\u0442\u0435\/ \u043a\u043b\u043e\u043d\u0438\u0440\u0443\u0439\u0442\u0435\/\u0441\u043a\u0430\u0447\u0430\u0439\u0442\u0435 \u0440\u0435\u043f\u0443 PyConversations, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u043f\u0440\u043e\u0435\u043a\u0442, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043c\u044b \u0441 \u0432\u0430\u043c\u0438 \u0437\u0430\u0442\u0435\u044f\u043b\u0438, \u0431\u0443\u0434\u0435\u0442 \u043d\u0435 \u043c\u0430\u043b\u0435\u043d\u044c\u043a\u0438\u0439, \u0438 \u043f\u043e \u0445\u043e\u0434\u0443 \u0432\u044b\u0445\u043e\u0434\u0430 \u043d\u043e\u0432\u044b\u0445 \u0441\u0442\u0430\u0442\u0435\u0439, \u043e\u043d \u0431\u0443\u0434\u0435\u0442 \u043e\u0431\u0440\u0430\u0441\u0442\u0430\u0442\u044c \u043d\u043e\u0432\u044b\u043c\u0438 \u0444\u0443\u043d\u043a\u0446\u0438\u044f\u043c\u0438, \u043a\u043b\u0430\u0441\u0441\u0430\u043c\u0438 \u0438 \u0444\u0430\u0439\u043b\u0430\u043c\u0438. \u0412 \u043f\u0440\u043e\u0442\u0438\u0432\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435, \u0443\u0436\u0435 \u0432\u043e \u0432\u0442\u043e\u0440\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u0432\u044b \u0431\u0443\u0434\u0435\u0442\u0435 <s>\u043a\u0443\u0440\u0438\u0442\u044c \u0431\u0430\u043c\u0431\u0443\u043a<\/s> \u043d\u0435\u0434\u043e\u0443\u043c\u0435\u0432\u0430\u0442\u044c, \u043f\u043e\u0447\u0435\u043c\u0443 \u0443 \u0432\u0430\u0441 \u043d\u0438\u0447\u0435\u0433\u043e \u043d\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442.<\/p>\n<p>  <\/p>\n<p>\u0418\u0442\u0430\u043a, \u043f\u0440\u043e\u0435\u043a\u0442 \u0441\u043e\u0437\u0434\u0430\u043d:<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/d49\/398\/557\/d49398557ace404fb6fb6aad5914a74f.png\" \/><\/div>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u0441\u0435\u0433\u043e\u0434\u043d\u044f\u0448\u043d\u0435\u0439 \u0441\u0442\u0430\u0442\u044c\u0438 \u044f \u0432\u0437\u044f\u043b \u043f\u0435\u0440\u0432\u044b\u0435 \u0447\u0435\u0442\u044b\u0440\u0435 Activity \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f Conversations (Activity \u0440\u0435\u0433\u0438\u0441\u0442\u0430\u0440\u0446\u0438\u0438 \u043d\u043e\u0432\u043e\u0433\u043e \u0430\u043a\u043a\u0430\u0443\u043d\u0442\u0430), \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u044b \u0441 \u0432\u0430\u043c\u0438 \u0441\u0435\u0439\u0447\u0430\u0441 \u0431\u0443\u0434\u0435\u043c \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c:<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/202\/ae3\/5d9\/202ae35d9b6c425991db11dfe3c8ebde.png\" \/><\/div>\n<p>  <\/p>\n<p>\u041e\u0434\u043d\u0430\u043a\u043e \u043f\u0440\u0435\u0436\u0434\u0435, \u0447\u0435\u043c \u043d\u0430\u0447\u0430\u0442\u044c, \u0447\u0442\u043e\u0431\u044b \u043c\u044b \u0441 \u0432\u0430\u043c\u0438 \u043f\u043e\u043d\u0438\u043c\u0430\u043b\u0438 \u0434\u0440\u0443\u0433 \u0434\u0440\u0443\u0433\u0430, \u0432\u0430\u043c \u0441\u0442\u043e\u0438\u0442 \u043e\u0437\u043d\u0430\u043a\u043e\u043c\u0438\u0442\u044c\u0441\u044f \u0441 \u0431\u0430\u0437\u043e\u0432\u044b\u043c\u0438 \u043f\u0440\u0430\u0432\u0438\u043b\u0430\u043c\u0438 \u0438 \u043f\u043e\u043d\u044f\u0442\u0438\u044f\u043c\u0438&#8230;<\/p>\n<p>  <\/p>\n<h4><b>\u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u0438\u043c\u0438 \u043a\u043b\u0430\u0441\u0441\u0430\u043c\u0438<\/b><\/h4>\n<p>  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">\u0411\u0430\u0437\u043e\u0432\u043e\u0435 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 \u043d\u0430 \u043f\u0440\u043e\u0441\u0442\u043e\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u0435:<\/b><\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"python\">from kivy.app import App  from kivy.uix.boxlayout import BoxLayout  from kivy.lang import Builder  from kivy.properties import StringProperty   Builder.load_string('''  #: import MDFlatButton kivymd.button.MDFlatButton   # \u0414\u0430\u043d\u043d\u044b\u0435 \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u0438 \u0432 Kivy-Language \u0430\u043d\u0430\u043b\u043e\u0433\u0438\u0447\u043d\u044b \u0438\u043c\u043f\u043e\u0440\u0442\u0443 \u0432 python \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u044f\u0445:  # from kivymd.button import MDFlatButton  #  # \u0412 kv-\u0444\u0430\u0439\u043b\u0435 \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0432\u043a\u043b\u044e\u0447\u0430\u0442\u044c \u0434\u0440\u0443\u0433\u0438\u0435 \u0444\u0430\u0439\u043b\u044b \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0438,  # \u0435\u0441\u043b\u0438 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0441\u043b\u0438\u0448\u043a\u043e\u043c \u0441\u043b\u043e\u0436\u043d\u044b\u0439: #: include your_kv_file.kv  # # \u0421\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0435 \u0432\u0438\u0434\u0436\u0435\u0442\u044b \u0438 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u044b, \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u043c\u044b\u0435 Kivy \u0438\u0437 \u043a\u043e\u0440\u043e\u0431\u043a\u0438, # \u043d\u0435 \u043d\u0443\u0436\u043d\u043e \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0432 Activity \u2014 \u043f\u0440\u043e\u0441\u0442\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435 \u0438\u0445.  # \u0412\u0441\u0435 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u044b \u0434\u0430\u043d\u043d\u043e\u0433\u043e Activity \u0431\u0443\u0434\u0443\u0442 \u0440\u0430\u0441\u043f\u043e\u043b\u0430\u0433\u0430\u0442\u044c\u0441\u044f \u0432 BoxLayout -  # \u0432\u0438\u0434\u0436\u0435\u0442\u0435, \u043e\u0442 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0443\u043d\u0430\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d \u0431\u0430\u0437\u043e\u0432\u044b\u0439 \u043a\u043b\u0430\u0441\u0441.  &lt;StartScreen&gt;       MDFlatButton:          id: button          text: 'Press Me'          size_hint_x: 1  # \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u0430\u044f \u0448\u0438\u0440\u0438\u043d\u0430 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0430 - \u043e\u0442 0 \u0434\u043e 1          pos_hint: {'y': .5}  # \u043f\u043e\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0430 \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0432\u0435\u0440\u0442\u0438\u043a\u0430\u043b\u0438 'y' \u043a\u043e\u0440\u043d\u0435\u0432\u043e\u0433\u043e \u0432\u0438\u0434\u0436\u0435\u0442\u0430           # \u0421\u043e\u0431\u044b\u0442\u0438\u0435 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0430.          on_release:              # \u041a\u043b\u044e\u0447\u0435\u0432\u043e\u0435 \u0441\u043b\u043e\u0432\u043e 'root' - \u044d\u0442\u043e \u0438\u043d\u0441\u0442\u0430\u043d\u0441 \u0431\u0430\u0437\u043e\u0432\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0438,              # \u0447\u0435\u0440\u0435\u0437 \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a\u043e \u0432\u0441\u0435\u043c \u0435\u0433\u043e \u043c\u0435\u0442\u043e\u0434\u0430\u043c \u0438 \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u0430\u043c.              root.set_text_on_button()  ''')  # \u0418\u043b\u0438 Builder.load_file('path\/to\/kv-file'),  # \u0435\u0441\u043b\u0438 \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0430 Activity \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u0432 \u0444\u0430\u0439\u043b\u0435.   class StartScreen(BoxLayout):      '''\u0411\u0430\u0437\u043e\u0432\u044b\u0439 \u043a\u043b\u0430\u0441\u0441.'''       new_text_for_button = StringProperty()      # \u0412 Kivy \u0432\u044b \u0434\u043e\u043b\u0436\u043d\u044b \u044f\u0432\u043d\u043e \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c \u0442\u0438\u043f \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u043e\u0432:      #      # StringProperty;      # NumericProperty;      # BoundedNumericProperty;      # ObjectProperty;      # DictProperty;      # ListProperty;      # OptionProperty;      # AliasProperty;      # BooleanProperty;      # ReferenceListProperty;      #      # \u0432 \u043f\u0440\u043e\u0442\u0438\u0432\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u0432\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u0435 \u043e\u0448\u0438\u0431\u043a\u0443      # \u043f\u0440\u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0439 \u044d\u0442\u0438\u0445 \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u043e\u0432.      #      # \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0435\u0441\u043b\u0438 \u043d\u0435 \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c \u0442\u0438\u043f:      #      # new_text_for_button = ''      #      # \u0431\u0443\u0434\u0435\u0442 \u0432\u043e\u0437\u0431\u0443\u0436\u0434\u0435\u043d\u043e \u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 -      # TypeError: object.__init__() takes no parameters.       def set_text_on_button(self):          self.ids.button.text = self.new_text_for_button          # ids - \u044d\u0442\u043e \u0441\u043b\u043e\u0432\u0430\u0440\u044c \u0432\u0441\u0435\u0445 \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u0432 Activity          # \u043a\u043e\u0442\u043e\u0440\u044b\u043c \u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d \u0438\u0434\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440.          #          # \u0422\u0430\u043a, \u043e\u0431\u0440\u0430\u0442\u0438\u0432\u0448\u0438\u0441\u044c \u0447\u0435\u0440\u0435\u0437 \u0438\u0434\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440 'button' - self.ids.button -          # \u043a \u043e\u0431\u044a\u0435\u043a\u0442\u0443 \u043a\u043d\u043e\u043f\u043a\u0438, \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u0434\u043e\u0441\u0442\u0443\u043f          # \u043a\u043e \u0432\u0441\u0435\u043c \u0435\u0433\u043e \u043c\u0435\u0442\u043e\u0434\u0430\u043c \u0438 \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u0430\u043c.       # \u041b\u044e\u0431\u043e\u0439 \u0430\u0442\u0440\u0438\u0431\u0443\u0442, \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0438\u0440\u043e\u0432\u0432\u0430\u043d\u043d\u044b\u0439 \u043a\u0430\u043a Properties,      # \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442 \u043c\u0435\u0442\u043e\u0434 \u0432 \u0431\u0430\u0437\u043e\u0432\u043e\u043c \u043a\u043b\u0430\u0441\u0441\u0435 \u0441 \u043f\u0440\u0435\u0444\u0438\u043a\u0441\u043e\u043c 'on_',      # \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0437\u0432\u0430\u043d \u043a\u0430\u043a \u0442\u043e\u043b\u044c\u043a\u043e \u0434\u0430\u043d\u043d\u044b\u0439 \u0430\u0442\u0440\u0438\u0431\u0443\u0442 \u043f\u043e\u043b\u0443\u0447\u0438\u0442 \u043d\u043e\u0432\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435.      def on_new_text_for_button(self, instance, value):          print(instance, value)   class Program(App):      def build(self):          '''\u041c\u0435\u0442\u043e\u0434, \u0432\u044b\u0437\u044b\u0432\u0430\u0435\u043c\u044b\u0439 \u043f\u0440\u0438 \u0441\u0442\u0430\u0440\u0442\u0435 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u044b.          \u0414\u043e\u043b\u0436\u0435\u043d \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0442\u044c \u043e\u0431\u044a\u0435\u043a\u0442 \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0435\u043c\u043e\u0433\u043e Activity.'''           return StartScreen(new_text_for_button='This new text')   if __name__ in ('__main__', '__android__'):      Program().run()  # \u0437\u0430\u043f\u0443\u0441\u043a \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f<\/code><\/pre>\n<\/div>\n<\/div>\n<p>  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">\u0421\u0441\u044b\u043b\u0430\u0435\u043c\u0441\u044f \u043d\u0430 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0435 \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u044b \u0438 \u043c\u0435\u0442\u043e\u0434\u044b \u0432\u043d\u0443\u0442\u0440\u0438 Activity:<\/b><\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"python\">from kivy.app import App  from kivy.uix.boxlayout import BoxLayout  from kivy.lang import Builder  from kivy.properties import StringProperty   Builder.load_string('''  #: import MDFlatButton kivymd.button.MDFlatButton   &lt;StartScreen&gt;       MDFlatButton:          id: button          text: 'Press Me'          size_hint_x: 1          pos_hint: {'y': .5}           on_release:              # \u0427\u0435\u0440\u0435\u0437 \u043a\u043b\u044e\u0447\u0435\u0432\u043e \u0441\u043b\u043e\u0432\u043e 'self' \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u0441\u0441\u044b\u043b\u0430\u0442\u044c\u0441\u044f              # \u043d\u0430 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u044b\u0435 \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u044b \u0438 \u043c\u0435\u0442\u043e\u0434\u044b \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e \u0432\u0438\u0434\u0436\u0435\u0442\u0430.              self.text = root.new_text_for_button  ''')   class StartScreen(BoxLayout):      new_text_for_button = StringProperty()       def on_new_text_for_button(self, instance, value):          print(instance, value)   class Program(App):      def build(self):          return StartScreen(new_text_for_button='This new text')   if __name__ in ('__main__', '__android__'):      Program().run()<\/code><\/pre>\n<\/div>\n<\/div>\n<p>  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 id \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u043e\u0432 \u0438 \u0432\u0438\u0434\u0436\u0435\u0442\u043e\u0432 \u0432\u043d\u0443\u0442\u0440\u0438 Activity:<\/b><\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"python\">from kivy.app import App  from kivy.uix.boxlayout import BoxLayout  from kivy.lang import Builder  from kivy.properties import StringProperty   Builder.load_string('''  #: import MDFlatButton kivymd.button.MDFlatButton   &lt;StartScreen&gt;      orientation: 'vertical'       MDFlatButton:          id: button          text: 'Press Me'          size_hint: 1, 1          pos_hint: {'center_y': .5}           on_release:              # \u041f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u0434\u043e\u0441\u0442\u0443\u043f \u0447\u0435\u0440\u0435\u0437 id \u043a \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u0430\u043c \u0438 \u043c\u0435\u0442\u043e\u0434\u0430\u043c \u0432\u0442\u043e\u0440\u043e\u0439 \u043a\u043d\u043e\u043f\u043a\u0438.              # \u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435, \u0447\u0442\u043e \u0432\u043d\u0443\u0442\u0440\u0438 \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0438 \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u043a\u043e\u0434 Python              # \u0442\u043e\u0447\u043d\u043e \u0442\u0430\u043a, \u043a\u0430\u043a \u0438 \u0432 \u043e\u0431\u044b\u0447\u043d\u043e\u043c Python \u0441\u0446\u0435\u043d\u0430\u0440\u0438\u0438.              button_two.text = 'Id: &quot;button_two: &quot; {}'.format(root.new_text_for_button)       MDFlatButton:          id: button_two          text: 'Id: &quot;button_two: &quot; Old text'          size_hint: 1, 1          pos_hint: {'center_y': .5}  ''')   class StartScreen(BoxLayout):      new_text_for_button = StringProperty()   class Program(App):      def build(self):          return StartScreen(new_text_for_button='This new text')   if __name__ in ('__main__', '__android__'):      Program().run()<\/code><\/pre>\n<\/div>\n<\/div>\n<p>  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u043c\u0435\u0442\u043e\u0434\u043e\u0432 \u0441 \u043f\u0440\u0435\u0444\u0438\u043a\u0441\u043e\u043c &#39;on_&#39; \u0432\u043d\u0443\u0442\u0440\u0438 Activity:<\/b><\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"python\">from kivy.app import App  from kivy.uix.boxlayout import BoxLayout  from kivy.lang import Builder  from kivy.properties import StringProperty   Builder.load_string('''  #: import MDFlatButton kivymd.button.MDFlatButton  #: import snackbar kivymd.snackbar   &lt;StartScreen&gt;      orientation: 'vertical'       MDFlatButton:          id: button          text: 'Press Me'          size_hint: 1, 1          pos_hint: {'center_y': .5}           on_release:              button_two.text = 'Id: &quot;button_two: &quot; {}'.format(root.new_text_for_button)       MDFlatButton:          id: button_two          text: 'Id: &quot;button_two: &quot; Old text'          size_hint: 1, 1          pos_hint: {'center_y': .5}           on_text:              # \u0421\u043e\u0431\u044b\u0442\u0438\u0435 \u043d\u0430 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u0430 'text'.              snackbar.make('\u041e, \u0411\u043e\u0436\u0435! \u041c\u043e\u0439 \u0442\u0435\u043a\u0441\u0442 \u0442\u043e\u043b\u044c\u043a\u043e \u0447\u0442\u043e \u0438\u0437\u043c\u0435\u043d\u0438\u043b\u0438!')  ''')   class StartScreen(BoxLayout):      new_text_for_button = StringProperty()   class Program(App):      def build(self):          return StartScreen(new_text_for_button='This new text')   if __name__ in ('__main__', '__android__'):      Program().run()<\/code><\/pre>\n<\/div>\n<\/div>\n<p>  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u0430\u0442\u0442\u0440\u0438\u0431\u0443\u0442\u043e\u0432 \u0438 \u043c\u0435\u0442\u043e\u0434\u043e\u0432 \u0438\u0437 \u0433\u043b\u0430\u0432\u043d\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u0432\u043d\u0443\u0442\u0440\u0438 Activity:<\/b><\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"python\">from kivy.app import App from kivy.uix.boxlayout import BoxLayout from kivy.lang import Builder from kivy.properties import StringProperty  Builder.load_string(''' #: import MDFlatButton kivymd.button.MDFlatButton  &lt;StartScreen&gt;     MDFlatButton:         # \u0427\u0435\u0440\u0435\u0437 \u043b\u043a\u044e\u0447\u0435\u0432\u043e\u0435 \u0441\u043b\u043e\u0432\u043e 'app' \u2014 \u044d\u043a\u0437\u0435\u043c\u043f\u043b\u044f\u0440 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f -         # \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u043c\u0435\u0442\u043e\u0434\u0430\u043c \u0438 \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u0430\u043c,         # \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u044c\u0437\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u043c \u0432 \u0433\u043b\u0430\u0432\u043d\u043e\u043c \u043a\u043b\u0430\u0441\u0441\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f,         # \u0443\u043d\u0430\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d\u043d\u043e\u043c \u043e\u0442 kivy.app.App.         text: app.string_attribute         size_hint_x: 1         pos_hint: {'y': .5} ''')  class StartScreen(BoxLayout):     pass  class Program(App):     string_attribute = StringProperty('String from App')      def build(self):         return StartScreen()  if __name__ in ('__main__', '__android__'):     Program().run()<\/code><\/pre>\n<\/div>\n<\/div>\n<p>  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 Activity \u0431\u0435\u0437 \u043a\u043e\u0440\u043d\u0435\u0432\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430:<\/b><\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"python\">from kivy.app import App  from kivy.lang import Builder   Activity = '''  &lt;MyScreen@FloatLayout&gt;:       Label:          text: 'Text 1'   BoxLayout:      MyScreen:  '''   class Program(App):      def build(self):          return Builder.load_string(Activity)   if __name__ in ('__main__', '__android__'):      Program().run()<\/code><\/pre>\n<\/div>\n<\/div>\n<p>  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 ids \u0432 Activity \u0431\u0435\u0437 \u043a\u043e\u0440\u043d\u0435\u0432\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430:<\/b><\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"python\">from kivy.app import App  from kivy.lang import Builder   Activity = '''  #: import MDFlatButton kivymd.button.MDFlatButton   # \u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435, \u0435\u0441\u043b\u0438 \u043c\u044b \u043d\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c \u0431\u0430\u0437\u043e\u0432\u044b\u0439 \u043a\u043b\u0430\u0441\u0441, # \u043c\u044b \u0434\u043e\u043b\u0436\u043d\u044b \u0443\u043a\u0430\u0437\u0430\u0442\u044c, \u0431\u0430\u0437\u043e\u0432\u044b\u0439 \u0432\u0438\u0434\u0436\u0435\u0442. \u0412 \u0442\u0435\u043a\u0443\u0449\u0435\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u0435 - FloatLayout. &lt;MyScreen@FloatLayout&gt;:      Label:          id: label_1          text: 'Text 1'   BoxLayout:      orientation: 'vertical'       MyScreen:          id: my_screen       MDFlatButton:          text: 'Press me'          size_hint_x: 1           on_press:              my_screen.ids.label_1.text = 'New text'  '''   class Program(App):      def build(self):          return Builder.load_string(Activity)   if __name__ in ('__main__', '__android__'):      Program().run()<\/code><\/pre>\n<\/div>\n<\/div>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u043f\u043e\u043d\u0438\u043c\u0430\u043d\u0438\u044f \u0442\u043e\u0433\u043e, \u043e \u0447\u0435\u043c \u044f \u0431\u0443\u0434\u0443 \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c \u0434\u0430\u043b\u0435\u0435, \u044d\u0442\u043e\u0433\u043e \u043f\u043e\u043a\u0430 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e, \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u043e\u0435 \u0431\u0443\u0434\u0443 \u043e\u0431\u044a\u044f\u0441\u043d\u044f\u0442\u044c <s>\u0432 \u043e\u043a\u043e\u043f\u0435<\/s> \u043f\u043e \u0434\u043e\u0440\u043e\u0433\u0435. \u0427\u0442\u043e \u0436, \u0434\u0430\u0432\u0430\u0439\u0442\u0435 \u043d\u0430\u0447\u043d\u0435\u043c \u0441\u043e \u0441\u0442\u0430\u0440\u0442\u043e\u0432\u043e\u0433\u043e Activity \u043d\u0430\u0448\u0435\u0433\u043e \u043f\u0440\u043e\u0435\u043a\u0442\u0430. \u041e\u0442\u043a\u0440\u043e\u0439\u0442\u0435 \u0444\u0430\u0439\u043b <i>start_screen.kv<\/i>. \u0412 \u0434\u0435\u0440\u0435\u0432\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u043e\u043d, \u043a\u0430\u043a \u0432\u0441\u0435 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0435 Activity \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f, \u0440\u0430\u0437\u043c\u0435\u0449\u0430\u0435\u0442\u0441\u044f \u0432 \u0434\u0438\u0440\u0435\u043a\u0442\u043e\u0440\u0438\u0438 <i>libs\/uix\/kv\/activity<\/i>:<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/78b\/c47\/238\/78bc472386004e2c8075e2ba48be7492.png\" \/><\/div>\n<p>  <\/p>\n<p>\u0418 Activity \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u0442\u0430\u043a:<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">#: kivy 1.9.1 #: import Toolbar kivymd.toolbar.Toolbar #: import NoTransition kivy.uix.screenmanager.NoTransition  &lt;StartScreen&gt;:     orientation: 'vertical'      Toolbar:         id: action_bar         background_color: app.theme_cls.primary_color  # \u0446\u0432\u0435\u0442 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u043d\u043e\u0439 \u0442\u0435\u043c\u044b         title: app.title         opposite_colors: True  # \u0447\u0435\u0440\u043d\u0430\u044f \u043b\u0438\u0431\u043e \u0431\u0435\u043b\u0430\u044f \u0438\u043a\u043e\u043d\u043a\u0430         elevation: 10  # \u0434\u043b\u0438\u043d\u043d\u0430 \u0442\u0435\u043d\u0438         # \u0418\u043a\u043e\u043d\u043a\u0438 \u0441\u043b\u0435\u0432\u0430 -          # left_action_items: [['name-icon', function], \u2026]         # \u0418\u043a\u043e\u043d\u043a\u0438 \u0441\u043f\u0440\u0430\u0432\u0430 -          # right_action_items: [['name-icon', function], \u2026]      ScreenManager:         id: root_manager         transition: NoTransition() # \u044d\u0444\u0444\u0435\u043a\u0442 \u0441\u043c\u0435\u043d\u044b Activity          Introduction:             id: introduction             # \u0412\u044b\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043f\u0440\u0438 \u0432\u044b\u0432\u043e\u0434\u0435 \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e Activity \u043d\u0430 \u044d\u043a\u0440\u0430\u043d.             on_enter: self._on_enter(action_bar, app)          CreateAccount:             id: create_account             on_enter: self._on_enter(action_bar, app, root_manager)          AddAccount:             id: add_account             on_enter: self._on_enter(action_bar, app)             # \u0412\u044b\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043f\u0440\u0438 \u0437\u0430\u043a\u0440\u044b\u0442\u0438\u0438 \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e Activity.             on_leave: action_bar.title = app.data.string_lang_create_account          AddAccountOwn:             id: add_account_own_provider             on_enter: self._on_enter(action_bar, app, root_manager)             on_leave: action_bar.title = app.title; action_bar.left_action_items = []<\/code><\/pre>\n<p>  <\/p>\n<p>\u0410 \u0432\u043e\u0442 \u0431\u043e\u043b\u0435\u0435 \u043d\u0430\u0433\u043b\u044f\u0434\u043d\u043e:<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/252\/7f0\/fe4\/2527f0fe445044939d6c566cf670d4b8.png\" \/><\/div>\n<p>  <\/p>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u043e\u0442\u043a\u0440\u043e\u0435\u043c \u0431\u0430\u0437\u043e\u0432\u044b\u0439 \u043a\u043b\u0430\u0441\u0441 Activity StartScreen, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u043f\u043e \u043f\u0443\u0442\u0438 <i>libs\/uix\/kv\/activity\/baseclass<\/i>:<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/29b\/2f3\/04e\/29b2f304e0324451a134d3ba25c2bd09.png\" \/><\/div>\n<p>  <\/p>\n<p><b>startscreen.py:<\/b><\/p>\n<p>  <\/p>\n<pre><code class=\"python\">from kivy.uix.boxlayout import BoxLayout  class StartScreen(BoxLayout):     pass<\/code><\/pre>\n<p>  <\/p>\n<p>\u041a\u0430\u043a \u0432\u0438\u0434\u0438\u0442\u0435, \u043a\u043b\u0430\u0441\u0441 \u043f\u0443\u0441\u0442, \u043d\u043e \u0443\u043d\u0430\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d \u043e\u0442 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0430 BoxLayout, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0440\u0430\u0437\u043c\u0435\u0449\u0430\u0435\u0442 \u0432 \u0441\u0435\u0431\u0435 \u0432\u0438\u0434\u0436\u0435\u0442\u044b \u0432\u0435\u0440\u0442\u0438\u043a\u0430\u043b\u044c\u043d\u043e, \u043b\u0438\u0431\u043e \u0433\u043e\u0440\u0438\u0437\u043e\u043d\u0442\u0430\u043b\u044c\u043d\u043e \u0432 \u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e\u0441\u0442\u0438 \u043e\u0442 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430 &#8216;orientation&#8217; \u2014 &#8216;vertical&#8217; \u0438\u043b\u0438 &#8216;horizontal&#8217; (\u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u2014 &#8216;horizontal&#8217;). \u0412\u043e\u0442 \u0435\u0449\u0435 \u0431\u043e\u043b\u0435\u0435 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0430\u044f \u0441\u0445\u0435\u043c\u0430 Activity StartScreen:<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/a94\/967\/d7e\/a94967d7ed884ed1b6d8e63d86484b9e.png\" \/><\/div>\n<p>  <\/p>\n<p>\u0411\u0430\u0437\u043e\u0432\u044b\u0439 \u043a\u043b\u0430\u0441\u0441 Activity StartScreen, \u043c\u044b \u0443\u043d\u0430\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043b\u0438 \u043e\u0442 BoxLayout, \u0432 \u0441\u0430\u043c\u043e\u0439 \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0435 \u043e\u0431\u044a\u044f\u0432\u0438\u043b\u0438 \u0435\u0433\u043e \u043e\u0440\u0438\u0435\u043d\u0442\u0430\u0446\u0438\u044e \u043a\u0430\u043a <s>\u043d\u0435\u0442\u0440\u0430\u0434\u0438\u0446\u0438\u043e\u043d\u043d\u0443\u044e<\/s> \u0432\u0435\u0440\u0442\u0438\u043a\u0430\u043b\u044c\u043d\u0443\u044e, \u0438 \u043f\u043e\u043c\u0435\u0441\u0442\u0438\u043b\u0438 \u0432 \u0435\u0433\u043e \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440 ToolBar \u0438 \u043c\u0435\u043d\u0435\u0434\u0436\u0435\u0440 \u044d\u043a\u0440\u0430\u043d\u043e\u0432 ScreenManager. ScreenManager \u2014 \u044d\u0442\u043e \u0442\u043e\u0436\u0435 \u0441\u0432\u043e\u0435\u0433\u043e \u0440\u043e\u0434\u0430 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440, \u0432 \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043c\u044b \u043f\u043e\u043c\u0435\u0449\u0430\u0435\u043c \u044d\u043a\u0440\u0430\u043d\u044b Screen \u0441 \u0441\u043e\u0437\u0434\u0430\u043d\u043d\u044b\u043c\u0438 Activity \u0438 \u0432 \u0434\u0430\u043b\u044c\u043d\u0435\u0439\u0448\u0435\u043c \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u043c \u0438\u0445 \u043d\u0430 \u044d\u043a\u0440\u0430\u043d \u043f\u0440\u043e\u0441\u0442\u043e \u043d\u044b\u0437\u044b\u0432\u0430\u044f \u0438\u0445 \u043f\u043e \u0438\u043c\u0435\u043d\u0430\u043c. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440:<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">from kivy.app import App  from kivy.lang import Builder   Activity = '''  #: import MDFlatButton kivymd.button.MDFlatButton   ScreenManager:       Screen:          name: 'Screen one'  # \u0438\u043c\u044f \u044d\u043a\u0440\u0430\u043d\u0430          MDFlatButton:              text: 'I`m Screen one with Button'              size_hint: 1, 1              on_release:                  root.current = 'Screen two'  # \u0441\u043c\u0435\u043d\u0430 \u044d\u043a\u0440\u0430\u043d\u0430      Screen:          name: 'Screen two'           BoxLayout:              orientation: 'vertical'               Image:                  source: 'data\/logo\/kivy-icon-128.png'               MDFlatButton:                  text: 'I`m Screen two with Button'                  size_hint: 1, 1                  on_release: root.current = 'Screen one'  '''   class Program(App):      def build(self):          return Builder.load_string(Activity)   if __name__ in ('__main__', '__android__'):      Program().run()<\/code><\/pre>\n<p>  <\/p>\n<p>\u041d\u0430\u0448 ScreenManager \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0447\u0435\u0442\u044b\u0440\u0435 \u044d\u043a\u0440\u0430\u043d\u0430 \u0441 Activity: Introduction, CreateAccount, AddAccount \u0438 AddAccountOwn. \u041d\u0430\u0447\u043d\u0435\u043c \u0441 \u043f\u0435\u0440\u0432\u043e\u0433\u043e:<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/9ef\/e48\/a94\/9efe48a94a484fc9868fbcbf9a891622.png\" \/><\/div>\n<p>  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">Introduction.kv<\/b><\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"xml\">#: kivy 1.9.1  #: import MDFlatButton kivymd.button.MDFlatButton   # \u0421\u0442\u0430\u0440\u0442\u043e\u0432\u043e\u0435 Activity \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f.   &lt;Introduction&gt;:      name: 'Start screen'       BoxLayout:          orientation: 'vertical'          padding: dp(5), dp(20)           Image:              source: 'data\/images\/logo.png'              size_hint: None, None              size: dp(150), dp(150)              pos_hint: {'center_x': .5}           Label:              text: app.data.string_lang_introduction              markup: True              color: app.data.text_color              text_size: dp(self.size[0] - 10), self.size[1]              size_hint_y: None              valign: 'top'              height: dp(250)           Widget:           BoxLayout:               MDFlatButton:                  text: app.data.string_lang_create_account                  on_release: app.screen_root_manager.current = 'Create account'               MDFlatButton:                  text: app.data.string_lang_own_provider                  theme_text_color: 'Primary'                  on_release:                      app.delete_textfield_and_set_check_in_addaccountroot ()                     app.screen_root_manager.current = 'Add account own provider'<\/code><\/pre>\n<\/div>\n<\/div>\n<p>  <\/p>\n<p>\u0412\u043e\u0442, \u0447\u0442\u043e \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0434\u0430\u043d\u043d\u043e\u0435 Activity \u043d\u0430 \u044d\u043a\u0440\u0430\u043d\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430 (\u044f \u043f\u043e\u0437\u0432\u043e\u043b\u0438\u043b \u0441\u0435\u0431\u0435 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0432\u043e\u043b\u044c\u043d\u043e\u0441\u0442\u0438, \u043d\u043e, \u043c\u043d\u0435 \u043f\u043e\u043a\u0430\u0437\u0430\u043b\u043e\u0441\u044c, \u0442\u0430\u043a \u0431\u0443\u0434\u0435\u0442 \u043b\u0443\u0447\u0448\u0435):<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/22c\/27e\/fe0\/22c27efe01e9464baca2c815e31a67c1.png\" \/><\/div>\n<p>  <\/p>\n<p>\u0412\u043e\u0442 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u043d\u0430 Java:<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/5a0\/185\/368\/5a0185368e87483ab992c254d2860194.png\" \/><\/div>\n<p>  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">\u041e\u0440\u0438\u0433\u0438\u043d\u0430\u043b\u044c\u043d\u0430\u044f \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0430 Activity \u0432 Java<\/b><\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"xml\">&lt;?xml version=&quot;1.0&quot; encoding=&quot;utf-8&quot;?&gt; &lt;ScrollView xmlns:android=&quot;http:\/\/schemas.android.com\/apk\/res\/android&quot;             android:layout_width=&quot;match_parent&quot;             android:layout_height=&quot;match_parent&quot;             android:fillViewport=&quot;true&quot;&gt;     &lt;RelativeLayout         android:layout_width=&quot;match_parent&quot;         android:layout_height=&quot;match_parent&quot;         android:background=&quot;?attr\/color_background_primary&quot;&gt;          &lt;LinearLayout             android:id=&quot;@+id\/linearLayout&quot;             android:layout_width=&quot;match_parent&quot;             android:layout_height=&quot;wrap_content&quot;             android:layout_alignParentBottom=&quot;true&quot;             android:layout_alignParentLeft=&quot;true&quot;             android:layout_alignParentStart=&quot;true&quot;             android:minHeight=&quot;256dp&quot;             android:orientation=&quot;vertical&quot;             android:paddingBottom=&quot;10dp&quot;             android:paddingLeft=&quot;16dp&quot;             android:paddingRight=&quot;16dp&quot;&gt;             &lt;Space                 android:layout_width=&quot;match_parent&quot;                 android:layout_height=&quot;0dp&quot;                 android:layout_weight=&quot;1&quot;\/&gt;             &lt;TextView                 android:layout_width=&quot;wrap_content&quot;                 android:layout_height=&quot;wrap_content&quot;                 android:text=&quot;@string\/welcome_header&quot;                 android:textColor=&quot;?attr\/color_text_primary&quot;                 android:textSize=&quot;?attr\/TextSizeHeadline&quot;                 android:textStyle=&quot;bold&quot;\/&gt;             &lt;TextView                 android:layout_width=&quot;wrap_content&quot;                 android:layout_height=&quot;wrap_content&quot;                 android:layout_marginTop=&quot;8dp&quot;                 android:text=&quot;@string\/welcome_text&quot;                 android:textColor=&quot;?attr\/color_text_primary&quot;                 android:textSize=&quot;?attr\/TextSizeBody&quot;\/&gt;             &lt;Button                 android:id=&quot;@+id\/create_account&quot;                 style=&quot;?android:attr\/borderlessButtonStyle&quot;                 android:layout_width=&quot;wrap_content&quot;                 android:layout_height=&quot;wrap_content&quot;                 android:layout_gravity=&quot;right&quot;                 android:text=&quot;@string\/create_account&quot;                 android:textColor=&quot;@color\/accent&quot;\/&gt;             &lt;Button                 android:id=&quot;@+id\/use_own_provider&quot;                 style=&quot;?android:attr\/borderlessButtonStyle&quot;                 android:layout_width=&quot;wrap_content&quot;                 android:layout_height=&quot;wrap_content&quot;                 android:layout_gravity=&quot;right&quot;                 android:text=&quot;@string\/use_own_provider&quot;                 android:textColor=&quot;?attr\/color_text_secondary&quot;\/&gt;         &lt;\/LinearLayout&gt;         &lt;RelativeLayout             android:layout_width=&quot;match_parent&quot;             android:layout_height=&quot;match_parent&quot;             android:layout_above=&quot;@+id\/linearLayout&quot;             android:layout_alignParentLeft=&quot;true&quot;             android:layout_alignParentStart=&quot;true&quot;             android:layout_alignParentTop=&quot;true&quot;&gt;             &lt;ImageView                 android:layout_width=&quot;wrap_content&quot;                 android:layout_height=&quot;wrap_content&quot;                 android:layout_centerHorizontal=&quot;true&quot;                 android:layout_centerVertical=&quot;true&quot;                 android:padding=&quot;8dp&quot;                 android:src=&quot;@drawable\/main_logo&quot;\/&gt;         &lt;\/RelativeLayout&gt;         &lt;TextView             android:paddingLeft=&quot;8dp&quot;             android:paddingRight=&quot;8dp&quot;             android:layout_width=&quot;wrap_content&quot;             android:layout_height=&quot;wrap_content&quot;             android:layout_alignParentBottom=&quot;true&quot;             android:textColor=&quot;?attr\/color_text_secondary&quot;             android:textSize=&quot;@dimen\/fineprint_size&quot;             android:maxLines=&quot;1&quot;             android:text=&quot;@string\/free_for_six_month&quot;             android:layout_centerHorizontal=&quot;true&quot;\/&gt;     &lt;\/RelativeLayout&gt; &lt;\/ScrollView&gt;<\/code><\/pre>\n<\/div>\n<\/div>\n<p>  <\/p>\n<p>\u041d\u0438\u0436\u0435 \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442\u0441\u044f \u0441\u0445\u0435\u043c\u0430 Activity Introduction:<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/8da\/da0\/41e\/8dada041e89e4407af7674ba8c6135d7.png\" \/><\/div>\n<p>  <\/p>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u0445\u043e\u0442\u0435\u043b\u043e\u0441\u044c \u0431\u044b \u043f\u0440\u043e\u0439\u0442\u0438 \u043f\u043e \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u0430\u043c \u0432\u0438\u0434\u0436\u0435\u0442\u043e\u0432:<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">BoxLayout:     \u2026      padding: dp(5), dp(20)  # \u043e\u0442\u0441\u0442\u0443\u043f\u044b \u043a\u043e\u043d\u0442\u0435\u043d\u0442\u0430 \u043e\u0442 \u043a\u0440\u0430\u0435\u0432 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0430 \u2014 \u0441\u043b\u0435\u0432\u0430\/\u0441\u043f\u0440\u0430\u0432\u0430 \u0438 \u0441\u0432\u0435\u0440\u0445\u0443\/\u0441\u043d\u0438\u0437\u0443<\/code><\/pre>\n<p>  <\/p>\n<pre><code class=\"python\">Image:     \u2026      # \u041a\u0430\u043a \u0441\u043b\u0435\u0434\u0443\u0435\u0442 \u0438\u0437 \u0438\u043c\u0435\u043d\u0438 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430,\u044d\u0442\u043e \u043f\u043e\u0434\u0441\u043a\u0430\u0437\u043a\u0430 - \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0439     # \u0440\u0430\u0437\u043c\u0435\u0440 \u0432\u0438\u0434\u0436\u0435\u0442\u0430 \u043e\u0442 0 \u0434\u043e 1 (.1, .5, .01 \u0438 \u0442. \u0434.). \u0415\u0441\u043b\u0438 \u043c\u044b \u0436\u0435\u043b\u0430\u0435\u043c     # \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u044b\u0435 \u0440\u0430\u0437\u043c\u0435\u0440\u044b, \u043c\u044b \u0434\u043e\u043b\u0436\u043d\u044b \u0437\u0430\u0434\u0430\u0442\u044c \u0432 size_hint     # \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0432 None, \u043f\u043e\u0441\u043b\u0435 \u0447\u0435\u0433\u043e \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u0444\u0438\u043a\u0441\u0438\u0440\u043e\u0432\u0430\u043d\u044b\u0439 \u0440\u0430\u0437\u043c\u0435\u0440.     # \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0443\u043a\u0430\u0436\u0435\u043c \u0448\u0438\u0440\u0438\u043d\u0443 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f:     #     # size_hint_x: None     # width: 250     #     # \u0438\u043b\u0438 \u0432\u044b\u0441\u043e\u0442\u0443     #     # size_hint_y: None     # height: 50     #     # \u0438\u043b\u0438, \u043a\u0430\u043a \u0432 \u043a\u043e\u0434\u0435 Activity, \u0438 \u0448\u0438\u0440\u0438\u043d\u0443 \u0438 \u0432\u044b\u0441\u043e\u0442\u0443 \u0441\u0440\u0430\u0437\u0443.     # \u041f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440 size_hint \u0438\u043c\u0435\u0435\u0442 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f (1, 1),     # \u0442\u043e \u0435\u0441\u0442\u044c, \u0437\u0430\u043d\u0438\u043c\u0430\u0435\u0442 \u0432\u0441\u044e \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u0443\u044e \u0435\u043c\u0443 \u0432 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0435 \u043f\u043b\u043e\u0449\u0430\u0434\u044c.     size_hint: None, None     size: dp(150), dp(150)     # \u041e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0435 \u043f\u043e\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u0432\u0438\u0434\u0436\u0435\u0442\u0430 \u043e\u0442 \u0446\u0435\u043d\u0440\u0430 \u043f\u043e \u043e\u0441\u0438 'x'     # \u0422\u0430\u043a\u0436\u0435 \u0435\u0441\u0442\u044c '\u0436\u0435\u0441\u0442\u0441\u043a\u043e\u0435' \u043f\u043e\u043b\u043e\u0436\u0435\u043d\u0438\u0435, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0437\u0430\u0434\u0430\u0435\u0442\u0441\u044f \u0432 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0435     # pos, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, pos: 120, 90.     pos_hint: {'center_x': .5}<\/code><\/pre>\n<p>  <\/p>\n<p>\u0421 \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u043c\u0438 \u043f\u043e\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u043c\u0438 \u0438 \u0440\u0430\u0437\u043c\u0435\u0440\u0430\u043c\u0438 \u0432\u0438\u0434\u0436\u0435\u0442\u0430 \u043c\u043e\u0436\u0435\u0442\u0435 \u043f\u043e\u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043d\u0430 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u043d\u0438\u0436\u0435:<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">from kivy.app import App from kivy.lang import Builder  Activity = ''' FloatLayout:      Button:         text: &quot;We Will&quot;         pos: 100, 100         size_hint: .2, .4      Button:         text: &quot;Wee Wiill&quot;         pos: 280, 200         size_hint: .4, .2      Button:         text: &quot;ROCK YOU!!&quot;         pos_hint: {'x': .3, 'y': .6}         size_hint: .5, .2 '''  class Program(App):     def build(self):         return Builder.load_string(Activity)  if __name__ in ('__main__', '__android__'):     Program().run()<\/code><\/pre>\n<p>  <\/p>\n<p>\u0414\u0430\u043b\u0435\u0435 \u043f\u043e \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u0430\u043c:<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">Label:     \u2026      # \u0423\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043b\u0438 markdown \u0442\u0435\u0433\u0438 \u0432 \u0442\u0435\u043a\u0441\u0442\u0435     # \u0438\u043b\u0438 \u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c as is.     # \u041f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u043c\u044b\u0445 \u0442\u0435\u0433\u043e\u0432 \u043d\u0435\u043c\u043d\u043e\u0433\u043e:     # [b][\/b]     # [i][\/i]     # [u][\/u]     # [s][\/s]     # [font=&lt;str&gt;][\/font]     # [size=&lt;integer&gt;][\/size]     # [color=#&lt;color&gt;][\/color]     # [ref=&lt;str&gt;][\/ref]     # [anchor=&lt;str&gt;]     # [sub][\/sub]     # [sup][\/sup]     markup: True     # \u041e\u0431\u043b\u0430\u0441\u0442\u044c, \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0438\u0432\u0430\u044e\u0449\u0430\u044f \u0442\u0435\u043a\u0441\u0442.     text_size: dp(self.size[0] - 10), self.size[1]     # \u0412\u0435\u0440\u0442\u0438\u043a\u0430\u043b\u044c\u043d\u043e\u0435 \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u0435 \u0442\u0435\u043a\u0441\u0442\u0430:     # 'bottom', 'middle', 'center' \u0438\u043b\u0438 'top'.     valign: 'top'<\/code><\/pre>\n<p>  <\/p>\n<p>\u0421 \u043e\u0431\u043b\u0430\u0441\u0442\u044c\u044e, \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0438\u0432\u0430\u044e\u0449\u0443\u044e \u0442\u0435\u043a\u0441\u0442, \u043c\u043e\u0436\u0435\u0442\u0435 \u043f\u043e\u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043d\u0430 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u043d\u0438\u0436\u0435:<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">from kivy.app import App  from kivy.uix.label import Label   class LabelTextSizeTest(App):      def build(self):          return Label(              text='\u041e\u0431\u043b\u0430\u0441\u0442\u044c \u0442\u0435\u043a\u0441\u0442\u0430, \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u043d\u0430\u044f \u043f\u0440\u044f\u043c\u043e\u0443\u0433\u043e\u043b\u044c\u043d\u0438\u043a\u043e\u043c\\n' * 50,              text_size=(250, 300),  # \u043f\u043e\u044d\u043a\u0441\u043f\u0435\u0440\u0435\u043c\u0435\u043d\u0442\u0438\u0440\u0443\u0439\u0442\u0435 \u0441 \u044d\u0442\u0438\u043c\u0438 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f\u043c\u0438              line_height=1.5          )   if __name__ == '__main__':      LabelTextSizeTest().run()<\/code><\/pre>\n<p>  <\/p>\n<p>\u0414\u0430\u043b\u0435\u0435 \u043f\u043e Activity:<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">Widget:<\/code><\/pre>\n<p>  <\/p>\n<p>\u0412 \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u043a\u0430\u043a \u0430\u043d\u0430\u043b\u043e\u0433 \u0432 Java:<\/p>\n<p>  <\/p>\n<pre><code class=\"xml\">&lt;Space     android:layout_width=&quot;match_parent&quot;     android:layout_height=&quot;0dp&quot;     android:layout_weight=&quot;1&quot;\/&gt;<\/code><\/pre>\n<p>  <\/p>\n<p>\u0414\u0430\u043b\u0435\u0435:<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">BoxLayout:      MDFlatButton:         text: app.data.string_lang_create_account         # \u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 Activity \u0441 \u0438\u043c\u0435\u043d\u0435\u043c 'Create account'.         on_release: app.screen_root_manager.current = 'Create account'      MDFlatButton:         text: app.data.string_lang_own_provider         # \u0414\u043b\u044f \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u0441\u0432\u043e\u0435\u0433\u043e \u0446\u044b\u0432\u0435\u0442\u0430 \u0442\u0435\u043a\u0441\u0442\u0430 \u043d\u0430 \u043a\u043d\u043e\u043f\u043a\u0435         # \u0434\u0430\u0439\u0442\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0443 theme_text_color \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 'Custom'         # \u0438 \u0434\u0430\u043b\u0435\u0435 \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0439\u0442\u0435 \u0446\u0432\u0435\u0442 - text_color: .7, .2, .2, 1         theme_text_color: 'Primary'         on_release:             # \u0412\u044b\u0437\u043e\u0432 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u0438\u0437 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0430 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u044b.             # \u041c\u043e\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u0440\u0435\u0430\u043b\u0438\u0437\u043e\u0432\u0430\u0442\u044c \u043f\u0440\u044f\u043c\u043e \u0437\u0434\u0435\u0441\u044c, \u043d\u043e, \u043a\u043e\u0441\u043a\u043e\u043b\u044c\u043a\u0443             # \u044f \u0441\u0447\u0438\u0442\u0430\u044e, \u0447\u0442\u043e \u043b\u0438\u0448\u043d\u0438\u0439 \u043a\u043e\u0434 \u0432 \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0435 \u043e\u0442\u0432\u043b\u0435\u043a\u0430\u0435\u0442             # \u043e\u0442 \u043f\u043e\u043d\u0438\u043c\u0430\u043d\u0438\u044f \u0434\u0435\u0440\u0435\u0432\u0430 Activity, \u0431\u044b\u043b\u043e \u0440\u0435\u0448\u0435\u043d\u043e \u0435\u0433\u043e \u0432\u044b\u043d\u0435\u0441\u0442\u0438.             app.delete_textfield_and_set_check_in_addaccountroot()             app.screen_root_manager.current = 'Add account own provider'<\/code><\/pre>\n<p>  <\/p>\n<p>\u0422\u0430\u043a. \u0423 \u043d\u0430\u0441 \u043e\u0441\u0442\u0430\u043b\u0441\u044f \u043d\u0435 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043d\u043d\u044b\u043c \u0435\u0449\u0435 \u043e\u0434\u0438\u043d \u0432\u043e\u043f\u0440\u043e\u0441. \u0412\u0435\u0440\u043d\u0435\u043c\u0441\u044f \u043a \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0435 Activity StartScreen:<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">        Introduction:             id: introduction             # \u0412\u044b\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043f\u0440\u0438 \u0432\u044b\u0432\u043e\u0434\u0435 \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e Activity \u043d\u0430 \u044d\u043a\u0440\u0430\u043d.             on_enter: self._on_enter(action_bar, app)<\/code><\/pre>\n<p>  <\/p>\n<p>\u0422\u043e \u0435\u0441\u0442\u044c, \u043a\u0430\u043a \u0442\u043e\u043b\u044c\u043a\u043e Activity \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0432\u0435\u0434\u0435\u043d\u043e \u043d\u0430 \u044d\u043a\u0440\u0430\u043d, \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u0441\u044f \u043a\u043e\u0434 \u0441\u043e\u0431\u044b\u0442\u0438\u044f on_enter. \u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c, \u0447\u0442\u043e \u0434\u0435\u043b\u0430\u0435\u0442 \u043c\u0435\u0442\u043e\u0434 _on_enter \u0432 \u0431\u0430\u0437\u043e\u0432\u043e\u043c \u043a\u043b\u0430\u0441\u0441\u0435 Activity (\u0444\u0430\u0439\u043b <i>libs\/uix\/kv\/activity\/baseclass\/introduction.py<\/i>):<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/e5e\/f5d\/8ed\/e5ef5d8ed3284ba991a98dd950e17de1.png\" \/><\/div>\n<p>  <\/p>\n<pre><code class=\"python\">from kivy.uix.screenmanager import Screen  class Introduction(Screen):     def _on_enter(self, instance_toolbar, instance_program):         instance_toolbar.left_action_items = []         instance_toolbar.title = instance_program.title<\/code><\/pre>\n<p>  <\/p>\n<p>\u041c\u0435\u0442\u043e\u0434 _on_enter \u0443\u0434\u0430\u043b\u044f\u0435\u0442 \u0438\u043a\u043e\u043d\u043a\u0443 \u0432 ToolBar \u0441\u043b\u0435\u0432\u0430, \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u044f \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 left_action_items, \u043a\u0430\u043a \u043f\u0443\u0441\u0442\u043e\u0439 \u0441\u043f\u0438\u0441\u043e\u043a, \u0438 \u043c\u0435\u043d\u044f\u0435\u0442 \u043f\u043e\u0434\u043f\u0438\u0441\u044c ToolBar \u043d\u0430 \u0438\u043c\u044f \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f.<\/p>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u043f\u0440\u0438\u043c\u0435\u0440\u0430 \u043f\u0440\u0438\u0432\u0435\u0434\u0443 \u0443\u043f\u0440\u0430\u0432\u043b\u044f\u044e\u0449\u0438\u0439 \u043a\u043b\u0430\u0441\u0441 \u0438\u0437 Java \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b\u0430:<\/p>\n<p>  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">WelcomeActivity<\/b><\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"java\">package eu.siacs.conversations.ui;   import android.app.ActionBar;  import android.app.Activity;  import android.content.Intent;  import android.content.pm.ActivityInfo;  import android.os.Bundle;  import android.view.View;  import android.widget.Button;   import eu.siacs.conversations.R;   public class WelcomeActivity extends Activity {       @Override      protected void onCreate(final Bundle savedInstanceState) {          if (getResources().getBoolean(R.bool.portrait_only)) {              setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_PORTRAIT);          }          final ActionBar ab = getActionBar();          if (ab != null) {              ab.setDisplayShowHomeEnabled(false);              ab.setDisplayHomeAsUpEnabled(false);          }          super.onCreate(savedInstanceState);          setContentView(R.layout.welcome);          final Button createAccount = (Button) findViewById(R.id.create_account);          createAccount.setOnClickListener(new View.OnClickListener() {              @Override              public void onClick(View v) {                  Intent intent = new Intent(WelcomeActivity.this, MagicCreateActivity.class);                  intent.addFlags(Intent.FLAG_ACTIVITY_NO_ANIMATION);                  startActivity(intent);              }          });          final Button useOwnProvider = (Button) findViewById(R.id.use_own_provider);          useOwnProvider.setOnClickListener(new View.OnClickListener() {              @Override              public void onClick(View v) {                  startActivity(new Intent(WelcomeActivity.this, EditAccountActivity.class));              }          });       }   }<\/code><\/pre>\n<\/div>\n<\/div>\n<p>  <\/p>\n<p>\u0422\u0430\u043a. \u0421 \u044d\u0442\u0438\u043c \u0440\u0430\u0437\u043e\u0431\u0440\u0430\u043b\u0438\u0441\u044c. \u0423 \u043d\u0430\u0441 \u0435\u0441\u0442\u044c Activity \u0438 \u0434\u0432\u0435 \u044e\u0437\u0430\u0431\u0435\u043b\u044c\u043d\u044b\u0435 \u043a\u043d\u043e\u043f\u043a\u0438. \u041d\u0430\u0447\u043d\u0435\u043c \u0441 \u043f\u0435\u0440\u0432\u043e\u0439:<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/c2e\/88a\/b9e\/c2e88ab9e71646e796333c8d67d57fa1.png\" \/><\/div>\n<p>  <\/p>\n<p>\u041f\u0440\u0438 \u043a\u043b\u0438\u043a\u0435 \u043d\u0430 \u043a\u043d\u043e\u043f\u043a\u0443 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0432\u0435\u0434\u0435\u043d\u043e Activity CreateAccount:<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">MDFlatButton:     text: app.data.string_lang_create_account     on_release: app.screen_root_manager.current = 'Create account'<\/code><\/pre>\n<p>  <\/p>\n<p>Activity CreateAccount (Kivy):<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/370\/697\/810\/370697810da940c581c0ce4ad841e05d.png\" \/><\/div>\n<p>  <\/p>\n<p>Activity CreateAccount (original):<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/883\/5d0\/268\/8835d0268c724b89834e24e07b5d5c87.png\" \/><\/div>\n<p>  <\/p>\n<p>\u041e\u0442\u043a\u0440\u043e\u0435\u043c Activity CreateAccount \u043d\u0430\u0448\u0435\u0433\u043e \u043f\u0440\u043e\u0435\u0442\u0430:<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/72e\/42a\/eef\/72e42aeef02c4ad3889ff89a9219b505.png\" \/><\/div>\n<p>  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">createaccount.kv<\/b><\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"python\">#: kivy 1.9.1  #: import SingleLineTextField kivymd.textfields.SingleLineTextField  #: import snackbar kivymd.snackbar   # Activity \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430\u0446\u0438\u0438 \u043d\u043e\u0432\u043e\u0433\u043e \u0430\u043a\u043a\u0430\u0443\u043d\u0442\u0430.  # \u0412\u044b\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043f\u043e \u0441\u043e\u0431\u044b\u0442\u0438\u044e \u043a\u043d\u043e\u043f\u043a\u0438 'Create account' \u0441\u0442\u0430\u0440\u0442\u043e\u0432\u043e\u0433\u043e Activity.   &lt;CreateAccount&gt;:      name: 'Create account'       BoxLayout:          orientation: 'vertical'          padding: dp(5), dp(20)           Image:              source: 'data\/images\/logo.png'              size_hint: None, None              size: dp(150), dp(150)              pos_hint: {'center_x': .5}           Label:              text: app.data.string_lang_enter_user_name              markup: True              color: app.data.text_color              text_size: dp(self.size[0] - 10), self.size[1]              size_hint_y: None              valign: 'top'              height: dp(215)           Widget:              size_hint_y: None              height: dp(10)           SingleLineTextField:              id: username              hint_text: 'Username'              message: 'username@conversations.im'              message_mode: 'persistent'              on_text: app.check_len_login_in_textfield(self)           Widget:           BoxLayout:               MDFlatButton:                  text: app.data.string_lang_next                  on_release:                      if username.text == '' or username.text.isspace(): \\                      snackbar.make(app.data.string_lang_not_valid_username)                      else: app.screen_root_manager.current = 'Add account'<\/code><\/pre>\n<\/div>\n<\/div>\n<p>  <\/p>\n<p>\u041d\u0438\u0447\u0435\u0433\u043e \u043d\u043e\u0432\u043e\u0433\u043e \u0437\u0434\u0435\u0441\u044c \u0434\u043b\u044f \u0432\u0430\u0441 \u043d\u0435\u0442, \u043d\u0430 \u0441\u0445\u0435\u043c\u0435 \u043d\u0438\u0436\u0435 \u043f\u0440\u0438\u0432\u0435\u0434\u0443 \u0442\u043e\u043b\u044c\u043a\u043e \u0442\u043e, \u0447\u0442\u043e \u043c\u044b \u0435\u0449\u0435 \u043d\u0435 \u043e\u0431\u0441\u0443\u0436\u0434\u0430\u043b\u0438:<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/c94\/427\/0a8\/c944270a8d98495f8adda04c115e58e1.png\" \/><\/div>\n<p>  <\/p>\n<p>\u0417\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u043a \u0438 \u0438\u043a\u043e\u043d\u043a\u0430 \u0432 ToolBar \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u0432 \u0431\u0430\u0437\u043e\u0432\u043e\u043c \u043a\u043b\u0430\u0441\u0441\u0435 Activity CreateAccount \u0432 \u043c\u0435\u0442\u043e\u0434\u0435 _on_enter:<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">from kivy.uix.screenmanager import Screen   class CreateAccount(Screen):       def _on_enter(self, instance_toolbar, instance_program, instance_screenmanager):          instance_toolbar.title = instance_program.data.string_lang_create_account          instance_toolbar.left_action_items = [              ['chevron-left', lambda x: instance_program.back_screen(                  instance_screenmanager.previous())]          ]<\/code><\/pre>\n<p>  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">\u041e\u0440\u0438\u0433\u0438\u043d\u0430\u043b\u044c\u043d\u044b\u0439 \u0443\u043f\u0440\u0430\u0432\u043b\u044f\u044e\u0449\u0438\u0439 \u043a\u043b\u0430\u0441\u0441 MagicCreateActivity \u043d\u0430 Java<\/b><\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"python\">package eu.siacs.conversations.ui;   import android.content.Intent;  import android.content.pm.ActivityInfo;  import android.os.Bundle;  import android.text.Editable;  import android.text.TextWatcher;  import android.view.View;  import android.widget.Button;  import android.widget.EditText;  import android.widget.TextView;  import android.widget.Toast;   import java.security.SecureRandom;   import eu.siacs.conversations.Config;  import eu.siacs.conversations.R;  import eu.siacs.conversations.entities.Account;  import eu.siacs.conversations.xmpp.jid.InvalidJidException;  import eu.siacs.conversations.xmpp.jid.Jid;   public class MagicCreateActivity extends XmppActivity implements TextWatcher {       private TextView mFullJidDisplay;      private EditText mUsername;      private SecureRandom mRandom;       private static final String CHARS = &quot;ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456780+-\/#$!?&quot;;      private static final int PW_LENGTH = 10;       @Override      protected void refreshUiReal() {       }       @Override      void onBackendConnected() {       }       @Override      protected void onCreate(final Bundle savedInstanceState) {          if (getResources().getBoolean(R.bool.portrait_only)) {              setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_PORTRAIT);          }          super.onCreate(savedInstanceState);          setContentView(R.layout.magic_create);          mFullJidDisplay = (TextView) findViewById(R.id.full_jid);          mUsername = (EditText) findViewById(R.id.username);          mRandom = new SecureRandom();          Button next = (Button) findViewById(R.id.create_account);          next.setOnClickListener(new View.OnClickListener() {              @Override              public void onClick(View v) {                  String username = mUsername.getText().toString();                  if (username.contains(&quot;@&quot;) || username.length() &lt; 3) {                      mUsername.setError(getString(R.string.invalid_username));                      mUsername.requestFocus();                  } else {                      mUsername.setError(null);                      try {                          Jid jid = Jid.fromParts(username.toLowerCase(), Config.MAGIC_CREATE_DOMAIN, null);                          Account account = xmppConnectionService.findAccountByJid(jid);                          if (account == null) {                              account = new Account(jid, createPassword());                              account.setOption(Account.OPTION_REGISTER, true);                              account.setOption(Account.OPTION_DISABLED, true);                              account.setOption(Account.OPTION_MAGIC_CREATE, true);                              xmppConnectionService.createAccount(account);                          }                          Intent intent = new Intent(MagicCreateActivity.this, EditAccountActivity.class);                          intent.putExtra(&quot;jid&quot;, account.getJid().toBareJid().toString());                          intent.putExtra(&quot;init&quot;, true);                          intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TASK);                          Toast.makeText(MagicCreateActivity.this, R.string.secure_password_generated, Toast.LENGTH_SHORT).show();                          startActivity(intent);                      } catch (InvalidJidException e) {                          mUsername.setError(getString(R.string.invalid_username));                          mUsername.requestFocus();                      }                  }              }          });          mUsername.addTextChangedListener(this);      }       private String createPassword() {          StringBuilder builder = new StringBuilder(PW_LENGTH);          for(int i = 0; i &lt; PW_LENGTH; ++i) {              builder.append(CHARS.charAt(mRandom.nextInt(CHARS.length() - 1)));          }          return builder.toString();      }       @Override      public void beforeTextChanged(CharSequence s, int start, int count, int after) {       }       @Override      public void onTextChanged(CharSequence s, int start, int before, int count) {       }       @Override      public void afterTextChanged(Editable s) {          if (s.toString().trim().length() &gt; 0) {              try {                  mFullJidDisplay.setVisibility(View.VISIBLE);                  Jid jid = Jid.fromParts(s.toString().toLowerCase(), Config.MAGIC_CREATE_DOMAIN, null);                  mFullJidDisplay.setText(getString(R.string.your_full_jid_will_be, jid.toString()));              } catch (InvalidJidException e) {                  mFullJidDisplay.setVisibility(View.INVISIBLE);              }           } else {              mFullJidDisplay.setVisibility(View.INVISIBLE);          }      }  }<\/code><\/pre>\n<\/div>\n<\/div>\n<p>  <\/p>\n<p>\u2026 \u0432\u044b\u0437\u0432\u0430\u043d\u043d\u043e\u043c \u043f\u043e \u0441\u043e\u0431\u044b\u0442\u0438\u044e on_enter (\u043a\u043e\u0433\u0434\u0430 Activity \u0431\u044b\u043b\u043e \u0432\u044b\u0432\u0435\u0434\u0435\u043d\u043e \u043d\u0430 \u044d\u043a\u0440\u0430\u043d):<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">&lt;StartScreen&gt;:      \u2026      ScreenManager:          \u2026          CreateAccount:              on_enter: self._on_enter(action_bar, app, root_manager)           \u2026<\/code><\/pre>\n<p>  <\/p>\n<p>\u0422\u0430\u043a\u0436\u0435 \u043d\u0430\u0441 \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u0443\u0435\u0442 \u0441\u043e\u0431\u044b\u0442\u0438\u0435 on_text, \u043a\u043e\u0433\u0434\u0430 \u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u0442\u0435\u043a\u0441\u0442\u043e\u0432\u043e\u0433\u043e \u043f\u043e\u043b\u044f:<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">&lt;CreateAccount&gt;:     \u2026          SingleLineTextField:              \u2026              on_text: app.check_len_login_in_textfield(self)<\/code><\/pre>\n<p>  <\/p>\n<p>\u041c\u0435\u0442\u043e\u0434 check_len_login_in_textfield \u0438\u0437 \u0433\u043b\u0430\u0432\u043d\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f:<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/9ff\/551\/520\/9ff551520fcc4daca2d1f01160822392.png\" \/><\/div>\n<p>  <\/p>\n<pre><code class=\"python\">def check_len_login_in_textfield(self, instance_textfield):     # \u0415\u0441\u043b\u0438 \u0432\u0432\u0435\u0434\u0435\u043d\u043d\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u0432 \u043f\u043e\u043b\u0435 \u0431\u043e\u043b\u044c\u0448\u0435 20 \u0441\u0438\u043c\u0432\u043e\u043b\u043e\u0432.     if len(instance_textfield.text) &gt; 20:             instance_textfield.text = instance_textfield.text[:20]     # \u0418\u0437\u043c\u0435\u043d\u044f\u0435\u043c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043f\u043e\u0434\u043f\u0438\u0441\u0438 \u043f\u043e\u0434 \u0442\u0435\u043a\u0441\u0442\u043e\u0432\u044b\u043c \u043f\u043e\u043b\u0435\u043c \u0441\u043e\u0433\u043b\u0430\u0441\u043d\u043e     # \u0432\u0432\u0435\u0434\u0435\u043d\u043d\u044b\u043c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u043c \u0432 \u0442\u0435\u043a\u0441\u0442\u043e\u0432\u043e\u0435 \u043f\u043e\u043b\u0435 \u0434\u0430\u043d\u043d\u044b\u043c.     instance_textfield.message = 'username@conversations.im' \\         if instance_textfield.text == '' \\         else '{}@conversations.im'.format(instance_textfield.text)<\/code><\/pre>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/cb4\/396\/358\/cb439635873b4ad2b4356b95df65812f.png\" \/><\/div>\n<p>  <\/p>\n<p>\u0418\u0442\u0430\u043a, \u0435\u0441\u043b\u0438 \u0434\u0430\u043d\u043d\u044b\u0435 \u0442\u0435\u043a\u0441\u0442\u043e\u0432\u043e\u0433\u043e \u043f\u043e\u043b\u044f \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u044b, \u0432\u044b\u0432\u043e\u0434\u0438\u043c Activity AddAccount:<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">MDFlatButton:     \u2026      on_release:         if \u2026             \u2026         else: app.screen_root_manager.current = 'Add account'<\/code><\/pre>\n<p>  <\/p>\n<p>\u0412 \u043f\u0440\u043e\u0442\u0438\u0432\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u0432\u044b\u0432\u043e\u0434\u0438\u043c \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435 \u043e \u043d\u0435\u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u044b\u0445 \u0434\u0430\u043d\u043d\u044b\u0445:<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">MDFlatButton:     \u2026      on_release:         if username.text == '' or username.text.isspace(): \\         snackbar.make(app.data.string_lang_not_valid_username)         \u2026<\/code><\/pre>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/781\/297\/352\/781297352bcc4dceae1d46202811eab8.png\" \/><\/div>\n<p>  <\/p>\n<p>\u041d\u0443, \u0438, \u043d\u0430\u043a\u043e\u043d\u0435\u0446, \u0443 \u043d\u0430\u0441 \u043e\u0441\u0442\u0430\u043b\u043e\u0441\u044c \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0435\u0435 Activity&#8230;<\/p>\n<p>  <\/p>\n<p>Original:<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/521\/f8e\/ff1\/521f8eff1d604a1b944c76a11146cdc0.png\" \/><\/div>\n<p>  <\/p>\n<p>Kivy:<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/f8f\/269\/2e9\/f8f2692e9fd94005928b0aab1ca2daba.png\" \/><\/div>\n<p>  <\/p>\n<p>\u0414\u0430, \u044d\u0442\u043e \u043e\u0434\u043d\u043e Activity. \u0418\u0437 \u0432\u0442\u043e\u0440\u043e\u0433\u043e, \u043f\u0440\u0438 \u0435\u0433\u043e \u0432\u044b\u0432\u043e\u0434\u0435 \u043d\u0430 \u044d\u043a\u0440\u0430\u043d, \u043c\u044b \u043f\u0440\u043e\u0441\u0442\u043e \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u043d\u043e \u0443\u0434\u0430\u043b\u044f\u0435\u043c \u00ab\u043b\u0438\u0448\u043d\u0435\u0435\u00bb \u0442\u0435\u043a\u0441\u0442\u043e\u0432\u043e\u0435 \u043f\u043e\u043b\u0435.<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">&lt;StartScreen&gt;:     \u2026      ScreenManager:         \u2026          AddAccount:             id: add_account             on_enter: self._on_enter(action_bar, app)             on_leave: action_bar.title = app.data.string_lang_create_account         AddAccountOwn:             id: add_account_own_provider             on_enter: self._on_enter(action_bar, app, root_manager)             on_leave: action_bar.title = app.title; action_bar.left_action_items = []<\/code><\/pre>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/7ca\/c36\/181\/7cac36181711460dae6e514c0a89e9ea.png\" \/><\/div>\n<p>  <\/p>\n<p>\u0412 \u0444\u0430\u0439\u043b\u0430\u0445 \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0438 \u043c\u044b \u0441\u043e\u0437\u0434\u0430\u043b\u0438 \u0448\u0430\u0431\u043b\u043e\u043d\u044b Activity:<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">&lt;AddAccount&gt;:     name: 'Add account'      AddAccountRoot:         id: add_account_root<\/code><\/pre>\n<p>  <\/p>\n<pre><code class=\"python\">&lt;AddAccountOwn&gt;:     name: 'Add account own provider'      AddAccountRoot:         id: add_account_root<\/code><\/pre>\n<p>  <\/p>\n<p>\u00ab\u0443\u043d\u0430\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0432\u00bb \u0438\u0445 \u043e\u0442 Activity AddAccountRoot:<\/p>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/d12\/205\/4af\/d122054af020424bb0663ceccafdd6e8.png\" \/><\/div>\n<p>  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">Activity AddAccountRoot<\/b><\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"python\">#: kivy 1.9.1 #: import progress libs.uix.dialogs.dialog_progress #: import MDFlatButton kivymd.button.MDFlatButton #: import SingleLineTextField kivymd.textfields.SingleLineTextField #: import MDCheckbox kivymd.selectioncontrols.MDCheckbox  # Activity \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430\u0446\u0438\u0438 \u043d\u043e\u0432\u043e\u0433\u043e \u0430\u043a\u043a\u0430\u0443\u043d\u0442\u0430 \u043d\u0430 \u0441\u0435\u0440\u0432\u0435\u0440\u0435.  &lt;AddAccountRoot@BoxLayout&gt;:     canvas:         Color:             rgba: app.data.background         Rectangle:             size: self.size             pos: self.pos      orientation: 'vertical'     padding: dp(10), dp(10)      BoxLayout:         id: box         canvas:             Color:                 rgba: app.data.rectangle             Rectangle:                 size: self.size                 pos: self.pos             Color:                 rgba: app.data.list_color             Rectangle:                 size: self.size[0] - 2, self.size[1] - 2                 pos: self.pos[0] + 1, self.pos[1] + 1          orientation: 'vertical'         size_hint_y: None         padding: dp(10), dp(10)         spacing: dp(15)         height: app.window.height \/\/ 2          SingleLineTextField:             id: username             hint_text: 'Username'             on_text:                 if self.message != '': app.check_len_login_in_textfield(self)          SingleLineTextField:             id: password             hint_text: 'Password'             password: True          BoxLayout:             id: box_check             size_hint_y: None             height: dp(40)              MDCheckbox:                 id: check                 size_hint: None, None                 size: dp(40), dp(40)                 active: True                 on_state:                     if self.active: box.add_widget(confirm_password)                     else: box.remove_widget(confirm_password)                     if username.message != '': confirm_password.hint_text = 'Confirm password'              Label:                 text: 'Register new account on server'                 valign: 'middle'                 color: app.data.text_color                 size_hint_x: .9                 text_size: self.size[0] - 10, self.size[1]          SingleLineTextField:             id: confirm_password             password: True          Widget:      Widget:      BoxLayout:         padding: dp(0), dp(10)          MDFlatButton:             text: app.data.string_lang_cancel             theme_text_color: 'Primary'             on_release:                 if app.screen.ids.root_manager.current == 'Add account own provider': \\                 app.screen.ids.root_manager.current = 'Start screen'; \\                 app.screen.ids.action_bar.title = app.title                 else: \\                 app.screen.ids.root_manager.current = 'Create account';                 app.screen.ids.action_bar.title = app.data.string_lang_create_account          MDFlatButton:             text: app.data.string_lang_next             on_release:                 instance_progress, instance_text_wait = \\                 progress(text_wait=app.data.string_lang_text_wait.format(app.data.text_color_hex), \\                 events_callback=lambda x: instance_progress.dismiss())<\/code><\/pre>\n<\/div>\n<\/div>\n<p>  <\/p>\n<div style=\"text-align:center;\"><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/917\/fb4\/059\/917fb405982444d38fd23aea716be46e.png\" \/><\/div>\n<p>  <\/p>\n<p>\u041b\u044e\u0431\u043e\u0439 \u0432\u0438\u0434\u0436\u0435\u0442 \u0432 Kivy \u0438\u043c\u0435\u0435\u0442 \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u043e <i>canvas<\/i>. \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0440\u0438\u0441\u043e\u0432\u0430\u0442\u044c \u043d\u0430 \u043d\u0435\u043c \u0432\u0441\u0435, \u0447\u0442\u043e \u0443\u0433\u043e\u0434\u043d\u043e: \u043e\u0442 \u043f\u0440\u0438\u043c\u0438\u0442\u0438\u0432\u043d\u044b\u0445 \u0444\u0438\u0433\u0443\u0440 \u0434\u043e \u043d\u0430\u043a\u043b\u0430\u0434\u044b\u0432\u0430\u043d\u0438\u044f \u0442\u0435\u043a\u0441\u0442\u0443\u0440. \u0412 \u0434\u0430\u043d\u043d\u043e\u043c Activity \u044f \u043d\u0430\u0440\u0438\u0441\u043e\u0432\u0430\u043b \u043f\u0440\u044f\u043c\u043e\u0443\u0433\u043e\u043b\u044c\u043d\u0438\u043a \u0441\u043d\u0430\u0447\u0430\u043b\u0430 \u0441\u0435\u0440\u044b\u043c \u0446\u0432\u0435\u0442\u043e\u043c, \u0437\u0430\u0442\u0435\u043c \u0441\u0432\u0435\u0440\u0445\u0443 \u043d\u0430\u043b\u043e\u0436\u0438\u043b \u043f\u0440\u044f\u043c\u043e\u0443\u0433\u043e\u043b\u044c\u043d\u0438\u043a \u0431\u0435\u043b\u043e\u0433\u043e \u0446\u0432\u0435\u0442\u0430, \u043d\u043e \u043c\u0435\u043d\u044c\u0448\u0438\u043c \u0440\u0430\u0437\u043c\u0435\u0440\u043e\u043c (\u0440\u0438\u0441\u043e\u0432\u0430\u0442\u044c \u043f\u0440\u043e\u0441\u0442\u043e \u043b\u0438\u043d\u0438\u0438, \u0432\u044b\u0447\u0438\u0441\u043b\u044f\u044f \u0438\u0445 \u043a\u043e\u043e\u0440\u0434\u0438\u043d\u0430\u0442\u044b \u0431\u044b\u043b\u043e \u043b\u0435\u043d\u044c). \u041f\u043e\u043b\u0443\u0447\u0438\u043b\u0430\u0441\u044c \u0440\u0430\u043c\u043a\u0430.<\/p>\n<p>  <\/p>\n<p>\u041f\u0440\u0438 \u0430\u043a\u0442\u0438\u0432\u0430\u0446\u0438\u0438 \u0447\u0435\u043a\u0431\u043e\u043a\u0441\u0430 \u043d\u0438\u0436\u043d\u0435\u0435 \u0442\u0435\u043a\u0441\u0442\u043e\u0432\u043e\u0435 \u043f\u043e\u043b\u0435 \u0443\u0434\u0430\u043b\u044f\u0435\u0442\u0441\u044f:<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">MDCheckbox:     \u2026      on_state:         # True\/False \u2014 \u0430\u043a\u0442\u0438\u0432\u0435\u043d\/\u043d\u0435 \u0430\u043a\u0442\u0438\u0432\u0435\u043d         if self.active: box.add_widget(confirm_password)         else: box.remove_widget(confirm_password)          \u2026<\/code><\/pre>\n<p>  <\/p>\n<p>\u041a\u043e\u0433\u0434\u0430 Activity AddAccount \u0432\u044b\u0432\u043e\u0434\u0438\u0442\u0441\u044f \u043d\u0430 \u044d\u043a\u0440\u0430\u043d, \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u043c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0442\u0435\u043a\u0441\u0442\u043e\u0432\u044b\u0445 \u043f\u043e\u043b\u0435\u0439 \u0438 \u0438\u0445 \u0444\u043e\u043a\u0443\u0441:<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">from kivy.uix.screenmanager import Screen from kivy.clock import Clock  class AddAccount(Screen):      def _on_enter(self, instance_toolbar, instance_program):         instance_toolbar.title = self.name         self.ids.add_account_root.ids.username.focus = True         # \u0412\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u0435\u0434\u0438\u043d\u043e\u0436\u0434\u044b \u0447\u0435\u0440\u0435\u0437 \u0437\u0430\u0434\u0430\u043d\u043d\u044b\u0439 \u0438\u043d\u0442\u0435\u0440\u0432\u0430\u043b \u0432\u0440\u0435\u043c\u0435\u043d\u0438.         Clock.schedule_once(instance_program.set_text_on_textfields, .5)<\/code><\/pre>\n<p>  <\/p>\n<p>\u0413\u043b\u0430\u0432\u043d\u044b\u0439 \u043a\u043b\u0430\u0441\u0441 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u044b:<\/p>\n<p>  <\/p>\n<pre><code class=\"python\">def set_focus_on_textfield(self, interval=0, instance_textfield=None, focus=True):     if instance_textfield: instance_textfield.focus = focus  def set_text_on_textfields(self, interval):     add_account_root = self.screen.ids.add_account.ids.add_account_root     field_username = add_account_root.ids.username     field_password = add_account_root.ids.password     field_confirm_password = add_account_root.ids.confirm_password     field_username.text = self.screen.ids.create_account.ids.username.text.lower()     field_password.focus = True     password = self.generate_password()     field_password.text = password     field_confirm_password.text = password      Clock.schedule_once(         lambda x: self.set_focus_on_textfield(             instance_textfield=field_password, focus=False), .5     )     Clock.schedule_once(         lambda x: self.set_focus_on_textfield(             instance_textfield=field_username), .5     )<\/code><\/pre>\n<p>  <\/p>\n<p>\u0427\u0442\u043e \u0436! \u0427\u0435\u0442\u044b\u0440\u0435 \u0437\u0430\u043f\u043b\u0430\u043d\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 Activity \u0433\u043e\u0442\u043e\u0432\u044b, \u043f\u0430\u043b\u044c\u0446\u044b \u0443\u0441\u0442\u0430\u043b\u0438, \u0433\u043e\u043b\u043e\u0432\u0430 \u0440\u0430\u0437\u0431\u043e\u043b\u0435\u043b\u0430\u0441\u044c. \u042d\u0442\u043e \u044f \u043e \u0441\u0435\u0431\u0435. \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u043d\u0430 \u0441\u0435\u0433\u043e\u0434\u043d\u044f \u043f\u043e\u043a\u0430 \u0432\u0441\u0435. \u041f\u043e\u0441\u043a\u043e\u043b\u044c\u043a\u0443 \u043d\u0435\u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e \u0432 \u0440\u0430\u043c\u043a\u0430\u0445 \u043e\u0434\u043d\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0438 \u043e\u0441\u0432\u0435\u0442\u0438\u0442\u044c \u0432\u0441\u0435 \u0432\u043e\u043f\u0440\u043e\u0441\u044b, \u043e\u043f\u0438\u0441\u0430\u0442\u044c \u0432\u0441\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u0432\u0438\u0434\u0436\u0435\u0442\u043e\u0432 Kivy \u0438 \u043d\u044e\u0430\u043d\u0441\u044b, \u043e\u043d\u0438 \u0431\u0443\u0434\u0443\u0442 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043d\u044b \u0432 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0445 \u0441\u0442\u0430\u0442\u044c\u044f\u0445, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043d\u0435 \u0441\u0442\u0435\u0441\u043d\u044f\u0439\u0442\u0435\u0441\u044c, \u0437\u0430\u0434\u0430\u0432\u0430\u0439\u0442\u0435 \u0432\u043e\u043f\u0440\u043e\u0441\u044b.<\/p>\n<p>  <\/p>\n<p>\u0421\u043a\u043e\u0440\u0435\u0435 \u0432\u0441\u0435\u0433\u043e, \u0432\u043e \u0432\u0442\u043e\u0440\u043e\u0439 \u0447\u0430\u0441\u0442\u0438 \u0441\u0442\u0430\u0442\u044c\u0438 \u0431\u0443\u0434\u0435\u0442 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043d\u0430 \u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0430 \u0441\u0430\u043c\u043e\u0433\u043e \u043f\u0440\u043e\u0435\u043a\u0442\u0430 PyConversations \u0438 \u0432\u0430\u0448\u0438 \u0432\u043e\u043f\u0440\u043e\u0441\u044b \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043f\u0435\u0440\u0432\u043e\u0439 \u0447\u0430\u0441\u0442\u0438, \u0435\u0441\u043b\u0438 \u0442\u0430\u043a\u043e\u0432\u044b\u0435 \u0431\u0443\u0434\u0443\u0442. \u0414\u043e \u0432\u0441\u0442\u0440\u0435\u0447\u0438!<\/p>\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=\"https:\/\/habrahabr.ru\/post\/314236\/\"> https:\/\/habrahabr.ru\/post\/314236\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/33d\/628\/491\/33d6284916964a4a81ff15ac7ac0ed0d.png\" align=\"left\"\/>  <\/p>\n<p>\u0411\u0443\u043a\u0432\u0430\u043b\u044c\u043d\u043e <a href=\"https:\/\/habrahabr.ru\/post\/313160\/\">\u0441\u0442\u0430\u0442\u044c\u044e<\/a> \u0442\u043e\u043c\u0443 \u043d\u0430\u0437\u0430\u0434, \u0431\u043e\u043b\u044c\u0448\u0438\u043d\u0441\u0442\u0432\u043e\u043c \u0433\u043e\u043b\u043e\u0441\u043e\u0432, \u0431\u044b\u043b\u043e \u0440\u0435\u0448\u0435\u043d\u043e \u043d\u0430\u0447\u0430\u0442\u044c \u0441\u0435\u0440\u0438\u044e \u0443\u0440\u043e\u043a\u043e\u0432 \u043f\u043e \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044e \u0430\u043d\u0430\u043b\u043e\u0433\u0430 \u043d\u0430\u0442\u0438\u0432\u043d\u043e\u0433\u043e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f, \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u043d\u043e\u0433\u043e \u0434\u043b\u044f Android \u043d\u0430 Java, \u043d\u043e \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u0430 Kivy + Python. \u0411\u0443\u0434\u0435\u0442 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043d\u043e: \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0438 \u043a\u043e\u043c\u043f\u043e\u043d\u043e\u0432\u043a\u0430 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u043e\u0432 \u0438 \u0432\u0438\u0434\u0436\u0435\u0442\u043e\u0432, \u0443\u0433\u043b\u0443\u0431\u043b\u0435\u043d\u043d\u043e\u0435 \u0438\u0441\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d\u0438\u0435 \u0442\u0435\u0445\u043d\u0438\u043a\u0438 \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0438 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u0433\u043e \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430 \u0432 Kv-Language, \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430\u043c\u0438 \u044d\u043a\u0440\u0430\u043d\u043e\u0432, \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430, \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u044e\u0449\u0430\u044f \u0434\u043e\u0441\u0442\u0443\u043f \u043a Android Material Design, \u0438 \u043c\u043d\u043e\u0433\u043e\u0435 \u0434\u0440\u0443\u0433\u043e\u0435\u2026<br \/>  \u0417\u0430\u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043e\u0432\u0430\u0432\u0448\u0438\u0445\u0441\u044f, \u043f\u0440\u043e\u0448\u0443 \u043f\u043e\u0434 \u043a\u0430\u0442!<\/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-280337","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/280337","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=280337"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/280337\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=280337"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=280337"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=280337"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}