diff options
author | David Boddie <dboddie@trolltech.com> | 2010-06-30 17:06:37 (GMT) |
---|---|---|
committer | David Boddie <dboddie@trolltech.com> | 2010-06-30 17:06:37 (GMT) |
commit | 0713442baa4120050e85c13998797415bb40efce (patch) | |
tree | 2735cae5573363fd5edceae71ae8b7af60518df2 /tools/qdoc3 | |
parent | 08478207ee9a6563ae63ebcef833925db6426bd8 (diff) | |
parent | 01648005f1f546dc0281155fecd94b4f47a94584 (diff) | |
download | Qt-0713442baa4120050e85c13998797415bb40efce.zip Qt-0713442baa4120050e85c13998797415bb40efce.tar.gz Qt-0713442baa4120050e85c13998797415bb40efce.tar.bz2 |
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2 into 4.7
Conflicts:
tools/qdoc3/test/qt-html-templates.qdocconf
Diffstat (limited to 'tools/qdoc3')
-rw-r--r-- | tools/qdoc3/codechunk.h | 2 | ||||
-rw-r--r-- | tools/qdoc3/codemarker.cpp | 12 | ||||
-rw-r--r-- | tools/qdoc3/cppcodeparser.cpp | 39 | ||||
-rw-r--r-- | tools/qdoc3/ditaxmlgenerator.cpp | 231 | ||||
-rw-r--r-- | tools/qdoc3/ditaxmlgenerator.h | 7 | ||||
-rw-r--r-- | tools/qdoc3/htmlgenerator.cpp | 10 | ||||
-rw-r--r-- | tools/qdoc3/node.cpp | 52 | ||||
-rw-r--r-- | tools/qdoc3/node.h | 161 | ||||
-rw-r--r-- | tools/qdoc3/pagegenerator.cpp | 3 | ||||
-rw-r--r-- | tools/qdoc3/test/qt-build-docs.qdocconf | 76 | ||||
-rw-r--r-- | tools/qdoc3/test/qt-build-docs_ja_JP.qdocconf | 67 | ||||
-rw-r--r-- | tools/qdoc3/test/qt-build-docs_zh_CN.qdocconf | 14 | ||||
-rw-r--r-- | tools/qdoc3/test/qt-html-templates.qdocconf | 6 | ||||
-rw-r--r-- | tools/qdoc3/tree.cpp | 10 |
14 files changed, 517 insertions, 173 deletions
diff --git a/tools/qdoc3/codechunk.h b/tools/qdoc3/codechunk.h index e78873c..a0c554e 100644 --- a/tools/qdoc3/codechunk.h +++ b/tools/qdoc3/codechunk.h @@ -55,7 +55,7 @@ QT_BEGIN_NAMESPACE /* The CodeChunk class represents a tiny piece of C++ code. - The class provides convertion between a list of lexemes and a string. It adds + The class provides conversion between a list of lexemes and a string. It adds spaces at the right place for consistent style. The tiny pieces of code it represents are data types, enum values, and default parameter values. diff --git a/tools/qdoc3/codemarker.cpp b/tools/qdoc3/codemarker.cpp index 818a91f..33ceaf5 100644 --- a/tools/qdoc3/codemarker.cpp +++ b/tools/qdoc3/codemarker.cpp @@ -257,6 +257,7 @@ QString CodeMarker::typified(const QString &string) QString CodeMarker::taggedNode(const Node* node) { QString tag; + QString name = node->name(); switch (node->type()) { case Node::Namespace: @@ -277,11 +278,20 @@ QString CodeMarker::taggedNode(const Node* node) case Node::Property: tag = QLatin1String("@property"); break; +#ifdef QDOC_QML + case Node::Fake: + if (node->subType() == Node::QmlClass) { + if (node->name().startsWith(QLatin1String("QML:"))) + name = name.mid(4); // remove the "QML:" prefix + } + tag = QLatin1String("@property"); + break; +#endif default: tag = QLatin1String("@unknown"); break; } - return QLatin1Char('<') + tag + QLatin1Char('>') + protect(node->name()) + return QLatin1Char('<') + tag + QLatin1Char('>') + protect(name) + QLatin1String("</") + tag + QLatin1Char('>'); } diff --git a/tools/qdoc3/cppcodeparser.cpp b/tools/qdoc3/cppcodeparser.cpp index 13678af..e4870e3 100644 --- a/tools/qdoc3/cppcodeparser.cpp +++ b/tools/qdoc3/cppcodeparser.cpp @@ -728,7 +728,10 @@ Node *CppCodeParser::processTopicCommand(const Doc& doc, if (n) classNode = static_cast<const ClassNode*>(n); } - return new QmlClassNode(tre->root(), names[0], classNode); + if (names[0].startsWith("Q")) + return new QmlClassNode(tre->root(), QLatin1String("QML:")+names[0], classNode); + else + return new QmlClassNode(tre->root(), names[0], classNode); } else if (command == COMMAND_QMLBASICTYPE) { #if 0 @@ -752,6 +755,8 @@ Node *CppCodeParser::processTopicCommand(const Doc& doc, QString type; QmlClassNode* qmlClass = 0; if (splitQmlMethodArg(doc,arg,type,element)) { + if (element.startsWith(QLatin1String("Q"))) + element = QLatin1String("QML:") + element; Node* n = tre->findNode(QStringList(element),Node::Fake); if (n && n->subType() == Node::QmlClass) { qmlClass = static_cast<QmlClassNode*>(n); @@ -1850,16 +1855,40 @@ bool CppCodeParser::matchProperty(InnerNode *parent) else if (key == "WRITE") { tre->addPropertyFunction(property, value, PropertyNode::Setter); property->setWritable(true); - } else if (key == "STORED") + } + else if (key == "STORED") property->setStored(value.toLower() == "true"); - else if (key == "DESIGNABLE") - property->setDesignable(value.toLower() == "true"); + else if (key == "DESIGNABLE") { + QString v = value.toLower(); + if (v == "true") + property->setDesignable(true); + else if (v == "false") + property->setDesignable(false); + else { + property->setDesignable(false); + property->setRuntimeDesFunc(value); + } + } else if (key == "RESET") tre->addPropertyFunction(property, value, PropertyNode::Resetter); else if (key == "NOTIFY") { tre->addPropertyFunction(property, value, PropertyNode::Notifier); } - + else if (key == "SCRIPTABLE") { + QString v = value.toLower(); + if (v == "true") + property->setScriptable(true); + else if (v == "false") + property->setScriptable(false); + else { + property->setScriptable(false); + property->setRuntimeScrFunc(value); + } + } + else if (key == "COSTANT") + property->setConstant(); + else if (key == "FINAL") + property->setFinal(); } match(Tok_RightParen); return true; diff --git a/tools/qdoc3/ditaxmlgenerator.cpp b/tools/qdoc3/ditaxmlgenerator.cpp index be734ac..d7a9c9e 100644 --- a/tools/qdoc3/ditaxmlgenerator.cpp +++ b/tools/qdoc3/ditaxmlgenerator.cpp @@ -1,3 +1,4 @@ + /**************************************************************************** ** ** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). @@ -1465,7 +1466,6 @@ DitaXmlGenerator::generateClassLikeNode(const InnerNode* inner, CodeMarker* mark writeFunctions((*s),cn,marker); } else if ((*s).name == "Member Type Documentation") { - writeNestedClasses((*s),cn,marker); writeEnumerations((*s),cn,marker); writeTypedefs((*s),cn,marker); } @@ -1475,6 +1475,9 @@ DitaXmlGenerator::generateClassLikeNode(const InnerNode* inner, CodeMarker* mark else if ((*s).name == "Property Documentation") { writeProperties((*s),cn,marker); } + else if ((*s).name == "Macro Documentation") { + writeMacros((*s),cn,marker); + } ++s; } writer.writeEndElement(); // </cxxClass> @@ -4573,7 +4576,8 @@ void DitaXmlGenerator::writeLocation(const Node* n) s2 = CXXTYPEDEFDECLARATIONFILE; s3 = CXXTYPEDEFDECLARATIONFILELINE; } - else if (n->type() == Node::Property) { + else if ((n->type() == Node::Property) || + (n->type() == Node::Variable)) { s1 = CXXVARIABLEAPIITEMLOCATION; s2 = CXXVARIABLEDECLARATIONFILE; s3 = CXXVARIABLEDECLARATIONFILELINE; @@ -4716,6 +4720,8 @@ void DitaXmlGenerator::writeParameters(const FunctionNode* fn, CodeMarker* marke writer.writeStartElement(CXXFUNCTIONPARAMETER); writer.writeStartElement(CXXFUNCTIONPARAMETERDECLAREDTYPE); writer.writeCharacters((*p).leftType()); + if (!(*p).rightType().isEmpty()) + writer.writeCharacters((*p).rightType()); writer.writeEndElement(); // <cxxFunctionParameterDeclaredType> writer.writeStartElement(CXXFUNCTIONPARAMETERDECLARATIONNAME); writer.writeCharacters((*p).name()); @@ -4732,12 +4738,6 @@ void DitaXmlGenerator::writeParameters(const FunctionNode* fn, CodeMarker* marke } } -void DitaXmlGenerator::writeNestedClasses(const Section& s, - const ClassNode* cn, - CodeMarker* marker) -{ -} - void DitaXmlGenerator::writeEnumerations(const Section& s, const ClassNode* cn, CodeMarker* marker) @@ -4888,12 +4888,6 @@ void DitaXmlGenerator::writeTypedefs(const Section& s, } } -void DitaXmlGenerator::writeDataMembers(const Section& s, - const ClassNode* cn, - CodeMarker* marker) -{ -} - void DitaXmlGenerator::writeProperties(const Section& s, const ClassNode* cn, CodeMarker* marker) @@ -4914,9 +4908,9 @@ void DitaXmlGenerator::writeProperties(const Section& s, writer.writeAttribute("value",pn->accessString()); writer.writeEndElement(); // <cxxVariableAccessSpecifier> - if (!pn->dataType().isEmpty()) { + if (!pn->qualifiedDataType().isEmpty()) { writer.writeStartElement(CXXVARIABLEDECLAREDTYPE); - writer.writeCharacters(pn->dataType()); + writer.writeCharacters(pn->qualifiedDataType()); writer.writeEndElement(); // <cxxVariableDeclaredType> } QString fq = fullQualification(pn); @@ -4925,11 +4919,49 @@ void DitaXmlGenerator::writeProperties(const Section& s, writer.writeCharacters(fq); writer.writeEndElement(); // <cxxVariableScopedName> } + + writer.writeStartElement(CXXVARIABLEPROTOTYPE); + writer.writeCharacters("Q_PROPERTY("); + writer.writeCharacters(pn->qualifiedDataType()); + writer.writeCharacters(" "); + writer.writeCharacters(pn->name()); + writePropParams("READ",pn->getters()); + writePropParams("WRITE",pn->setters()); + writePropParams("RESET",pn->resetters()); + writePropParams("NOTIFY",pn->notifiers()); + if (pn->isDesignable() != pn->designableDefault()) { + writer.writeCharacters(" DESIGNABLE "); + if (!pn->runtimeDesignabilityFunction().isEmpty()) + writer.writeCharacters(pn->runtimeDesignabilityFunction()); + else + writer.writeCharacters(pn->isDesignable() ? "true" : "false"); + } + if (pn->isScriptable() != pn->scriptableDefault()) { + writer.writeCharacters(" SCRIPTABLE "); + if (!pn->runtimeScriptabilityFunction().isEmpty()) + writer.writeCharacters(pn->runtimeScriptabilityFunction()); + else + writer.writeCharacters(pn->isScriptable() ? "true" : "false"); + } + if (pn->isWritable() != pn->writableDefault()) { + writer.writeCharacters(" STORED "); + writer.writeCharacters(pn->isStored() ? "true" : "false"); + } + if (pn->isUser() != pn->userDefault()) { + writer.writeCharacters(" USER "); + writer.writeCharacters(pn->isUser() ? "true" : "false"); + } + if (pn->isConstant()) + writer.writeCharacters(" CONSTANT"); + if (pn->isFinal()) + writer.writeCharacters(" FINAL"); + writer.writeCharacters(")"); + writer.writeEndElement(); // <cxxVariablePrototype> + writer.writeStartElement(CXXVARIABLENAMELOOKUP); writer.writeCharacters(pn->parent()->name() + "::" + pn->name()); writer.writeEndElement(); // <cxxVariableNameLookup> - if (pn->overriddenFrom() != 0) { PropertyNode* opn = (PropertyNode*)pn->overriddenFrom(); writer.writeStartElement(CXXVARIABLEREIMPLEMENTED); @@ -4954,4 +4986,169 @@ void DitaXmlGenerator::writeProperties(const Section& s, } } +void DitaXmlGenerator::writeDataMembers(const Section& s, + const ClassNode* cn, + CodeMarker* marker) +{ + NodeList::ConstIterator m = s.members.begin(); + while (m != s.members.end()) { + if ((*m)->type() == Node::Variable) { + const VariableNode* vn = static_cast<const VariableNode*>(*m); + writer.writeStartElement(CXXVARIABLE); + writer.writeAttribute("id",vn->guid()); + writer.writeStartElement(APINAME); + writer.writeCharacters(vn->name()); + writer.writeEndElement(); // </apiName> + generateBrief(vn,marker); + writer.writeStartElement(CXXVARIABLEDETAIL); + writer.writeStartElement(CXXVARIABLEDEFINITION); + writer.writeStartElement(CXXVARIABLEACCESSSPECIFIER); + writer.writeAttribute("value",vn->accessString()); + writer.writeEndElement(); // <cxxVariableAccessSpecifier> + + if (vn->isStatic()) { + writer.writeStartElement(CXXVARIABLESTORAGECLASSSPECIFIERSTATIC); + writer.writeAttribute("name","static"); + writer.writeAttribute("value","static"); + writer.writeEndElement(); // <cxxVariableStorageClassSpecifierStatic> + } + + writer.writeStartElement(CXXVARIABLEDECLAREDTYPE); + writer.writeCharacters(vn->leftType()); + if (!vn->rightType().isEmpty()) + writer.writeCharacters(vn->rightType()); + writer.writeEndElement(); // <cxxVariableDeclaredType> + + QString fq = fullQualification(vn); + if (!fq.isEmpty()) { + writer.writeStartElement(CXXVARIABLESCOPEDNAME); + writer.writeCharacters(fq); + writer.writeEndElement(); // <cxxVariableScopedName> + } + + writer.writeStartElement(CXXVARIABLEPROTOTYPE); + writer.writeCharacters(vn->leftType() + " "); + //writer.writeCharacters(vn->parent()->name() + "::" + vn->name()); + writer.writeCharacters(vn->name()); + if (!vn->rightType().isEmpty()) + writer.writeCharacters(vn->rightType()); + writer.writeEndElement(); // <cxxVariablePrototype> + + writer.writeStartElement(CXXVARIABLENAMELOOKUP); + writer.writeCharacters(vn->parent()->name() + "::" + vn->name()); + writer.writeEndElement(); // <cxxVariableNameLookup> + + writeLocation(vn); + writer.writeEndElement(); // <cxxVariableDefinition> + writer.writeStartElement(APIDESC); + + if (!vn->doc().isEmpty()) { + generateBody(vn, marker); + } + + writer.writeEndElement(); // </apiDesc> + writer.writeEndElement(); // </cxxVariableDetail> + writer.writeEndElement(); // </cxxVariable> + } + ++m; + } +} + +void DitaXmlGenerator::writeMacros(const Section& s, + const ClassNode* cn, + CodeMarker* marker) +{ + NodeList::ConstIterator m = s.members.begin(); + while (m != s.members.end()) { + if ((*m)->type() == Node::Function) { + const FunctionNode* fn = static_cast<const FunctionNode*>(*m); + if (fn->isMacro()) { + writer.writeStartElement(CXXDEFINE); + writer.writeAttribute("id",fn->guid()); + writer.writeStartElement(APINAME); + writer.writeCharacters(fn->name()); + writer.writeEndElement(); // </apiName> + generateBrief(fn,marker); + writer.writeStartElement(CXXDEFINEDETAIL); + writer.writeStartElement(CXXDEFINEDEFINITION); + writer.writeStartElement(CXXDEFINEACCESSSPECIFIER); + writer.writeAttribute("value",fn->accessString()); + writer.writeEndElement(); // <cxxDefineAccessSpecifier> + + writer.writeStartElement(CXXDEFINEPROTOTYPE); + writer.writeCharacters("#define "); + writer.writeCharacters(fn->name()); + if (fn->metaness() == FunctionNode::MacroWithParams) { + QStringList params = fn->parameterNames(); + if (!params.isEmpty()) { + writer.writeCharacters("("); + for (int i = 0; i < params.size(); ++i) { + if (params[i].isEmpty()) + writer.writeCharacters("..."); + else + writer.writeCharacters(params[i]); + if ((i+1) < params.size()) + writer.writeCharacters(", "); + } + writer.writeCharacters(")"); + } + } + writer.writeEndElement(); // <cxxDefinePrototype> + + writer.writeStartElement(CXXDEFINENAMELOOKUP); + writer.writeCharacters(fn->name()); + writer.writeEndElement(); // <cxxDefineNameLookup> + + if (fn->reimplementedFrom() != 0) { + FunctionNode* rfn = (FunctionNode*)fn->reimplementedFrom(); + writer.writeStartElement(CXXDEFINEREIMPLEMENTED); + writer.writeAttribute("href",rfn->ditaXmlHref()); + writer.writeCharacters(marker->plainFullName(rfn)); + writer.writeEndElement(); // </cxxDefineReimplemented> + } + + if (fn->metaness() == FunctionNode::MacroWithParams) { + QStringList params = fn->parameterNames(); + if (!params.isEmpty()) { + writer.writeStartElement(CXXDEFINEPARAMETERS); + for (int i = 0; i < params.size(); ++i) { + writer.writeStartElement(CXXDEFINEPARAMETER); + writer.writeStartElement(CXXDEFINEPARAMETERDECLARATIONNAME); + writer.writeCharacters(params[i]); + writer.writeEndElement(); // <cxxDefineParameterDeclarationName> + writer.writeEndElement(); // <cxxDefineParameter> + } + writer.writeEndElement(); // <cxxDefineParameters> + } + } + + writeLocation(fn); + writer.writeEndElement(); // <cxxDefineDefinition> + writer.writeStartElement(APIDESC); + + if (!fn->doc().isEmpty()) { + generateBody(fn, marker); + } + + writer.writeEndElement(); // </apiDesc> + writer.writeEndElement(); // </cxxDefineDetail> + writer.writeEndElement(); // </cxxDefine> + } + } + ++m; + } +} + +void DitaXmlGenerator::writePropParams(const QString& tag, const NodeList& nlist) +{ + NodeList::const_iterator n = nlist.begin(); + while (n != nlist.end()) { + writer.writeCharacters(" "); + writer.writeCharacters(tag); + writer.writeCharacters(" "); + writer.writeCharacters((*n)->name()); + ++n; + } +} + QT_END_NAMESPACE diff --git a/tools/qdoc3/ditaxmlgenerator.h b/tools/qdoc3/ditaxmlgenerator.h index 8c7e439..446f735 100644 --- a/tools/qdoc3/ditaxmlgenerator.h +++ b/tools/qdoc3/ditaxmlgenerator.h @@ -118,9 +118,6 @@ class DitaXmlGenerator : public PageGenerator const ClassNode* cn, CodeMarker* marker); void writeParameters(const FunctionNode* fn, CodeMarker* marker); - void writeNestedClasses(const Section& s, - const ClassNode* cn, - CodeMarker* marker); void writeEnumerations(const Section& s, const ClassNode* cn, CodeMarker* marker); @@ -133,6 +130,10 @@ class DitaXmlGenerator : public PageGenerator void writeProperties(const Section& s, const ClassNode* cn, CodeMarker* marker); + void writeMacros(const Section& s, + const ClassNode* cn, + CodeMarker* marker); + void writePropParams(const QString& tag, const NodeList& nlist); private: enum SubTitleSize { SmallSubTitle, LargeSubTitle }; diff --git a/tools/qdoc3/htmlgenerator.cpp b/tools/qdoc3/htmlgenerator.cpp index 339c390..b93db4f 100644 --- a/tools/qdoc3/htmlgenerator.cpp +++ b/tools/qdoc3/htmlgenerator.cpp @@ -1891,6 +1891,16 @@ void HtmlGenerator::generateFooter(const Node *node) else { out() << " <script src=\"scripts/functions.js\" type=\"text/javascript\"></script>\n"; + out() << " <!-- <script type=\"text/javascript\">\n"; + out() << " var _gaq = _gaq || [];\n"; + out() << " _gaq.push(['_setAccount', 'UA-4457116-5']);\n"; + out() << " _gaq.push(['_trackPageview']);\n"; + out() << " (function() {\n"; + out() << " var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;\n"; + out() << " ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';\n"; + out() << " var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);\n"; + out() << " })();\n"; + out() << " </script> -->\n"; out() << "</body>\n"; } out() << "</html>\n"; diff --git a/tools/qdoc3/node.cpp b/tools/qdoc3/node.cpp index 26957ac..b077074 100644 --- a/tools/qdoc3/node.cpp +++ b/tools/qdoc3/node.cpp @@ -923,6 +923,14 @@ FakeNode::FakeNode(InnerNode *parent, const QString& name, SubType subtype) } /*! + Returns the fake node's title. This is used for the page title. +*/ +QString FakeNode::title() const +{ + return tle; +} + +/*! Returns the fake node's full title, which is usually just title(), but for some SubType values is different from title() @@ -1287,21 +1295,39 @@ void FunctionNode::debug() const /*! \class PropertyNode + + This class describes one instance of using the Q_PROPERTY macro. */ /*! + The constructor sets the \a parent and the \a name, but + everything else is set to default values. */ PropertyNode::PropertyNode(InnerNode *parent, const QString& name) : LeafNode(Property, parent, name), sto(Trool_Default), des(Trool_Default), + scr(Trool_Default), + wri(Trool_Default), + usr(Trool_Default), + cst(false), + fnl(false), overrides(0) { + // nothing. } /*! + Sets this property's \e {overridden from} property to + \a baseProperty, which indicates that this property + overrides \a baseProperty. To begin with, all the values + in this property are set to the corresponding values in + \a baseProperty. + + We probably should ensure that the constant and final + attributes are not being overridden improperly. */ -void PropertyNode::setOverriddenFrom(const PropertyNode *baseProperty) +void PropertyNode::setOverriddenFrom(const PropertyNode* baseProperty) { for (int i = 0; i < NumFunctionRoles; ++i) { if (funcs[i].isEmpty()) @@ -1311,6 +1337,12 @@ void PropertyNode::setOverriddenFrom(const PropertyNode *baseProperty) sto = baseProperty->sto; if (des == Trool_Default) des = baseProperty->des; + if (scr == Trool_Default) + scr = baseProperty->scr; + if (wri == Trool_Default) + wri = baseProperty->wri; + if (usr == Trool_Default) + usr = baseProperty->usr; overrides = baseProperty; } @@ -1336,7 +1368,9 @@ QString PropertyNode::qualifiedDataType() const } } -/*! +/*! Converts the \a boolean value to an enum representation + of the boolean type, which includes an enum value for the + \e {default value} of the item, i.e. true, false, or default. */ PropertyNode::Trool PropertyNode::toTrool(bool boolean) { @@ -1344,6 +1378,15 @@ PropertyNode::Trool PropertyNode::toTrool(bool boolean) } /*! + Converts the enum \a troolean back to a boolean value. + If \a troolean is neither the true enum value nor the + false enum value, the boolean value returned is + \a defaultValue. + + Note that runtimeDesignabilityFunction() should be called + first. If that function returns the name of a function, it + means the function must be called at runtime to determine + whether the property is Designable. */ bool PropertyNode::fromTrool(Trool troolean, bool defaultValue) { @@ -1392,7 +1435,10 @@ QmlClassNode::QmlClassNode(InnerNode *parent, const ClassNode* cn) : FakeNode(parent, name, QmlClass), cnode(cn) { - setTitle((qmlOnly ? "" : "QML ") + name + " Element"); + if (name.startsWith(QLatin1String("QML:"))) + setTitle((qmlOnly ? QLatin1String("") : QLatin1String("QML ")) + name.mid(4) + QLatin1String(" Element")); + else + setTitle((qmlOnly ? QLatin1String("") : QLatin1String("QML ")) + name + QLatin1String(" Element")); } /*! diff --git a/tools/qdoc3/node.h b/tools/qdoc3/node.h index 37f2f26..e9f2d74 100644 --- a/tools/qdoc3/node.h +++ b/tools/qdoc3/node.h @@ -153,7 +153,7 @@ class Node void setStatus(Status status) { sta = status; } void setThreadSafeness(ThreadSafeness safeness) { saf = safeness; } void setSince(const QString &since) { sinc = since; } - void setRelates(InnerNode *pseudoParent); + void setRelates(InnerNode* pseudoParent); void setModuleName(const QString &module) { mod = module; } void setLink(LinkType linkType, const QString &link, const QString &desc); void setUrl(const QString &url); @@ -167,8 +167,8 @@ class Node virtual bool isQmlNode() const { return false; } Type type() const { return typ; } virtual SubType subType() const { return NoSubType; } - InnerNode *parent() const { return par; } - InnerNode *relates() const { return rel; } + InnerNode* parent() const { return par; } + InnerNode* relates() const { return rel; } const QString& name() const { return nam; } QMap<LinkType, QPair<QString,QString> > links() const { return linkMap; } QString moduleName() const; @@ -195,7 +195,7 @@ class Node QString ditaXmlHref(); protected: - Node(Type type, InnerNode *parent, const QString& name); + Node(Type type, InnerNode* parent, const QString& name); private: @@ -212,8 +212,8 @@ class Node PageType pageTyp : 4; Status sta : 3; #endif - InnerNode *par; - InnerNode *rel; + InnerNode* par; + InnerNode* rel; QString nam; Location loc; Doc d; @@ -228,35 +228,35 @@ class Node class FunctionNode; class EnumNode; -typedef QList<Node *> NodeList; +typedef QList<Node*> NodeList; class InnerNode : public Node { public: virtual ~InnerNode(); - Node *findNode(const QString& name); - Node *findNode(const QString& name, Type type); - FunctionNode *findFunctionNode(const QString& name); - FunctionNode *findFunctionNode(const FunctionNode *clone); + Node* findNode(const QString& name); + Node* findNode(const QString& name, Type type); + FunctionNode* findFunctionNode(const QString& name); + FunctionNode* findFunctionNode(const FunctionNode* clone); void addInclude(const QString &include); void setIncludes(const QStringList &includes); - void setOverload(const FunctionNode *func, bool overlode); + void setOverload(const FunctionNode* func, bool overlode); void normalizeOverloads(); void makeUndocumentedChildrenInternal(); void deleteChildren(); void removeFromRelated(); virtual bool isInnerNode() const; - const Node *findNode(const QString& name) const; - const Node *findNode(const QString& name, Type type) const; - const FunctionNode *findFunctionNode(const QString& name) const; - const FunctionNode *findFunctionNode(const FunctionNode *clone) const; - const EnumNode *findEnumNodeForValue(const QString &enumValue) const; + const Node* findNode(const QString& name) const; + const Node* findNode(const QString& name, Type type) const; + const FunctionNode* findFunctionNode(const QString& name) const; + const FunctionNode* findFunctionNode(const FunctionNode* clone) const; + const EnumNode* findEnumNodeForValue(const QString &enumValue) const; const NodeList & childNodes() const { return children; } const NodeList & relatedNodes() const { return related; } int count() const { return children.size(); } - int overloadNumber(const FunctionNode *func) const; + int overloadNumber(const FunctionNode* func) const; int numOverloads(const QString& funcName) const; NodeList overloads(const QString &funcName) const; const QStringList& includes() const { return inc; } @@ -269,23 +269,23 @@ class InnerNode : public Node virtual void setAbstract(bool ) { } protected: - InnerNode(Type type, InnerNode *parent, const QString& name); + InnerNode(Type type, InnerNode* parent, const QString& name); private: friend class Node; - static bool isSameSignature(const FunctionNode *f1, const FunctionNode *f2); - void addChild(Node *child); - void removeChild(Node *child); - void removeRelated(Node *pseudoChild); + static bool isSameSignature(const FunctionNode* f1, const FunctionNode* f2); + void addChild(Node* child); + void removeChild(Node* child); + void removeRelated(Node* pseudoChild); QStringList pageKeywds; QStringList inc; NodeList children; NodeList enumChildren; NodeList related; - QMap<QString, Node *> childMap; - QMap<QString, Node *> primaryFunctionMap; + QMap<QString, Node*> childMap; + QMap<QString, Node*> primaryFunctionMap; QMap<QString, NodeList> secondaryFunctionMap; }; @@ -304,7 +304,7 @@ class LeafNode : public Node class NamespaceNode : public InnerNode { public: - NamespaceNode(InnerNode *parent, const QString& name); + NamespaceNode(InnerNode* parent, const QString& name); virtual ~NamespaceNode() { } }; @@ -329,11 +329,11 @@ struct RelatedClass class ClassNode : public InnerNode { public: - ClassNode(InnerNode *parent, const QString& name); + ClassNode(InnerNode* parent, const QString& name); virtual ~ClassNode() { } void addBaseClass(Access access, - ClassNode *node, + ClassNode* node, const QString &dataTypeWithTemplateArgs = ""); void fixBaseClasses(); @@ -363,17 +363,17 @@ class FakeNode : public InnerNode { public: - FakeNode(InnerNode *parent, const QString& name, SubType subType); + FakeNode(InnerNode* parent, const QString& name, SubType subType); virtual ~FakeNode() { } void setTitle(const QString &title) { tle = title; } void setSubTitle(const QString &subTitle) { stle = subTitle; } - void addGroupMember(Node *node) { gr.append(node); } + void addGroupMember(Node* node) { gr.append(node); } SubType subType() const { return sub; } - QString title() const { return tle; } - QString fullTitle() const; - QString subTitle() const; + virtual QString title() const; + virtual QString fullTitle() const; + virtual QString subTitle() const; const NodeList &groupMembers() const { return gr; } virtual QString nameForLists() const { return title(); } @@ -388,7 +388,7 @@ class FakeNode : public InnerNode class QmlClassNode : public FakeNode { public: - QmlClassNode(InnerNode *parent, + QmlClassNode(InnerNode* parent, const QString& name, const ClassNode* cn); virtual ~QmlClassNode(); @@ -411,7 +411,7 @@ class QmlClassNode : public FakeNode class QmlBasicTypeNode : public FakeNode { public: - QmlBasicTypeNode(InnerNode *parent, + QmlBasicTypeNode(InnerNode* parent, const QString& name); virtual ~QmlBasicTypeNode() { } virtual bool isQmlNode() const { return true; } @@ -498,41 +498,41 @@ class TypedefNode; class EnumNode : public LeafNode { public: - EnumNode(InnerNode *parent, const QString& name); + EnumNode(InnerNode* parent, const QString& name); virtual ~EnumNode() { } void addItem(const EnumItem& item); - void setFlagsType(TypedefNode *typedeff); + void setFlagsType(TypedefNode* typedeff); bool hasItem(const QString &name) const { return names.contains(name); } const QList<EnumItem>& items() const { return itms; } Access itemAccess(const QString& name) const; - const TypedefNode *flagsType() const { return ft; } + const TypedefNode* flagsType() const { return ft; } QString itemValue(const QString &name) const; private: QList<EnumItem> itms; QSet<QString> names; - const TypedefNode *ft; + const TypedefNode* ft; }; class TypedefNode : public LeafNode { public: - TypedefNode(InnerNode *parent, const QString& name); + TypedefNode(InnerNode* parent, const QString& name); virtual ~TypedefNode() { } - const EnumNode *associatedEnum() const { return ae; } + const EnumNode* associatedEnum() const { return ae; } private: - void setAssociatedEnum(const EnumNode *enume); + void setAssociatedEnum(const EnumNode* enume); friend class EnumNode; - const EnumNode *ae; + const EnumNode* ae; }; -inline void EnumNode::setFlagsType(TypedefNode *typedeff) +inline void EnumNode::setFlagsType(TypedefNode* typedeff) { ft = typedeff; typedeff->setAssociatedEnum(this); @@ -584,8 +584,8 @@ class FunctionNode : public LeafNode Native }; enum Virtualness { NonVirtual, ImpureVirtual, PureVirtual }; - FunctionNode(InnerNode *parent, const QString &name); - FunctionNode(Type type, InnerNode *parent, const QString &name, bool attached); + FunctionNode(InnerNode* parent, const QString &name); + FunctionNode(Type type, InnerNode* parent, const QString &name, bool attached); virtual ~FunctionNode() { } void setReturnType(const QString& returnType) { rt = returnType; } @@ -598,8 +598,8 @@ class FunctionNode : public LeafNode void setReimp(bool r); void addParameter(const Parameter& parameter); inline void setParameters(const QList<Parameter>& parameters); - void borrowParameterNames(const FunctionNode *source); - void setReimplementedFrom(FunctionNode *from); + void borrowParameterNames(const FunctionNode* source); + void setReimplementedFrom(FunctionNode* from); const QString& returnType() const { return rt; } Metaness metaness() const { return met; } @@ -616,9 +616,9 @@ class FunctionNode : public LeafNode int numOverloads() const; const QList<Parameter>& parameters() const { return params; } QStringList parameterNames() const; - const FunctionNode *reimplementedFrom() const { return rf; } - const QList<FunctionNode *> &reimplementedBy() const { return rb; } - const PropertyNode *associatedProperty() const { return ap; } + const FunctionNode* reimplementedFrom() const { return rf; } + const QList<FunctionNode*> &reimplementedBy() const { return rb; } + const PropertyNode* associatedProperty() const { return ap; } const QStringList& parentPath() const { return pp; } QStringList reconstructParams(bool values = false) const; @@ -632,7 +632,7 @@ class FunctionNode : public LeafNode void debug() const; private: - void setAssociatedProperty(PropertyNode *property); + void setAssociatedProperty(PropertyNode* property); friend class InnerNode; friend class PropertyNode; @@ -652,9 +652,9 @@ class FunctionNode : public LeafNode bool reimp: 1; bool att: 1; QList<Parameter> params; - const FunctionNode *rf; - const PropertyNode *ap; - QList<FunctionNode *> rb; + const FunctionNode* rf; + const PropertyNode* ap; + QList<FunctionNode*> rb; }; class PropertyNode : public LeafNode @@ -663,16 +663,22 @@ class PropertyNode : public LeafNode enum FunctionRole { Getter, Setter, Resetter, Notifier }; enum { NumFunctionRoles = Notifier + 1 }; - PropertyNode(InnerNode *parent, const QString& name); + PropertyNode(InnerNode* parent, const QString& name); virtual ~PropertyNode() { } void setDataType(const QString& dataType) { dt = dataType; } - void addFunction(FunctionNode *function, FunctionRole role); - void addSignal(FunctionNode *function, FunctionRole role); + void addFunction(FunctionNode* function, FunctionRole role); + void addSignal(FunctionNode* function, FunctionRole role); void setStored(bool stored) { sto = toTrool(stored); } void setDesignable(bool designable) { des = toTrool(designable); } + void setScriptable(bool scriptable) { scr = toTrool(scriptable); } void setWritable(bool writable) { wri = toTrool(writable); } - void setOverriddenFrom(const PropertyNode *baseProperty); + void setUser(bool user) { usr = toTrool(user); } + void setOverriddenFrom(const PropertyNode* baseProperty); + void setRuntimeDesFunc(const QString& rdf) { runtimeDesFunc = rdf; } + void setRuntimeScrFunc(const QString& scrf) { runtimeScrFunc = scrf; } + void setConstant() { cst = true; } + void setFinal() { fnl = true; } const QString &dataType() const { return dt; } QString qualifiedDataType() const; @@ -684,8 +690,20 @@ class PropertyNode : public LeafNode NodeList notifiers() const { return functions(Notifier); } bool isStored() const { return fromTrool(sto, storedDefault()); } bool isDesignable() const { return fromTrool(des, designableDefault()); } + bool isScriptable() const { return fromTrool(scr, scriptableDefault()); } + const QString& runtimeDesignabilityFunction() const { return runtimeDesFunc; } + const QString& runtimeScriptabilityFunction() const { return runtimeScrFunc; } bool isWritable() const { return fromTrool(wri, writableDefault()); } - const PropertyNode *overriddenFrom() const { return overrides; } + bool isUser() const { return fromTrool(usr, userDefault()); } + bool isConstant() const { return cst; } + bool isFinal() const { return fnl; } + const PropertyNode* overriddenFrom() const { return overrides; } + + bool storedDefault() const { return true; } + bool userDefault() const { return false; } + bool designableDefault() const { return !setters().isEmpty(); } + bool scriptableDefault() const { return true; } + bool writableDefault() const { return !setters().isEmpty(); } private: enum Trool { Trool_True, Trool_False, Trool_Default }; @@ -693,16 +711,18 @@ class PropertyNode : public LeafNode static Trool toTrool(bool boolean); static bool fromTrool(Trool troolean, bool defaultValue); - bool storedDefault() const { return true; } - bool designableDefault() const { return !setters().isEmpty(); } - bool writableDefault() const { return !setters().isEmpty(); } - QString dt; + QString runtimeDesFunc; + QString runtimeScrFunc; NodeList funcs[NumFunctionRoles]; Trool sto; Trool des; + Trool scr; Trool wri; - const PropertyNode *overrides; + Trool usr; + bool cst; + bool fnl; + const PropertyNode* overrides; }; inline void FunctionNode::setParameters(const QList<Parameter> ¶meters) @@ -710,13 +730,13 @@ inline void FunctionNode::setParameters(const QList<Parameter> ¶meters) params = parameters; } -inline void PropertyNode::addFunction(FunctionNode *function, FunctionRole role) +inline void PropertyNode::addFunction(FunctionNode* function, FunctionRole role) { funcs[(int)role].append(function); function->setAssociatedProperty(this); } -inline void PropertyNode::addSignal(FunctionNode *function, FunctionRole role) +inline void PropertyNode::addSignal(FunctionNode* function, FunctionRole role) { funcs[(int)role].append(function); } @@ -732,7 +752,7 @@ inline NodeList PropertyNode::functions() const class VariableNode : public LeafNode { public: - VariableNode(InnerNode *parent, const QString &name); + VariableNode(InnerNode* parent, const QString &name); virtual ~VariableNode() { } void setLeftType(const QString &leftType) { lt = leftType; } @@ -750,15 +770,16 @@ class VariableNode : public LeafNode bool sta; }; -inline VariableNode::VariableNode(InnerNode *parent, const QString &name) +inline VariableNode::VariableNode(InnerNode* parent, const QString &name) : LeafNode(Variable, parent, name), sta(false) { + // nothing. } class TargetNode : public LeafNode { public: - TargetNode(InnerNode *parent, const QString& name); + TargetNode(InnerNode* parent, const QString& name); virtual ~TargetNode() { } virtual bool isInnerNode() const; diff --git a/tools/qdoc3/pagegenerator.cpp b/tools/qdoc3/pagegenerator.cpp index cd364ef..a187c2e 100644 --- a/tools/qdoc3/pagegenerator.cpp +++ b/tools/qdoc3/pagegenerator.cpp @@ -209,7 +209,8 @@ QString PageGenerator::fileBase(const Node *node) const */ if ((p->subType() == Node::QmlClass) || (p->subType() == Node::QmlBasicType)) { - base.prepend("qml-"); + if (!base.startsWith(QLatin1String("QML:"))) + base.prepend("qml-"); } #endif if (!pp || pp->name().isEmpty() || pp->type() == Node::Fake) diff --git a/tools/qdoc3/test/qt-build-docs.qdocconf b/tools/qdoc3/test/qt-build-docs.qdocconf index 09cbc45..140b81f 100644 --- a/tools/qdoc3/test/qt-build-docs.qdocconf +++ b/tools/qdoc3/test/qt-build-docs.qdocconf @@ -22,43 +22,43 @@ qhp.Qt.indexTitle = Qt Reference Documentation # Files not referenced in any qdoc file (last four are needed by qtdemo) # See also extraimages.HTML qhp.Qt.extraFiles = index.html \ - images/bg_l.png \ - images/bg_l_blank.png \ - images/bg_r.png \ - images/box_bg.png \ - images/breadcrumb.png \ - images/bullet_gt.png \ - images/bullet_dn.png \ - images/bullet_sq.png \ - images/bullet_up.png \ - images/feedbackground.png \ - images/horBar.png \ - images/page.png \ - images/page_bg.png \ - images/sprites-combined.png \ - images/arrow-down.png \ - images/spinner.gif \ - images/stylesheet-coffee-plastique.png \ - images/taskmenuextension-example.png \ - images/coloreditorfactoryimage.png \ - images/dynamiclayouts-example.png \ - scripts/functions.js \ - scripts/jquery.js \ - scripts/shBrushCpp.js \ - scripts/shCore.js \ - scripts/shLegacy.js \ - scripts/narrow.js \ - scripts/superfish.js \ - style/shCore.css \ - style/shThemeDefault.css \ - style/narrow.css \ - style/superfish.css \ - style/superfish_skin.css \ - style/OfflineStyle.css \ - style/style_ie6.css \ - style/style_ie7.css \ - style/style_ie8.css \ - style/style.css + images/bg_l.png \ + images/bg_l_blank.png \ + images/bg_r.png \ + images/box_bg.png \ + images/breadcrumb.png \ + images/bullet_gt.png \ + images/bullet_dn.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/feedbackground.png \ + images/horBar.png \ + images/page.png \ + images/page_bg.png \ + images/sprites-combined.png \ + images/arrow-down.png \ + images/spinner.gif \ + images/stylesheet-coffee-plastique.png \ + images/taskmenuextension-example.png \ + images/coloreditorfactoryimage.png \ + images/dynamiclayouts-example.png \ + scripts/functions.js \ + scripts/jquery.js \ + scripts/shBrushCpp.js \ + scripts/shCore.js \ + scripts/shLegacy.js \ + scripts/narrow.js \ + scripts/superfish.js \ + style/shCore.css \ + style/shThemeDefault.css \ + style/narrow.css \ + style/superfish.css \ + style/superfish_skin.css \ + style/OfflineStyle.css \ + style/style_ie6.css \ + style/style_ie7.css \ + style/style_ie8.css \ + style/style.css @@ -141,7 +141,7 @@ exampledirs = $QT_SOURCE_TREE/doc/src \ imagedirs = $QT_SOURCE_TREE/doc/src/images \ $QT_SOURCE_TREE/examples \ $QT_SOURCE_TREE/doc/src/declarative/pics \ - $QT_SOURCE_TREE/doc/src/template/images + $QT_SOURCE_TREE/doc/src/template/images outputdir = $QT_BUILD_TREE/doc/html tagfile = $QT_BUILD_TREE/doc/html/qt.tags base = file:$QT_BUILD_TREE/doc/html diff --git a/tools/qdoc3/test/qt-build-docs_ja_JP.qdocconf b/tools/qdoc3/test/qt-build-docs_ja_JP.qdocconf index e517b33..7701cae 100644 --- a/tools/qdoc3/test/qt-build-docs_ja_JP.qdocconf +++ b/tools/qdoc3/test/qt-build-docs_ja_JP.qdocconf @@ -30,33 +30,43 @@ qhp.Qt.customFilters.Qt.filterAttributes = qt 4.7.0 # Files not referenced in any qdoc file (last four are needed by qtdemo) # See also extraimages.HTML qhp.Qt.extraFiles = index.html \ - images/bg_l.png \ - images/bg_l_blank.png \ - images/bg_r.png \ - images/box_bg.png \ - images/breadcrumb.png \ - images/bullet_gt.png \ - images/bullet_dn.png \ - images/bullet_sq.png \ - images/bullet_up.png \ - images/feedbackground.png \ - images/horBar.png \ - images/page.png \ - images/page_bg.png \ - images/sprites-combined.png \ - images/arrow-down.png \ - images/spinner.gif \ - images/stylesheet-coffee-plastique.png \ - images/taskmenuextension-example.png \ - images/coloreditorfactoryimage.png \ - images/dynamiclayouts-example.png \ - scripts/functions.js \ - scripts/jquery.js \ - style/OfflineStyle.css \ - style/style_ie6.css \ - style/style_ie7.css \ - style/style_ie8.css \ - style/style.css + images/bg_l.png \ + images/bg_l_blank.png \ + images/bg_r.png \ + images/box_bg.png \ + images/breadcrumb.png \ + images/bullet_gt.png \ + images/bullet_dn.png \ + images/bullet_sq.png \ + images/bullet_up.png \ + images/feedbackground.png \ + images/horBar.png \ + images/page.png \ + images/page_bg.png \ + images/sprites-combined.png \ + images/arrow-down.png \ + images/spinner.gif \ + images/stylesheet-coffee-plastique.png \ + images/taskmenuextension-example.png \ + images/coloreditorfactoryimage.png \ + images/dynamiclayouts-example.png \ + scripts/functions.js \ + scripts/jquery.js \ + scripts/shBrushCpp.js \ + scripts/shCore.js \ + scripts/shLegacy.js \ + scripts/narrow.js \ + scripts/superfish.js \ + style/shCore.css \ + style/shThemeDefault.css \ + style/narrow.css \ + style/superfish.css \ + style/superfish_skin.css \ + style/OfflineStyle.css \ + style/style_ie6.css \ + style/style_ie7.css \ + style/style_ie8.css \ + style/style.css language = Cpp @@ -102,7 +112,8 @@ exampledirs = $QT_SOURCE_TREE/doc/src \ imagedirs = $QT_SOURCE_TREE/doc/src/ja_JP/images \ $QT_SOURCE_TREE/doc/src/images \ $QT_SOURCE_TREE/examples \ - $QT_SOURCE_TREE/doc/src/template/images + $QT_SOURCE_TREE/doc/src/declarative/pics \ + $QT_SOURCE_TREE/doc/src/template/images outputdir = $QT_BUILD_TREE/doc/html_ja_JP tagfile = $QT_BUILD_TREE/doc/html_ja_JP/qt.tags base = file:$QT_BUILD_TREE/doc/html_ja_JP diff --git a/tools/qdoc3/test/qt-build-docs_zh_CN.qdocconf b/tools/qdoc3/test/qt-build-docs_zh_CN.qdocconf index 909a2d4..be459d8 100644 --- a/tools/qdoc3/test/qt-build-docs_zh_CN.qdocconf +++ b/tools/qdoc3/test/qt-build-docs_zh_CN.qdocconf @@ -52,6 +52,17 @@ qhp.Qt.extraFiles = index.html \ images/dynamiclayouts-example.png \ scripts/functions.js \ scripts/jquery.js \ + scripts/shBrushCpp.js \ + scripts/shCore.js \ + scripts/shLegacy.js \ + scripts/narrow.js \ + scripts/superfish.js \ + style/shCore.css \ + style/shThemeDefault.css \ + style/narrow.css \ + style/superfish.css \ + style/superfish_skin.css \ + style/OfflineStyle.css \ style/style_ie6.css \ style/style_ie7.css \ style/style_ie8.css \ @@ -99,7 +110,8 @@ exampledirs = $QT_SOURCE_TREE/doc/src \ $QT_SOURCE_TREE/src/3rdparty/webkit/WebKit/qt/docs imagedirs = $QT_SOURCE_TREE/doc/src/images \ $QT_SOURCE_TREE/examples \ - $QT_SOURCE_TREE/doc/src/template/images + $QT_SOURCE_TREE/doc/src/declarative/pics \ + $QT_SOURCE_TREE/doc/src/template/images outputdir = $QT_BUILD_TREE/doc/html_zh_CN tagfile = $QT_BUILD_TREE/doc/html_zh_CN/qt.tags base = file:$QT_BUILD_TREE/doc/html_zh_CN diff --git a/tools/qdoc3/test/qt-html-templates.qdocconf b/tools/qdoc3/test/qt-html-templates.qdocconf index 8708f1b..b82e337 100644 --- a/tools/qdoc3/test/qt-html-templates.qdocconf +++ b/tools/qdoc3/test/qt-html-templates.qdocconf @@ -11,7 +11,7 @@ HTML.postheader = " <div class=\"header\" id=\"qtdocheader\">\n" \ " <a href=\"index.html\" class=\"qtref\"><span>Qt Reference Documentation</span></a>\n" \ " <div id=\"narrowsearch\"><form onsubmit=\"return false;\" action=\"\" id=\"qtdocsearch\">\n" \ " <fieldset>\n" \ - " <input type=\"text\" value=\"\" id=\"pageType\" name=\"searchstring\">\n" \ + " <input type=\"text\" value=\"\" id=\"pageType2\" name=\"searchstring\">\n" \ " </fieldset>\n" \ " </form></div>\n" \ " <div id=\"nav-topright\">\n" \ @@ -160,7 +160,9 @@ HTML.footer = " <!-- /div -->\n" \ " <div id=\"feedbackBox\">\n" \ " <div id=\"feedcloseX\" class=\"feedclose t_button\">X</div>\n" \ " <form id=\"feedform\" action=\"http://doc.qt.nokia.com/docFeedbck/feedback.php\" method=\"get\">\n" \ - " <p><textarea id=\"feedbox\" name=\"feedText\" rows=\"5\" cols=\"40\">Please submit your feedback...</textarea></p>\n" \ + " <p>Thank you for giving your feedback. <div class=\"note\">Make sure it is related the page. For more general bugs and \n" \ + " requests, please use the <a href=\"http://bugreports.qt.nokia.com/secure/Dashboard.jspa\">Qt Bug Tracker</a></div></p>\n" \ + " <p><textarea id=\"feedbox\" name=\"feedText\" rows=\"5\" cols=\"40\"></textarea></p>\n" \ " <p><input id=\"feedsubmit\" class=\"feedclose\" type=\"submit\" name=\"feedback\" /></p>\n" \ " </form>\n" \ " </div>\n" \ diff --git a/tools/qdoc3/tree.cpp b/tools/qdoc3/tree.cpp index 31bbf54..d31de4d 100644 --- a/tools/qdoc3/tree.cpp +++ b/tools/qdoc3/tree.cpp @@ -1952,9 +1952,13 @@ QString Tree::fullDocumentLocation(const Node *node) const else if (node->type() == Node::Fake) { #ifdef QDOC_QML if ((node->subType() == Node::QmlClass) || - (node->subType() == Node::QmlBasicType)) - return "qml-" + node->fileBase() + ".html"; - else + (node->subType() == Node::QmlBasicType)) { + QString fb = node->fileBase(); + if (fb.startsWith(QLatin1String("QML:"))) + return node->fileBase() + ".html"; + else + return "qml-" + node->fileBase() + ".html"; + } else #endif parentName = node->fileBase() + ".html"; } |