summaryrefslogtreecommitdiffstats
path: root/doc/qembed.doc
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-11-08 12:31:36 -0600
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-11-08 12:31:36 -0600
commitd796c9dd933ab96ec83b9a634feedd5d32e1ba3f (patch)
tree6e3dcca4f77e20ec8966c666aac7c35bd4704053 /doc/qembed.doc
downloadtqt3-d796c9dd933ab96ec83b9a634feedd5d32e1ba3f.tar.gz
tqt3-d796c9dd933ab96ec83b9a634feedd5d32e1ba3f.zip
Test conversion to TQt3 from Qt3 8c6fc1f8e35fd264dd01c582ca5e7549b32ab731
Diffstat (limited to 'doc/qembed.doc')
-rw-r--r--doc/qembed.doc71
1 files changed, 71 insertions, 0 deletions
diff --git a/doc/qembed.doc b/doc/qembed.doc
new file mode 100644
index 000000000..8b5e7e23b
--- /dev/null
+++ b/doc/qembed.doc
@@ -0,0 +1,71 @@
+/*!
+\page qembed.html
+
+\title QEmbed - File and Image Embedder
+
+The QEmbed tool, found in \c{qt/tools/qembed}, converts arbitrary files
+into C++ code. This is useful for including image files and other resources
+directly into your application rather than loading the data from external
+files.
+
+QEmbed can also generate uncompressed versions of images that can be included
+directly into your application, thus avoiding both the external file and the
+need to parse the image file format. This is useful for small images such as
+icons for which compression is not a great gain.
+
+\section1 Usage
+
+\code
+ qembed [ general-files ] [ --images image-files ]
+\endcode
+
+\list
+\i \c{general-files}
+
+These files can be any type of file.
+
+\i \c{--images image-files}
+
+These files must be in image formats supported by Qt.
+\endlist
+
+\section1 Output
+
+The output from QEmbed is a C++ header file which you should
+include in a C++ source file. In the source file, you should make a
+wrapper function that suits your application. Two functions are
+provided; your wrapper function could just call one of these, or
+you can implement your own. Here's a simple example of usage for each
+of the supplied functions:
+
+\section2 qembed_findImage()
+
+\code
+ #include "generated_qembed_file.h"
+
+ QImage myFindImage(const char* name)
+ {
+ return qembed_findImage(name);
+ }
+\endcode
+
+Just call the generated function; \e name is the original image
+filename <b>without</b> the extension.
+
+\section2 qembed_findData()
+
+\code
+ #include "generated_qembed_file.h"
+
+ QByteArray myFindData(const char* name)
+ {
+ return qembed_findData(name);
+ }
+\endcode
+
+Just call the generated function; \e name is the original filename
+<b>with</b> the extension
+
+Alternatively, look at the output from QEmbed and write a function
+tailored to your needs.
+*/