[PR #800] Center #1044

Open
opened 2026-03-04 01:09:10 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/rivo/tview/pull/800
Author: @vendelin8
Created: 1/28/2023
Status: 🔄 Open

Base: masterHead: center


📝 Commits (3)

  • de5c053 A center widget with its own demo
  • dee47f6 updated presentation demo with Center widget
  • ddf204f center draw redraws background first

📊 Changes

9 files changed (+147 additions, -20 deletions)

View changed files

center.go (+113 -0)
demos/center/README.md (+1 -0)
demos/center/main.go (+29 -0)
📝 demos/center/screenshot.png (+0 -0)
demos/presentation/center.go (+0 -16)
📝 demos/presentation/code.go (+1 -1)
📝 demos/presentation/colors.go (+1 -1)
📝 demos/presentation/end.go (+1 -1)
📝 demos/presentation/introduction.go (+1 -1)

📄 Description

A new Center widget that is more lightweight than two nested Flex, and it's cleaner a little bit.

Wiki should be updated with these changes, also I moved a screenshot from demos/modal/centered.png to demos/center/screenshot.png


🔄 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/rivo/tview/pull/800 **Author:** [@vendelin8](https://github.com/vendelin8) **Created:** 1/28/2023 **Status:** 🔄 Open **Base:** `master` ← **Head:** `center` --- ### 📝 Commits (3) - [`de5c053`](https://github.com/rivo/tview/commit/de5c0537b57c654838432c1011e8d7830ee9fcf7) A center widget with its own demo - [`dee47f6`](https://github.com/rivo/tview/commit/dee47f684d35c67905701a8242b4a080c809b6bb) updated presentation demo with Center widget - [`ddf204f`](https://github.com/rivo/tview/commit/ddf204f6bd5328c332a899ea36c1356aa6b5c08b) center draw redraws background first ### 📊 Changes **9 files changed** (+147 additions, -20 deletions) <details> <summary>View changed files</summary> ➕ `center.go` (+113 -0) ➕ `demos/center/README.md` (+1 -0) ➕ `demos/center/main.go` (+29 -0) 📝 `demos/center/screenshot.png` (+0 -0) ➖ `demos/presentation/center.go` (+0 -16) 📝 `demos/presentation/code.go` (+1 -1) 📝 `demos/presentation/colors.go` (+1 -1) 📝 `demos/presentation/end.go` (+1 -1) 📝 `demos/presentation/introduction.go` (+1 -1) </details> ### 📄 Description A new Center widget that is more lightweight than two nested Flex, and it's cleaner a little bit. [Wiki](https://github.com/rivo/tview/wiki/Modal) should be updated with these changes, also I moved a screenshot from `demos/modal/centered.png` to `demos/center/screenshot.png` --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
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/tview#1044
No description provided.