summaryrefslogtreecommitdiffstats
path: root/tools/qdoc3/node.cpp
diff options
context:
space:
mode:
authorMartin Smith <msmith@trolltech.com>2009-12-04 14:01:49 (GMT)
committerMartin Smith <msmith@trolltech.com>2009-12-04 14:01:49 (GMT)
commit77f274672480e5980d9f42e4fd94c9770279543b (patch)
tree159b4e4238d8e9ec6d5c056db4c8090a164850cb /tools/qdoc3/node.cpp
parent271936b063fb261293e3f77f7a2273e3a4dbb5d6 (diff)
downloadQt-77f274672480e5980d9f42e4fd94c9770279543b.zip
Qt-77f274672480e5980d9f42e4fd94c9770279543b.tar.gz
Qt-77f274672480e5980d9f42e4fd94c9770279543b.tar.bz2
doc: Example page now lists images used by the example
It just links to an empty page at the moment, i.e., it doesn't load the images. But I will add that. Task-number: QTBUG-4484
Diffstat (limited to 'tools/qdoc3/node.cpp')
-rw-r--r--tools/qdoc3/node.cpp12
1 files changed, 11 insertions, 1 deletions
diff --git a/tools/qdoc3/node.cpp b/tools/qdoc3/node.cpp
index 373002c..b855823 100644
--- a/tools/qdoc3/node.cpp
+++ b/tools/qdoc3/node.cpp
@@ -767,6 +767,9 @@ FakeNode::FakeNode(InnerNode *parent, const QString& name, SubType subtype)
}
/*!
+ Returns the fake node's full title, which is usually
+ just title(), but for some SubType values is different
+ from title()
*/
QString FakeNode::fullTitle() const
{
@@ -776,6 +779,12 @@ QString FakeNode::fullTitle() const
else
return title();
}
+ else if (sub == Image) {
+ if (title().isEmpty())
+ return name().mid(name().lastIndexOf('/') + 1) + " Image File";
+ else
+ return title();
+ }
else if (sub == HeaderFile) {
if (title().isEmpty())
return name();
@@ -788,13 +797,14 @@ QString FakeNode::fullTitle() const
}
/*!
+ Returns the subtitle.
*/
QString FakeNode::subTitle() const
{
if (!stle.isEmpty())
return stle;
- if (sub == File) {
+ if ((sub == File) || (sub == Image)) {
if (title().isEmpty() && name().contains("/"))
return name();
}