forked from genewildish/Mainline
docs: add terminal resize handling clarification
This commit is contained in:
@@ -255,6 +255,14 @@ All three gradient sequences (green, orange, purple main + complementary) are no
|
|||||||
### Theme ID Naming
|
### Theme ID Naming
|
||||||
IDs are `"green"`, `"orange"`, `"purple"` — matching the menu labels exactly for clarity.
|
IDs are `"green"`, `"orange"`, `"purple"` — matching the menu labels exactly for clarity.
|
||||||
|
|
||||||
|
### Terminal Resize Handling
|
||||||
|
The `pick_color_theme()` function mirrors `pick_font_face()`, which does not handle terminal resizing during the picker display. If the terminal is resized while the picker menu is shown, the menu redraw may be incomplete; pressing any key (arrow, j/k, q) continues normally. This is acceptable because:
|
||||||
|
1. The picker completes quickly (< 5 seconds typical interaction)
|
||||||
|
2. Once a theme is selected, the menu closes and rendering begins
|
||||||
|
3. The streaming phase (`stream()`) is resilient to terminal resizing and auto-reflows to new dimensions
|
||||||
|
|
||||||
|
No special resize handling is needed for the color picker beyond what exists for the font picker.
|
||||||
|
|
||||||
### Testing Strategy
|
### Testing Strategy
|
||||||
1. **Unit tests** (`tests/test_themes.py`):
|
1. **Unit tests** (`tests/test_themes.py`):
|
||||||
- Verify Theme class construction
|
- Verify Theme class construction
|
||||||
|
|||||||
Reference in New Issue
Block a user