Skip to content

Commit

Permalink
Added barBorder attribute to barCode and barCodeFlowable tags.
Browse files Browse the repository at this point in the history
This attribute controls the thickness of a white border around a QR code.
  • Loading branch information
strichter committed May 6, 2015
1 parent d37be64 commit 8b7eedb
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 3 deletions.
5 changes: 3 additions & 2 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,9 @@ CHANGES
2.8.1 (unreleased)
------------------

- Nothing changed yet.

- Added `barBorder` attribute to ``barCode`` and ``barCodeFlowable``
tags. This attribute controls the thickness of a white border around a QR
code.

2.8.0 (2015-02-02)
------------------
Expand Down
6 changes: 5 additions & 1 deletion src/z3c/rml/form.py
Original file line number Diff line number Diff line change
Expand Up @@ -183,14 +183,18 @@ class IBarCodeBase(interfaces.IRMLDirectiveSignature):
title=u'Routing',
description=u'The routing information string.',
required=False)

# QR
barLevel = attr.Choice(
title=u'Bar Level',
description=u'The error correction level for QR code',
choices=['L', 'M', 'Q', 'H'],
required=False)

barBorder = attr.Measurement(
title=u'Bar Border',
description=u'The width of the border around a QR code.',
required=False)


class IBarCode(IBarCodeBase):
"""A barcode graphic."""
Expand Down
Binary file modified src/z3c/rml/rml-reference.pdf
Binary file not shown.
2 changes: 2 additions & 0 deletions src/z3c/rml/rml.dtd
Original file line number Diff line number Diff line change
Expand Up @@ -339,6 +339,7 @@
<!ATTLIST barCodeFlowable textColor CDATA #IMPLIED>
<!ATTLIST barCodeFlowable routing CDATA #IMPLIED>
<!ATTLIST barCodeFlowable barLevel (q|h|m|l) #IMPLIED>
<!ATTLIST barCodeFlowable barBorder CDATA #IMPLIED>
<!ATTLIST barCodeFlowable value CDATA #REQUIRED>

<!ELEMENT outlineAdd (#PCDATA)>
Expand Down Expand Up @@ -1108,6 +1109,7 @@
<!ATTLIST barCode textColor CDATA #IMPLIED>
<!ATTLIST barCode routing CDATA #IMPLIED>
<!ATTLIST barCode barLevel (q|h|m|l) #IMPLIED>
<!ATTLIST barCode barBorder CDATA #IMPLIED>
<!ATTLIST barCode x CDATA #IMPLIED>
<!ATTLIST barCode y CDATA #IMPLIED>
<!ATTLIST barCode isoScale CDATA #IMPLIED>
Expand Down

0 comments on commit 8b7eedb

Please sign in to comment.