Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Administrator
/
level3-lesson18-diy1
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
179cd75c
authored
Jun 08, 2023
by
BellCodeEditor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
auto save
parent
145fe74a
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
31 additions
and
4 deletions
1.py
my_app.py
1.py
0 → 100644
View file @
179cd75c
import
turtle
#导入turtle模块
#写字
#pen=turtle.Pen()
#pen.write("Hi,诺依~\n用python写电子贺卡真是太有趣啦~\n我也喜欢python~\n——悟空 ",font=("Times",18,"normal"))
#pen.hideturtle()
#画爱心
pen1
=
turtle
.
Pen
()
#创建画心的代码
pen1
.
pencolor
(
"red"
)
#设置画笔颜色
pen1
.
pensize
(
5
)
#设置画笔大小
pen1
.
left
(
45
)
#左转45
pen1
.
forward
(
100
)
pen1
.
circle
(
50
,
180
)
#画一个半径为50的半圆
pen1
.
right
(
90
)
pen1
.
circle
(
50
,
180
)
pen1
.
forward
(
100
)
pen1
.
hideturtle
()
#隐藏画笔
turtle
.
done
()
#保存画布
\ No newline at end of file
my_app.py
View file @
179cd75c
import
tkinter
from
tkinter
import
messagebox
def
login_to_reg
():
# 登录界面转注册界面
pass
app_login
.
root
.
destroy
()
global
app_reg
app_reg
=
My_register
()
app_reg
.
show
()
def
reg_to_login
():
# 注册界面转登录界面
pass
app_reg
.
root
.
destroy
()
global
app_login
app_login
=
My_register
()
app_login
.
show
()
def
register
():
# 注册验证
pass
name
,
password
,
password1
=
app_reg
.
get_input
()
if
name
==
""
:
messagebox
.
showwarning
(
"竞答"
)
def
login
():
# 登录验证
pass
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment