summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--svgbob/src/buffer/cell_buffer/cell.rs2
-rw-r--r--svgbob/src/buffer/cell_buffer/cell/cell_grid.rs4
2 files changed, 6 insertions, 0 deletions
diff --git a/svgbob/src/buffer/cell_buffer/cell.rs b/svgbob/src/buffer/cell_buffer/cell.rs
index 81150fe..db54d8b 100644
--- a/svgbob/src/buffer/cell_buffer/cell.rs
+++ b/svgbob/src/buffer/cell_buffer/cell.rs
@@ -192,6 +192,8 @@ impl Cell {
}
/// snap a point closest to any of the intersection of this cellgrid
+ /// Note: There are 4 horizontal mini cell for each cell
+ /// There are 8 vertical mini cell for each cell
#[inline]
fn snap_xy(x: f32, y: f32) -> Point {
let tx = (x * 4.0).round() / 4.0;
diff --git a/svgbob/src/buffer/cell_buffer/cell/cell_grid.rs b/svgbob/src/buffer/cell_buffer/cell/cell_grid.rs
index 6f07406..0e6f25a 100644
--- a/svgbob/src/buffer/cell_buffer/cell/cell_grid.rs
+++ b/svgbob/src/buffer/cell_buffer/cell/cell_grid.rs
@@ -152,11 +152,15 @@ impl CellGrid {
Self::point(4, 8)
}
+ //TODO: use proper aspect ratio for width
+ //and height based on the text rendering
#[inline]
pub fn width() -> f32 {
1.0
}
+ //TODO: use proper aspect ratio for width
+ //and height based on the text rendering
#[inline]
pub fn height() -> f32 {
2.0