Lines Matching refs:attributes
33 private $attributes; variable in DokuWiki\\Barcodes\\BarcodesWrapper
41 public function __construct($attributes) argument
43 $this->attributes = $attributes;
52 if (!$this->attributes->type) {
55 elseif ($this->attributes->type == "QRCODE") {
59 elseif ($this->attributes->type == "DATAMATRIX") {
63 elseif (in_array($this->attributes->type, self::JUCKESARM_BARCODES)) {
65 $this->factory->setType($this->attributes->type);
68 throw new BarcodesException('unsupported type "' . $this->attributes->type . '"');
72 $this->factory->setCode($this->attributes->value);
75 $this->factory->setColor($this->attributes->color);
78 if ($this->attributes->size) {
80 $this->factory->setSize($this->attributes->size);
83 $this->factory->setHeight($this->attributes->size);
88 … if ($this->factory instanceof BarcodeFactory) $this->factory->setScale($this->attributes->scale);
95 …if ($this->attributes->background_color) $styles[] = sprintf('background-color: #%s', $this->attri…
98 if ($this->attributes->size) {
100 $styles[] = sprintf('width: %dpx', $this->attributes->size);
101 $styles[] = sprintf('height: %dpx', $this->attributes->size);
104 $styles[] = sprintf('height: %dpx', $this->attributes->size);
109 $styles[] = sprintf('padding: %dpx', $this->attributes->padding);
119 if ($this->attributes->img_type == 'svg') {
130 } elseif ($this->attributes->img_type == 'png') {
142 … throw new BarcodesException('Unsupported img-type "' . $this->attributes->img_type . '"');