Return a function which returns console width. Supported: linux, osx, windows, cygwin.
()
| 350 | |
| 351 | |
| 352 | def _environ_cols_wrapper(): # pragma: no cover |
| 353 | """ |
| 354 | Return a function which returns console width. |
| 355 | Supported: linux, osx, windows, cygwin. |
| 356 | """ |
| 357 | warn("Use `_screen_shape_wrapper()(file)[0]` instead of" |
| 358 | " `_environ_cols_wrapper()(file)`", DeprecationWarning, stacklevel=2) |
| 359 | shape = _screen_shape_wrapper() |
| 360 | if not shape: |
| 361 | return None |
| 362 | |
| 363 | @wraps(shape) |
| 364 | def inner(fp): |
| 365 | return shape(fp)[0] |
| 366 | |
| 367 | return inner |
| 368 | |
| 369 | |
| 370 | def _term_move_up(): # pragma: no cover |
nothing calls this directly
no test coverage detected