Class: C128BObject

From IHRIS Wiki
Revision as of 22:42, 16 October 2009 by Litlfred (talk | contribs)

This article desrcibes the class C128BObject.

  • Author: Karim Mribti, Nicola Asuni
  • Since: 2001-03-25
  • Since: 2001-03-25

Code 128-B Barcode Render Class for PHP using the GD graphics library.
Code 128-B is a continuous, multilevel and full ASCII code. @name BarcodeObject @license http://www.gnu.org/copyleft/lesser.html LGPL Code 128-B Barcode Render Class for PHP using the GD graphics library.
Code 128-B is a continuous, multilevel and full ASCII code. @name BarcodeObject @license http://www.gnu.org/copyleft/lesser.html LGPL

Methods

DrawCheckChar()

Draws the check-char code.

  • Signature: private function DrawCheckChar($DrawPos,$yPos,$ySize,$xres)
  • Parameters:
    • int $DrawPos
      Drawing position.
    • int $yPos
      Vertical position.
    • int $ySize
      Vertical size.
    • int $xres
      Horizontal resolution.
  • Returns: int
    drawing position. @access private

DrawObject()

Draws the barcode object.

  • Signature: public function DrawObject($xres)
  • Parameters:
    • int $xres
      Horizontal resolution.
  • Returns: bool
    true in case of success.

DrawStart()

Draws the start code.

  • Signature: private function DrawStart($DrawPos,$yPos,$ySize,$xres)
  • Parameters:
    • int $DrawPos
      Drawing position.
    • int $yPos
      Vertical position.
    • int $ySize
      Vertical size.
    • int $xres
      Horizontal resolution.
  • Returns: int
    drawing position. @access private

DrawStop()

Draws the stop code.

  • Signature: private function DrawStop($DrawPos,$yPos,$ySize,$xres)
  • Parameters:
    • int $DrawPos
      Drawing position.
    • int $yPos
      Vertical position.
    • int $ySize
      Vertical size.
    • int $xres
      Horizontal resolution.
  • Returns: int
    drawing position. @access private

GetBarSize()

Returns the bar size.

  • Signature: private function GetBarSize($xres,$char)
  • Parameters:
    • int $xres
      Horizontal resolution.
    • char $char
      Character.
  • Returns: int
    barcode size. @access private

GetCharIndex()

Returns the character index.

  • Signature: private function GetCharIndex($char)
  • Parameters:
    • char $char
      character.
  • Returns: int
    character index or -1 in case of error. @access private

GetCheckCharValue()

Returns the check-char value.

  • Signature: private function GetCheckCharValue()
  • Returns: string.@access private

GetSize()

Returns barcode size.

  • Signature: private function GetSize($xres)
  • Parameters:
    • int $xres
      Horizontal resolution.
  • Returns: barcode
    size. @access private

__construct()

Class Constructor.

  • Signature: public function __construct($Width,$Height,$Style,$Value)
  • Parameters:
    • int $Width
      Image width in pixels.
    • int $Height
      Image height in pixels.
    • int $Style
      Barcode style.
    • int $Value
      value to print on barcode.