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 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207
|
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.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" />
<!-- qwebhistory.cpp -->
<title>Qt 4.8: QWebHistory Class Reference</title>
<link rel="stylesheet" type="text/css" href="style/offline.css" />
</head>
<body>
<div class="header" id="qtdocheader">
<div class="content">
<a href="index.html" class="qtref"><span>Qt Reference Documentation</span></a>
</div>
<div class="breadcrumb toolblock">
<ul>
<li class="first"><a href="index.html">Home</a></li>
<!-- Breadcrumbs go here -->
<li><a href="modules.html">Modules</a></li>
<li><a href="qtwebkit.html">QtWebKit</a></li>
<li>QWebHistory</li>
</ul>
</div>
</div>
<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="#related-non-members">Related Non-Members</a></li>
<li class="level1"><a href="#details">Detailed Description</a></li>
</ul>
</div>
<h1 class="title">QWebHistory Class Reference</h1>
<!-- $$$QWebHistory-brief -->
<p>The QWebHistory class represents the history of a <a href="qwebpage.html">QWebPage</a> <a href="#details">More...</a></p>
<!-- @@@QWebHistory -->
<pre class="cpp"> <span class="preprocessor">#include <QWebHistory></span></pre><p>This class was introduced in Qt 4.4.</p>
<ul>
<li><a href="qwebhistory-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"> void </td><td class="memItemRight bottomAlign"><b><a href="qwebhistory.html#back">back</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QWebHistoryItem </td><td class="memItemRight bottomAlign"><b><a href="qwebhistory.html#backItem">backItem</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QList<QWebHistoryItem> </td><td class="memItemRight bottomAlign"><b><a href="qwebhistory.html#backItems">backItems</a></b> ( int <i>maxItems</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qwebhistory.html#canGoBack">canGoBack</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="qwebhistory.html#canGoForward">canGoForward</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwebhistory.html#clear">clear</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="qwebhistory.html#count">count</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QWebHistoryItem </td><td class="memItemRight bottomAlign"><b><a href="qwebhistory.html#currentItem">currentItem</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="qwebhistory.html#currentItemIndex">currentItemIndex</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwebhistory.html#forward">forward</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QWebHistoryItem </td><td class="memItemRight bottomAlign"><b><a href="qwebhistory.html#forwardItem">forwardItem</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QList<QWebHistoryItem> </td><td class="memItemRight bottomAlign"><b><a href="qwebhistory.html#forwardItems">forwardItems</a></b> ( int <i>maxItems</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwebhistory.html#goToItem">goToItem</a></b> ( const QWebHistoryItem & <i>item</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QWebHistoryItem </td><td class="memItemRight bottomAlign"><b><a href="qwebhistory.html#itemAt">itemAt</a></b> ( int <i>i</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QList<QWebHistoryItem> </td><td class="memItemRight bottomAlign"><b><a href="qwebhistory.html#items">items</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="qwebhistory.html#maximumItemCount">maximumItemCount</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="qwebhistory.html#setMaximumItemCount">setMaximumItemCount</a></b> ( int <i>count</i> )</td></tr>
</table>
<a name="related-non-members"></a>
<h2>Related Non-Members</h2>
<table class="alignedsummary">
<tr><td class="memItemLeft rightAlign topAlign"> QDataStream & </td><td class="memItemRight bottomAlign"><b><a href="qwebhistory.html#operator-lt-lt-87">operator<<</a></b> ( QDataStream & <i>stream</i>, const QWebHistory & <i>history</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> QDataStream & </td><td class="memItemRight bottomAlign"><b><a href="qwebhistory.html#operator-gt-gt-45">operator>></a></b> ( QDataStream & <i>stream</i>, QWebHistory & <i>history</i> )</td></tr>
</table>
<a name="details"></a>
<!-- $$$QWebHistory-description -->
<div class="descr">
<h2>Detailed Description</h2>
<p>The QWebHistory class represents the history of a <a href="qwebpage.html">QWebPage</a></p>
<p>Each <a href="qwebpage.html">QWebPage</a> instance contains a history of visited pages that can be accessed by <a href="qwebpage.html#history">QWebPage::history</a>(). QWebHistory represents this history and makes it possible to navigate it.</p>
<p>The history uses the concept of a <i>current item</i>, dividing the pages visited into those that can be visited by navigating <i>back</i> and <i>forward</i> using the <a href="qwebhistory.html#back">back</a>() and <a href="qwebhistory.html#forward">forward</a>() functions. The current item can be obtained by calling <a href="qwebhistory.html#currentItem">currentItem</a>(), and an arbitrary item in the history can be made the current item by passing it to <a href="qwebhistory.html#goToItem">goToItem</a>().</p>
<p>A list of items describing the pages that can be visited by going back can be obtained by calling the <a href="qwebhistory.html#backItems">backItems</a>() function; similarly, items describing the pages ahead of the current page can be obtained with the <a href="qwebhistory.html#forwardItems">forwardItems</a>() function. The total list of items is obtained with the <a href="qwebhistory.html#items">items</a>() function.</p>
<p>Just as with containers, functions are available to examine the history in terms of a list. Arbitrary items in the history can be obtained with <a href="qwebhistory.html#itemAt">itemAt</a>(), the total number of items is given by <a href="qwebhistory.html#count">count</a>(), and the history can be cleared with the <a href="qwebhistory.html#clear">clear</a>() function.</p>
<p>QWebHistory's state can be saved to a <a href="qdatastream.html">QDataStream</a> using the >> operator and loaded by using the << operator.</p>
</div>
<p><b>See also </b><a href="qwebhistoryitem.html">QWebHistoryItem</a>, <a href="qwebhistoryinterface.html">QWebHistoryInterface</a>, and <a href="qwebpage.html">QWebPage</a>.</p>
<!-- @@@QWebHistory -->
<div class="func">
<h2>Member Function Documentation</h2>
<!-- $$$back[overload1]$$$back -->
<h3 class="fn"><a name="back"></a><span class="type">void</span> QWebHistory::<span class="name">back</span> ()</h3>
<p>Set the current item to be the previous item in the history and goes to the corresponding page; i.e., goes back one history item.</p>
<p><b>See also </b><a href="qwebhistory.html#forward">forward</a>() and <a href="qwebhistory.html#goToItem">goToItem</a>().</p>
<!-- @@@back -->
<!-- $$$backItem[overload1]$$$backItem -->
<h3 class="fn"><a name="backItem"></a><span class="type"><a href="qwebhistoryitem.html">QWebHistoryItem</a></span> QWebHistory::<span class="name">backItem</span> () const</h3>
<p>Returns the item before the current item in the history.</p>
<!-- @@@backItem -->
<!-- $$$backItems[overload1]$$$backItemsint -->
<h3 class="fn"><a name="backItems"></a><span class="type"><a href="qlist.html">QList</a></span><<span class="type"><a href="qwebhistoryitem.html">QWebHistoryItem</a></span>> QWebHistory::<span class="name">backItems</span> ( <span class="type">int</span> <i>maxItems</i> ) const</h3>
<p>Returns the list of items in the backwards history list. At most <i>maxItems</i> entries are returned.</p>
<p><b>See also </b><a href="qwebhistory.html#forwardItems">forwardItems</a>().</p>
<!-- @@@backItems -->
<!-- $$$canGoBack[overload1]$$$canGoBack -->
<h3 class="fn"><a name="canGoBack"></a><span class="type">bool</span> QWebHistory::<span class="name">canGoBack</span> () const</h3>
<p>Returns true if there is an item preceding the current item in the history; otherwise returns false.</p>
<p><b>See also </b><a href="qwebhistory.html#canGoForward">canGoForward</a>().</p>
<!-- @@@canGoBack -->
<!-- $$$canGoForward[overload1]$$$canGoForward -->
<h3 class="fn"><a name="canGoForward"></a><span class="type">bool</span> QWebHistory::<span class="name">canGoForward</span> () const</h3>
<p>Returns true if we have an item to go forward to; otherwise returns false.</p>
<p><b>See also </b><a href="qwebhistory.html#canGoBack">canGoBack</a>().</p>
<!-- @@@canGoForward -->
<!-- $$$clear[overload1]$$$clear -->
<h3 class="fn"><a name="clear"></a><span class="type">void</span> QWebHistory::<span class="name">clear</span> ()</h3>
<p>Clears the history.</p>
<p><b>See also </b><a href="qwebhistory.html#count">count</a>() and <a href="qwebhistory.html#items">items</a>().</p>
<!-- @@@clear -->
<!-- $$$count[overload1]$$$count -->
<h3 class="fn"><a name="count"></a><span class="type">int</span> QWebHistory::<span class="name">count</span> () const</h3>
<p>Returns the total number of items in the history.</p>
<!-- @@@count -->
<!-- $$$currentItem[overload1]$$$currentItem -->
<h3 class="fn"><a name="currentItem"></a><span class="type"><a href="qwebhistoryitem.html">QWebHistoryItem</a></span> QWebHistory::<span class="name">currentItem</span> () const</h3>
<p>Returns the current item in the history.</p>
<!-- @@@currentItem -->
<!-- $$$currentItemIndex[overload1]$$$currentItemIndex -->
<h3 class="fn"><a name="currentItemIndex"></a><span class="type">int</span> QWebHistory::<span class="name">currentItemIndex</span> () const</h3>
<p>Returns the index of the current item in history.</p>
<p>This function was introduced in Qt 4.5.</p>
<!-- @@@currentItemIndex -->
<!-- $$$forward[overload1]$$$forward -->
<h3 class="fn"><a name="forward"></a><span class="type">void</span> QWebHistory::<span class="name">forward</span> ()</h3>
<p>Sets the current item to be the next item in the history and goes to the corresponding page; i.e., goes forward one history item.</p>
<p><b>See also </b><a href="qwebhistory.html#back">back</a>() and <a href="qwebhistory.html#goToItem">goToItem</a>().</p>
<!-- @@@forward -->
<!-- $$$forwardItem[overload1]$$$forwardItem -->
<h3 class="fn"><a name="forwardItem"></a><span class="type"><a href="qwebhistoryitem.html">QWebHistoryItem</a></span> QWebHistory::<span class="name">forwardItem</span> () const</h3>
<p>Returns the item after the current item in the history.</p>
<!-- @@@forwardItem -->
<!-- $$$forwardItems[overload1]$$$forwardItemsint -->
<h3 class="fn"><a name="forwardItems"></a><span class="type"><a href="qlist.html">QList</a></span><<span class="type"><a href="qwebhistoryitem.html">QWebHistoryItem</a></span>> QWebHistory::<span class="name">forwardItems</span> ( <span class="type">int</span> <i>maxItems</i> ) const</h3>
<p>Returns the list of items in the forward history list. At most <i>maxItems</i> entries are returned.</p>
<p><b>See also </b><a href="qwebhistory.html#backItems">backItems</a>().</p>
<!-- @@@forwardItems -->
<!-- $$$goToItem[overload1]$$$goToItemconstQWebHistoryItem& -->
<h3 class="fn"><a name="goToItem"></a><span class="type">void</span> QWebHistory::<span class="name">goToItem</span> ( const <span class="type"><a href="qwebhistoryitem.html">QWebHistoryItem</a></span> & <i>item</i> )</h3>
<p>Sets the current item to be the specified <i>item</i> in the history and goes to the page.</p>
<p><b>See also </b><a href="qwebhistory.html#back">back</a>() and <a href="qwebhistory.html#forward">forward</a>().</p>
<!-- @@@goToItem -->
<!-- $$$itemAt[overload1]$$$itemAtint -->
<h3 class="fn"><a name="itemAt"></a><span class="type"><a href="qwebhistoryitem.html">QWebHistoryItem</a></span> QWebHistory::<span class="name">itemAt</span> ( <span class="type">int</span> <i>i</i> ) const</h3>
<p>Returns the item at index <i>i</i> in the history.</p>
<!-- @@@itemAt -->
<!-- $$$items[overload1]$$$items -->
<h3 class="fn"><a name="items"></a><span class="type"><a href="qlist.html">QList</a></span><<span class="type"><a href="qwebhistoryitem.html">QWebHistoryItem</a></span>> QWebHistory::<span class="name">items</span> () const</h3>
<p>Returns a list of all items currently in the history.</p>
<p><b>See also </b><a href="qwebhistory.html#count">count</a>() and <a href="qwebhistory.html#clear">clear</a>().</p>
<!-- @@@items -->
<!-- $$$maximumItemCount[overload1]$$$maximumItemCount -->
<h3 class="fn"><a name="maximumItemCount"></a><span class="type">int</span> QWebHistory::<span class="name">maximumItemCount</span> () const</h3>
<p>Returns the maximum number of items in the history.</p>
<p>This function was introduced in Qt 4.5.</p>
<p><b>See also </b><a href="qwebhistory.html#setMaximumItemCount">setMaximumItemCount</a>().</p>
<!-- @@@maximumItemCount -->
<!-- $$$setMaximumItemCount[overload1]$$$setMaximumItemCountint -->
<h3 class="fn"><a name="setMaximumItemCount"></a><span class="type">void</span> QWebHistory::<span class="name">setMaximumItemCount</span> ( <span class="type">int</span> <i>count</i> )</h3>
<p>Sets the maximum number of items in the history to <i>count</i>.</p>
<p>This function was introduced in Qt 4.5.</p>
<p><b>See also </b><a href="qwebhistory.html#maximumItemCount">maximumItemCount</a>().</p>
<!-- @@@setMaximumItemCount -->
</div>
<div class="relnonmem">
<h2>Related Non-Members</h2>
<!-- $$$operator<<$$$operator<<QDataStream&constQWebHistory& -->
<h3 class="fn"><a name="operator-lt-lt-87"></a><span class="type"><a href="qdatastream.html">QDataStream</a></span> & <span class="name">operator<<</span> ( <span class="type"><a href="qdatastream.html">QDataStream</a></span> & <i>stream</i>, const <span class="type">QWebHistory</span> & <i>history</i> )</h3>
<p>The operator<< function streams a history into a data stream.</p>
<p>It saves the <i>history</i> into the specified <i>stream</i>.</p>
<p>This function was introduced in Qt 4.6.</p>
<!-- @@@operator<< -->
<!-- $$$operator>>$$$operator>>QDataStream&QWebHistory& -->
<h3 class="fn"><a name="operator-gt-gt-45"></a><span class="type"><a href="qdatastream.html">QDataStream</a></span> & <span class="name">operator>></span> ( <span class="type"><a href="qdatastream.html">QDataStream</a></span> & <i>stream</i>, <span class="type">QWebHistory</span> & <i>history</i> )</h3>
<p>The operator>> function loads a history from a data stream.</p>
<p>Loads a <a href="qwebhistory.html">QWebHistory</a> from the specified <i>stream</i> into the given <i>history</i>.</p>
<p>This function was introduced in Qt 4.6.</p>
<!-- @@@operator>> -->
</div>
<div class="ft">
<span></span>
</div>
</div>
<div class="footer">
<p>
<acronym title="Copyright">©</acronym> 2012 Nokia Corporation and/or its
subsidiaries. Documentation contributions included herein are the copyrights of
their respective owners.</p>
<br />
<p>
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.</p>
<p>
Documentation sources may be obtained from <a href="http://www.qt-project.org">
www.qt-project.org</a>.</p>
<br />
<p>
Nokia, Qt and their respective logos are trademarks of Nokia Corporation
in Finland and/or other countries worldwide. All other trademarks are property
of their respective owners. <a title="Privacy Policy"
href="http://en.gitorious.org/privacy_policy/">Privacy Policy</a></p>
</div>
</body>
</html>
|