doc: correct TODO, NOTE and FIX comment statements
All checks were successful
Zig Project Action / Lint, Spell-check and test zig project (push) Successful in 48s

This commit is contained in:
2025-03-03 21:49:11 +01:00
parent edefc80759
commit 91ac6241f4
21 changed files with 52 additions and 52 deletions

View File

@@ -92,12 +92,12 @@ pub fn Scrollable(Event: type) type {
switch (event) {
.resize => |size| {
this.size = size;
// TODO: scrollbar space - depending on configuration and only if necessary?
// TODO scrollbar space - depending on configuration and only if necessary?
this.container_size = size.max(this.min_size);
this.container_size.anchor = size.anchor;
try this.container.handle(.{ .resize = this.container_size });
},
// TODO: other means to scroll except with the mouse? (i.e. Ctrl-u/d, k/j, etc.?)
// TODO other means to scroll except with the mouse? (i.e. Ctrl-u/d, k/j, etc.?)
.mouse => |mouse| switch (mouse.button) {
Mouse.Button.wheel_up => if (this.container_size.rows > this.size.rows) {
this.anchor.row -|= 1;
@@ -164,7 +164,7 @@ pub fn Scrollable(Event: type) type {
for (this.container.elements.items) |child| try render_container(child, container_cells, container_size);
const anchor = (@as(usize, this.anchor.row) * @as(usize, container_size.cols)) + @as(usize, this.anchor.col);
// TODO: render scrollbar according to configuration!
// TODO render scrollbar according to configuration!
for (0..size.rows) |row| {
for (0..size.cols) |col| {
cells[(row * size.cols) + col] = container_cells[anchor + (row * container_size.cols) + col];
@@ -175,8 +175,8 @@ pub fn Scrollable(Event: type) type {
};
}
// TODO: nested scrollable `Container`s?'
// TODO: reaction only for when the event is actually pushed to the corresponding `Container` rendered container
// TODO nested scrollable `Container`s?'
// TODO reaction only for when the event is actually pushed to the corresponding `Container` rendered container
test "scrollable vertical" {
const event = @import("event.zig");