moved pixel

This commit is contained in:
Djeeberjr 2022-02-21 17:04:36 +01:00
parent 0ad907f74a
commit fd1428c749
3 changed files with 10 additions and 7 deletions

9
src/kernel/ui/Pixel.hx Normal file
View File

@ -0,0 +1,9 @@
package kernel.ui;
import util.Color;
@:structInit class Pixel {
public var char:String;
public var bg:Color;
public var textColor:Color;
}

View File

@ -6,12 +6,6 @@ import util.Vec.Vec2;
import util.Color;
import lib.TermWriteable;
@:structInit class Pixel {
public var char:String;
public var bg:Color;
public var textColor:Color;
}
class TermBuffer implements TermWriteable {
/**
format [y][x]. First index is the line. Second index the char in the line.

View File

@ -1,7 +1,7 @@
package lib.ui;
import util.Vec.Vec2;
import kernel.ui.TermBuffer.Pixel;
import kernel.ui.Pixel;
abstract Canvas(Array<Array<Pixel>>) to Array<Array<Pixel>> {
inline public function new() {