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 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>Wt: Wt::WTreeView Class Reference</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main Page</span></a></li>
<li><a href="pages.html"><span>Related Pages</span></a></li>
<li><a href="modules.html"><span>Modules</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Classes</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Class List</span></a></li>
<li><a href="hierarchy.html"><span>Class Hierarchy</span></a></li>
<li><a href="functions.html"><span>Class Members</span></a></li>
</ul>
</div>
<div class="navpath"><a class="el" href="namespaceWt.html">Wt</a>::<a class="el" href="classWt_1_1WTreeView.html">WTreeView</a>
</div>
</div>
<div class="contents">
<h1>Wt::WTreeView Class Reference<br>
<small>
[<a class="el" href="group__modelview.html">Model/view system</a>]</small>
</h1><!-- doxytag: class="Wt::WTreeView" --><!-- doxytag: inherits="Wt::WAbstractItemView" -->A view class that displays a model as a tree or tree table.
<a href="#_details">More...</a>
<p>
<code>#include <Wt/WTreeView></code>
<p>
<div class="dynheader">
Inheritance diagram for Wt::WTreeView:</div>
<div class="dynsection">
<p><center><img src="classWt_1_1WTreeView__inherit__graph.png" border="0" usemap="#Wt_1_1WTreeView__inherit__map" alt="Inheritance graph"></center>
<map name="Wt_1_1WTreeView__inherit__map">
<area shape="rect" href="classWt_1_1WAbstractItemView.html" title="An abstract base class for item views." alt="" coords="5,229,165,256"><area shape="rect" href="classWt_1_1WCompositeWidget.html" title="A widget that hides the implementation of composite widgets." alt="" coords="5,155,165,181"><area shape="rect" href="classWt_1_1WWidget.html" title="The abstract base class for a user-interface component." alt="" coords="37,80,133,107"><area shape="rect" href="classWt_1_1WObject.html" title="A base class for objects that participate in the signal/slot system." alt="" coords="37,5,133,32"></map>
<center><font size="2">[<a href="graph_legend.html">legend</a>]</font></center></div>
<p>
<a href="classWt_1_1WTreeView-members.html">List of all members.</a><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="a6555aa2d53557340824faa314b318f2"></a><!-- doxytag: member="Wt::WTreeView::WTreeView" ref="a6555aa2d53557340824faa314b318f2" args="(WContainerWidget *parent=0)" -->
</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#a6555aa2d53557340824faa314b318f2">WTreeView</a> (<a class="el" href="classWt_1_1WContainerWidget.html">WContainerWidget</a> *parent=0)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Creates a new tree view. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="3b361f93a9937accae2303ebda6b561f"></a><!-- doxytag: member="Wt::WTreeView::~WTreeView" ref="3b361f93a9937accae2303ebda6b561f" args="()" -->
</td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#3b361f93a9937accae2303ebda6b561f">~WTreeView</a> ()</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Destructor. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#d3dae955c9012df8e368dadd1e8a8c75">setRootIndex</a> (const <a class="el" href="classWt_1_1WModelIndex.html">WModelIndex</a> &rootIndex)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Sets the root index. <a href="#d3dae955c9012df8e368dadd1e8a8c75"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">const <a class="el" href="classWt_1_1WModelIndex.html">WModelIndex</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#b23b53eab9aebe8aef5d4936fb997aae">rootIndex</a> () const </td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Returns the root index. <a href="#b23b53eab9aebe8aef5d4936fb997aae"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#8b8bfc22f30f0edfe8fe2de37a5fefc4">setColumnFormat</a> (int column, const <a class="el" href="classWt_1_1WString.html">WString</a> &format)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Sets the column format string (<b>deprecated</b>). <a href="#8b8bfc22f30f0edfe8fe2de37a5fefc4"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="classWt_1_1WString.html">WString</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#ab731f1046a7c0b602678171af9dc33e">columnFormat</a> (int column) const </td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Returns the column format string (<b>deprecated</b>). <a href="#ab731f1046a7c0b602678171af9dc33e"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#49566dd5cc8d1d0d95bad4783dd4e11a">setExpanded</a> (const <a class="el" href="classWt_1_1WModelIndex.html">WModelIndex</a> &, bool expanded)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Expands or collapses a node. <a href="#49566dd5cc8d1d0d95bad4783dd4e11a"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#48eac450ec46ac1eea41822bfd227e9b">isExpanded</a> (const <a class="el" href="classWt_1_1WModelIndex.html">WModelIndex</a> &index) const </td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Returns whether a node is expanded. <a href="#48eac450ec46ac1eea41822bfd227e9b"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#be1b839fc999634806df030301422411">collapse</a> (const <a class="el" href="classWt_1_1WModelIndex.html">WModelIndex</a> &index)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Collapses a node. <a href="#be1b839fc999634806df030301422411"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#03cd862e9c5dbbfbc126ac627b48592a">expand</a> (const <a class="el" href="classWt_1_1WModelIndex.html">WModelIndex</a> &index)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Expands a node. <a href="#03cd862e9c5dbbfbc126ac627b48592a"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#dd40d3e05352ae094f6fe2b9c879c2c7">expandToDepth</a> (int depth)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Expands all nodes to a depth. <a href="#dd40d3e05352ae094f6fe2b9c879c2c7"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#48f74194ae6bd63c08a6ff76ecb3e39c">setAlternatingRowColors</a> (bool enable)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Sets if alternating row colors are to be used. Configure whether rows get an alternating background color. These are implemented by using a background image on the root node, like:. <a href="#48f74194ae6bd63c08a6ff76ecb3e39c"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#0d681bab3b32204d64b7902c5bce8f2b">alternatingRowColors</a> () const </td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Returns whether alternating row colors are used. <a href="#0d681bab3b32204d64b7902c5bce8f2b"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#ef8576ebdf2089edc259362a15e2f750">setRootIsDecorated</a> (bool show)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Sets whether toplevel items are decorated. <a href="#ef8576ebdf2089edc259362a15e2f750"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#c6e70d3de6623882f70219934d5f8253">rootIsDecorated</a> () const </td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Returns whether toplevel items are decorated. <a href="#c6e70d3de6623882f70219934d5f8253"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#c6d50ab57d086e67a2463f8a6a43e605">setColumn1Fixed</a> (bool enable)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Configures whether horizontal scrolling includes the first column. <a href="#c6d50ab57d086e67a2463f8a6a43e605"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#403dade7876fdd7e44600738660e17f8">column1Fixed</a> () const </td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Returns whether horizontal scrolling includes the first column. <a href="#403dade7876fdd7e44600738660e17f8"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#482314306c8404d7ed941fd986e32623">resize</a> (const <a class="el" href="classWt_1_1WLength.html">WLength</a> &width, const <a class="el" href="classWt_1_1WLength.html">WLength</a> &height)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Resizes the widget. <a href="#482314306c8404d7ed941fd986e32623"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="classWt_1_1Signal.html">Signal</a>< <a class="el" href="classWt_1_1WModelIndex.html">WModelIndex</a> > & </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#8d014f2cd6637f5f842d7fe2fff00418">collapsed</a> ()</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Signal emitted when a node is collapsed. <a href="#8d014f2cd6637f5f842d7fe2fff00418"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="classWt_1_1Signal.html">Signal</a>< <a class="el" href="classWt_1_1WModelIndex.html">WModelIndex</a> > & </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#96586671660b0e81cc2ae99fff284909">expanded</a> ()</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Signal emitted when a node is expanded. <a href="#96586671660b0e81cc2ae99fff284909"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#390300f766472476e6a0df5aefaa2ef0">setModel</a> (<a class="el" href="classWt_1_1WAbstractItemModel.html">WAbstractItemModel</a> *model)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Sets the model. <a href="#390300f766472476e6a0df5aefaa2ef0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#33ba5111945bc0ec4745a536d52adec5">setColumnWidth</a> (int column, const <a class="el" href="classWt_1_1WLength.html">WLength</a> &width)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Sets the column width. <a href="#33ba5111945bc0ec4745a536d52adec5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classWt_1_1WLength.html">WLength</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#362478c3c72d50b12fb28e6167831688">columnWidth</a> (int column) const </td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Returns the column width. <a href="#362478c3c72d50b12fb28e6167831688"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#849f805206bd1bc83e6bc411f208031d">setRowHeight</a> (const <a class="el" href="classWt_1_1WLength.html">WLength</a> &rowHeight)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Sets the row height. <a href="#849f805206bd1bc83e6bc411f208031d"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#2367f47b0c80ec909d8e4d7626955a83">setHeaderHeight</a> (const <a class="el" href="classWt_1_1WLength.html">WLength</a> &height, bool multiLine=false)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Sets the header height. <a href="#2367f47b0c80ec909d8e4d7626955a83"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#c3362a9f4ee26be8603a53661a5dcf32">setColumnAlignment</a> (int column, <a class="el" href="namespaceWt.html#b8f772c69bc8180c31f9e4f4593b143f">AlignmentFlag</a> alignment)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Sets the content alignment for a column. <a href="#c3362a9f4ee26be8603a53661a5dcf32"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="namespaceWt.html#b8f772c69bc8180c31f9e4f4593b143f">AlignmentFlag</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#637cefec32545eae957ee29a6ff54db6">columnAlignment</a> (int column) const </td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Returns the content alignment for a column. <a href="#637cefec32545eae957ee29a6ff54db6"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#f51c40dde539c64396fcf4735aa54a8d">setHeaderAlignment</a> (int column, <a class="el" href="namespaceWt.html#b8f772c69bc8180c31f9e4f4593b143f">AlignmentFlag</a> alignment)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Sets the header alignment for a column. <a href="#f51c40dde539c64396fcf4735aa54a8d"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="namespaceWt.html#b8f772c69bc8180c31f9e4f4593b143f">AlignmentFlag</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#2daf20310ac763199d88ff73ead8b856">headerAlignment</a> (int column) const </td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Returns the header alignment for a column. <a href="#2daf20310ac763199d88ff73ead8b856"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#dba2dc39faa8d427e8adb241b067ebf2">setColumnBorder</a> (const <a class="el" href="classWt_1_1WColor.html">WColor</a> &color)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Sets the column border color. <a href="#dba2dc39faa8d427e8adb241b067ebf2"></a><br></td></tr>
<tr><td colspan="2"><br><h2>Protected Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WTreeView.html#11f8eb2390ce4585b99344e540fef8b1">enableAjax</a> ()</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Progresses to an Ajax-enabled widget. <a href="#11f8eb2390ce4585b99344e540fef8b1"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
A view class that displays a model as a tree or tree table.
<p>
The view displays data from a <a class="el" href="classWt_1_1WAbstractItemModel.html" title="An abstract model for use with Wt's view classes.">WAbstractItemModel</a> in a tree or tree table. It provides incremental rendering, allowing the display of data models of any size efficiently, without excessive use of client- or serverside resources. Data of all predefined roles is displayed (see also ItemDataRole), including text, icons, checkboxes, and tooltips .<p>
By default, all but the first columns are given a width of 150px, and the first column takes the remaining size. <b>Note that this may have as consequence that the first column's size is reduced to 0.</b> Column widths of all columns, including the first column, can be set through the API method <a class="el" href="classWt_1_1WTreeView.html#33ba5111945bc0ec4745a536d52adec5" title="Sets the column width.">setColumnWidth()</a>, and also by the user using handles provided in the header.<p>
Optionally, the treeview may be configured so that the first column is always visible while scrolling through the other columns, which may be convenient if you wish to display a model with many columns. Use <a class="el" href="classWt_1_1WTreeView.html#c6d50ab57d086e67a2463f8a6a43e605" title="Configures whether horizontal scrolling includes the first column.">setColumn1Fixed()</a> to enable this behaviour.<p>
If the model supports sorting (<a class="el" href="classWt_1_1WAbstractItemModel.html#133931424d4daa8422bcdea911cda713" title="Sorts the model according to a particular column.">WAbstractItemModel::sort()</a>), such as the <a class="el" href="classWt_1_1WStandardItemModel.html" title="A standard data model, which stores its data in memory.">WStandardItemModel</a>, then you can enable sorting buttons in the header, using <a class="el" href="classWt_1_1WAbstractItemView.html#e1c86a0f37f97f63aed3b00fd8ffad7c" title="Enables or disables sorting for all columns.">setSortingEnabled()</a>.<p>
You can allow selection on row or item level (using <a class="el" href="classWt_1_1WAbstractItemView.html#d59b47cf9a1c5a65c5adc3e1900ceb5c" title="Changes the selection behaviour.">setSelectionBehavior()</a>), and selection of single or multiple items (using <a class="el" href="classWt_1_1WAbstractItemView.html#f6fcd9761e2f7a3b497d3563c849d320" title="Sets the selection mode.">setSelectionMode()</a>), and listen for changes in the selection using the <a class="el" href="classWt_1_1WAbstractItemView.html#9ed7710caa82e030db59020f4add4025" title="Signal emitted when the selection is changed.">selectionChanged()</a> signal.<p>
You may enable drag & drop support for this view, whith awareness of the items in the model. When enabling dragging (see <a class="el" href="classWt_1_1WAbstractItemView.html#0ca99b835708d990b90000917045738e" title="Enables the selection to be dragged (drag & drop).">setDragEnabled()</a>), the current selection may be dragged, but only when all items in the selection indicate support for dragging (controlled by the <a class="el" href="group__modelview.html#gg1d77c4de293aebfacbdde124de06b8b02b0edddfd15d67a84723c9043479ced1">ItemIsDragEnabled</a> flag), and if the model indicates a mime-type (controlled by <a class="el" href="classWt_1_1WAbstractItemModel.html#4c62d2cc18d133d7926a91b4f2eebe62" title="Returns a mime-type for dragging a set of indexes.">WAbstractItemModel::mimeType()</a>). Likewise, by enabling support for dropping (see <a class="el" href="classWt_1_1WAbstractItemView.html#1eda46c8e9a21af7f6281e7096af8fbe" title="Enables drop operations (drag & drop).">setDropsEnabled()</a>), the treeview may receive a drop event on a particular item, at least if the item indicates support for drops (controlled by the <a class="el" href="group__modelview.html#gg1d77c4de293aebfacbdde124de06b8b095d23063251001545d4bfab1308879a3">ItemIsDropEnabled</a> flag).<p>
You may also react to mouse click events on any item, by connecting to one of the <a class="el" href="classWt_1_1WAbstractItemView.html#3b72d5f8e5b0afdea83e224354d3e91b" title="Signal emitted when an item is clicked.">clicked()</a> or <a class="el" href="classWt_1_1WAbstractItemView.html#14ac099f58621d66834aa5674ea8ecb5" title="Signal emitted when an item is double clicked.">doubleClicked()</a> signals.<p>
Usage example: <div class="fragment"><pre class="fragment"> <span class="comment">// WTreeView will display the data of a model</span>
<a class="code" href="classWt_1_1WAbstractItemModel.html" title="An abstract model for use with Wt&#39;s view classes.">Wt::WAbstractItemModel</a> *model = ...
<span class="comment">// Create the WTreeView</span>
<a class="code" href="classWt_1_1WTreeView.html" title="A view class that displays a model as a tree or tree table.">Wt::WTreeView</a> *gitView = <span class="keyword">new</span> <a class="code" href="classWt_1_1WTreeView.html" title="A view class that displays a model as a tree or tree table.">Wt::WTreeView</a>();
gitView-><a class="code" href="classWt_1_1WTreeView.html#482314306c8404d7ed941fd986e32623" title="Resizes the widget.">resize</a>(300, <a class="code" href="classWt_1_1WLength.html#0cf39ca4225776879d56ade60320c31a" title="An &#39;auto&#39; length.">Wt::WLength::Auto</a>);
gitView-><a class="code" href="classWt_1_1WAbstractItemView.html#e1c86a0f37f97f63aed3b00fd8ffad7c" title="Enables or disables sorting for all columns.">setSortingEnabled</a>(<span class="keyword">false</span>);
gitView-><a class="code" href="classWt_1_1WTreeView.html#390300f766472476e6a0df5aefaa2ef0" title="Sets the model.">setModel</a>(model);
gitView-><a class="code" href="classWt_1_1WAbstractItemView.html#f6fcd9761e2f7a3b497d3563c849d320" title="Sets the selection mode.">setSelectionMode</a>(<a class="code" href="namespaceWt.html#74b3f7eb1689a3cbf0ea514ffd20bccc4fd3c5ba6ce5289a1e732d85f002882a" title="Single selection only.">SingleSelection</a>);
</pre></div><p>
<h3>CSS</h3>
<p>
The treeview is styled by the current CSS theme. The look can be overridden using the <code>Wt-treeview</code> CSS class and the following selectors.<p>
Selectors that apply to the header: <div class="fragment"><pre class="fragment">
.Wt-treeview .Wt-headerdiv : header (background)
.Wt-treeview .Wt-header .Wt-label : header label
.Wt-treeview .Wt-tv-rh : column resize handle
.Wt-treeview .Wt-tv-sh-none : column sort handle, no sorting
.Wt-treeview .Wt-tv-sh-up : column sort handle, sort up
.Wt-treeview .Wt-tv-sh-down : column sort handle, sort down
</pre></div> Selectors that apply to the tree decoration: <div class="fragment"><pre class="fragment">
.Wt-treeview .Wt-trunk : vertical line, trunk
.Wt-treeview .Wt-end : vertical line, last item
.Wt-treeview .Wt-collapse : collapse icon
.Wt-treeview .Wt-expand : expand icon
.Wt-treeview .Wt-noexpand : leaf icon
</pre></div> Selectors that apply to the table contents: <div class="fragment"><pre class="fragment">
.Wt-treeview .Wt-spacer : spacer for non-loaded content
.Wt-treeview .Wt-selected : selected item
.Wt-treeview .Wt-drop-site : possible drop site
</pre></div> Selectors that apply to the table borders (which must be 1 pixel wide) <div class="fragment"><pre class="fragment">
.Wt-treeview .Wt-tv-row .Wt-tv-c : border-right property of cells
.Wt-treeview .Wt-header .Wt-tv-row,
.Wt-treeview .Wt-tv-node .Wt-tv-row : border-left property of cells
</pre></div><p>
A snapshot of the <a class="el" href="classWt_1_1WTreeView.html" title="A view class that displays a model as a tree or tree table.">WTreeView</a>: <div align="center">
<img src="WTreeView-default-1.png" alt="WTreeView-default-1.png">
<p><strong>WTreeView example (default)</strong></p></div>
<div align="center">
<img src="WTreeView-polished-1.png" alt="WTreeView-polished-1.png">
<p><strong>WTreeView example (polished)</strong></p></div>
<hr><h2>Member Function Documentation</h2>
<a class="anchor" name="d3dae955c9012df8e368dadd1e8a8c75"></a><!-- doxytag: member="Wt::WTreeView::setRootIndex" ref="d3dae955c9012df8e368dadd1e8a8c75" args="(const WModelIndex &rootIndex)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void Wt::WTreeView::setRootIndex </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classWt_1_1WModelIndex.html">WModelIndex</a> & </td>
<td class="paramname"> <em>rootIndex</em> </td>
<td> ) </td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Sets the root index.
<p>
The root index is the model index that is considered the root node. This node itself is not rendered, but all its children are the top level nodes.<p>
The default value is WModelIndex(), corresponding to the invisible root.<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#390300f766472476e6a0df5aefaa2ef0" title="Sets the model.">setModel()</a> </dd></dl>
</div>
</div><p>
<a class="anchor" name="b23b53eab9aebe8aef5d4936fb997aae"></a><!-- doxytag: member="Wt::WTreeView::rootIndex" ref="b23b53eab9aebe8aef5d4936fb997aae" args="() const " -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">const <a class="el" href="classWt_1_1WModelIndex.html">WModelIndex</a>& Wt::WTreeView::rootIndex </td>
<td>(</td>
<td class="paramname"> </td>
<td> ) </td>
<td> const<code> [inline]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Returns the root index.
<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#d3dae955c9012df8e368dadd1e8a8c75" title="Sets the root index.">setRootIndex()</a> </dd></dl>
</div>
</div><p>
<a class="anchor" name="8b8bfc22f30f0edfe8fe2de37a5fefc4"></a><!-- doxytag: member="Wt::WTreeView::setColumnFormat" ref="8b8bfc22f30f0edfe8fe2de37a5fefc4" args="(int column, const WString &format)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void Wt::WTreeView::setColumnFormat </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"> <em>column</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const <a class="el" href="classWt_1_1WString.html">WString</a> & </td>
<td class="paramname"> <em>format</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Sets the column format string (<b>deprecated</b>).
<p>
The DisplayRole data for that column is converted to a string using <a class="el" href="classWt_1_1WAbstractItemModel.html#86307ac8fa69203e5de72d7c08197fbc" title="Interpret a boost::any as a string value.">asString()</a>, with the given format.<p>
The default value is "".<p>
<dl compact><dt><b><a class="el" href="deprecated.html#_deprecated000023">Deprecated:</a></b></dt><dd>use <a class="el" href="classWt_1_1WAbstractItemView.html#8d3d37b13cc684248e06700c40dd7672" title="Returns the delegate that was set for a column.">itemDelegateForColumn()</a> to customize the formatting. This method will create a new <a class="el" href="classWt_1_1WItemDelegate.html" title="Standard delegate class for rendering a view item.">WItemDelegate</a> for the column, and configure its format. </dd></dl>
</div>
</div><p>
<a class="anchor" name="ab731f1046a7c0b602678171af9dc33e"></a><!-- doxytag: member="Wt::WTreeView::columnFormat" ref="ab731f1046a7c0b602678171af9dc33e" args="(int column) const " -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classWt_1_1WString.html">WString</a> Wt::WTreeView::columnFormat </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"> <em>column</em> </td>
<td> ) </td>
<td> const</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Returns the column format string (<b>deprecated</b>).
<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#8b8bfc22f30f0edfe8fe2de37a5fefc4" title="Sets the column format string (deprecated).">setColumnFormat()</a></dd></dl>
<dl compact><dt><b><a class="el" href="deprecated.html#_deprecated000024">Deprecated:</a></b></dt><dd>use <a class="el" href="classWt_1_1WAbstractItemView.html#8d3d37b13cc684248e06700c40dd7672" title="Returns the delegate that was set for a column.">itemDelegateForColumn()</a> to customize the formatting. This method will try to cast the <a class="el" href="classWt_1_1WAbstractItemView.html#8d3d37b13cc684248e06700c40dd7672" title="Returns the delegate that was set for a column.">itemDelegateForColumn()</a> to a <a class="el" href="classWt_1_1WItemDelegate.html" title="Standard delegate class for rendering a view item.">WItemDelegate</a> and return the format. </dd></dl>
</div>
</div><p>
<a class="anchor" name="49566dd5cc8d1d0d95bad4783dd4e11a"></a><!-- doxytag: member="Wt::WTreeView::setExpanded" ref="49566dd5cc8d1d0d95bad4783dd4e11a" args="(const WModelIndex &, bool expanded)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void Wt::WTreeView::setExpanded </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classWt_1_1WModelIndex.html">WModelIndex</a> & </td>
<td class="paramname">, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">bool </td>
<td class="paramname"> <em>expanded</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Expands or collapses a node.
<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#03cd862e9c5dbbfbc126ac627b48592a" title="Expands a node.">expand()</a>, <a class="el" href="classWt_1_1WTreeView.html#be1b839fc999634806df030301422411" title="Collapses a node.">collapse()</a> </dd></dl>
</div>
</div><p>
<a class="anchor" name="48eac450ec46ac1eea41822bfd227e9b"></a><!-- doxytag: member="Wt::WTreeView::isExpanded" ref="48eac450ec46ac1eea41822bfd227e9b" args="(const WModelIndex &index) const " -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool Wt::WTreeView::isExpanded </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classWt_1_1WModelIndex.html">WModelIndex</a> & </td>
<td class="paramname"> <em>index</em> </td>
<td> ) </td>
<td> const</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Returns whether a node is expanded.
<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#49566dd5cc8d1d0d95bad4783dd4e11a" title="Expands or collapses a node.">setExpanded()</a> </dd></dl>
</div>
</div><p>
<a class="anchor" name="be1b839fc999634806df030301422411"></a><!-- doxytag: member="Wt::WTreeView::collapse" ref="be1b839fc999634806df030301422411" args="(const WModelIndex &index)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void Wt::WTreeView::collapse </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classWt_1_1WModelIndex.html">WModelIndex</a> & </td>
<td class="paramname"> <em>index</em> </td>
<td> ) </td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Collapses a node.
<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#49566dd5cc8d1d0d95bad4783dd4e11a" title="Expands or collapses a node.">setExpanded()</a>, <a class="el" href="classWt_1_1WTreeView.html#03cd862e9c5dbbfbc126ac627b48592a" title="Expands a node.">expand()</a> </dd></dl>
</div>
</div><p>
<a class="anchor" name="03cd862e9c5dbbfbc126ac627b48592a"></a><!-- doxytag: member="Wt::WTreeView::expand" ref="03cd862e9c5dbbfbc126ac627b48592a" args="(const WModelIndex &index)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void Wt::WTreeView::expand </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classWt_1_1WModelIndex.html">WModelIndex</a> & </td>
<td class="paramname"> <em>index</em> </td>
<td> ) </td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Expands a node.
<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#49566dd5cc8d1d0d95bad4783dd4e11a" title="Expands or collapses a node.">setExpanded()</a>, <a class="el" href="classWt_1_1WTreeView.html#be1b839fc999634806df030301422411" title="Collapses a node.">collapse()</a> </dd></dl>
</div>
</div><p>
<a class="anchor" name="dd40d3e05352ae094f6fe2b9c879c2c7"></a><!-- doxytag: member="Wt::WTreeView::expandToDepth" ref="dd40d3e05352ae094f6fe2b9c879c2c7" args="(int depth)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void Wt::WTreeView::expandToDepth </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"> <em>depth</em> </td>
<td> ) </td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Expands all nodes to a depth.
<p>
Expands all nodes to the given <code>depth</code>. A depth of 1 corresponds to the top level nodes.<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#03cd862e9c5dbbfbc126ac627b48592a" title="Expands a node.">expand()</a> </dd></dl>
</div>
</div><p>
<a class="anchor" name="48f74194ae6bd63c08a6ff76ecb3e39c"></a><!-- doxytag: member="Wt::WTreeView::setAlternatingRowColors" ref="48f74194ae6bd63c08a6ff76ecb3e39c" args="(bool enable)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual void Wt::WTreeView::setAlternatingRowColors </td>
<td>(</td>
<td class="paramtype">bool </td>
<td class="paramname"> <em>enable</em> </td>
<td> ) </td>
<td><code> [virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Sets if alternating row colors are to be used. Configure whether rows get an alternating background color. These are implemented by using a background image on the root node, like:.
<p>
<div align="center">
<img src="stripe-30px.gif" alt="stripe-30px.gif">
<p><strong>Sample image use for alternating row colors</strong></p></div>
The image that is used is <em>resourcesURL</em>"/stripes/stripe-<i>n</i>px.gif", where <code>n</code> is the row height. In the resource folder are images pregenerated for one color and row sizes from 10 to 30px.<p>
The default value is <code>false</code>.<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd>setImagePack() </dd></dl>
<p>Implements <a class="el" href="classWt_1_1WAbstractItemView.html#1ce7b3a80265224ddc7f204fc54d1803">Wt::WAbstractItemView</a>.</p>
</div>
</div><p>
<a class="anchor" name="0d681bab3b32204d64b7902c5bce8f2b"></a><!-- doxytag: member="Wt::WTreeView::alternatingRowColors" ref="0d681bab3b32204d64b7902c5bce8f2b" args="() const " -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual bool Wt::WTreeView::alternatingRowColors </td>
<td>(</td>
<td class="paramname"> </td>
<td> ) </td>
<td> const<code> [inline, virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Returns whether alternating row colors are used.
<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#48f74194ae6bd63c08a6ff76ecb3e39c" title="Sets if alternating row colors are to be used. Configure whether rows get an alternating...">setAlternatingRowColors()</a> </dd></dl>
<p>Implements <a class="el" href="classWt_1_1WAbstractItemView.html#593836d5c5ebc6f241094afe230c2cc2">Wt::WAbstractItemView</a>.</p>
</div>
</div><p>
<a class="anchor" name="ef8576ebdf2089edc259362a15e2f750"></a><!-- doxytag: member="Wt::WTreeView::setRootIsDecorated" ref="ef8576ebdf2089edc259362a15e2f750" args="(bool show)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void Wt::WTreeView::setRootIsDecorated </td>
<td>(</td>
<td class="paramtype">bool </td>
<td class="paramname"> <em>show</em> </td>
<td> ) </td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Sets whether toplevel items are decorated.
<p>
By default, top level nodes have expand/collapse and other lines to display their linkage and offspring, like any node.<p>
By setting <code>show</code> to <code>false</code>, you can hide these decorations for root nodes, and in this way mimic a plain list.<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1Ext_1_1TableView.html" title="A widget that displays data in a table.">Ext::TableView</a> </dd></dl>
</div>
</div><p>
<a class="anchor" name="c6e70d3de6623882f70219934d5f8253"></a><!-- doxytag: member="Wt::WTreeView::rootIsDecorated" ref="c6e70d3de6623882f70219934d5f8253" args="() const " -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool Wt::WTreeView::rootIsDecorated </td>
<td>(</td>
<td class="paramname"> </td>
<td> ) </td>
<td> const<code> [inline]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Returns whether toplevel items are decorated.
<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#ef8576ebdf2089edc259362a15e2f750" title="Sets whether toplevel items are decorated.">setRootIsDecorated()</a> </dd></dl>
</div>
</div><p>
<a class="anchor" name="c6d50ab57d086e67a2463f8a6a43e605"></a><!-- doxytag: member="Wt::WTreeView::setColumn1Fixed" ref="c6d50ab57d086e67a2463f8a6a43e605" args="(bool enable)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void Wt::WTreeView::setColumn1Fixed </td>
<td>(</td>
<td class="paramtype">bool </td>
<td class="paramname"> <em>enable</em> </td>
<td> ) </td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Configures whether horizontal scrolling includes the first column.
<p>
To display a model with many columns, this option allows you to keep the first column fixed while scrolling through the other columns of the model.<p>
The default value is <code>false</code>.<p>
<dl class="note" compact><dt><b>Note:</b></dt><dd>Currently, you must set this option before any other manipulation of a newly created treeview, and only <code>enable</code> = <code>true</code> is supported. </dd></dl>
</div>
</div><p>
<a class="anchor" name="403dade7876fdd7e44600738660e17f8"></a><!-- doxytag: member="Wt::WTreeView::column1Fixed" ref="403dade7876fdd7e44600738660e17f8" args="() const " -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool Wt::WTreeView::column1Fixed </td>
<td>(</td>
<td class="paramname"> </td>
<td> ) </td>
<td> const<code> [inline]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Returns whether horizontal scrolling includes the first column.
<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#c6d50ab57d086e67a2463f8a6a43e605" title="Configures whether horizontal scrolling includes the first column.">setColumn1Fixed()</a> </dd></dl>
</div>
</div><p>
<a class="anchor" name="482314306c8404d7ed941fd986e32623"></a><!-- doxytag: member="Wt::WTreeView::resize" ref="482314306c8404d7ed941fd986e32623" args="(const WLength &width, const WLength &height)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual void Wt::WTreeView::resize </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classWt_1_1WLength.html">WLength</a> & </td>
<td class="paramname"> <em>width</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const <a class="el" href="classWt_1_1WLength.html">WLength</a> & </td>
<td class="paramname"> <em>height</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Resizes the widget.
<p>
Specify a new size for this widget, by specifying width and height. By default a widget has automatic width and height, see <a class="el" href="classWt_1_1WLength.html#b4c9733029342fdbc1dee34a523ee40d" title="Returns whether the ength is 'auto'.">WLength::isAuto()</a>.<p>
This applies to CSS-based layout, and only <a class="el" href="classWt_1_1WCompositeWidget.html#ed7eec7b9a562b84fdb97f68f37ce694">block</a> widgets can be given a size reliably.<p>
When inserted in a layout manager, the widget may be informed about its current size using <a class="el" href="classWt_1_1WWidget.html#4f83592912a7f8fa4fd35dadde78ee74" title="Sets the widget to be aware of its size set by a layout manager.">setLayoutSizeAware()</a>. If you have defined a "wtResize()" JavaScript method for the widget, then this method will also be called. operation.<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WCompositeWidget.html#3358bb9a93e5c7999c4f6d39d9880c8f" title="Returns the width.">width()</a>, <a class="el" href="classWt_1_1WCompositeWidget.html#b20c559ba960c80be16572293df7fd96" title="Returns the height.">height()</a> </dd></dl>
<p>Reimplemented from <a class="el" href="classWt_1_1WCompositeWidget.html#976e94e38c7a9cc0f212e13a9792912e">Wt::WCompositeWidget</a>.</p>
</div>
</div><p>
<a class="anchor" name="8d014f2cd6637f5f842d7fe2fff00418"></a><!-- doxytag: member="Wt::WTreeView::collapsed" ref="8d014f2cd6637f5f842d7fe2fff00418" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classWt_1_1Signal.html">Signal</a><<a class="el" href="classWt_1_1WModelIndex.html">WModelIndex</a>>& Wt::WTreeView::collapsed </td>
<td>(</td>
<td class="paramname"> </td>
<td> ) </td>
<td><code> [inline]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Signal emitted when a node is collapsed.
<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#49566dd5cc8d1d0d95bad4783dd4e11a" title="Expands or collapses a node.">setExpanded()</a>, <a class="el" href="classWt_1_1WTreeView.html#96586671660b0e81cc2ae99fff284909" title="Signal emitted when a node is expanded.">expanded()</a> </dd></dl>
</div>
</div><p>
<a class="anchor" name="96586671660b0e81cc2ae99fff284909"></a><!-- doxytag: member="Wt::WTreeView::expanded" ref="96586671660b0e81cc2ae99fff284909" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classWt_1_1Signal.html">Signal</a><<a class="el" href="classWt_1_1WModelIndex.html">WModelIndex</a>>& Wt::WTreeView::expanded </td>
<td>(</td>
<td class="paramname"> </td>
<td> ) </td>
<td><code> [inline]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Signal emitted when a node is expanded.
<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#49566dd5cc8d1d0d95bad4783dd4e11a" title="Expands or collapses a node.">setExpanded()</a>, <a class="el" href="classWt_1_1WTreeView.html#8d014f2cd6637f5f842d7fe2fff00418" title="Signal emitted when a node is collapsed.">collapsed()</a> </dd></dl>
</div>
</div><p>
<a class="anchor" name="390300f766472476e6a0df5aefaa2ef0"></a><!-- doxytag: member="Wt::WTreeView::setModel" ref="390300f766472476e6a0df5aefaa2ef0" args="(WAbstractItemModel *model)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual void Wt::WTreeView::setModel </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classWt_1_1WAbstractItemModel.html">WAbstractItemModel</a> * </td>
<td class="paramname"> <em>model</em> </td>
<td> ) </td>
<td><code> [virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Sets the model.
<p>
The view will render the data in the given <code>model</code>. Changes to the model are reflected in the view.<p>
The initial model is <code>0</code>.<p>
Ownership of the model is not transferred (and thus the previously set model is not deleted).<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#d3dae955c9012df8e368dadd1e8a8c75" title="Sets the root index.">setRootIndex()</a> </dd></dl>
<p>Reimplemented from <a class="el" href="classWt_1_1WAbstractItemView.html#b6a137595a1c6ddb9406d328a3cbf261">Wt::WAbstractItemView</a>.</p>
</div>
</div><p>
<a class="anchor" name="33ba5111945bc0ec4745a536d52adec5"></a><!-- doxytag: member="Wt::WTreeView::setColumnWidth" ref="33ba5111945bc0ec4745a536d52adec5" args="(int column, const WLength &width)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual void Wt::WTreeView::setColumnWidth </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"> <em>column</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const <a class="el" href="classWt_1_1WLength.html">WLength</a> & </td>
<td class="paramname"> <em>width</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Sets the column width.
<p>
For a model with <a class="el" href="classWt_1_1WAbstractItemModel.html#bcf7912a95a0a60f8e9b1c37d30b8383">columnCount()</a> == <code>N</code>, the initial width of columns 1..<code>N</code> is set to 150 pixels, and column 0 will take all remaining space.<p>
<dl class="note" compact><dt><b>Note:</b></dt><dd>The actual space occupied by each column is the column width augmented by 7 pixels for internal padding and a border.</dd></dl>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#849f805206bd1bc83e6bc411f208031d" title="Sets the row height.">setRowHeight()</a> </dd></dl>
<p>Implements <a class="el" href="classWt_1_1WAbstractItemView.html#a80794ca5438e2b9971e8f85919353fd">Wt::WAbstractItemView</a>.</p>
</div>
</div><p>
<a class="anchor" name="362478c3c72d50b12fb28e6167831688"></a><!-- doxytag: member="Wt::WTreeView::columnWidth" ref="362478c3c72d50b12fb28e6167831688" args="(int column) const " -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual <a class="el" href="classWt_1_1WLength.html">WLength</a> Wt::WTreeView::columnWidth </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"> <em>column</em> </td>
<td> ) </td>
<td> const<code> [virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Returns the column width.
<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#33ba5111945bc0ec4745a536d52adec5" title="Sets the column width.">setColumnWidth()</a> </dd></dl>
<p>Implements <a class="el" href="classWt_1_1WAbstractItemView.html#93541f2d346be1e3e8ea14d83e1120aa">Wt::WAbstractItemView</a>.</p>
</div>
</div><p>
<a class="anchor" name="849f805206bd1bc83e6bc411f208031d"></a><!-- doxytag: member="Wt::WTreeView::setRowHeight" ref="849f805206bd1bc83e6bc411f208031d" args="(const WLength &rowHeight)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual void Wt::WTreeView::setRowHeight </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classWt_1_1WLength.html">WLength</a> & </td>
<td class="paramname"> <em>rowHeight</em> </td>
<td> ) </td>
<td><code> [virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Sets the row height.
<p>
The view assumes that all rows are of the same height. Use this method to set the height.<p>
The default value is 20 pixels.<p>
<dl class="note" compact><dt><b>Note:</b></dt><dd>The height must be specified in <a class="el" href="classWt_1_1WLength.html#908caf5d6be7e244e24598e6d22cd4c00b1fa4c1bd7adb92e1a04d62b96d30ba" title="Pixel, relative to canvas resolution.">WLength::Pixel</a> units.</dd></dl>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#33ba5111945bc0ec4745a536d52adec5" title="Sets the column width.">setColumnWidth()</a> </dd></dl>
<p>Implements <a class="el" href="classWt_1_1WAbstractItemView.html#ec32b316a7c535300aa8d2f1ff26d72c">Wt::WAbstractItemView</a>.</p>
</div>
</div><p>
<a class="anchor" name="2367f47b0c80ec909d8e4d7626955a83"></a><!-- doxytag: member="Wt::WTreeView::setHeaderHeight" ref="2367f47b0c80ec909d8e4d7626955a83" args="(const WLength &height, bool multiLine=false)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual void Wt::WTreeView::setHeaderHeight </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classWt_1_1WLength.html">WLength</a> & </td>
<td class="paramname"> <em>height</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">bool </td>
<td class="paramname"> <em>multiLine</em> = <code>false</code></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Sets the header height.
<p>
Use this method to change the header height. You may also enable the use of multi-line headers. By default, the header text is a single line, that is centered vertically.<p>
The default value is 20 pixels.
<p>Implements <a class="el" href="classWt_1_1WAbstractItemView.html#fb02f8ce5317b961741bc7c544645653">Wt::WAbstractItemView</a>.</p>
</div>
</div><p>
<a class="anchor" name="c3362a9f4ee26be8603a53661a5dcf32"></a><!-- doxytag: member="Wt::WTreeView::setColumnAlignment" ref="c3362a9f4ee26be8603a53661a5dcf32" args="(int column, AlignmentFlag alignment)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual void Wt::WTreeView::setColumnAlignment </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"> <em>column</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="namespaceWt.html#b8f772c69bc8180c31f9e4f4593b143f">AlignmentFlag</a> </td>
<td class="paramname"> <em>alignment</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Sets the content alignment for a column.
<p>
The default value is <a class="el" href="namespaceWt.html#b8f772c69bc8180c31f9e4f4593b143fd033ef69b45d0b75633be34168c9b606">AlignLeft</a>.<p>
<dl class="note" compact><dt><b>Note:</b></dt><dd>For column 0, <a class="el" href="namespaceWt.html#b8f772c69bc8180c31f9e4f4593b143f121104cdbb5db77c7d038813a93998e5">AlignCenter</a> is currently not supported.</dd></dl>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#f51c40dde539c64396fcf4735aa54a8d" title="Sets the header alignment for a column.">setHeaderAlignment()</a> </dd></dl>
<p>Implements <a class="el" href="classWt_1_1WAbstractItemView.html#61cd01f6de2967db3fcc9ffd64e411ae">Wt::WAbstractItemView</a>.</p>
</div>
</div><p>
<a class="anchor" name="637cefec32545eae957ee29a6ff54db6"></a><!-- doxytag: member="Wt::WTreeView::columnAlignment" ref="637cefec32545eae957ee29a6ff54db6" args="(int column) const " -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual <a class="el" href="namespaceWt.html#b8f772c69bc8180c31f9e4f4593b143f">AlignmentFlag</a> Wt::WTreeView::columnAlignment </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"> <em>column</em> </td>
<td> ) </td>
<td> const<code> [virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Returns the content alignment for a column.
<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#c3362a9f4ee26be8603a53661a5dcf32" title="Sets the content alignment for a column.">setColumnAlignment()</a> </dd></dl>
<p>Implements <a class="el" href="classWt_1_1WAbstractItemView.html#d4e3d4b8ceb23d103a28a0c0faa216c2">Wt::WAbstractItemView</a>.</p>
</div>
</div><p>
<a class="anchor" name="f51c40dde539c64396fcf4735aa54a8d"></a><!-- doxytag: member="Wt::WTreeView::setHeaderAlignment" ref="f51c40dde539c64396fcf4735aa54a8d" args="(int column, AlignmentFlag alignment)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual void Wt::WTreeView::setHeaderAlignment </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"> <em>column</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="namespaceWt.html#b8f772c69bc8180c31f9e4f4593b143f">AlignmentFlag</a> </td>
<td class="paramname"> <em>alignment</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td><code> [virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Sets the header alignment for a column.
<p>
The default value is <a class="el" href="namespaceWt.html#b8f772c69bc8180c31f9e4f4593b143fd033ef69b45d0b75633be34168c9b606">AlignLeft</a>.<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#c3362a9f4ee26be8603a53661a5dcf32" title="Sets the content alignment for a column.">setColumnAlignment()</a> </dd></dl>
<p>Implements <a class="el" href="classWt_1_1WAbstractItemView.html#b4b3544161a7e037e8de7af192f8a03d">Wt::WAbstractItemView</a>.</p>
</div>
</div><p>
<a class="anchor" name="2daf20310ac763199d88ff73ead8b856"></a><!-- doxytag: member="Wt::WTreeView::headerAlignment" ref="2daf20310ac763199d88ff73ead8b856" args="(int column) const " -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual <a class="el" href="namespaceWt.html#b8f772c69bc8180c31f9e4f4593b143f">AlignmentFlag</a> Wt::WTreeView::headerAlignment </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"> <em>column</em> </td>
<td> ) </td>
<td> const<code> [virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Returns the header alignment for a column.
<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WTreeView.html#f51c40dde539c64396fcf4735aa54a8d" title="Sets the header alignment for a column.">setHeaderAlignment()</a> </dd></dl>
<p>Implements <a class="el" href="classWt_1_1WAbstractItemView.html#6e39f33083824acd1d07457113d14b00">Wt::WAbstractItemView</a>.</p>
</div>
</div><p>
<a class="anchor" name="dba2dc39faa8d427e8adb241b067ebf2"></a><!-- doxytag: member="Wt::WTreeView::setColumnBorder" ref="dba2dc39faa8d427e8adb241b067ebf2" args="(const WColor &color)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual void Wt::WTreeView::setColumnBorder </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classWt_1_1WColor.html">WColor</a> & </td>
<td class="paramname"> <em>color</em> </td>
<td> ) </td>
<td><code> [virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Sets the column border color.
<p>
The default border color is white.
<p>Implements <a class="el" href="classWt_1_1WAbstractItemView.html#6b58e9040dfbe9547cb737c7d5e71e0f">Wt::WAbstractItemView</a>.</p>
</div>
</div><p>
<a class="anchor" name="11f8eb2390ce4585b99344e540fef8b1"></a><!-- doxytag: member="Wt::WTreeView::enableAjax" ref="11f8eb2390ce4585b99344e540fef8b1" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual void Wt::WTreeView::enableAjax </td>
<td>(</td>
<td class="paramname"> </td>
<td> ) </td>
<td><code> [protected, virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Progresses to an Ajax-enabled widget.
<p>
This method is called when the progressive bootstrap method is used, and support for AJAX has been detected. The default behavior will upgrade the widget's event handling to use AJAX instead of full page reloads, and propagate the call to its children.<p>
You may want to reimplement this method if you want to make changes to widget when AJAX is enabled. You should always call the base implementation.<p>
<dl class="see" compact><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WApplication.html#78016406c4746c56b2c2ffce7c5e181f" title="Progresses to an Ajax-enabled user interface.">WApplication::enableAjax()</a> </dd></dl>
<p>Reimplemented from <a class="el" href="classWt_1_1WCompositeWidget.html#90e07c1bb6c48732ed4b5d98f91cfda0">Wt::WCompositeWidget</a>.</p>
</div>
</div><p>
</div>
<hr size="1"><address style="align: right;"><small>
Generated on Fri Mar 26 17:12:08 2010 for <a href="http://www.webtoolkit.eu/wt/">Wt</a> by <a href="http://www.doxygen.org/index.html"><img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.6</small></address>
</body>
</html>
|