Please enable JavaScript to view this site.

CWT User Interface Design Handbook

Navigation: TFT Controls

MatrixBarcode (TFT)

Scroll Prev Top Next More

The MatrixBarcode control is used to render a QR code.

Properties

Name

Type:String of any length
Description:The name of the MatrixBarcode . Remember that the name must be unique within the same panel.

Location

Type:String in format “X, Y” where X and Y are both unsigned integers. Value range for X and Y is 0–1023.
Description:The Location property specifies where the MatrixBarcode shall be placed in relation to the parent control.

Size

Type:String in format “width, height” where width and height are both unsigned integers. Value range for  width and height is 0–1023.
Description:Defines the width of the MatrixBarcode on the display.

Code

Type:String of any length
Description:The data that is encoded into a matrix barcode
Default:“https://www.flowbird.group/”

QRCodeErrorCorrectionLevelInt

Type:Unsigned integer. Value range 0–3.
Description:Defines the amount of error correction.  

0 - Approx. 7% of codewords can be restored. Error correction level 0 is appropriate for high symbol quality and/or the need for the smallest possible symbol.

1 - Approx. 15% of codewords can be restored. Level 1 is described as Standard level and offers a good compromise between small size and increased reliability.

2 - Approx. 25% of codewords can be restored. Level 2 is a High reliability level and suitable for more critical or poor print quality applications

3 - Approx. 30% of codewords can be restored. Level 3 offers the maximum achievable reliability.

Default:3

QRCodeModuleSize

Type:positive floating point number. 0.01.
Description:Defines the size of each subsquare in inches, assuming a resolution of 100 pixels per inch.
I.e. 0.01 equals one pixel.
Default:0.07

Example

The example renders an image file with a QR code that is a link to http://www.google.com with minimum error correction and 10 pixels per module.

<TFT:MatrixBarcode Name="MyQrCode" Location="234,250" Size="300,300" Code="http://www.google.com" QRCodeErrorCorrectionLevelInt="0" QRCodeModuleSize="0.10"/>