mcpp index

huxerui.qrcode

import

QR code and barcode generation, declarative HuxerUI views, and multi-format image decoding

import huxerui.qrcode;

Module name read from the upstream `export module` declaration in modules/qrcode.cppm.

mcpp add huxerui.qrcode@0.1.1

Usage

From this repository's own test project — built and run by CI, not written for the website.

// Headless C++23 module consumer test for huxerui.qrcode.
// Verifies vendored ZXing 3.1.1 + generated Version.h compilation, QR/1D/2D
// encode-SVG-rasterize-decode round-trips, HuxerUI view construction, and
// std::invalid_argument exceptions across the module boundary.
import std;
import huxerui.qrcode;

int main() {
    using namespace huxerui::qrcode;

    bool ok = true;
    const auto check = [&](bool cond, std::string_view label) {
        if (!cond) {
            std::cerr << "FAILED: " << label << '\n';
            ok = false;
        }
    };

    // 1. Format queries (out-of-line in src/codec.cpp)
    check(FormatName(BarcodeFormat::QRCode) == "QR Code", "FormatName(QRCode)");
    check(CanEncode(BarcodeFormat::QRCode), "CanEncode(QRCode)");
    check(CanDecode(BarcodeFormat::QRCode), "CanDecode(QRCode)");
// …

tests/examples/huxerui-qrcode/tests/runtime.cpp · project tests/examples/huxerui-qrcode

Build · upstream manifest

modules
huxerui.qrcode
targets
huxerui_qrcode (lib), qrcode (lib)
language
c++23
manifest version
0.1.1
dependencies
huxerui
source
https://raw.githubusercontent.com/HuxerUI/Lib-QRCode/v0.1.1/mcpp.toml

Versions

VersionPlatforms Mirrorssha256
0.1.1 latest LinuxWindowsmacOS source 14fb81089e30…