Results 1 to 4 of 4

Thread: Printing txt file vs Printing pdf file

  1. #1
    Join Date
    Jun 2007
    Location
    italy
    Posts
    126
    Thanks
    15
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Printing txt file vs Printing pdf file

    Hi all,
    is it different to print (sending to printer) a txt file from printing a pdf file?
    I mean, can the same Qt code handle both situation ?

    If not, how do I load (with qt code) a pdf file, for sending it to the default printer?

    Thank you very mutch for you kind reply..

    Roby

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Printing txt file vs Printing pdf file

    You can use QDesktopServices to open it in a default PDF viewer for your system.

  3. #3
    Join Date
    Jul 2012
    Posts
    3
    Thanks
    2
    Qt products
    Qt4
    Platforms
    Windows Symbian S60

    Default Re: Printing txt file vs Printing pdf file

    I have written some sample data to file "sample.txt". I would like to print the contents of the file to my printer. Could you please tell me how will the code be in order to do this ? Sorry for asking a question in middle of this discussion.

  4. #4
    Join Date
    Jan 2006
    Location
    Munich, Germany
    Posts
    4,714
    Thanks
    21
    Thanked 418 Times in 411 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: Printing txt file vs Printing pdf file

    Could you please tell me how will the code be in order to do this ?
    Could you please ask a question that can be answered?
    ==========================signature=============== ==================
    S.O.L.I.D principles (use them!):
    https://en.wikipedia.org/wiki/SOLID_...iented_design)

    Do you write clean code? - if you are TDD'ing then maybe, if not, your not writing clean code.

Similar Threads

  1. printing a(n existing) file in Qt
    By caduel in forum Qt Programming
    Replies: 3
    Last Post: 21st July 2008, 07:20
  2. Set up the Qt4.3.2 with Visual Studio 2005
    By lamoda in forum Installation and Deployment
    Replies: 6
    Last Post: 30th January 2008, 06:51
  3. qt-3.3.8 fail in scratchbox
    By nass in forum Installation and Deployment
    Replies: 0
    Last Post: 25th May 2007, 15:21
  4. Printing a PRN file on an NDPS printer
    By janca in forum General Discussion
    Replies: 4
    Last Post: 20th March 2006, 22:11

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.