/usr/share/qt5/doc/qtqml/qqmlparserstatus.html is in qtdeclarative5-doc-html 5.2.1-3ubuntu15.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 | <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en_US" lang="en_US">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<!-- qqmlparserstatus.cpp -->
<title>QQmlParserStatus Class | QtQml 5.2</title>
<link rel="stylesheet" type="text/css" href="style/offline.css" />
</head>
<body>
<div class="header" id="qtdocheader">
<div class="main">
<div class="main-rounded">
<div class="navigationbar">
<ul>
<li>Qt 5.2</li>
<li><a href="qtqml-index.html">Qt QML</a></li>
<li><a href="qtqml-module.html">C++ Classes</a></li>
<li>QQmlParserStatus</li>
<li id="buildversion">
Qt 5.2.1 Reference Documentation</li>
</ul>
</div>
</div>
<div class="content">
<div class="line">
<div class="content mainContent">
<div class="toc">
<h3><a name="toc">Contents</a></h3>
<ul>
<li class="level1"><a href="#public-functions">Public Functions</a></li>
<li class="level1"><a href="#details">Detailed Description</a></li>
</ul>
</div>
<h1 class="title">QQmlParserStatus Class</h1>
<!-- $$$QQmlParserStatus-brief -->
<p>The QQmlParserStatus class provides updates on the QML parser state. <a href="#details">More...</a></p>
<!-- @@@QQmlParserStatus -->
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> Header:</td><td class="memItemRight bottomAlign"> </b><tt><span class="preprocessor">#include <QQmlParserStatus></span>
</tt></td></tr><tr><td class="memItemLeft rightAlign topAlign"> qmake:</td><td class="memItemRight bottomAlign"> <tt>QT += qml</tt></td></tr><tr><td class="memItemLeft rightAlign topAlign"> Since:</td><td class="memItemRight bottomAlign"> Qt 5.0</td></tr></table><ul>
<li><a href="qqmlparserstatus-members.html">List of all members, including inherited members</a></li>
</ul>
<a name="public-functions"></a>
<h2>Public Functions</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="qqmlparserstatus.html#classBegin">classBegin</a></b>() = 0</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> virtual void </td><td class="memItemRight bottomAlign"><b><a href="qqmlparserstatus.html#componentComplete">componentComplete</a></b>() = 0</td></tr>
</table>
<a name="details"></a>
<!-- $$$QQmlParserStatus-description -->
<div class="descr">
<h2>Detailed Description</h2>
<p>The QQmlParserStatus class provides updates on the QML parser state.</p>
<p>QQmlParserStatus provides a mechanism for classes instantiated by a <a href="qqmlengine.html">QQmlEngine</a> to receive notification at key points in their creation.</p>
<p>This class is often used for optimization purposes, as it allows you to defer an expensive operation until after all the properties have been set on an object. For example, QML's Text element uses the parser status to defer text layout until all of its properties have been set (we don't want to layout when the <tt>text</tt> is assigned, and then relayout when the <tt>font</tt> is assigned, and relayout again when the <tt>width</tt> is assigned, and so on).</p>
<p>Be aware that QQmlParserStatus methods are only called when a class is instantiated by a <a href="qqmlengine.html">QQmlEngine</a>. If you create the same class directly from C++, these methods will not be called automatically. To avoid this problem, it is recommended that you start deferring operations from classBegin instead of from the initial creation of your class. This will still prevent multiple revaluations during initial binding assignment in QML, but will not defer operations invoked from C++.</p>
<p>To use QQmlParserStatus, you must inherit both a QObject-derived class and QQmlParserStatus, and use the Q_INTERFACES() macro.</p>
<pre class="cpp"><span class="keyword">class</span> MyObject : <span class="keyword">public</span> <span class="type">QObject</span><span class="operator">,</span> <span class="keyword">public</span> <span class="type">QQmlParserStatus</span>
{
Q_OBJECT
Q_INTERFACES(<span class="type">QQmlParserStatus</span>)
<span class="keyword">public</span>:
MyObject(<span class="type">QObject</span> <span class="operator">*</span>parent <span class="operator">=</span> <span class="number">0</span>);
<span class="operator">.</span><span class="operator">.</span><span class="operator">.</span>
<span class="type">void</span> classBegin();
<span class="type">void</span> componentComplete();
}</pre>
<p>The Qt Quick 1 version of this class is named QDeclarativeParserStatus.</p>
</div>
<!-- @@@QQmlParserStatus -->
<div class="func">
<h2>Member Function Documentation</h2>
<!-- $$$classBegin[overload1]$$$classBegin -->
<h3 class="fn"><a name="classBegin"></a><span class="type">void</span> QQmlParserStatus::<span class="name">classBegin</span>()<tt> [pure virtual]</tt></h3>
<p>Invoked after class creation, but before any properties have been set.</p>
<!-- @@@classBegin -->
<!-- $$$componentComplete[overload1]$$$componentComplete -->
<h3 class="fn"><a name="componentComplete"></a><span class="type">void</span> QQmlParserStatus::<span class="name">componentComplete</span>()<tt> [pure virtual]</tt></h3>
<p>Invoked after the root component that caused this instantiation has completed construction. At this point all static values and binding values have been assigned to the class.</p>
<!-- @@@componentComplete -->
</div>
</div>
</div>
</div>
</div>
</div>
<div class="footer">
<p>
<acronym title="Copyright">©</acronym> 2013 Digia Plc and/or its
subsidiaries. Documentation contributions included herein are the copyrights of
their respective owners.<br> The documentation provided herein is licensed under the terms of the <a href="http://www.gnu.org/licenses/fdl.html">GNU Free Documentation License version 1.3</a> as published by the Free Software Foundation.<br> Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide. All other trademarks are property
of their respective owners. </p>
</div>
</body>
</html>
|