Skip to content

Commit

Permalink
QR Code: allow empty content, if user requests it
Browse files Browse the repository at this point in the history
  • Loading branch information
gredler committed May 9, 2024
1 parent add1d7f commit 2cb8814
Show file tree
Hide file tree
Showing 4 changed files with 53 additions and 2 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,9 @@ and data.

### Recent Releases

#### Okapi Barcode 0.4.6
- QR Code: allow empty content, if user requests it

#### Okapi Barcode 0.4.5
- Code 128: allow user to restrict the code sets used to encode data
- First [reproducible build](https://github.com/jvm-repo-rebuild/reproducible-central/)
Expand Down
5 changes: 3 additions & 2 deletions src/main/java/uk/org/okapibarcode/backend/QrCode.java
Original file line number Diff line number Diff line change
Expand Up @@ -927,7 +927,8 @@ private void qrBinary(int[] datastream, int version, int target_binlen, QrMode[]

info("Encoding: ");

do {
while (position < inputMode.length) {

data_block = inputMode[position];
short_data_block_length = 0;
do {
Expand Down Expand Up @@ -1095,7 +1096,7 @@ private void qrBinary(int[] datastream, int version, int target_binlen, QrMode[]

position += short_data_block_length;

} while (position < inputMode.length);
}

infoLine();

Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
PROPERTIES

emptyContentAllowed=true
content=

LOG

ECI Mode: 3
ECI Charset: ISO-8859-1
Encoding:
Codewords: 0 236 17 236 17 236 17 236 17
Version: 1
ECC Level: H
Mask 000 Penalties: 103 229 749 749
Mask 001 Penalties: 125 299 779 EXIT
Mask 010 Penalties: 131 302 782 EXIT
Mask 011 Penalties: 120 282 762 EXIT
Mask 100 Penalties: 132 327 807 EXIT
Mask 101 Penalties: 132 324 804 EXIT
Mask 110 Penalties: 124 328 808 EXIT
Mask 111 Penalties: 112 319 839 EXIT
Mask Pattern: 000
Blocks Merged: 113 -> 80

CODEWORDS

7112127
15122111151
1131133111311
113111121211311
11311711311
151322151
711111117
091128
0211312223121
0234222312
212191131
16223412
3251112111111
0812511111
73141131
15111312312
11311111132131
113113121421
1131111322131
1512114321
725211111

0 comments on commit 2cb8814

Please sign in to comment.