Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
0b095bc0
Commit
0b095bc0
authored
May 08, 2000
by
Guido van Rossum
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Deleted the stdwin-based test() function.
parent
813008e5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
66 deletions
+0
-66
Lib/lib-old/Para.py
Lib/lib-old/Para.py
+0
-66
No files found.
Lib/lib-old/Para.py
View file @
0b095bc0
...
...
@@ -341,69 +341,3 @@ class Para:
d
.
invert
((
h1
,
bottom1
),
(
self
.
right
,
top2
))
top1
,
bottom1
=
top2
,
bottom2
d
.
invert
((
h1
,
top1
),
(
h2
,
bottom2
))
# Test class Para
# XXX This was last used on the Mac, hence the weird fonts...
def
test
():
import
stdwin
from
stdwinevents
import
*
words
=
'The'
,
'quick'
,
'brown'
,
'fox'
,
'jumps'
,
'over'
,
\
'the'
,
'lazy'
,
'dog.'
paralist
=
[]
for
just
in
'l'
,
'r'
,
'lr'
,
'c'
:
p
=
Para
()
p
.
just
=
just
p
.
addword
(
stdwin
,
(
'New York'
,
'p'
,
12
),
words
[
0
],
1
,
1
)
for
word
in
words
[
1
:
-
1
]:
p
.
addword
(
stdwin
,
None
,
word
,
1
,
1
)
p
.
addword
(
stdwin
,
None
,
words
[
-
1
],
2
,
4
)
p
.
addword
(
stdwin
,
(
'New York'
,
'b'
,
18
),
'Bye!'
,
0
,
0
)
p
.
addword
(
stdwin
,
(
'New York'
,
'p'
,
10
),
'Bye!'
,
0
,
0
)
paralist
.
append
(
p
)
window
=
stdwin
.
open
(
'Para.test()'
)
start
=
stop
=
selpara
=
None
while
1
:
etype
,
win
,
detail
=
stdwin
.
getevent
()
if
etype
==
WE_CLOSE
:
break
if
etype
==
WE_SIZE
:
window
.
change
((
0
,
0
),
(
1000
,
1000
))
if
etype
==
WE_DRAW
:
width
,
height
=
window
.
getwinsize
()
d
=
None
try
:
d
=
window
.
begindrawing
()
d
.
cliprect
(
detail
)
d
.
erase
(
detail
)
v
=
0
for
p
in
paralist
:
v
=
p
.
render
(
d
,
0
,
v
,
width
)
if
p
==
selpara
and
\
start
<>
None
and
stop
<>
None
:
p
.
invert
(
d
,
start
,
stop
)
finally
:
if
d
:
d
.
close
()
if
etype
==
WE_MOUSE_DOWN
:
if
selpara
and
start
<>
None
and
stop
<>
None
:
d
=
window
.
begindrawing
()
selpara
.
invert
(
d
,
start
,
stop
)
d
.
close
()
start
=
stop
=
selpara
=
None
mouseh
,
mousev
=
detail
[
0
]
for
p
in
paralist
:
start
=
p
.
whereis
(
stdwin
,
mouseh
,
mousev
)
if
start
<>
None
:
selpara
=
p
break
if
etype
==
WE_MOUSE_UP
and
start
<>
None
and
selpara
:
mouseh
,
mousev
=
detail
[
0
]
stop
=
selpara
.
whereis
(
stdwin
,
mouseh
,
mousev
)
if
stop
==
None
:
start
=
selpara
=
None
else
:
if
start
>
stop
:
start
,
stop
=
stop
,
start
d
=
window
.
begindrawing
()
selpara
.
invert
(
d
,
start
,
stop
)
d
.
close
()
window
.
close
()
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