Hi guys,
I would like to send to printer a doc file, or any other binary file using Qt4,
but i'm not ablet to get to a solution.
Is there an easy way to do that ?
Thank you very mutch in advance..
Roby
Hi guys,
I would like to send to printer a doc file, or any other binary file using Qt4,
but i'm not ablet to get to a solution.
Is there an easy way to do that ?
Thank you very mutch in advance..
Roby
read source from:
http://www.qt-apps.org/content/show....?content=62383
is a easy example inside ....
I do not understand which is the part in that example code that should lead me to the solution for the problem I posted..
I mean some of you knows the two or three lines of code to send to the default printer,
a file which is in the file system?
Thanks to all
Hi all,
ABout this tematic, I would like to know if there is the possibilitiy to treat binary document the same way as text document..
we, indeed know, that for txt file it is possible to write somethink like:
Qt Code:
QPrinter printer; return; document->print(&printer);To copy to clipboard, switch view to plain text mode
is there some possibility to do the same for binary files (doc, pdf, etc..) ?
Thank you very mutch for you kind reply.
Roby
any help ?
Thx
Guys
The problem I posted I found was discussed in the past bu even at that time there was not solution..
This mean it is not possibile to do that using Qt ????
Please let me know
no one have idea?
Hi everybody..Any of you could help with the question posted ?
Thank you
Qt doesn't handle such things. If you want things that platform dependent, use platform dependent API. Just be aware there is no magic call that would be able to print any file format. For example for printing postscript or pdf files on KDE you can simply call "kprinter /path/to/file", but you won't be able to print MS Word documents like that, in that case you have to open the document in an appropriate application (like Word itself or Open Office) and call the application's print method manually (or using ActiveX on Windows).
You can use QDesktopServices to open a document in an appropriate application, but this won't get it printed automatically (the application might not even support printing at all).
rmagro (1st September 2008)
it means I can't use Qt Api to print a .odt file as well ?
Thx
As for Qt 4.4 that's correct. As far as I know Qt 4.5 will be able to handle the Open Document Format.
rmagro (2nd September 2008)
Bookmarks