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 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502
|
<!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">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta name="author" content="Emanuel Eichhammer" />
<meta name="copyright" content="(C) 2011-2016 Emanuel Eichhammer" />
<title>QCPAxisTickerText Class Reference</title>
<link href="qcp.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top">
<a class="headerLink" href="index.html">Main Page</a> ·
<a class="headerLink" href="classoverview.html">Class Overview</a> ·
<a class="headerLink" href="hierarchy.html">Hierarchy</a> ·
<a class="headerLink" href="annotated.html">All Classes</a> ·
<a class="headerLink" href="pages.html">Special Pages</a>
<!-- Generated by Doxygen 1.8.12 -->
</div><!-- top -->
<div class="header">
<div class="summary">
<a href="#pub-methods">Public Functions</a> |
<a href="#pro-methods">Protected Functions</a> </div>
<div class="headertitle">
<div class="title">QCPAxisTickerText Class Reference</div> </div>
</div><!--header-->
<div class="contents">
<p>Specialized axis ticker which allows arbitrary labels at specified coordinates.
<a href="classQCPAxisTickerText.html#details">More...</a></p>
<div class="dynheader">
Inheritance diagram for QCPAxisTickerText:</div>
<div class="dyncontent">
<div class="center"><img src="classQCPAxisTickerText__inherit__graph.png" border="0" usemap="#QCPAxisTickerText_inherit__map" alt="Inheritance graph"/></div>
<map name="QCPAxisTickerText_inherit__map" id="QCPAxisTickerText_inherit__map">
<area shape="rect" id="node2" href="classQCPAxisTicker.html" title="The base class tick generator used by QCPAxis to create tick positions and tick labels. " alt="" coords="15,5,117,29"/>
</map>
</div>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Functions</h2></td></tr>
<tr class="memitem:a1d7243b1256c1aa9d1d5b99b2e84e648"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTickerText.html#a1d7243b1256c1aa9d1d5b99b2e84e648">QCPAxisTickerText</a> ()</td></tr>
<tr class="separator:a1d7243b1256c1aa9d1d5b99b2e84e648"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ac84622a6bb4f2a98474e185ecaf3189a"><td class="memItemLeft" align="right" valign="top">QMap< double, QString > & </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTickerText.html#ac84622a6bb4f2a98474e185ecaf3189a">ticks</a> ()</td></tr>
<tr class="separator:ac84622a6bb4f2a98474e185ecaf3189a"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a5c3c59e8fdf4c96568dd50d4a653e791"><td class="memItemLeft" align="right" valign="top"><a id="a5c3c59e8fdf4c96568dd50d4a653e791"></a>
int </td><td class="memItemRight" valign="bottom"><b>subTickCount</b> () const</td></tr>
<tr class="separator:a5c3c59e8fdf4c96568dd50d4a653e791"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a8cdf1f21940f1f53f5e3d30b2c74f5cf"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTickerText.html#a8cdf1f21940f1f53f5e3d30b2c74f5cf">setTicks</a> (const QMap< double, QString > &<a class="el" href="classQCPAxisTickerText.html#ac84622a6bb4f2a98474e185ecaf3189a">ticks</a>)</td></tr>
<tr class="separator:a8cdf1f21940f1f53f5e3d30b2c74f5cf"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a686f38f358a0cf2d9309c84c22581d9b"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTickerText.html#a686f38f358a0cf2d9309c84c22581d9b">setTicks</a> (const QVector< double > &positions, const QVector< QString > &labels)</td></tr>
<tr class="separator:a686f38f358a0cf2d9309c84c22581d9b"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a8cfa50c51183c90186892eeef978d571"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTickerText.html#a8cfa50c51183c90186892eeef978d571">setSubTickCount</a> (int subTicks)</td></tr>
<tr class="separator:a8cfa50c51183c90186892eeef978d571"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a21826d2fcd9a25c194d34d4f67aa1460"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTickerText.html#a21826d2fcd9a25c194d34d4f67aa1460">clear</a> ()</td></tr>
<tr class="separator:a21826d2fcd9a25c194d34d4f67aa1460"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a3362873a48614e6d446c193548cb85e3"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTickerText.html#a3362873a48614e6d446c193548cb85e3">addTick</a> (double position, const QString &label)</td></tr>
<tr class="separator:a3362873a48614e6d446c193548cb85e3"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:aba34051300eecaefbedb2df8feff2d45"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTickerText.html#aba34051300eecaefbedb2df8feff2d45">addTicks</a> (const QMap< double, QString > &<a class="el" href="classQCPAxisTickerText.html#ac84622a6bb4f2a98474e185ecaf3189a">ticks</a>)</td></tr>
<tr class="separator:aba34051300eecaefbedb2df8feff2d45"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a8140c730e20b0050e1b702af3db00b2e"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTickerText.html#a8140c730e20b0050e1b702af3db00b2e">addTicks</a> (const QVector< double > &positions, const QVector< QString > &labels)</td></tr>
<tr class="separator:a8140c730e20b0050e1b702af3db00b2e"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="inherit_header pub_methods_classQCPAxisTicker"><td colspan="2" onclick="javascript:toggleInherit('pub_methods_classQCPAxisTicker')"><img src="closed.png" alt="-"/> Public Functions inherited from <a class="el" href="classQCPAxisTicker.html">QCPAxisTicker</a></td></tr>
<tr class="memitem:a8fcf23c79ebd72202fe79253f9f01ea8 inherit pub_methods_classQCPAxisTicker"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTicker.html#a8fcf23c79ebd72202fe79253f9f01ea8">QCPAxisTicker</a> ()</td></tr>
<tr class="separator:a8fcf23c79ebd72202fe79253f9f01ea8 inherit pub_methods_classQCPAxisTicker"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a58df76f2ec3eb48401bdd314b0e14ba1 inherit pub_methods_classQCPAxisTicker"><td class="memItemLeft" align="right" valign="top"><a id="a58df76f2ec3eb48401bdd314b0e14ba1"></a>
<a class="el" href="classQCPAxisTicker.html#ab6d2f9d9477821623ac9bc4b21ddf49a">TickStepStrategy</a> </td><td class="memItemRight" valign="bottom"><b>tickStepStrategy</b> () const</td></tr>
<tr class="separator:a58df76f2ec3eb48401bdd314b0e14ba1 inherit pub_methods_classQCPAxisTicker"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:aaf9edbe4169ce55e216fd067cc139452 inherit pub_methods_classQCPAxisTicker"><td class="memItemLeft" align="right" valign="top"><a id="aaf9edbe4169ce55e216fd067cc139452"></a>
int </td><td class="memItemRight" valign="bottom"><b>tickCount</b> () const</td></tr>
<tr class="separator:aaf9edbe4169ce55e216fd067cc139452 inherit pub_methods_classQCPAxisTicker"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ac0c6e9587c36fdeefb5518c00fe7ab15 inherit pub_methods_classQCPAxisTicker"><td class="memItemLeft" align="right" valign="top"><a id="ac0c6e9587c36fdeefb5518c00fe7ab15"></a>
double </td><td class="memItemRight" valign="bottom"><b>tickOrigin</b> () const</td></tr>
<tr class="separator:ac0c6e9587c36fdeefb5518c00fe7ab15 inherit pub_methods_classQCPAxisTicker"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a73b1d847c1a12159af6bfda4ebebe7d5 inherit pub_methods_classQCPAxisTicker"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTicker.html#a73b1d847c1a12159af6bfda4ebebe7d5">setTickStepStrategy</a> (<a class="el" href="classQCPAxisTicker.html#ab6d2f9d9477821623ac9bc4b21ddf49a">TickStepStrategy</a> strategy)</td></tr>
<tr class="separator:a73b1d847c1a12159af6bfda4ebebe7d5 inherit pub_methods_classQCPAxisTicker"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a47752abba8293e6dc18491501ae34008 inherit pub_methods_classQCPAxisTicker"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTicker.html#a47752abba8293e6dc18491501ae34008">setTickCount</a> (int count)</td></tr>
<tr class="separator:a47752abba8293e6dc18491501ae34008 inherit pub_methods_classQCPAxisTicker"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ab509c7e500293bf66a8409f0d7c23943 inherit pub_methods_classQCPAxisTicker"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTicker.html#ab509c7e500293bf66a8409f0d7c23943">setTickOrigin</a> (double origin)</td></tr>
<tr class="separator:ab509c7e500293bf66a8409f0d7c23943 inherit pub_methods_classQCPAxisTicker"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:aefbd11725678ca824add8cf926cbc856 inherit pub_methods_classQCPAxisTicker"><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTicker.html#aefbd11725678ca824add8cf926cbc856">generate</a> (const <a class="el" href="classQCPRange.html">QCPRange</a> &range, const QLocale &locale, QChar formatChar, int precision, QVector< double > &ticks, QVector< double > *subTicks, QVector< QString > *tickLabels)</td></tr>
<tr class="separator:aefbd11725678ca824add8cf926cbc856 inherit pub_methods_classQCPAxisTicker"><td class="memSeparator" colspan="2"> </td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pro-methods"></a>
Protected Functions</h2></td></tr>
<tr class="memitem:a3db56d8bb32347b45b78190667553af5"><td class="memItemLeft" align="right" valign="top">virtual double </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTickerText.html#a3db56d8bb32347b45b78190667553af5">getTickStep</a> (const <a class="el" href="classQCPRange.html">QCPRange</a> &range)</td></tr>
<tr class="separator:a3db56d8bb32347b45b78190667553af5"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ab5b6f425cb2e0047735dd209958f8717"><td class="memItemLeft" align="right" valign="top">virtual int </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTickerText.html#ab5b6f425cb2e0047735dd209958f8717">getSubTickCount</a> (double tickStep)</td></tr>
<tr class="separator:ab5b6f425cb2e0047735dd209958f8717"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a0fbace8a70c16ba90d37c921365d695c"><td class="memItemLeft" align="right" valign="top">virtual QString </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTickerText.html#a0fbace8a70c16ba90d37c921365d695c">getTickLabel</a> (double tick, const QLocale &locale, QChar formatChar, int precision)</td></tr>
<tr class="separator:a0fbace8a70c16ba90d37c921365d695c"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ad572f0c9bab76020efb3da8b10d24db2"><td class="memItemLeft" align="right" valign="top">virtual QVector< double > </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTickerText.html#ad572f0c9bab76020efb3da8b10d24db2">createTickVector</a> (double tickStep, const <a class="el" href="classQCPRange.html">QCPRange</a> &range)</td></tr>
<tr class="separator:ad572f0c9bab76020efb3da8b10d24db2"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="inherit_header pro_methods_classQCPAxisTicker"><td colspan="2" onclick="javascript:toggleInherit('pro_methods_classQCPAxisTicker')"><img src="closed.png" alt="-"/> Protected Functions inherited from <a class="el" href="classQCPAxisTicker.html">QCPAxisTicker</a></td></tr>
<tr class="memitem:a9a6435723fa0bd366d1ea4c2cff7c33f inherit pro_methods_classQCPAxisTicker"><td class="memItemLeft" align="right" valign="top">virtual QVector< double > </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTicker.html#a9a6435723fa0bd366d1ea4c2cff7c33f">createSubTickVector</a> (int subTickCount, const QVector< double > &ticks)</td></tr>
<tr class="separator:a9a6435723fa0bd366d1ea4c2cff7c33f inherit pro_methods_classQCPAxisTicker"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a804050e408f37a0b9770c6654ebe6aa7 inherit pro_methods_classQCPAxisTicker"><td class="memItemLeft" align="right" valign="top">virtual QVector< QString > </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTicker.html#a804050e408f37a0b9770c6654ebe6aa7">createLabelVector</a> (const QVector< double > &ticks, const QLocale &locale, QChar formatChar, int precision)</td></tr>
<tr class="separator:a804050e408f37a0b9770c6654ebe6aa7 inherit pro_methods_classQCPAxisTicker"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ab28cc1ab549489be7975f5ce7e717916 inherit pro_methods_classQCPAxisTicker"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTicker.html#ab28cc1ab549489be7975f5ce7e717916">trimTicks</a> (const <a class="el" href="classQCPRange.html">QCPRange</a> &range, QVector< double > &ticks, bool keepOneOutlier) const</td></tr>
<tr class="separator:ab28cc1ab549489be7975f5ce7e717916 inherit pro_methods_classQCPAxisTicker"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a4ea0a7c4ca1c610f92b9bd5944ab4260 inherit pro_methods_classQCPAxisTicker"><td class="memItemLeft" align="right" valign="top">double </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTicker.html#a4ea0a7c4ca1c610f92b9bd5944ab4260">pickClosest</a> (double target, const QVector< double > &candidates) const</td></tr>
<tr class="separator:a4ea0a7c4ca1c610f92b9bd5944ab4260 inherit pro_methods_classQCPAxisTicker"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a2f1e223bafbf2cec7c3ba8b08d5c77e8 inherit pro_methods_classQCPAxisTicker"><td class="memItemLeft" align="right" valign="top">double </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTicker.html#a2f1e223bafbf2cec7c3ba8b08d5c77e8">getMantissa</a> (double input, double *magnitude=0) const</td></tr>
<tr class="separator:a2f1e223bafbf2cec7c3ba8b08d5c77e8 inherit pro_methods_classQCPAxisTicker"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ac7df6c72876b7abd67c932663a0b0f6a inherit pro_methods_classQCPAxisTicker"><td class="memItemLeft" align="right" valign="top">double </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTicker.html#ac7df6c72876b7abd67c932663a0b0f6a">cleanMantissa</a> (double input) const</td></tr>
<tr class="separator:ac7df6c72876b7abd67c932663a0b0f6a inherit pro_methods_classQCPAxisTicker"><td class="memSeparator" colspan="2"> </td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="inherited"></a>
Additional Inherited Members</h2></td></tr>
<tr class="inherit_header pub_types_classQCPAxisTicker"><td colspan="2" onclick="javascript:toggleInherit('pub_types_classQCPAxisTicker')"><img src="closed.png" alt="-"/> Public Types inherited from <a class="el" href="classQCPAxisTicker.html">QCPAxisTicker</a></td></tr>
<tr class="memitem:ab6d2f9d9477821623ac9bc4b21ddf49a inherit pub_types_classQCPAxisTicker"><td class="memItemLeft" align="right" valign="top">enum  </td><td class="memItemRight" valign="bottom"><a class="el" href="classQCPAxisTicker.html#ab6d2f9d9477821623ac9bc4b21ddf49a">TickStepStrategy</a> </td></tr>
<tr class="separator:ab6d2f9d9477821623ac9bc4b21ddf49a inherit pub_types_classQCPAxisTicker"><td class="memSeparator" colspan="2"> </td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Specialized axis ticker which allows arbitrary labels at specified coordinates. </p>
<div class="image">
<img src="axisticker-text.png" alt="axisticker-text.png"/>
</div>
<p>This <a class="el" href="classQCPAxisTicker.html" title="The base class tick generator used by QCPAxis to create tick positions and tick labels. ">QCPAxisTicker</a> subclass generates ticks which can be directly specified by the user as coordinates and associated strings. They can be passed as a whole with <a class="el" href="classQCPAxisTickerText.html#a8cdf1f21940f1f53f5e3d30b2c74f5cf">setTicks</a> or one at a time with <a class="el" href="classQCPAxisTickerText.html#a3362873a48614e6d446c193548cb85e3">addTick</a>. Alternatively you can directly access the internal storage via <a class="el" href="classQCPAxisTickerText.html#ac84622a6bb4f2a98474e185ecaf3189a">ticks</a> and modify the tick/label data there.</p>
<p>This is useful for cases where the axis represents categories rather than numerical values.</p>
<p>If you are updating the ticks of this ticker regularly and in a dynamic fasion (e.g. dependent on the axis range), it is a sign that you should probably create an own ticker by subclassing <a class="el" href="classQCPAxisTicker.html" title="The base class tick generator used by QCPAxis to create tick positions and tick labels. ">QCPAxisTicker</a>, instead of using this one.</p>
<p>The ticker can be created and assigned to an axis like this: </p><div class="fragment"><div class="line"> QSharedPointer<QCPAxisTickerText> textTicker(<span class="keyword">new</span> <a class="code" href="classQCPAxisTickerText.html">QCPAxisTickerText</a>);</div><div class="line"> customPlot->xAxis->setTicker(textTicker);</div><div class="line"> </div><div class="line"> textTicker->addTick(1.0, <span class="stringliteral">"Bacteria"</span>);</div><div class="line"> textTicker->addTick(2.0, <span class="stringliteral">"Protozoa"</span>);</div><div class="line"> textTicker->addTick(3.0, <span class="stringliteral">"Chromista"</span>);</div><div class="line"> textTicker->addTick(4.0, <span class="stringliteral">"Plants"</span>);</div><div class="line"> textTicker->addTick(5.0, <span class="stringliteral">"Fungi"</span>);</div><div class="line"> textTicker->addTick(6.0, <span class="stringliteral">"Animals"</span>);</div><div class="line"> textTicker->addTick(8.0, <span class="stringliteral">"Vogons"</span>);</div></div><!-- fragment --></div><h2 class="groupheader">Constructor & Destructor Documentation</h2>
<a id="a1d7243b1256c1aa9d1d5b99b2e84e648"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a1d7243b1256c1aa9d1d5b99b2e84e648">§ </a></span>QCPAxisTickerText()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">QCPAxisTickerText::QCPAxisTickerText </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Constructs the ticker and sets reasonable default values. Axis tickers are commonly created managed by a QSharedPointer, which then can be passed to <a class="el" href="classQCPAxis.html#a4ee03fcd2c74d05cd1a419b9af5cfbdc">QCPAxis::setTicker</a>. </p>
</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a id="ac84622a6bb4f2a98474e185ecaf3189a"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac84622a6bb4f2a98474e185ecaf3189a">§ </a></span>ticks()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">QMap< double, QString > & QCPAxisTickerText::ticks </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns a non-const reference to the internal map which stores the tick coordinates and their labels.</p>
<p>You can access the map directly in order to add, remove or manipulate ticks, as an alternative to using the methods provided by <a class="el" href="classQCPAxisTickerText.html" title="Specialized axis ticker which allows arbitrary labels at specified coordinates. ">QCPAxisTickerText</a>, such as <a class="el" href="classQCPAxisTickerText.html#a8cdf1f21940f1f53f5e3d30b2c74f5cf">setTicks</a> and <a class="el" href="classQCPAxisTickerText.html#a3362873a48614e6d446c193548cb85e3">addTick</a>. </p>
</div>
</div>
<a id="a8cdf1f21940f1f53f5e3d30b2c74f5cf"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8cdf1f21940f1f53f5e3d30b2c74f5cf">§ </a></span>setTicks() <span class="overload">[1/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void QCPAxisTickerText::setTicks </td>
<td>(</td>
<td class="paramtype">const QMap< double, QString > & </td>
<td class="paramname"><em>ticks</em></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>This is an overloaded function.</p>
<p>Sets the ticks that shall appear on the axis. The map key of <em>ticks</em> corresponds to the axis coordinate, and the map value is the string that will appear as tick label.</p>
<p>An alternative to manipulate ticks is to directly access the internal storage with the <a class="el" href="classQCPAxisTickerText.html#ac84622a6bb4f2a98474e185ecaf3189a">ticks</a> getter.</p>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="classQCPAxisTickerText.html#aba34051300eecaefbedb2df8feff2d45">addTicks</a>, <a class="el" href="classQCPAxisTickerText.html#a3362873a48614e6d446c193548cb85e3">addTick</a>, <a class="el" href="classQCPAxisTickerText.html#a21826d2fcd9a25c194d34d4f67aa1460">clear</a> </dd></dl>
</div>
</div>
<a id="a686f38f358a0cf2d9309c84c22581d9b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a686f38f358a0cf2d9309c84c22581d9b">§ </a></span>setTicks() <span class="overload">[2/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void QCPAxisTickerText::setTicks </td>
<td>(</td>
<td class="paramtype">const QVector< double > & </td>
<td class="paramname"><em>positions</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const QVector< QString > & </td>
<td class="paramname"><em>labels</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>This is an overloaded function.</p>
<p>Sets the ticks that shall appear on the axis. The entries of <em>positions</em> correspond to the axis coordinates, and the entries of <em>labels</em> are the respective strings that will appear as tick labels.</p>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="classQCPAxisTickerText.html#aba34051300eecaefbedb2df8feff2d45">addTicks</a>, <a class="el" href="classQCPAxisTickerText.html#a3362873a48614e6d446c193548cb85e3">addTick</a>, <a class="el" href="classQCPAxisTickerText.html#a21826d2fcd9a25c194d34d4f67aa1460">clear</a> </dd></dl>
</div>
</div>
<a id="a8cfa50c51183c90186892eeef978d571"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8cfa50c51183c90186892eeef978d571">§ </a></span>setSubTickCount()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void QCPAxisTickerText::setSubTickCount </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"><em>subTicks</em></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the number of sub ticks that shall appear between ticks. For <a class="el" href="classQCPAxisTickerText.html" title="Specialized axis ticker which allows arbitrary labels at specified coordinates. ">QCPAxisTickerText</a>, there is no automatic sub tick count calculation. So if sub ticks are needed, they must be configured with this method. </p>
</div>
</div>
<a id="a21826d2fcd9a25c194d34d4f67aa1460"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a21826d2fcd9a25c194d34d4f67aa1460">§ </a></span>clear()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void QCPAxisTickerText::clear </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Clears all ticks.</p>
<p>An alternative to manipulate ticks is to directly access the internal storage with the <a class="el" href="classQCPAxisTickerText.html#ac84622a6bb4f2a98474e185ecaf3189a">ticks</a> getter.</p>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="classQCPAxisTickerText.html#a8cdf1f21940f1f53f5e3d30b2c74f5cf">setTicks</a>, <a class="el" href="classQCPAxisTickerText.html#aba34051300eecaefbedb2df8feff2d45">addTicks</a>, <a class="el" href="classQCPAxisTickerText.html#a3362873a48614e6d446c193548cb85e3">addTick</a> </dd></dl>
</div>
</div>
<a id="a3362873a48614e6d446c193548cb85e3"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a3362873a48614e6d446c193548cb85e3">§ </a></span>addTick()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void QCPAxisTickerText::addTick </td>
<td>(</td>
<td class="paramtype">double </td>
<td class="paramname"><em>position</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const QString & </td>
<td class="paramname"><em>label</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Adds a single tick to the axis at the given axis coordinate <em>position</em>, with the provided tick <em>label</em>.</p>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="classQCPAxisTickerText.html#aba34051300eecaefbedb2df8feff2d45">addTicks</a>, <a class="el" href="classQCPAxisTickerText.html#a8cdf1f21940f1f53f5e3d30b2c74f5cf">setTicks</a>, <a class="el" href="classQCPAxisTickerText.html#a21826d2fcd9a25c194d34d4f67aa1460">clear</a> </dd></dl>
</div>
</div>
<a id="aba34051300eecaefbedb2df8feff2d45"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aba34051300eecaefbedb2df8feff2d45">§ </a></span>addTicks() <span class="overload">[1/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void QCPAxisTickerText::addTicks </td>
<td>(</td>
<td class="paramtype">const QMap< double, QString > & </td>
<td class="paramname"><em>ticks</em></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>This is an overloaded function.</p>
<p>Adds the provided <em>ticks</em> to the ones already existing. The map key of <em>ticks</em> corresponds to the axis coordinate, and the map value is the string that will appear as tick label.</p>
<p>An alternative to manipulate ticks is to directly access the internal storage with the <a class="el" href="classQCPAxisTickerText.html#ac84622a6bb4f2a98474e185ecaf3189a">ticks</a> getter.</p>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="classQCPAxisTickerText.html#a3362873a48614e6d446c193548cb85e3">addTick</a>, <a class="el" href="classQCPAxisTickerText.html#a8cdf1f21940f1f53f5e3d30b2c74f5cf">setTicks</a>, <a class="el" href="classQCPAxisTickerText.html#a21826d2fcd9a25c194d34d4f67aa1460">clear</a> </dd></dl>
</div>
</div>
<a id="a8140c730e20b0050e1b702af3db00b2e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8140c730e20b0050e1b702af3db00b2e">§ </a></span>addTicks() <span class="overload">[2/2]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void QCPAxisTickerText::addTicks </td>
<td>(</td>
<td class="paramtype">const QVector< double > & </td>
<td class="paramname"><em>positions</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const QVector< QString > & </td>
<td class="paramname"><em>labels</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>This is an overloaded function.</p>
<p>Adds the provided ticks to the ones already existing. The entries of <em>positions</em> correspond to the axis coordinates, and the entries of <em>labels</em> are the respective strings that will appear as tick labels.</p>
<p>An alternative to manipulate ticks is to directly access the internal storage with the <a class="el" href="classQCPAxisTickerText.html#ac84622a6bb4f2a98474e185ecaf3189a">ticks</a> getter.</p>
<dl class="section see"><dt>See also</dt><dd><a class="el" href="classQCPAxisTickerText.html#a3362873a48614e6d446c193548cb85e3">addTick</a>, <a class="el" href="classQCPAxisTickerText.html#a8cdf1f21940f1f53f5e3d30b2c74f5cf">setTicks</a>, <a class="el" href="classQCPAxisTickerText.html#a21826d2fcd9a25c194d34d4f67aa1460">clear</a> </dd></dl>
</div>
</div>
<a id="a3db56d8bb32347b45b78190667553af5"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a3db56d8bb32347b45b78190667553af5">§ </a></span>getTickStep()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">double QCPAxisTickerText::getTickStep </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classQCPRange.html">QCPRange</a> & </td>
<td class="paramname"><em>range</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">protected</span><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Since the tick coordinates are provided externally, this method implementation does nothing.</p>
<p>For general information about this virtual method, see the base class implementation. </p>
<p>Reimplemented from <a class="el" href="classQCPAxisTicker.html#a910d69bcec2de37e92d8d4e1ecf201e2">QCPAxisTicker</a>.</p>
</div>
</div>
<a id="ab5b6f425cb2e0047735dd209958f8717"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab5b6f425cb2e0047735dd209958f8717">§ </a></span>getSubTickCount()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">int QCPAxisTickerText::getSubTickCount </td>
<td>(</td>
<td class="paramtype">double </td>
<td class="paramname"><em>tickStep</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">protected</span><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the sub tick count that was configured with <a class="el" href="classQCPAxisTickerText.html#a8cfa50c51183c90186892eeef978d571">setSubTickCount</a>.</p>
<p>For general information about this virtual method, see the base class implementation. </p>
<p>Reimplemented from <a class="el" href="classQCPAxisTicker.html#a4ccc403ced7a1457ce6ba293509933c8">QCPAxisTicker</a>.</p>
</div>
</div>
<a id="a0fbace8a70c16ba90d37c921365d695c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a0fbace8a70c16ba90d37c921365d695c">§ </a></span>getTickLabel()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">QString QCPAxisTickerText::getTickLabel </td>
<td>(</td>
<td class="paramtype">double </td>
<td class="paramname"><em>tick</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const QLocale & </td>
<td class="paramname"><em>locale</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">QChar </td>
<td class="paramname"><em>formatChar</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"><em>precision</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">protected</span><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the tick label which corresponds to the key <em>tick</em> in the internal tick storage. Since the labels are provided externally, <em>locale</em>, <em>formatChar</em>, and <em>precision</em> are ignored.</p>
<p>For general information about this virtual method, see the base class implementation. </p>
<p>Reimplemented from <a class="el" href="classQCPAxisTicker.html#a8201eb4aa8be192bf786b126eb5ee089">QCPAxisTicker</a>.</p>
</div>
</div>
<a id="ad572f0c9bab76020efb3da8b10d24db2"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ad572f0c9bab76020efb3da8b10d24db2">§ </a></span>createTickVector()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">QVector< double > QCPAxisTickerText::createTickVector </td>
<td>(</td>
<td class="paramtype">double </td>
<td class="paramname"><em>tickStep</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const <a class="el" href="classQCPRange.html">QCPRange</a> & </td>
<td class="paramname"><em>range</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">protected</span><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the externally provided tick coordinates which are in the specified <em>range</em>. If available, one tick above and below the range is provided in addition, to allow possible sub tick calculation. The parameter <em>tickStep</em> is ignored.</p>
<p>For general information about this virtual method, see the base class implementation. </p>
<p>Reimplemented from <a class="el" href="classQCPAxisTicker.html#af4645a824c7bd2ca8fc7e86ebf9055bd">QCPAxisTicker</a>.</p>
</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li>src/axis/axistickertext.h</li>
<li>src/axis/axistickertext.cpp</li>
</ul>
</div><!-- contents -->
</body>
</html>
|