mirror of
https://codeberg.org/unspeaker/tek.git
synced 2025-12-06 19:56:42 +01:00
autoedit
This commit is contained in:
parent
968441850f
commit
c08d1bee5d
7 changed files with 177 additions and 150 deletions
|
|
@ -38,7 +38,7 @@ impl Content<TuiOut> for Repeat<'_> {
|
|||
fn render (&self, to: &mut TuiOut) {
|
||||
let [x, y, w, h] = to.area().xywh();
|
||||
let a = self.0.len();
|
||||
for (v, y) in (y..y+h).enumerate() {
|
||||
for (_v, y) in (y..y+h).enumerate() {
|
||||
for (u, x) in (x..x+w).enumerate() {
|
||||
if let Some(cell) = to.buffer.cell_mut(ratatui::prelude::Position::from((x, y))) {
|
||||
let u = u % a;
|
||||
|
|
@ -56,7 +56,7 @@ impl Content<TuiOut> for RepeatV<'_> {
|
|||
to
|
||||
}
|
||||
fn render (&self, to: &mut TuiOut) {
|
||||
let [x, y, w, h] = to.area().xywh();
|
||||
let [x, y, _w, h] = to.area().xywh();
|
||||
for y in y..y+h {
|
||||
if let Some(cell) = to.buffer.cell_mut(ratatui::prelude::Position::from((x, y))) {
|
||||
cell.set_symbol(&self.0);
|
||||
|
|
@ -72,7 +72,7 @@ impl Content<TuiOut> for RepeatH<'_> {
|
|||
to
|
||||
}
|
||||
fn render (&self, to: &mut TuiOut) {
|
||||
let [x, y, w, h] = to.area().xywh();
|
||||
let [x, y, w, _h] = to.area().xywh();
|
||||
for x in x..x+w {
|
||||
if let Some(cell) = to.buffer.cell_mut(ratatui::prelude::Position::from((x, y))) {
|
||||
cell.set_symbol(&self.0);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue