Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Does QPrint assume page oriented printing?
QtWS25 Last Chance

Does QPrint assume page oriented printing?

Scheduled Pinned Locked Moved Solved General and Desktop
3 Posts 2 Posters 192 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • fcarneyF Offline
    fcarneyF Offline
    fcarney
    wrote on last edited by
    #1

    I need to print a line at a time on a dot matrix printer. Print a line, next line, carriage return, wait for more, repeat. I looked at the docs for QPrint, but I cannot tell if it assumes page oriented printing. This is for a logging application.

    C++ is a perfectly valid school of magic.

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi,

      Might be a silly question but are you sure you shouldn't rather talk to that printer directly ?

      From you question it seems you'll be using it as a direct logging output so I am not sure QPrinter will fit your use case.

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      1
      • fcarneyF Offline
        fcarneyF Offline
        fcarney
        wrote on last edited by
        #3

        @SGaist said in Does QPrint assume page oriented printing?:

        shouldn't rather talk to that printer directly

        Yeah, I looked over the Qt Printer objects and it does seem to assume page oriented printing. I briefly thought about creating a QPrintEngine just for this printer, but the reuse of the code would not be very good. I talked to another dev and we came to the same conclusion that we should just send it directly. We have done this in the past. I think I found the network port needed to do this and will figure out what it needs. Maybe I will do a stream interface.

        Thanks for the feedback!

        C++ is a perfectly valid school of magic.

        1 Reply Last reply
        0

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved