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
|
<?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" />
<!-- q3table.cpp -->
<title>Qt 4.8: Q3TableSelection 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="qt3support.html">Qt3Support</a></li>
<li>Q3TableSelection</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="#details">Detailed Description</a></li>
</ul>
</div>
<h1 class="title">Q3TableSelection Class Reference</h1>
<!-- $$$Q3TableSelection-brief -->
<p>The Q3TableSelection class provides access to a selected area in a <a href="q3table.html">Q3Table</a>. <a href="#details">More...</a></p>
<!-- @@@Q3TableSelection -->
<pre class="cpp"> <span class="preprocessor">#include <Q3TableSelection></span></pre><p><b>This class is part of the Qt 3 support library.</b> It is provided to keep old source code working. We strongly advise against using it in new code. See <a href="porting4.html">Porting to Qt 4</a> for more information.</p>
<ul>
<li><a href="q3tableselection-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"> </td><td class="memItemRight bottomAlign"><b><a href="q3tableselection.html#Q3TableSelection">Q3TableSelection</a></b> ()</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> </td><td class="memItemRight bottomAlign"><b><a href="q3tableselection.html#Q3TableSelection-2">Q3TableSelection</a></b> ( int <i>start_row</i>, int <i>start_col</i>, int <i>end_row</i>, int <i>end_col</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3tableselection.html#anchorCol">anchorCol</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3tableselection.html#anchorRow">anchorRow</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3tableselection.html#bottomRow">bottomRow</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3tableselection.html#expandTo">expandTo</a></b> ( int <i>row</i>, int <i>col</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> void </td><td class="memItemRight bottomAlign"><b><a href="q3tableselection.html#init">init</a></b> ( int <i>row</i>, int <i>col</i> )</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3tableselection.html#isActive">isActive</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3tableselection.html#isEmpty">isEmpty</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3tableselection.html#leftCol">leftCol</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3tableselection.html#numCols">numCols</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3tableselection.html#numRows">numRows</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3tableselection.html#rightCol">rightCol</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> int </td><td class="memItemRight bottomAlign"><b><a href="q3tableselection.html#topRow">topRow</a></b> () const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3tableselection.html#operator-not-eq">operator!=</a></b> ( const Q3TableSelection & <i>s</i> ) const</td></tr>
<tr><td class="memItemLeft rightAlign topAlign"> bool </td><td class="memItemRight bottomAlign"><b><a href="q3tableselection.html#operator-eq-eq">operator==</a></b> ( const Q3TableSelection & <i>s</i> ) const</td></tr>
</table>
<a name="details"></a>
<!-- $$$Q3TableSelection-description -->
<div class="descr">
<h2>Detailed Description</h2>
<p>The Q3TableSelection class provides access to a selected area in a <a href="q3table.html">Q3Table</a>.</p>
<p>The selection is a rectangular set of cells in a <a href="q3table.html">Q3Table</a>. One of the rectangle's cells is called the anchor cell; this is the cell that was selected first. The <a href="q3tableselection.html#init">init</a>() function sets the anchor and the selection rectangle to exactly this cell; the <a href="q3tableselection.html#expandTo">expandTo</a>() function expands the selection rectangle to include additional cells.</p>
<p>There are various access functions to find out about the area: <a href="q3tableselection.html#anchorRow">anchorRow</a>() and <a href="q3tableselection.html#anchorCol">anchorCol</a>() return the anchor's position; <a href="q3tableselection.html#leftCol">leftCol</a>(), <a href="q3tableselection.html#rightCol">rightCol</a>(), <a href="q3tableselection.html#topRow">topRow</a>() and <a href="q3tableselection.html#bottomRow">bottomRow</a>() return the rectangle's four edges. All four are part of the selection.</p>
<p>A newly created Q3TableSelection is inactive -- <a href="q3tableselection.html#isActive">isActive</a>() returns false. You must use <a href="q3tableselection.html#init">init</a>() and <a href="q3tableselection.html#expandTo">expandTo</a>() to activate it.</p>
<p><a href="q3table.html#selectCells">Q3Table::selectCells</a>() <a href="q3table.html#selectRow">Q3Table::selectRow</a>() <a href="q3table.html#selectColumn">Q3Table::selectColumn</a>()</p>
</div>
<p><b>See also </b><a href="q3table.html">Q3Table</a>, <a href="q3table.html#addSelection">Q3Table::addSelection</a>(), and <a href="q3table.html#selection">Q3Table::selection</a>().</p>
<!-- @@@Q3TableSelection -->
<div class="func">
<h2>Member Function Documentation</h2>
<!-- $$$Q3TableSelection[overload1]$$$Q3TableSelection -->
<h3 class="fn"><a name="Q3TableSelection"></a>Q3TableSelection::<span class="name">Q3TableSelection</span> ()</h3>
<p>Creates an inactive selection. Use <a href="q3tableselection.html#init">init</a>() and <a href="q3tableselection.html#expandTo">expandTo</a>() to activate it.</p>
<!-- @@@Q3TableSelection -->
<!-- $$$Q3TableSelection$$$Q3TableSelectionintintintint -->
<h3 class="fn"><a name="Q3TableSelection-2"></a>Q3TableSelection::<span class="name">Q3TableSelection</span> ( <span class="type">int</span> <i>start_row</i>, <span class="type">int</span> <i>start_col</i>, <span class="type">int</span> <i>end_row</i>, <span class="type">int</span> <i>end_col</i> )</h3>
<p>Creates an active selection, starting at <i>start_row</i> and <i>start_col</i>, ending at <i>end_row</i> and <i>end_col</i>.</p>
<!-- @@@Q3TableSelection -->
<!-- $$$anchorCol[overload1]$$$anchorCol -->
<h3 class="fn"><a name="anchorCol"></a><span class="type">int</span> Q3TableSelection::<span class="name">anchorCol</span> () const</h3>
<p>Returns the anchor column of the selection.</p>
<p><b>See also </b><a href="q3tableselection.html#anchorRow">anchorRow</a>() and <a href="q3tableselection.html#expandTo">expandTo</a>().</p>
<!-- @@@anchorCol -->
<!-- $$$anchorRow[overload1]$$$anchorRow -->
<h3 class="fn"><a name="anchorRow"></a><span class="type">int</span> Q3TableSelection::<span class="name">anchorRow</span> () const</h3>
<p>Returns the anchor row of the selection.</p>
<p><b>See also </b><a href="q3tableselection.html#anchorCol">anchorCol</a>() and <a href="q3tableselection.html#expandTo">expandTo</a>().</p>
<!-- @@@anchorRow -->
<!-- $$$bottomRow[overload1]$$$bottomRow -->
<h3 class="fn"><a name="bottomRow"></a><span class="type">int</span> Q3TableSelection::<span class="name">bottomRow</span> () const</h3>
<p>Returns the bottom row of the selection.</p>
<p><b>See also </b><a href="q3tableselection.html#topRow">topRow</a>(), <a href="q3tableselection.html#leftCol">leftCol</a>(), and <a href="q3tableselection.html#rightCol">rightCol</a>().</p>
<!-- @@@bottomRow -->
<!-- $$$expandTo[overload1]$$$expandTointint -->
<h3 class="fn"><a name="expandTo"></a><span class="type">void</span> Q3TableSelection::<span class="name">expandTo</span> ( <span class="type">int</span> <i>row</i>, <span class="type">int</span> <i>col</i> )</h3>
<p>Expands the selection to include cell <i>row</i>, <i>col</i>. The new selection rectangle is the bounding rectangle of <i>row</i>, <i>col</i> and the previous selection rectangle. After calling this function the selection is active.</p>
<p>If you haven't called <a href="q3tableselection.html#init">init</a>(), this function does nothing.</p>
<p><b>See also </b><a href="q3tableselection.html#init">init</a>() and <a href="q3tableselection.html#isActive">isActive</a>().</p>
<!-- @@@expandTo -->
<!-- $$$init[overload1]$$$initintint -->
<h3 class="fn"><a name="init"></a><span class="type">void</span> Q3TableSelection::<span class="name">init</span> ( <span class="type">int</span> <i>row</i>, <span class="type">int</span> <i>col</i> )</h3>
<p>Sets the selection anchor to cell <i>row</i>, <i>col</i> and the selection to only contain this cell. The selection is not active until <a href="q3tableselection.html#expandTo">expandTo</a>() is called.</p>
<p>To extend the selection to include additional cells, call <a href="q3tableselection.html#expandTo">expandTo</a>().</p>
<p><b>See also </b><a href="q3tableselection.html#isActive">isActive</a>().</p>
<!-- @@@init -->
<!-- $$$isActive[overload1]$$$isActive -->
<h3 class="fn"><a name="isActive"></a><span class="type">bool</span> Q3TableSelection::<span class="name">isActive</span> () const</h3>
<p>Returns whether the selection is active or not. A selection is active after <a href="q3tableselection.html#init">init</a>() <i>and</i> <a href="q3tableselection.html#expandTo">expandTo</a>() have been called.</p>
<!-- @@@isActive -->
<!-- $$$isEmpty[overload1]$$$isEmpty -->
<h3 class="fn"><a name="isEmpty"></a><span class="type">bool</span> Q3TableSelection::<span class="name">isEmpty</span> () const</h3>
<p>Returns whether the selection is empty or not.</p>
<p><b>See also </b><a href="q3tableselection.html#numRows">numRows</a>() and <a href="q3tableselection.html#numCols">numCols</a>().</p>
<!-- @@@isEmpty -->
<!-- $$$leftCol[overload1]$$$leftCol -->
<h3 class="fn"><a name="leftCol"></a><span class="type">int</span> Q3TableSelection::<span class="name">leftCol</span> () const</h3>
<p>Returns the left column of the selection.</p>
<p><b>See also </b><a href="q3tableselection.html#topRow">topRow</a>(), <a href="q3tableselection.html#bottomRow">bottomRow</a>(), and <a href="q3tableselection.html#rightCol">rightCol</a>().</p>
<!-- @@@leftCol -->
<!-- $$$numCols[overload1]$$$numCols -->
<h3 class="fn"><a name="numCols"></a><span class="type">int</span> Q3TableSelection::<span class="name">numCols</span> () const</h3>
<p>Returns the number of columns in the selection.</p>
<p><b>See also </b><a href="q3tableselection.html#numRows">numRows</a>().</p>
<!-- @@@numCols -->
<!-- $$$numRows[overload1]$$$numRows -->
<h3 class="fn"><a name="numRows"></a><span class="type">int</span> Q3TableSelection::<span class="name">numRows</span> () const</h3>
<p>Returns the number of rows in the selection.</p>
<p><b>See also </b><a href="q3tableselection.html#numCols">numCols</a>().</p>
<!-- @@@numRows -->
<!-- $$$rightCol[overload1]$$$rightCol -->
<h3 class="fn"><a name="rightCol"></a><span class="type">int</span> Q3TableSelection::<span class="name">rightCol</span> () const</h3>
<p>Returns the right column of the selection.</p>
<p><b>See also </b><a href="q3tableselection.html#topRow">topRow</a>(), <a href="q3tableselection.html#bottomRow">bottomRow</a>(), and <a href="q3tableselection.html#leftCol">leftCol</a>().</p>
<!-- @@@rightCol -->
<!-- $$$topRow[overload1]$$$topRow -->
<h3 class="fn"><a name="topRow"></a><span class="type">int</span> Q3TableSelection::<span class="name">topRow</span> () const</h3>
<p>Returns the top row of the selection.</p>
<p><b>See also </b><a href="q3tableselection.html#bottomRow">bottomRow</a>(), <a href="q3tableselection.html#leftCol">leftCol</a>(), and <a href="q3tableselection.html#rightCol">rightCol</a>().</p>
<!-- @@@topRow -->
<!-- $$$operator!=[overload1]$$$operator!=constQ3TableSelection& -->
<h3 class="fn"><a name="operator-not-eq"></a><span class="type">bool</span> Q3TableSelection::<span class="name">operator!=</span> ( const <span class="type">Q3TableSelection</span> & <i>s</i> ) const</h3>
<p>Returns true if <i>s</i> does not include the same cells as the selection; otherwise returns false.</p>
<!-- @@@operator!= -->
<!-- $$$operator==[overload1]$$$operator==constQ3TableSelection& -->
<h3 class="fn"><a name="operator-eq-eq"></a><span class="type">bool</span> Q3TableSelection::<span class="name">operator==</span> ( const <span class="type">Q3TableSelection</span> & <i>s</i> ) const</h3>
<p>Returns true if <i>s</i> includes the same cells as the selection; otherwise returns false.</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>
|