File tree Expand file tree Collapse file tree 3 files changed +23
-3
lines changed
Misc/NEWS.d/next/Documentation Expand file tree Collapse file tree 3 files changed +23
-3
lines changed Original file line number Diff line number Diff line change @@ -641,7 +641,8 @@ The module :mod:`curses` defines the following functions:
641
641
642
642
.. function :: update_lines_cols()
643
643
644
- Update :envvar: `LINES ` and :envvar: `COLS `. Useful for detecting manual screen resize.
644
+ Update the :const: `LINES ` and :const: `COLS ` module variables.
645
+ Useful for detecting manual screen resize.
645
646
646
647
.. versionadded :: 3.5
647
648
@@ -1342,10 +1343,27 @@ The :mod:`curses` module defines the following data members:
1342
1343
.. data :: COLORS
1343
1344
1344
1345
The maximum number of colors the terminal can support.
1346
+ It is defined only after the call to :func: `start_color `.
1345
1347
1346
1348
.. data :: COLOR_PAIRS
1347
1349
1348
1350
The maximum number of color pairs the terminal can support.
1351
+ It is defined only after the call to :func: `start_color `.
1352
+
1353
+ .. data :: COLS
1354
+
1355
+ The width of the screen, i.e., the number of columns.
1356
+ It is defined only after the call to :func: `initscr `.
1357
+ Updated by :func: `update_lines_cols `, :func: `resizeterm ` and
1358
+ :func: `resize_term `.
1359
+
1360
+ .. data :: LINES
1361
+
1362
+ The height of the screen, i.e., the number of lines.
1363
+ It is defined only after the call to :func: `initscr `.
1364
+ Updated by :func: `update_lines_cols `, :func: `resizeterm ` and
1365
+ :func: `resize_term `.
1366
+
1349
1367
1350
1368
Some constants are available to specify character cell attributes.
1351
1369
The exact constants available are system dependent.
Original file line number Diff line number Diff line change @@ -1045,8 +1045,8 @@ not just sequences. (Contributed by Serhiy Storchaka in :issue:`23171`.)
1045
1045
curses
1046
1046
------
1047
1047
1048
- The new :func: `~curses.update_lines_cols ` function updates the :envvar : `LINES `
1049
- and :envvar : `COLS ` environment variables. This is useful for detecting
1048
+ The new :func: `~curses.update_lines_cols ` function updates the :data : `LINES `
1049
+ and :data : `COLS ` module variables. This is useful for detecting
1050
1050
manual screen resizing. (Contributed by Arnon Yaari in :issue: `4254 `.)
1051
1051
1052
1052
Original file line number Diff line number Diff line change
1
+ Document the :mod: `curses ` module variables :const: `~curses.LINES ` and
2
+ :const: `~curses.COLS `.
You can’t perform that action at this time.
0 commit comments