diff --git a/index.html b/index.html
index 3b464a9..ff7633b 100644
--- a/index.html
+++ b/index.html
@@ -81,6 +81,31 @@
+
+ Border Size:
+ Size of white border around QR code. Typically need some
+ border around the code, but depending on your use case you
+ can get rid of it.
+
+
+
+
+
+
+
+
+
+
+
QRLength - 8 && j < 8) {
+ } else if (i > upperLimit && j < lowerLimit) {
return false;
- } else if (i < 8 && j > QRLength - 8) {
+ } else if (i < lowerLimit && j > upperLimit) {
return false;
}
@@ -156,7 +169,7 @@ function makeCode() {
// QR code sizing
bitLength = 10;
- canvasLength = bitLength * (QRLength + 2);
+ canvasLength = bitLength * (QRLength + borderSize * 2);
canvas.width = canvasLength;
canvas.height = canvasLength;
@@ -185,7 +198,14 @@ function makeCode() {
} else {
ctx.fillStyle = white;
}
- drawShape(ctx, i + 1, j + 1, bitLength, radiusRatio, QRLength);
+ drawShape(
+ ctx,
+ i + borderSize,
+ j + borderSize,
+ bitLength,
+ radiusRatio,
+ QRLength
+ );
}
}
}