Enable different initial encoding for datamatrix #86
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Datamtrix can be fully encoded with different encoding. The actual parameters in constructor don't allow that for now.
For instance :
$data = "IS010000000000000000000000S1173082622170111S21.2.250.1.213.1.4.10S3JEAN-MICHEL" . chr(29) . "S4INS-FAMILLE-UN" . chr(29) . "S5MS607-08-1973S726221";
I nned to fully encode that string in C40 (not related to the chr(29) aka GS character)
So here is this pull request to add a third parameter in constructor to set the initial encoding, according to the constant declared in Data class.
Examples :
DATAMATRIX,S / DATAMATRIX,S,N,0 => datamatrix square in ASCII encoding
DATAMATRIX,S,N,1 => datamatrix square in C40 encoding
DATAMATRIX,R,N,5 => datamatrix square in BASE256 encoding
I noticed than on master branch, the test "Test\BarcodeTest::testGetPng" is broken : filename expected isn't correct. So i couldn't check the first item in the checklist
...
Checklist:
make buildall
command has been run successfully without any error or warning.Type of change: