代码链接
github:https://github.com/fainco/Learning/tree/master/Kivy/ChatApp
欢迎加入公众号:数学交点
/* Kivy Chat Demo*/
class ConnectPage(GridLayout):
"""连接登陆页面"""
def login_page(self):
pass
def join_button(self,isinstance):
pass
def connect(self, _):
pass
class InfoPage(GridLayout):
"""程序消息显示页面"""
def __init__(self,**kwargs):
pass
def update_info(self,message):
pass
def update_text_width(self,*_):
class ChatPage(GridLayout):
"""聊天页面"""
def __init__(self,**kwargs):
pass
def adjust_fields(self, *_):
"""页面调整"""
pass
def on_key_down(self, instance, keyboard, keycode, tect, modifiers):
"""发送消息按键事件"""
pass
def send_message(self,_):
"""消息发送"""
pass
def incoming_message(self, username, message):
pass
class EpicApp(App):
def build(self):
pass
if __name__ == '__main__':
Config.set('graphics', 'width', '360')
Config.set('graphics', 'height', '640')
# Config.write()
chat_app = EpicApp()
chat_app.run()