diff options
author | Qt Continuous Integration System <qt-info@nokia.com> | 2010-03-30 13:16:59 (GMT) |
---|---|---|
committer | Qt Continuous Integration System <qt-info@nokia.com> | 2010-03-30 13:16:59 (GMT) |
commit | 7a48877fb523491dcf67aed2b17d497d76754180 (patch) | |
tree | c5c454e9d53fd936b01ce4cd32b2598e0950fbc5 /tools | |
parent | ae305abfdb795b472b2b9d200bf3b11af00d7d1f (diff) | |
parent | ff968f44124322f5cda47cc7eced79ccaf23de80 (diff) | |
download | Qt-7a48877fb523491dcf67aed2b17d497d76754180.zip Qt-7a48877fb523491dcf67aed2b17d497d76754180.tar.gz Qt-7a48877fb523491dcf67aed2b17d497d76754180.tar.bz2 |
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into 4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1: (24 commits)
qdoc: Added <div> elements to some html output for class references.
Fix compile error on mingw.
MONILITY-645
Do not override alternate background color in Plastique
Fix QComboBox ignoring foreground role in some styles
Fix compilation on HP-UXi: _SC_MONOTONIC_CLOCK isn't defined
Fix compilation with Sun CC:
Ensure that we return QPair<long,long> in all cases.
Update PLATFORM(SPARC64) to CPU(SPARC64)
jui files are no c++ ...
scan some more file types by default
Support EtchDisabledText with spin box on Windows style
QNAM HTTP: Fix invoking a method when being destructed right now
Fixed a typo in the QDoubleValidotor doc.
Trivial fix to JavaScriptCore to fix building with MSVC 2010
Autotest: oops, fix oops: remove qguard from auto.pro
Autotests: oops, remove last traces of QGuard
Remove QGuard.
Unskip test that used to crash
QtScript: Add yet more missing API shims
...
Diffstat (limited to 'tools')
-rw-r--r-- | tools/linguist/lupdate/main.cpp | 3 | ||||
-rw-r--r-- | tools/qdoc3/codemarker.cpp | 2 | ||||
-rw-r--r-- | tools/qdoc3/codemarker.h | 24 | ||||
-rw-r--r-- | tools/qdoc3/cppcodemarker.cpp | 76 | ||||
-rw-r--r-- | tools/qdoc3/htmlgenerator.cpp | 8 | ||||
-rw-r--r-- | tools/qdoc3/node.cpp | 2 | ||||
-rw-r--r-- | tools/qdoc3/qscodemarker.cpp | 18 |
7 files changed, 89 insertions, 44 deletions
diff --git a/tools/linguist/lupdate/main.cpp b/tools/linguist/lupdate/main.cpp index 0003baa..6c9157a 100644 --- a/tools/linguist/lupdate/main.cpp +++ b/tools/linguist/lupdate/main.cpp @@ -409,7 +409,7 @@ static void processProjects( int main(int argc, char **argv) { QCoreApplication app(argc, argv); - m_defaultExtensions = QLatin1String("ui,c,c++,cc,cpp,cxx,ch,h,h++,hh,hpp,hxx"); + m_defaultExtensions = QLatin1String("java,jui,ui,c,c++,cc,cpp,cxx,ch,h,h++,hh,hpp,hxx,js,qs,qml"); QStringList args = app.arguments(); QStringList tsFileNames; @@ -634,6 +634,7 @@ int main(int argc, char **argv) sourceFiles << fn; if (!fn.endsWith(QLatin1String(".java")) + && !fn.endsWith(QLatin1String(".jui")) && !fn.endsWith(QLatin1String(".ui")) && !fn.endsWith(QLatin1String(".js")) && !fn.endsWith(QLatin1String(".qs")) diff --git a/tools/qdoc3/codemarker.cpp b/tools/qdoc3/codemarker.cpp index 15f2c2d..818a91f 100644 --- a/tools/qdoc3/codemarker.cpp +++ b/tools/qdoc3/codemarker.cpp @@ -457,7 +457,7 @@ bool CodeMarker::insertReimpFunc(FastSection& fs, Node* node, Status status) void CodeMarker::append(QList<Section>& sectionList, const FastSection& fs) { if (!fs.isEmpty()) { - Section section(fs.name,fs.singularMember,fs.pluralMember); + Section section(fs.name,fs.divClass,fs.singularMember,fs.pluralMember); section.members = fs.memberMap.values(); section.reimpMembers = fs.reimpMemberMap.values(); section.inherited = fs.inherited; diff --git a/tools/qdoc3/codemarker.h b/tools/qdoc3/codemarker.h index 1b21753..aab8a9c 100644 --- a/tools/qdoc3/codemarker.h +++ b/tools/qdoc3/codemarker.h @@ -58,6 +58,7 @@ class Tree; struct Section { QString name; + QString divClass; QString singularMember; QString pluralMember; NodeList members; @@ -66,9 +67,11 @@ struct Section Section() { } Section(const QString& name0, + const QString& divClass0, const QString& singularMember0, const QString& pluralMember0) - : name(name0), + : name(name0), + divClass(divClass0), singularMember(singularMember0), pluralMember(pluralMember0) { } void appendMember(Node* node) { members.append(node); } @@ -79,6 +82,7 @@ struct FastSection { const InnerNode *innerNode; QString name; + QString divClass; QString singularMember; QString pluralMember; QMap<QString, Node *> memberMap; @@ -86,20 +90,30 @@ struct FastSection QList<QPair<ClassNode *, int> > inherited; FastSection(const InnerNode *innerNode0, - const QString& name0 = "", - const QString& singularMember0 = "member", - const QString& pluralMember0 = "members") + const QString& name0, + const QString& divClass0, + const QString& singularMember0, + const QString& pluralMember0) : innerNode(innerNode0), name(name0), + divClass(divClass0), singularMember(singularMember0), pluralMember(pluralMember0) { } bool isEmpty() const { - return (memberMap.isEmpty() && inherited.isEmpty() && + return (memberMap.isEmpty() && + inherited.isEmpty() && reimpMemberMap.isEmpty()); } }; +#if 0 + const QString& name0 = "", + const QString& divClass0 = "", + const QString& singularMember0 = "member", + const QString& pluralMember0 = "members") +#endif + class CodeMarker { public: diff --git a/tools/qdoc3/cppcodemarker.cpp b/tools/qdoc3/cppcodemarker.cpp index 3ff6ebe..c4ee054 100644 --- a/tools/qdoc3/cppcodemarker.cpp +++ b/tools/qdoc3/cppcodemarker.cpp @@ -482,55 +482,66 @@ QList<Section> CppCodeMarker::sections(const InnerNode *inner, if (style == Summary) { FastSection privateFunctions(classe, "Private Functions", + "", "private function", "private functions"); - FastSection privateSlots(classe, "Private Slots", "private slot", "private slots"); - FastSection privateTypes(classe, "Private Types", "private type", "private types"); + FastSection privateSlots(classe, "Private Slots", "", "private slot", "private slots"); + FastSection privateTypes(classe, "Private Types", "", "private type", "private types"); FastSection protectedFunctions(classe, "Protected Functions", + "", "protected function", "protected functions"); FastSection protectedSlots(classe, "Protected Slots", + "", "protected slot", "protected slots"); FastSection protectedTypes(classe, "Protected Types", + "", "protected type", "protected types"); FastSection protectedVariables(classe, "Protected Variables", + "", "protected type", "protected variables"); FastSection publicFunctions(classe, "Public Functions", + "", "public function", "public functions"); - FastSection publicSignals(classe, "Signals", "signal", "signals"); - FastSection publicSlots(classe, "Public Slots", "public slot", "public slots"); - FastSection publicTypes(classe, "Public Types", "public type", "public types"); + FastSection publicSignals(classe, "Signals", "", "signal", "signals"); + FastSection publicSlots(classe, "Public Slots", "", "public slot", "public slots"); + FastSection publicTypes(classe, "Public Types", "", "public type", "public types"); FastSection publicVariables(classe, "Public Variables", - "public type", + "", + "public variable", "public variables"); - FastSection properties(classe, "Properties", "property", "properties"); + FastSection properties(classe, "Properties", "", "property", "properties"); FastSection relatedNonMembers(classe, "Related Non-Members", + "", "related non-member", "related non-members"); FastSection staticPrivateMembers(classe, "Static Private Members", + "", "static private member", "static private members"); FastSection staticProtectedMembers(classe, "Static Protected Members", + "", "static protected member", "static protected members"); FastSection staticPublicMembers(classe, "Static Public Members", + "", "static public member", "static public members"); - FastSection macros(inner, "Macros", "macro", "macros"); + FastSection macros(inner, "Macros", "", "macro", "macros"); NodeList::ConstIterator r = classe->relatedNodes().begin(); while (r != classe->relatedNodes().end()) { @@ -666,12 +677,12 @@ QList<Section> CppCodeMarker::sections(const InnerNode *inner, append(sections, macros); } else if (style == Detailed) { - FastSection memberFunctions(classe,"Member Function Documentation"); - FastSection memberTypes(classe,"Member Type Documentation"); - FastSection memberVariables(classe,"Member Variable Documentation"); - FastSection properties(classe,"Property Documentation"); - FastSection relatedNonMembers(classe,"Related Non-Members"); - FastSection macros(classe,"Macro Documentation"); + FastSection memberFunctions(classe,"Member Function Documentation","func","member","members"); + FastSection memberTypes(classe,"Member Type Documentation","types","member","members"); + FastSection memberVariables(classe,"Member Variable Documentation","vars","member","members"); + FastSection properties(classe,"Property Documentation","prop","member","members"); + FastSection relatedNonMembers(classe,"Related Non-Members","relnonmem","member","members"); + FastSection macros(classe,"Macro Documentation","macros","member","members"); NodeList::ConstIterator r = classe->relatedNodes().begin(); while (r != classe->relatedNodes().end()) { @@ -717,7 +728,7 @@ QList<Section> CppCodeMarker::sections(const InnerNode *inner, append(sections, macros); } else { - FastSection all(classe); + FastSection all(classe,"","","member","members"); QStack<const ClassNode *> stack; stack.push(classe); @@ -747,25 +758,29 @@ QList<Section> CppCodeMarker::sections(const InnerNode *inner, if (style == Summary || style == Detailed) { FastSection namespaces(inner, "Namespaces", + style == Detailed ? "nmspace" : "", "namespace", "namespaces"); FastSection classes(inner, "Classes", + style == Detailed ? "classes" : "", "class", "classes"); FastSection types(inner, - style == Summary ? - "Types" : "Type Documentation", + style == Summary ? "Types" : "Type Documentation", + style == Detailed ? "types" : "", "type", "types"); FastSection functions(inner, style == Summary ? "Functions" : "Function Documentation", + style == Detailed ? "func" : "", "function", "functions"); FastSection macros(inner, style == Summary ? "Macros" : "Macro Documentation", + style == Detailed ? "macros" : "", "macro", "macros"); @@ -1116,26 +1131,32 @@ QList<Section> CppCodeMarker::qmlSections(const QmlClassNode* qmlClassNode, if (style == Summary) { FastSection qmlproperties(qmlClassNode, "Properties", + "", "property", "properties"); FastSection qmlattachedproperties(qmlClassNode, "Attached Properties", + "", "property", "properties"); FastSection qmlsignals(qmlClassNode, - "Signals", - "signal", - "signals"); + "Signals", + "", + "signal", + "signals"); FastSection qmlattachedsignals(qmlClassNode, "Attached Signals", + "", "signal", "signals"); FastSection qmlmethods(qmlClassNode, "Methods", + "", "method", "methods"); FastSection qmlattachedmethods(qmlClassNode, "Attached Methods", + "", "method", "methods"); @@ -1179,12 +1200,15 @@ QList<Section> CppCodeMarker::qmlSections(const QmlClassNode* qmlClassNode, append(sections,qmlattachedmethods); } else if (style == Detailed) { - FastSection qmlproperties(qmlClassNode, "Property Documentation"); - FastSection qmlattachedproperties(qmlClassNode,"Attached Property Documentation"); - FastSection qmlsignals(qmlClassNode,"Signal Documentation"); - FastSection qmlattachedsignals(qmlClassNode,"Attached Signal Documentation"); - FastSection qmlmethods(qmlClassNode,"Method Documentation"); - FastSection qmlattachedmethods(qmlClassNode,"Attached Method Documentation"); + FastSection qmlproperties(qmlClassNode, "Property Documentation","qmlprop","member","members"); + FastSection qmlattachedproperties(qmlClassNode,"Attached Property Documentation","qmlattprop", + "member","members"); + FastSection qmlsignals(qmlClassNode,"Signal Documentation","qmlsig","member","members"); + FastSection qmlattachedsignals(qmlClassNode,"Attached Signal Documentation","qmlattsig", + "member","members"); + FastSection qmlmethods(qmlClassNode,"Method Documentation","qmlmeth","member","members"); + FastSection qmlattachedmethods(qmlClassNode,"Attached Method Documentation","qmlattmeth", + "member","members"); NodeList::ConstIterator c = qmlClassNode->childNodes().begin(); while (c != qmlClassNode->childNodes().end()) { if ((*c)->subType() == Node::QmlPropertyGroup) { diff --git a/tools/qdoc3/htmlgenerator.cpp b/tools/qdoc3/htmlgenerator.cpp index cd3da3e..fb9fa95 100644 --- a/tools/qdoc3/htmlgenerator.cpp +++ b/tools/qdoc3/htmlgenerator.cpp @@ -696,7 +696,7 @@ int HtmlGenerator::generateAtom(const Atom *atom, QList<Section> sections; QList<Section>::ConstIterator s; for (int i=0; i<LastSinceType; ++i) - sections.append(Section(sinceTitle(i),QString(),QString())); + sections.append(Section(sinceTitle(i),QString(),QString(),QString())); NodeMultiMap::const_iterator n = nsmap.value().constBegin(); while (n != nsmap.value().constEnd()) { @@ -1356,8 +1356,10 @@ void HtmlGenerator::generateClassLikeNode(const InnerNode *inner, if (!inner->doc().isEmpty()) { out() << "<hr />\n" + << "<div class=\"descr\"/>\n" << "<h2>" << "Detailed Description" << "</h2>\n"; generateBody(inner, marker); + out() << "</div>\n"; generateAlsoList(inner, marker); } @@ -1365,6 +1367,8 @@ void HtmlGenerator::generateClassLikeNode(const InnerNode *inner, s = sections.begin(); while (s != sections.end()) { out() << "<hr />\n"; + if (!(*s).divClass.isEmpty()) + out() << "<div class=\"" << (*s).divClass << "\"/>\n"; out() << "<h2>" << protectEnc((*s).name) << "</h2>\n"; NodeList::ConstIterator m = (*s).members.begin(); @@ -1414,6 +1418,8 @@ void HtmlGenerator::generateClassLikeNode(const InnerNode *inner, } ++m; } + if (!(*s).divClass.isEmpty()) + out() << "</div>\n"; ++s; } generateFooter(inner); diff --git a/tools/qdoc3/node.cpp b/tools/qdoc3/node.cpp index bd37443..ef75f6e 100644 --- a/tools/qdoc3/node.cpp +++ b/tools/qdoc3/node.cpp @@ -1334,7 +1334,7 @@ QString QmlClassNode::fileBase() const void QmlClassNode::addInheritedBy(const QString& base, Node* sub) { inheritedBy.insert(base,sub); -#ifdef DEBUG_MULTIPLE-QDOCCONF_FILES +#ifdef DEBUG_MULTIPLE_QDOCCONF_FILES qDebug() << "QmlClassNode::addInheritedBy(): insert" << base << sub->name() << inheritedBy.size(); #endif } diff --git a/tools/qdoc3/qscodemarker.cpp b/tools/qdoc3/qscodemarker.cpp index 89c9c5c..d4b8e80 100644 --- a/tools/qdoc3/qscodemarker.cpp +++ b/tools/qdoc3/qscodemarker.cpp @@ -279,11 +279,11 @@ QList<Section> QsCodeMarker::sections( const InnerNode *inner, SynopsisStyle sty const ClassNode *classe = static_cast<const ClassNode *>(inner); if ( style == Summary ) { - FastSection enums(classe, "Enums", "enum", "enums"); - FastSection functions(classe, "Functions", "function", "functions"); - FastSection readOnlyProperties(classe, "Read-Only Properties", "property", "properties"); - FastSection signalz(classe, "Signals", "signal", "signals"); - FastSection writableProperties(classe, "Writable Properties", "property", "properties"); + FastSection enums(classe, "Enums", "", "enum", "enums"); + FastSection functions(classe, "Functions", "", "function", "functions"); + FastSection readOnlyProperties(classe, "", "Read-Only Properties", "property", "properties"); + FastSection signalz(classe, "Signals", "", "signal", "signals"); + FastSection writableProperties(classe, "", "Writable Properties", "property", "properties"); QStack<const ClassNode *> stack; stack.push( classe ); @@ -328,9 +328,9 @@ QList<Section> QsCodeMarker::sections( const InnerNode *inner, SynopsisStyle sty append( sections, functions ); append( sections, signalz ); } else if ( style == Detailed ) { - FastSection enums( classe, "Enum Documentation" ); - FastSection functionsAndSignals( classe, "Function and Signal Documentation" ); - FastSection properties( classe, "Property Documentation" ); + FastSection enums( classe, "Enum Documentation", "", "member", "members"); + FastSection functionsAndSignals( classe, "Function and Signal Documentation", "", "member", "members"); + FastSection properties( classe, "Property Documentation", "", "member", "members"); NodeList::ConstIterator c = classe->childNodes().begin(); while ( c != classe->childNodes().end() ) { @@ -349,7 +349,7 @@ QList<Section> QsCodeMarker::sections( const InnerNode *inner, SynopsisStyle sty append( sections, properties ); append( sections, functionsAndSignals ); } else { // ( style == SeparateList ) - FastSection all( classe ); + FastSection all(classe, "", "", "member", "members"); QStack<const ClassNode *> stack; stack.push( classe ); |