Don't generate lines from 0, 0 twice

This commit is contained in:
The Magician 2024-03-15 15:25:19 +00:00
parent 72461058ed
commit b87abe46c3
1 changed files with 2 additions and 2 deletions

View File

@ -30,14 +30,14 @@ generate_lines() {
# Generate column separators # Generate column separators
colwidth=$((width / columns)) colwidth=$((width / columns))
for i in $(seq 0 $columns); do for i in $(seq 1 $columns); do
current_colwidth=$((colwidth * i)) current_colwidth=$((colwidth * i))
printf "line %d, 0 %d, %d " $current_colwidth $current_colwidth $height printf "line %d, 0 %d, %d " $current_colwidth $current_colwidth $height
done done
# Generate row separators # Generate row separators
rowheight=$((height / rows)) rowheight=$((height / rows))
for i in $(seq 0 $rows); do for i in $(seq 1 $rows); do
current_rowheight=$((rowheight * i)) current_rowheight=$((rowheight * i))
printf "line 0, %d %d, %d " $current_rowheight $width $current_rowheight printf "line 0, %d %d, %d " $current_rowheight $width $current_rowheight
done done