Fix documentation page about how to generate the documentation.

This commit is contained in:
Hugo Parente Lima 2010-05-04 13:57:50 -03:00
commit f0e7ba8fe7

View file

@ -11,6 +11,7 @@ You will need:
3. PySide source code 3. PySide source code
4. cmake 4. cmake
5. sphinx 5. sphinx
6. graphviz
Extracting documentation from Qt4 Extracting documentation from Qt4
--------------------------------- ---------------------------------
@ -19,38 +20,23 @@ The API documentation is generated from source code comments (for now, just
``qdoc3`` tool is supported, ``doxygen`` support will be added soon). ``qdoc3`` tool is supported, ``doxygen`` support will be added soon).
``qdoc3`` is the tool used to generate the oficial Qt4 documentation, you will ``qdoc3`` is the tool used to generate the oficial Qt4 documentation, you will
use it to generate a bunch of XML files that will be used by boostpythongenerator use it to generate a bunch of XML files that will be used by the generator
to create the documentation. to create the documentation.
So, go to Qt4 source directory and type: You need to tell PySide where it can find the Qt source code, to do this, when running cmake add the following parameters:
::
$ cp /path/to/pyside/sources/doc/pyside.qdocconf tools/qdoc3/test/pyside.qdocconf
$ QTDIR=`pwd` qdoc3 tools/qdoc3/test/pyside.qdocconf
$ export QT_SRC_DIR=`pwd` # the next step uses this variable.
The xml files now can be found at ``$QT_SRC_DIR/qt4xmldoc``.
Last step
---------
You need to tell PySide where it can find the generated XML files and the Qt4
source directory (XML files refers to it in some tags). So, go to the PySide
directory and type:
:: ::
$ mkdir build $ mkdir build
$ cmake -DCMAKE_INSTALL_PREFIX=/usr -DDOC_DATA_DIR=$QT_SRC_DIR/qt4xmldoc -DQT_SRC_DIR=$QT_SRC_DIR .. $ cmake -DQT_SRC_DIR=PATH_TO_QT_SOURCE_DIR ..
$ make apidoc $ make apidoc
$ make apidocinstall $ make apidocinstall
Where: Where:
* *PATH_TO_QT_SOURCE_DIR* is the path to the Qt4 sources. * *PATH_TO_QT_SOURCE_DIR* is the path to the Qt sources.
* *PATH_TO_XMLS* is the path to the xml's generated by qdoc3 tool.
The documentation will be installed at ``/usr/share/doc/pyside/index.html``, change The documentation will be installed at ``<INSTALL_PREFIX>/share/doc/pyside/index.html``, change
the *CMAKE_INSTALL_PREFIX* value if you want to install the documentation in another the *CMAKE_INSTALL_PREFIX* value if you want to install the documentation in another
directory. directory.
If you want to have inheritance graphs on the generated documentation, make sure you have the bindings installed before generate the documentation.