7
7
msgstr ""
8
8
"Project-Id-Version :Python 3.12\n "
9
9
"Report-Msgid-Bugs-To :\n "
10
- "POT-Creation-Date :2024-03-25 00:03+0000\n "
10
+ "POT-Creation-Date :2024-04-23 00:03+0000\n "
11
11
"PO-Revision-Date :2018-05-23 16:08+0000\n "
12
12
"Last-Translator :Adrian Liaw <adrianliaw2000@gmail.com>\n "
13
13
"Language-Team :Chinese - TAIWAN (https://github.com/python/python-docs-zh- "
@@ -39,28 +39,27 @@ msgstr ""
39
39
#: ../../library/pprint.rst:21
40
40
msgid ""
41
41
"The formatted representation keeps objects on a single line if it can, and "
42
- "breaks them onto multiple lines if they don't fit within the allowed width. "
43
- "Construct :class:`PrettyPrinter` objects explicitly if you need to adjust "
44
- "the width constraint."
42
+ "breaks them onto multiple lines if they don't fit within the allowed width, "
43
+ "adjustable by the *width* parameter defaulting to 80 characters."
45
44
msgstr ""
46
45
47
- #: ../../library/pprint.rst:26
46
+ #: ../../library/pprint.rst:25
48
47
msgid "Dictionaries are sorted by key before the display is computed."
49
48
msgstr ""
50
49
51
- #: ../../library/pprint.rst:28
50
+ #: ../../library/pprint.rst:27
52
51
msgid "Added support for pretty-printing :class:`types.SimpleNamespace`."
53
52
msgstr ""
54
53
55
- #: ../../library/pprint.rst:31
54
+ #: ../../library/pprint.rst:30
56
55
msgid "Added support for pretty-printing :class:`dataclasses.dataclass`."
57
56
msgstr ""
58
57
59
- #: ../../library/pprint.rst:37
58
+ #: ../../library/pprint.rst:36
60
59
msgid "Functions"
61
60
msgstr ""
62
61
63
- #: ../../library/pprint.rst:41
62
+ #: ../../library/pprint.rst:40
64
63
msgid ""
65
64
"Prints the formatted representation of *object* followed by a newline. If "
66
65
"*sort_dicts* is false (the default), dictionaries will be displayed with "
@@ -69,7 +68,7 @@ msgid ""
69
68
"parameters."
70
69
msgstr ""
71
70
72
- #: ../../library/pprint.rst:64
71
+ #: ../../library/pprint.rst:63
73
72
msgid ""
74
73
"Prints the formatted representation of *object* on *stream*, followed by a "
75
74
"newline. If *stream* is ``None``, :data:`sys.stdout` is used. This may be "
@@ -78,43 +77,43 @@ msgid ""
78
77
"use within a scope)."
79
78
msgstr ""
80
79
81
- #: ../../library/pprint.rst:70
80
+ #: ../../library/pprint.rst:69
82
81
msgid ""
83
82
"The configuration parameters *stream*, *indent*, *width*, *depth*, "
84
83
"*compact*, *sort_dicts* and *underscore_numbers* are passed to the :class:"
85
84
"`PrettyPrinter` constructor and their meanings are as described in its "
86
85
"documentation below."
87
86
msgstr ""
88
87
89
- #: ../../library/pprint.rst:75
88
+ #: ../../library/pprint.rst:74
90
89
msgid ""
91
90
"Note that *sort_dicts* is ``True`` by default and you might want to use :"
92
91
"func:`~pprint.pp` instead where it is ``False`` by default."
93
92
msgstr ""
94
93
95
- #: ../../library/pprint.rst:81
94
+ #: ../../library/pprint.rst:80
96
95
msgid ""
97
96
"Return the formatted representation of *object* as a string. *indent*, "
98
97
"*width*, *depth*, *compact*, *sort_dicts* and *underscore_numbers* are "
99
98
"passed to the :class:`PrettyPrinter` constructor as formatting parameters "
100
99
"and their meanings are as described in its documentation below."
101
100
msgstr ""
102
101
103
- #: ../../library/pprint.rst:91
102
+ #: ../../library/pprint.rst:90
104
103
msgid ""
105
104
"Determine if the formatted representation of *object* is\" readable\" , or "
106
105
"can be used to reconstruct the value using :func:`eval`. This always "
107
106
"returns ``False`` for recursive objects."
108
107
msgstr ""
109
108
110
- #: ../../library/pprint.rst:101
109
+ #: ../../library/pprint.rst:100
111
110
msgid ""
112
111
"Determine if *object* requires a recursive representation. This function is "
113
112
"subject to the same limitations as noted in :func:`saferepr` below and may "
114
113
"raise an :exc:`RecursionError` if it fails to detect a recursive object."
115
114
msgstr ""
116
115
117
- #: ../../library/pprint.rst:108
116
+ #: ../../library/pprint.rst:107
118
117
msgid ""
119
118
"Return a string representation of *object*, protected against recursion in "
120
119
"some common data structures, namely instances of :class:`dict`, :class:"
@@ -124,117 +123,117 @@ msgid ""
124
123
"id=number>``. The representation is not otherwise formatted."
125
124
msgstr ""
126
125
127
- #: ../../library/pprint.rst:121
126
+ #: ../../library/pprint.rst:120
128
127
msgid "PrettyPrinter Objects"
129
128
msgstr "PrettyPrinter 物件"
130
129
131
- #: ../../library/pprint.rst:123
130
+ #: ../../library/pprint.rst:122
132
131
msgid "This module defines one class:"
133
132
msgstr ""
134
133
135
- #: ../../library/pprint.rst:133
134
+ #: ../../library/pprint.rst:132
136
135
msgid ""
137
136
"Construct a :class:`PrettyPrinter` instance. This constructor understands "
138
137
"several keyword parameters."
139
138
msgstr ""
140
139
141
- #: ../../library/pprint.rst:136
140
+ #: ../../library/pprint.rst:135
142
141
msgid ""
143
142
"*stream* (default :data:`!sys.stdout`) is a :term:`file-like object` to "
144
143
"which the output will be written by calling its :meth:`!write` method. If "
145
144
"both *stream* and :data:`!sys.stdout` are ``None``, then :meth:"
146
145
"`~PrettyPrinter.pprint` silently returns."
147
146
msgstr ""
148
147
149
- #: ../../library/pprint.rst:141
148
+ #: ../../library/pprint.rst:140
150
149
msgid ""
151
150
"Other values configure the manner in which nesting of complex data "
152
151
"structures is displayed."
153
152
msgstr ""
154
153
155
- #: ../../library/pprint.rst:144
154
+ #: ../../library/pprint.rst:143
156
155
msgid ""
157
156
"*indent* (default 1) specifies the amount of indentation added for each "
158
157
"nesting level."
159
158
msgstr ""
160
159
161
- #: ../../library/pprint.rst:147
160
+ #: ../../library/pprint.rst:146
162
161
msgid ""
163
162
"*depth* controls the number of nesting levels which may be printed; if the "
164
163
"data structure being printed is too deep, the next contained level is "
165
164
"replaced by ``...``. By default, there is no constraint on the depth of the "
166
165
"objects being formatted."
167
166
msgstr ""
168
167
169
- #: ../../library/pprint.rst:152
168
+ #: ../../library/pprint.rst:151
170
169
msgid ""
171
170
"*width* (default 80) specifies the desired maximum number of characters per "
172
171
"line in the output. If a structure cannot be formatted within the width "
173
172
"constraint, a best effort will be made."
174
173
msgstr ""
175
174
176
- #: ../../library/pprint.rst:156
175
+ #: ../../library/pprint.rst:155
177
176
msgid ""
178
177
"*compact* impacts the way that long sequences (lists, tuples, sets, etc) are "
179
178
"formatted. If *compact* is false (the default) then each item of a sequence "
180
179
"will be formatted on a separate line. If *compact* is true, as many items "
181
180
"as will fit within the *width* will be formatted on each output line."
182
181
msgstr ""
183
182
184
- #: ../../library/pprint.rst:162
183
+ #: ../../library/pprint.rst:161
185
184
msgid ""
186
185
"If *sort_dicts* is true (the default), dictionaries will be formatted with "
187
186
"their keys sorted, otherwise they will display in insertion order."
188
187
msgstr ""
189
188
190
- #: ../../library/pprint.rst:165
189
+ #: ../../library/pprint.rst:164
191
190
msgid ""
192
191
"If *underscore_numbers* is true, integers will be formatted with the ``_`` "
193
192
"character for a thousands separator, otherwise underscores are not displayed "
194
193
"(the default)."
195
194
msgstr ""
196
195
197
- #: ../../library/pprint.rst:169
196
+ #: ../../library/pprint.rst:168
198
197
msgid "Added the *compact* parameter."
199
198
msgstr "新增 *compact* 參數。"
200
199
201
- #: ../../library/pprint.rst:172
200
+ #: ../../library/pprint.rst:171
202
201
msgid "Added the *sort_dicts* parameter."
203
202
msgstr "新增 *sort_dicts* 參數。"
204
203
205
- #: ../../library/pprint.rst:175
204
+ #: ../../library/pprint.rst:174
206
205
msgid "Added the *underscore_numbers* parameter."
207
206
msgstr "新增 *underscore_numbers* 參數。"
208
207
209
- #: ../../library/pprint.rst:178
208
+ #: ../../library/pprint.rst:177
210
209
msgid "No longer attempts to write to :data:`!sys.stdout` if it is ``None``."
211
210
msgstr ""
212
211
213
- #: ../../library/pprint.rst:205
212
+ #: ../../library/pprint.rst:204
214
213
msgid ":class:`PrettyPrinter` instances have the following methods:"
215
214
msgstr ""
216
215
217
- #: ../../library/pprint.rst:210
216
+ #: ../../library/pprint.rst:209
218
217
msgid ""
219
218
"Return the formatted representation of *object*. This takes into account "
220
219
"the options passed to the :class:`PrettyPrinter` constructor."
221
220
msgstr ""
222
221
223
- #: ../../library/pprint.rst:216
222
+ #: ../../library/pprint.rst:215
224
223
msgid ""
225
224
"Print the formatted representation of *object* on the configured stream, "
226
225
"followed by a newline."
227
226
msgstr ""
228
227
229
- #: ../../library/pprint.rst:219
228
+ #: ../../library/pprint.rst:218
230
229
msgid ""
231
230
"The following methods provide the implementations for the corresponding "
232
231
"functions of the same names. Using these methods on an instance is slightly "
233
232
"more efficient since new :class:`PrettyPrinter` objects don't need to be "
234
233
"created."
235
234
msgstr ""
236
235
237
- #: ../../library/pprint.rst:229
236
+ #: ../../library/pprint.rst:228
238
237
msgid ""
239
238
"Determine if the formatted representation of the object is\" readable,\" or "
240
239
"can be used to reconstruct the value using :func:`eval`. Note that this "
@@ -243,18 +242,18 @@ msgid ""
243
242
"returns ``False``."
244
243
msgstr ""
245
244
246
- #: ../../library/pprint.rst:238
245
+ #: ../../library/pprint.rst:237
247
246
msgid "Determine if the object requires a recursive representation."
248
247
msgstr ""
249
248
250
- #: ../../library/pprint.rst:240
249
+ #: ../../library/pprint.rst:239
251
250
msgid ""
252
251
"This method is provided as a hook to allow subclasses to modify the way "
253
252
"objects are converted to strings. The default implementation uses the "
254
253
"internals of the :func:`saferepr` implementation."
255
254
msgstr ""
256
255
257
- #: ../../library/pprint.rst:247
256
+ #: ../../library/pprint.rst:246
258
257
msgid ""
259
258
"Returns three values: the formatted version of *object* as a string, a flag "
260
259
"indicating whether the result is readable, and a flag indicating whether "
@@ -272,45 +271,45 @@ msgid ""
272
271
"of the current call."
273
272
msgstr ""
274
273
275
- #: ../../library/pprint.rst:265
274
+ #: ../../library/pprint.rst:264
276
275
msgid "Example"
277
276
msgstr "範例"
278
277
279
- #: ../../library/pprint.rst:267
278
+ #: ../../library/pprint.rst:266
280
279
msgid ""
281
280
"To demonstrate several uses of the :func:`~pprint.pp` function and its "
282
281
"parameters, let's fetch information about a project from `PyPI <https://pypi."
283
282
"org>`_::"
284
283
msgstr ""
285
284
286
- #: ../../library/pprint.rst:276
285
+ #: ../../library/pprint.rst:275
287
286
msgid "In its basic form, :func:`~pprint.pp` shows the whole object::"
288
287
msgstr ""
289
288
290
- #: ../../library/pprint.rst:332
289
+ #: ../../library/pprint.rst:331
291
290
msgid ""
292
291
"The result can be limited to a certain *depth* (ellipsis is used for deeper "
293
292
"contents)::"
294
293
msgstr ""
295
294
296
- #: ../../library/pprint.rst:378
295
+ #: ../../library/pprint.rst:377
297
296
msgid ""
298
297
"Additionally, maximum character *width* can be suggested. If a long object "
299
298
"cannot be split, the specified width will be exceeded::"
300
299
msgstr ""
301
300
302
- #: ../../library/pprint.rst:89 ../../library/pprint.rst:227
301
+ #: ../../library/pprint.rst:88 ../../library/pprint.rst:226
303
302
msgid "built-in function"
304
303
msgstr "built-in function(內建函式)"
305
304
306
- #: ../../library/pprint.rst:89 ../../library/pprint.rst:227
305
+ #: ../../library/pprint.rst:88 ../../library/pprint.rst:226
307
306
msgid "eval"
308
307
msgstr "eval"
309
308
310
- #: ../../library/pprint.rst:128
309
+ #: ../../library/pprint.rst:127
311
310
msgid "..."
312
311
msgstr "..."
313
312
314
- #: ../../library/pprint.rst:128
313
+ #: ../../library/pprint.rst:127
315
314
msgid "placeholder"
316
315
msgstr "placeholder(佔位符號)"