[PR #121] [MERGED] Introduce scissorRect stack for buffers (allow clipping when drawing) #1084

Closed
opened 2026-03-14 09:17:33 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/anomalyco/opentui/pull/121
Author: @kommander
Created: 9/1/2025
Status: Merged
Merged: 9/1/2025
Merged by: @kommander

Base: mainHead: buffered-as-overflow-hidden


📝 Commits (10+)

📊 Changes

10 files changed (+345 additions, -47 deletions)

View changed files

📝 packages/core/src/Renderable.ts (+23 -0)
📝 packages/core/src/buffer.ts (+12 -0)
📝 packages/core/src/examples/framebuffer-demo.ts (+72 -11)
📝 packages/core/src/examples/mouse-interaction-demo.ts (+25 -14)
📝 packages/core/src/examples/relative-positioning-demo.ts (+1 -1)
📝 packages/core/src/renderables/Box.ts (+20 -0)
📝 packages/core/src/zig.ts (+27 -0)
📝 packages/core/src/zig/buffer.zig (+151 -19)
📝 packages/core/src/zig/lib.zig (+12 -0)
📝 packages/core/src/zig/renderer.zig (+2 -2)

📄 Description

Using buffered=true in the relative-positioning-demo and overflow=hidden in the mouse-interaction-demo. It suffers from the alpha blending issue and it doesn't respect borders yet.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/anomalyco/opentui/pull/121 **Author:** [@kommander](https://github.com/kommander) **Created:** 9/1/2025 **Status:** ✅ Merged **Merged:** 9/1/2025 **Merged by:** [@kommander](https://github.com/kommander) **Base:** `main` ← **Head:** `buffered-as-overflow-hidden` --- ### 📝 Commits (10+) - [`7e88368`](https://github.com/anomalyco/opentui/commit/7e883685b95aa2dbabac5f78efdfb0df5f083b16) attempt - [`8594c63`](https://github.com/anomalyco/opentui/commit/8594c639aeaa2bbd23243d3905409e07139ff9e2) stash - [`b10f4a3`](https://github.com/anomalyco/opentui/commit/b10f4a3868b770521cf6f8014e1f2f036debdeee) add overflow hidden to box demo - [`01618da`](https://github.com/anomalyco/opentui/commit/01618daeea30f5a140751965529a93f055f34383) stash - [`3d858ff`](https://github.com/anomalyco/opentui/commit/3d858ff0e304a202ddbcfb7a4c7490e9e819b3dd) stash - [`7591842`](https://github.com/anomalyco/opentui/commit/759184242dc04c0025846de1e2f01bb4827d9972) name buffers - [`91e3b73`](https://github.com/anomalyco/opentui/commit/91e3b736159c38f1d6a52a4fec85e93149479740) stash TRY - [`312599c`](https://github.com/anomalyco/opentui/commit/312599cc79f3a6593939f4b9ef0436a374d335e6) stash - [`1b23972`](https://github.com/anomalyco/opentui/commit/1b2397232de58d89c64f356e1955c61e772a1602) restore original buffered behaviour - [`679ac15`](https://github.com/anomalyco/opentui/commit/679ac15ed28620fef46646e2b240a0620cd9dcd9) use a scissor rect stack ### 📊 Changes **10 files changed** (+345 additions, -47 deletions) <details> <summary>View changed files</summary> 📝 `packages/core/src/Renderable.ts` (+23 -0) 📝 `packages/core/src/buffer.ts` (+12 -0) 📝 `packages/core/src/examples/framebuffer-demo.ts` (+72 -11) 📝 `packages/core/src/examples/mouse-interaction-demo.ts` (+25 -14) 📝 `packages/core/src/examples/relative-positioning-demo.ts` (+1 -1) 📝 `packages/core/src/renderables/Box.ts` (+20 -0) 📝 `packages/core/src/zig.ts` (+27 -0) 📝 `packages/core/src/zig/buffer.zig` (+151 -19) 📝 `packages/core/src/zig/lib.zig` (+12 -0) 📝 `packages/core/src/zig/renderer.zig` (+2 -2) </details> ### 📄 Description Using `buffered=true` in the _relative-positioning-demo_ and `overflow=hidden` in the _mouse-interaction-demo_. It suffers from the alpha blending issue and it doesn't respect borders yet. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-14 09:17:33 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/opentui#1084
No description provided.