猫史档案馆


【Python作品分享】聊天室布局【作品秀】

用户:ᝰ悠乐小小怪&光小滑ᝰ悠乐小小怪&光小滑查看:0 回复:1 评论:0 创建时间:2020-05-23T20:12:43


【作品展示】

center_image

 

【作品介绍】

就是简简单单的弄了一下聊天室的布局。

 

【作品源代码】

from tkinter import*
root = Tk()
root.title("聊天室")
message_frame = Frame(width=480, height=300, bg='white')
text_frame = Frame(width=480, height=100)
send_frame = Frame(width=480, height=30)
text_message = Text(message_frame)
text_text = Text(text_frame)
button_send = Button(send_frame, text='发送')
message_frame.grid(row=0, column=0, padx=3,pady=6)
text_frame.grid(row=1, column=0)
send_frame.grid(row=2, column=0)
message_frame.grid_propagate(0)
text_frame.grid_propagate(0)
send_frame.grid_propagate(0)
text_message.grid()
text_text.grid()
button_send.grid()
root.mainloop()

 

【提示】

部分含有Python第三方库相关内容的作品,在海龟编辑器网页端无法运行哦!如遇到这种情况,可以打开下面的链接,下载海龟编辑器客户端:

https://python.codemao.cn


回复

上一页1 页 / 共 1下一页
PX侠客行PX侠客行

加油emotion_编程猫_加油emotion_编程猫_加油emotion_编程猫_加油emotion_编程猫_加油emotion_编程猫_加油emotion_编程猫_加油emotion_编程猫_加油emotion_编程猫_加油

点赞0


评论