Revert "formatted all files."

This reverts commit 04250ebc98.
This commit is contained in:
Faris Armoush
2025-06-12 16:04:49 +03:00
parent 218f43bacb
commit c642ba2644
473 changed files with 4335 additions and 5417 deletions

View File

@ -28,11 +28,11 @@ class OccupancyPainter extends CustomPainter {
@override
void paint(Canvas canvas, Size size) {
final fillPaint = Paint();
final borderPaint = Paint()
final Paint fillPaint = Paint();
final Paint borderPaint = Paint()
..color = ColorsManager.grayBorder.withValues(alpha: 0.4)
..style = PaintingStyle.stroke;
final hoveredBorderPaint = Paint()
final Paint hoveredBorderPaint = Paint()
..color = Colors.black
..style = PaintingStyle.stroke
..strokeWidth = 1.5;
@ -66,24 +66,24 @@ class OccupancyPainter extends CustomPainter {
);
canvas.drawLine(Offset(x, y), Offset(x, y + cellSize), borderPaint);
canvas.drawLine(Offset(x + cellSize, y),
Offset(x + cellSize, y + cellSize), borderPaint);
canvas.drawLine(Offset(x + cellSize, y), Offset(x + cellSize, y + cellSize),
borderPaint);
}
}
}
void _drawDashedLine(Canvas canvas, Offset start, Offset end, Paint paint) {
const dashWidth = 2.0;
const dashSpace = 4.0;
final totalLength = (end - start).distance;
final direction = (end - start) / (end - start).distance;
const double dashWidth = 2.0;
const double dashSpace = 4.0;
final double totalLength = (end - start).distance;
final Offset direction = (end - start) / (end - start).distance;
var currentLength = 0.0;
double currentLength = 0.0;
while (currentLength < totalLength) {
final dashStart = start + direction * currentLength;
final nextLength = currentLength + dashWidth;
final dashEnd = start +
direction * (nextLength < totalLength ? nextLength : totalLength);
final Offset dashStart = start + direction * currentLength;
final double nextLength = currentLength + dashWidth;
final Offset dashEnd =
start + direction * (nextLength < totalLength ? nextLength : totalLength);
canvas.drawLine(dashStart, dashEnd, paint);
currentLength = nextLength + dashSpace;
}