annotate Lib/tkinter/constants.py @ 87690:66c1c9f32567 default tip

Add use_weakref option to functools.lru_cache The use_weakref option makes lru_cache create weak references to the function arguments when creating the cache key, which prevents them from staying in the memory forever even after all other references to them are gone. This is a proof of concept for http://bugs.python.org/issue19859
author Radomir Dopieralski <devel@sheep.art.pl>
date Tue, 03 Dec 2013 16:02:48 +0100
parents d63344ba1878
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
3072
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
1 # Symbolic constants for Tk
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
2
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
3 # Booleans
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
4 NO=FALSE=OFF=0
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
5 YES=TRUE=ON=1
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
6
9183
8e952bdd0fa3 Added NS and EW constants, which are meaningful values for grid's
Barry Warsaw <barry@python.org>
parents: 6882
diff changeset
7 # -anchor and -sticky
3072
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
8 N='n'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
9 S='s'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
10 W='w'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
11 E='e'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
12 NW='nw'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
13 SW='sw'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
14 NE='ne'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
15 SE='se'
9183
8e952bdd0fa3 Added NS and EW constants, which are meaningful values for grid's
Barry Warsaw <barry@python.org>
parents: 6882
diff changeset
16 NS='ns'
8e952bdd0fa3 Added NS and EW constants, which are meaningful values for grid's
Barry Warsaw <barry@python.org>
parents: 6882
diff changeset
17 EW='ew'
9190
3e0c87bdb588 NSEW is also valid for -sticky
Barry Warsaw <barry@python.org>
parents: 9183
diff changeset
18 NSEW='nsew'
3072
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
19 CENTER='center'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
20
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
21 # -fill
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
22 NONE='none'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
23 X='x'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
24 Y='y'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
25 BOTH='both'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
26
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
27 # -side
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
28 LEFT='left'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
29 TOP='top'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
30 RIGHT='right'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
31 BOTTOM='bottom'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
32
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
33 # -relief
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
34 RAISED='raised'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
35 SUNKEN='sunken'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
36 FLAT='flat'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
37 RIDGE='ridge'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
38 GROOVE='groove'
6882
3c12c0d69e12 Added SOLID definition.
Guido van Rossum <guido@python.org>
parents: 4561
diff changeset
39 SOLID = 'solid'
3072
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
40
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
41 # -orient
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
42 HORIZONTAL='horizontal'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
43 VERTICAL='vertical'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
44
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
45 # -tabs
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
46 NUMERIC='numeric'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
47
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
48 # -wrap
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
49 CHAR='char'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
50 WORD='word'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
51
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
52 # -align
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
53 BASELINE='baseline'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
54
13908
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
55 # -bordermode
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
56 INSIDE='inside'
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
57 OUTSIDE='outside'
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
58
3072
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
59 # Special tags, marks and insert positions
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
60 SEL='sel'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
61 SEL_FIRST='sel.first'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
62 SEL_LAST='sel.last'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
63 END='end'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
64 INSERT='insert'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
65 CURRENT='current'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
66 ANCHOR='anchor'
4561
c713de72e76e Added ALL='all'.
Guido van Rossum <guido@python.org>
parents: 3202
diff changeset
67 ALL='all' # e.g. Canvas.delete(ALL)
3072
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
68
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
69 # Text widget and button states
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
70 NORMAL='normal'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
71 DISABLED='disabled'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
72 ACTIVE='active'
30110
92d68083a0fd Add HIDDEN. Fixes #777664.
Martin v. Löwis <martin@v.loewis.de>
parents: 13908
diff changeset
73 # Canvas state
92d68083a0fd Add HIDDEN. Fixes #777664.
Martin v. Löwis <martin@v.loewis.de>
parents: 13908
diff changeset
74 HIDDEN='hidden'
3072
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
75
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
76 # Menu item types
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
77 CASCADE='cascade'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
78 CHECKBUTTON='checkbutton'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
79 COMMAND='command'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
80 RADIOBUTTON='radiobutton'
d14cef14fbf2 Initial revision
Guido van Rossum <guido@python.org>
parents:
diff changeset
81 SEPARATOR='separator'
3202
6491bd2bbdef added listbox selection modes
Guido van Rossum <guido@python.org>
parents: 3072
diff changeset
82
6491bd2bbdef added listbox selection modes
Guido van Rossum <guido@python.org>
parents: 3072
diff changeset
83 # Selection modes for list boxes
6491bd2bbdef added listbox selection modes
Guido van Rossum <guido@python.org>
parents: 3072
diff changeset
84 SINGLE='single'
6491bd2bbdef added listbox selection modes
Guido van Rossum <guido@python.org>
parents: 3072
diff changeset
85 BROWSE='browse'
6491bd2bbdef added listbox selection modes
Guido van Rossum <guido@python.org>
parents: 3072
diff changeset
86 MULTIPLE='multiple'
6491bd2bbdef added listbox selection modes
Guido van Rossum <guido@python.org>
parents: 3072
diff changeset
87 EXTENDED='extended'
13908
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
88
30458
61dba0aa9e37 Patch #805976: Add DOTBOX and UNDERLINE.
Martin v. Löwis <martin@v.loewis.de>
parents: 30110
diff changeset
89 # Activestyle for list boxes
61dba0aa9e37 Patch #805976: Add DOTBOX and UNDERLINE.
Martin v. Löwis <martin@v.loewis.de>
parents: 30110
diff changeset
90 # NONE='none' is also valid
61dba0aa9e37 Patch #805976: Add DOTBOX and UNDERLINE.
Martin v. Löwis <martin@v.loewis.de>
parents: 30110
diff changeset
91 DOTBOX='dotbox'
61dba0aa9e37 Patch #805976: Add DOTBOX and UNDERLINE.
Martin v. Löwis <martin@v.loewis.de>
parents: 30110
diff changeset
92 UNDERLINE='underline'
61dba0aa9e37 Patch #805976: Add DOTBOX and UNDERLINE.
Martin v. Löwis <martin@v.loewis.de>
parents: 30110
diff changeset
93
13908
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
94 # Various canvas styles
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
95 PIESLICE='pieslice'
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
96 CHORD='chord'
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
97 ARC='arc'
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
98 FIRST='first'
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
99 LAST='last'
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
100 BUTT='butt'
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
101 PROJECTING='projecting'
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
102 ROUND='round'
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
103 BEVEL='bevel'
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
104 MITER='miter'
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
105
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
106 # Arguments to xview/yview
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
107 MOVETO='moveto'
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
108 SCROLL='scroll'
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
109 UNITS='units'
52757baf030d -- added a couple of missing Tkinter constants (canvas item styles,
Fredrik Lundh <fredrik@pythonware.com>
parents: 13903
diff changeset
110 PAGES='pages'