PHP Classes

File: libs/Barcode/html/config/BCGBarcode1D.php

Recommend this page to a friend!
  Classes of william amed   Raptor 2   libs/Barcode/html/config/BCGBarcode1D.php   Download  
File: libs/Barcode/html/config/BCGBarcode1D.php
Role: Example script
Content type: text/plain
Description: Example script
Class: Raptor 2
Framework that takes routes from annotations
Author: By
Last change:
Date: 8 years ago
Size: 450 bytes
 

Contents

Class file image Download
<?php
function baseCustomSetup($barcode, $get) {
   
$font_dir = '..' . DIRECTORY_SEPARATOR . 'font';

    if (isset(
$get['thickness'])) {
       
$barcode->setThickness(max(9, min(90, intval($get['thickness']))));
    }

   
$font = 0;
    if (
$get['font_family'] !== '0' && intval($get['font_size']) >= 1) {
       
$font = new BCGFontFile($font_dir . '/' . $get['font_family'], intval($get['font_size']));
    }

   
$barcode->setFont($font);
}
?>