diff options
author | Martin Smith <martin.smith@digia.com> | 2013-04-16 15:03:31 +0200 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-04-17 12:29:55 +0200 |
commit | c77f7229d5c7e5017ddf90b1e9445251761878bf (patch) | |
tree | 9813a8246a64795bab2f214443347863a5a2b963 /src/tools/qdoc/node.h | |
parent | 3ae271523ff7fb951df16cfccfaf84c0aa298e16 (diff) |
qdoc: Add index of obsolete members to obsolete page
qdoc has been modified to emit a compact list of the
classes that have one or more obsolete members. The
command is:
\generatelist obsoletecppmembers
This generates an index of all such classes,
where each class name is a link to the class's
subpage of obsolete members. A class's subpage
of obsolete members is also accessible from the
class's reference page, but now it is also
accessible from this index.
Also, The command shown has been added to the
page obsoleteclasses.html in the generated
output. This page already contains the index
of obsolete classes.
Currently, no such output is generated for
QML types and QML types with obsolete members.
But qdoc does accept commands for those:
\generatelist obsoleteqmltypes
and
\generatelist obsoleteqmlmembers
...but qdoc doesn't know what to do with
those commands yet.
Task-number: QTBUG-30270
Change-Id: If19a3b977f64c948e4bd6f14a9e0a287419baa8a
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
Diffstat (limited to 'src/tools/qdoc/node.h')
-rw-r--r-- | src/tools/qdoc/node.h | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/src/tools/qdoc/node.h b/src/tools/qdoc/node.h index 642bcec06a..d1a95358f0 100644 --- a/src/tools/qdoc/node.h +++ b/src/tools/qdoc/node.h @@ -167,7 +167,11 @@ public: void setAccess(Access access) { access_ = access; } void setLocation(const Location& location) { loc = location; } void setDoc(const Doc& doc, bool replace = false); - void setStatus(Status status) { status_ = status; } + void setStatus(Status status) { + if (status_ == Obsolete && status == Deprecated) + return; + status_ = status; + } void setThreadSafeness(ThreadSafeness safeness) { safeness_ = safeness; } void setSince(const QString &since); void setRelates(InnerNode* pseudoParent); @@ -218,6 +222,8 @@ public: QString url() const; virtual QString nameForLists() const { return name_; } virtual QString outputFileName() const { return QString(); } + virtual QString obsoleteLink() const { return QString(); } + virtual void setObsoleteLink(const QString& ) { }; Access access() const { return access_; } QString accessString() const; @@ -253,6 +259,7 @@ public: QmlClassNode* qmlClassNode(); ClassNode* declarativeCppNode(); const QString& outputSubdirectory() const { return outSubDir_; } + void setOutputSubdirectory(const QString& t) { outSubDir_ = t; } QString fullDocumentName() const; static QString cleanId(QString str); QString idForNode() const; @@ -430,6 +437,8 @@ public: ClassNode(InnerNode* parent, const QString& name); virtual ~ClassNode() { } virtual bool isClass() const { return true; } + virtual QString obsoleteLink() const { return obsoleteLink_; } + virtual void setObsoleteLink(const QString& t) { obsoleteLink_ = t; }; void addBaseClass(Access access, ClassNode* node, @@ -455,6 +464,7 @@ private: QList<RelatedClass> ignoredBases; bool abstract_; QString sname; + QString obsoleteLink_; QmlClassNode* qmlelement; }; @@ -561,6 +571,8 @@ public: virtual void setAbstract(bool b) { abstract_ = b; } virtual bool isInternal() const { return (status() == Internal); } virtual QString qmlFullBaseName() const; + virtual QString obsoleteLink() const { return obsoleteLink_; } + virtual void setObsoleteLink(const QString& t) { obsoleteLink_ = t; }; const ImportList& importList() const { return importList_; } void setImportList(const ImportList& il) { importList_ = il; } const QString& qmlBaseName() const { return baseName_; } @@ -582,6 +594,7 @@ private: bool cnodeRequired_; ClassNode* cnode_; QString baseName_; + QString obsoleteLink_; QmlClassNode* baseNode_; ImportList importList_; }; |