| Summary: | Switch to ZXing-C++ library for generating QR codes | ||
|---|---|---|---|
| Product: | LibreOffice | Reporter: | Buovjaga <ilmari.lauhakangas> |
| Component: | LibreOffice | Assignee: | Homeboy_445 <akshitsan13> |
| Status: | RESOLVED FIXED | ||
| Severity: | enhancement | CC: | mentoring, samuel.mehrbrodt, sdc.blanco, serval2412, stephane.guillou, xiscofauli |
| Priority: | medium | Keywords: | difficultyInteresting, easyHack, skillCpp |
| Version: | unspecified | ||
| Hardware: | All | ||
| OS: | All | ||
| See Also: |
https://bugs.documentfoundation.org/show_bug.cgi?id=141193 https://bugs.documentfoundation.org/show_bug.cgi?id=149924 |
||
| Whiteboard: | target:7.2.0 | ||
| Crash report or crash signature: | Regression By: | ||
| Bug Depends on: | |||
| Bug Blocks: | 127232 | ||
|
Description
Buovjaga
2021-01-20 07:39:23 UTC
It looks like it also supports other 1D and 2D barcode formats too, which would be great if we make this available after the work. The Help content for this feature: https://help.libreoffice.org/latest/en-US/text/shared/guide/qrcode.html I would like to ask a few questions regarding bundling: 1.)Where to find the name of the package so as to include it in bundling like qrcodegen for QR-code-generator library. 2.)Also, should we include multiple header files in the configure.ac file instead of only one(as the requirement I think is to include multiple headers see: https://github.com/nu-book/zxing-cpp/blob/master/example/ZXingWriter.cpp) & which I think would require the use of the macro AC_CHECK_HEADERS. 3.)How to generate SHA256SUM in download.lst file for the package zxing-cpp-1.1.1.tar.gz. (In reply to Homeboy_445 from comment #3) > 3.)How to generate SHA256SUM in download.lst file for the package > zxing-cpp-1.1.1.tar.gz. At least on Linux you can just say sha256sum zxing-cpp-1.1.1.tar.gz thanks to https://www.gnu.org/software/coreutils/manual/html_node/sha2-utilities#sha2-utilities Since the bundling is somewhat complete, I would like to propose some slight changes in the UI of the Dialog box for Qrcodegen: 1.)Since the generation of QR code in ZXing requires margin length instead of the border(which was the case with qrcodegen lib). what would be a nice option here, changing 'Border' to 'Margin' or keep it 'Border' only? 2.)Also, in the qrcodegen lib error correction code levels are explicitly defined i.e LOW, MED, QUARTILE & HIGH but in ZXing only discrete values are allowed from 0 to 8 and so I propose that we keep these levels as is and assign some discrete value to each of them like LOW=1, MED=3, QUARTILE=6, HIGH=8 or as needed. 3.)We only need Qr code generation for now & so I think we should put QRCODE in its type by default(as ZXing has various other modes as well & so it needs to be specified). Please see:https://nu-book.github.io/zxing-cpp/demo_writer.html homeboy445 committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/f72cd65eef4f9c32201ac785c424d5b18651464f tdf#139778 bundle external:zxing lib It will be available in 7.2.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback. homeboy445 committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/cdeb5046be7f6259bd60f0951c51559edcab91c5 tdf#139778 Switch to ZXing for generating QR code It will be available in 7.2.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback. homeboy445 committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/66e88f46f7b9ef7a0b3366805860fd581bed6146 tdf#139778 qrcodegen library removal. It will be available in 7.2.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback. (In reply to Homeboy_445 from comment #5) > 1.)Since the generation of QR code in ZXing requires margin length instead > of the border(which was the case with qrcodegen lib). what would be a nice > option here, changing 'Border' to 'Margin' or keep it 'Border' only? Let’s change it. Remark: - QR-Code-generator-1.4.0.tar.gz 136kB - zxing-cpp-1.1.1.tar.gz 123MB Hope being able generate barcodes (even 1D) really worths it. (In reply to Julien Nabet from comment #10) > Remark: > - QR-Code-generator-1.4.0.tar.gz 136kB > - zxing-cpp-1.1.1.tar.gz 123MB > Hope being able generate barcodes (even 1D) really worths it. The huge size comes from the test samples in the test subdirectory. (In reply to Buovjaga from comment #11) > (In reply to Julien Nabet from comment #10) > > Remark: > > - QR-Code-generator-1.4.0.tar.gz 136kB > > - zxing-cpp-1.1.1.tar.gz 123MB > > Hope being able generate barcodes (even 1D) really worths it. > > The huge size comes from the test samples in the test subdirectory. Great then! I was afraid it would inflate LO built package. Thank you for the quick feedback! (In reply to Adolfo Jayme from comment #9) > (In reply to Homeboy_445 from comment #5) > > 1.)Since the generation of QR code in ZXing requires margin length instead > > of the border(which was the case with qrcodegen lib). what would be a nice > > option here, changing 'Border' to 'Margin' or keep it 'Border' only? > > Let’s change it. Alright! I'll see what can be done & send a new patch for it. > > option here, changing 'Border' to 'Margin' or keep it 'Border' only? > Let’s change it. I trust the help page will be updated to change "Border" to "Margin" and check if the other information on the page is still accurate. https://help.libreoffice.org/7.2/en-US/text/shared/guide/qrcode.html (In reply to sdc.blanco from comment #14) > > > option here, changing 'Border' to 'Margin' or keep it 'Border' only? > > Let’s change it. > I trust the help page will be updated to change "Border" to "Margin" and > check if the other information on the page is still accurate. > https://help.libreoffice.org/7.2/en-US/text/shared/guide/qrcode.html I can help with this when the time comes (In reply to Buovjaga from comment #0) > It has the advantage that it can also generate classic barcodes. Exposing > the barcode functionality in the UI can be a future easy hack. Now created as bug 141193 (In reply to Buovjaga from comment #15) > (In reply to sdc.blanco from comment #14) > > > > option here, changing 'Border' to 'Margin' or keep it 'Border' only? > > > Let’s change it. > > I trust the help page will be updated to change "Border" to "Margin" and > > check if the other information on the page is still accurate. > > https://help.libreoffice.org/7.2/en-US/text/shared/guide/qrcode.html > > I can help with this when the time comes Fortunately, The change has been merged successfully.['Border' has been changed to 'Margin'] Ilmari Lauhakangas committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/help/commit/a202f3a40b93e86354a32bcac95e595f5f636769 tdf#139778 Change border to margin in QR code help Wondering if we are missing a mention of ZXing in /core/readlicense_oo/license/license.xml ? |