for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Thermal\Profile;
use Thermal\Printer;
class Generic extends EscPOS
{
protected function setMode($mode, $enable)
if ($enable) {
// enable styles
if (Printer::STYLE_DOUBLE_WIDTH & $mode) {
$this->getConnection()->write("\x0E");
}
if (Printer::STYLE_DOUBLE_HEIGHT & $mode) {
$this->getConnection()->write("\ed1");
} else {
// disable styles
$this->getConnection()->write("\ed0");
$this->getConnection()->write("\x14");
return $this;