3

Say I have created a GUI (Qt) that operates with some data(text+image). How I can export that data in one of listed formates in title.

I guess it is better to export info .rtf as it is free cross-platform formt(??), isn't it?

Narek
  • 38,779
  • 79
  • 233
  • 389

3 Answers3

3

See question about RTF reading and writing.

Community
  • 1
  • 1
  • I have seen this question befor asking! Except librtf hopped find something new. Also it is not intuitive how to use librtf. Is there any simple example? – Narek Jun 12 '10 at 19:45
  • Oh, I have found a link that can help me and users that will read this answer :). Here it is: http://www.codeproject.com/KB/library/rtflib.aspx – Narek Jun 12 '10 at 20:12
1

Depends on what you're trying to do, but maybe HTML + separate image file would be good enough?

If you want to export a file that is easy to view/print etc., but you don't really need to import it back into your application, you could make a PDF.

Artelius
  • 48,337
  • 13
  • 89
  • 105
  • I want to export into one of listed formats above. Not in HTML! – Narek Jun 12 '10 at 08:48
  • I don't think `rtf` supports embedded images. `txt` certainly doesn't. Any particular reason you are limited to those formats? – Artelius Jun 12 '10 at 08:54
  • In rtf you can have images. But, OK, PDF sounds good. Only one big disadvatage, you can not edit pdf if you do not have adobe acrobat professional, which costs money. But rtf is free. Any wayhow can I do that? – Narek Jun 12 '10 at 08:55
  • http://stackoverflow.com/questions/58730/open-source-pdf-library-for-c-c-application – Artelius Jun 12 '10 at 08:56
0

Do you mean you want to have something that looks like a snapshot of your gui?

In other case you could see it like the document export is just another way to view your data. One way is building your GUI, another way is to build some sort of document and write to a file.

Depending on how much you've mixed your data with the presentation, this could be hard or (comparatively) easy.

I don't know of any way to automatically do this for a QT gui, and I doubt you'll find a tool that does what you want.

Mattias Nilsson
  • 3,639
  • 1
  • 22
  • 29
  • Not like a snapshot! I want to export some data that could be in future edited. Like, say, my GUI generates some data and I want to export it to edit, print, edit a bit more, print once agin :). – Narek Jun 12 '10 at 09:07