Logo Search packages:      
Sourcecode: lemonpos-kde4 version File versions  Download package

void lemonView::printBalance ( QStringList  lines  )  [private, slot]

Slot used to print balance for the user.

Definition at line 1892 of file lemonview.cpp.

Referenced by corteDeCaja().

{
  if (Settings::printTicket()) {
    QFile file("/dev/lp0");
    if (file.open(QIODevice::ReadWrite)) {
      qDebug()<<"Printing balance...";
      QTextStream out(&file);
      out << "\x1b\x4b\x30";              // Feed back x30 dot lines
      out << "\x1b\x4b\x20";              // Feed back x20 dot lines
      out << lines.join("\n");    // Print data
      out << "\x1b\x64\x06";              // Feed 6 lines
      file.close();
    } else qDebug()<<"ERROR: Could not open printer...";
  }
}


Generated by  Doxygen 1.6.0   Back to index