clay/renderers/ncurses
Seintian 97c1a797c4 [renderers/ncurses] Refactor Ncurses renderer and example with atomic functions and Doxygen docs
Major refactor of the Ncurses renderer and example application to improve code readability, maintainability, and documentation coverage.

**Ncurses Renderer (`renderers/ncurses/clay_renderer_ncurses.c`):**
*   **Atomic Rendering Functions**: Decomposed the monolithic `Clay_Ncurses_Render` function into specialized handlers:
    *   `Clay_Ncurses_RenderRectangle`
    *   `Clay_Ncurses_RenderText`
    *   `Clay_Ncurses_RenderBorder`
*   **Scissor Management**: Encapsulated scissor stack operations into `Clay_Ncurses_PushScissor` and `Clay_Ncurses_PopScissor`.
*   **Visibility Logic**: Extracted visibility/clipping checks into `Clay_Ncurses_GetVisibleRect` for cleaner reuse.
*   **Documentation**: Added comprehensive Doxygen documentation for file headers, internal state, constants, and all functions.

**Ncurses Example (`examples/ncurses-example/main.c`):**
*   **Architecture Refactor**: Implementation split into clear "App State", "Input Processing", and "UI Components" sections.
*   **UI Componentization**: Renamed and organized UI functions with a consistent `UI_` prefix (e.g., `UI_Sidebar`, `UI_FeedPost`, `UI_HelpModal`).
*   **State Management**: Introduced `AppState` struct to centralize application state (sidebar visibility, scroll delta, etc.).
*   **Input Handling**: Centralized input logic in `App_ProcessInput` loop.
*   **Documentation**: Added full Doxygen documentation for the example source.

This refactor maintains identical runtime behavior while significantly improving the codebase's "spoken english" readability and modularity. loop.
*   **Documentation**: Added full Doxygen documentation for the example source.

This refactor maintains identical runtime behavior while significantly improving the codebase's  readability and modularity.
2025-12-28 18:39:25 +01:00
..
clay_renderer_ncurses.c [renderers/ncurses] Refactor Ncurses renderer and example with atomic functions and Doxygen docs 2025-12-28 18:39:25 +01:00