Barcode generation parameters.
BarcodeParameters::getEnableEscape |
( |
| ) |
|
Indicates whether explains the character "\" as an escape character in CodeText property. Used for Pdf417, DataMatrix, Code128 only If the EnableEscape is true, "\" will be explained as a special escape character. Otherwise, "\" acts as normal characters. Aspose.BarCode supports inputing decimal ascii code and mnemonic for ASCII control-code characters. For example, \013 and \CR stands for CR.
BarcodeParameters::getGS1CompositeBar |
( |
| ) |
|
GS1 Composite Bar parameters.
This sample shows how to create and save a GS1 Composite Bar image. Note that 1D codetext and 2D codetext are separated by symbol '/'
$codetext = "(01)03212345678906/(21)A1B2C3D4E5F6G7H8"; $generator = new BarcodeGenerator(EncodeTypes::GS_1_COMPOSITE_BAR, $codetext);
$generator->getParameters()->getBarcode()->getGS1CompositeBar()->setLinearComponentType(EncodeTypes::GS_1_CODE_128); $generator->getParameters()->getBarcode()->getGS1CompositeBar()->setTwoDComponentType(TwoDComponentType::CC_A);
// Aspect ratio of 2D component $generator->getParameters()->getBarcode()->getPdf417()->setAspectRatio(3);
// X-Dimension of 1D and 2D components $generator->getParameters()->getBarcode()->getXDimension()->setPixels(3); /// // Height of 1D component $generator->getParameters()->getBarcode()->getBarHeight()->setPixels(100); /// $generator->save("test.png", BarcodeImageFormat::PNG);
- Returns
- GS1CompositeBarParameters GS1 Composite Bar parameters.
BarcodeParameters::getSupplement |
( |
| ) |
|
Supplement parameters. Used for Interleaved2of5, Standard2of5, EAN13, EAN8, UPCA, UPCE, ISBN, ISSN, ISMN.
BarcodeParameters::getWideNarrowRatio |
( |
| ) |
|
Wide bars to Narrow bars ratio. Default value: 3, that is, wide bars are 3 times as wide as narrow bars. Used for ITF, PZN, PharmaCode, Standard2of5, Interleaved2of5, Matrix2of5, ItalianPost25, IATA2of5, VIN, DeutschePost, OPC, Code32, DataLogic2of5, PatchCode, Code39Extended, Code39Standard
- Exceptions
-
IllegalArgumentException | The WideNarrowRatio parameter value is less than or equal to 0. |
BarcodeParameters::isChecksumEnabled |
( |
| ) |
|
Enable checksum during generation 1D barcodes. Default is treated as Yes for symbology which must contain checksum, as No where checksum only possible. Checksum is possible: Code39 Standard/Extended, Standard2of5, Interleaved2of5, Matrix2of5, ItalianPost25, DeutschePostIdentcode, DeutschePostLeitcode, VIN, Codabar Checksum always used: Rest symbology
BarcodeParameters::setChecksumEnabled |
( |
int |
$value | ) |
|
Enable checksum during generation 1D barcodes. Default is treated as Yes for symbology which must contain checksum, as No where checksum only possible. Checksum is possible: Code39 Standard/Extended, Standard2of5, Interleaved2of5, Matrix2of5, ItalianPost25, DeutschePostIdentcode, DeutschePostLeitcode, VIN, Codabar Checksum always used: Rest symbology
BarcodeParameters::setEnableEscape |
( |
bool |
$value | ) |
|
Indicates whether explains the character "\" as an escape character in CodeText property. Used for Pdf417, DataMatrix, Code128 only If the EnableEscape is true, "\" will be explained as a special escape character. Otherwise, "\" acts as normal characters.
Aspose.BarCode supports inputing decimal ascii code and mnemonic for ASCII control-code characters. For example, \013 and \CR stands for CR.
GS1 Composite Bar parameters.
This sample shows how to create and save a GS1 Composite Bar image. Note that 1D codetext and 2D codetext are separated by symbol '/'
$codetext = "(01)03212345678906/(21)A1B2C3D4E5F6G7H8"; $generator = new BarcodeGenerator(EncodeTypes::GS_1_COMPOSITE_BAR, $codetext);
$generator->getParameters()->getBarcode()->getGS1CompositeBar()->setLinearComponentType(EncodeTypes::GS_1_CODE_128); $generator->getParameters()->getBarcode()->getGS1CompositeBar()->setTwoDComponentType(TwoDComponentType::CC_A);
// Aspect ratio of 2D component $generator->getParameters()->getBarcode()->getPdf417()->setAspectRatio(3);
// X-Dimension of 1D and 2D components $generator->getParameters()->getBarcode()->getXDimension()->setPixels(3); /// // Height of 1D component $generator->getParameters()->getBarcode()->getBarHeight()->setPixels(100); /// $generator->save("test.png", BarcodeImageFormat::PNG);
BarcodeParameters::setWideNarrowRatio |
( |
float |
$value | ) |
|
Wide bars to Narrow bars ratio. Default value: 3, that is, wide bars are 3 times as wide as narrow bars. Used for ITF, PZN, PharmaCode, Standard2of5, Interleaved2of5, Matrix2of5, ItalianPost25, IATA2of5, VIN, DeutschePost, OPC, Code32, DataLogic2of5, PatchCode, Code39Extended, Code39Standard
- Exceptions
-
- Parameters
-
float | $value | The WideNarrowRatio parameter value is less than or equal to 0. |