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 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336
|
<!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 http-equiv="X-UA-Compatible" content="IE=9"/>
<title>wxWidgets: wxMenuItem Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="extra_stylesheet.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="page_container">
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0" style="width: 100%;">
<tbody>
<tr>
<td id="projectlogo">
<a href="http://www.wxwidgets.org/" target="_new">
<img alt="wxWidgets" src="logo.png"/>
</a>
</td>
<td style="padding-left: 0.5em; text-align: right;">
<span id="projectnumber">Version: 3.0.2</span>
</td>
</tr>
</tbody>
</table>
</div>
<!-- Generated by Doxygen 1.8.2 -->
<div id="navrow1" class="tabs">
<ul class="tablist">
<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>Categories</span></a></li>
<li class="current"><a href="annotated.html"><span>Classes</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div id="navrow2" class="tabs2">
<ul class="tablist">
<li><a href="annotated.html"><span>Class List</span></a></li>
<li><a href="classes.html"><span>Class Index</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><!-- top -->
<div class="header">
<div class="summary">
<a href="#pub-methods">Public Member Functions</a> |
<a href="#pub-static-methods">Static Public Member Functions</a> |
<a href="classwx_menu_item-members.html">List of all members</a> </div>
<div class="headertitle">
<div class="title">wxMenuItem Class Reference<div class="ingroups"><a class="el" href="group__group__class__menus.html">Menus</a></div></div> </div>
</div><!--header-->
<div class="contents">
<p><code>#include <wx/menuitem.h></code></p>
<div id="dynsection-0" onclick="return toggleVisibility(this)" class="dynheader closed" style="cursor:pointer;">
<img id="dynsection-0-trigger" src="closed.png" alt="+"/> Inheritance diagram for wxMenuItem:</div>
<div id="dynsection-0-summary" class="dynsummary" style="display:block;">
</div>
<div id="dynsection-0-content" class="dyncontent" style="display:none;">
<div class="center"><img src="classwx_menu_item__inherit__graph.png" border="0" usemap="#wx_menu_item_inherit__map" alt="Inheritance graph"/></div>
<map name="wx_menu_item_inherit__map" id="wx_menu_item_inherit__map">
<area shape="rect" id="node2" href="classwx_object.html" title="This is the root class of many of the wxWidgets classes." alt="" coords="15,6,89,34"/></map>
<center><span class="legend">[<a href="graph_legend.html">legend</a>]</span></center></div>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>A menu item represents an item in a menu. </p>
<p>Note that you usually don't have to deal with it directly as <a class="el" href="classwx_menu.html" title="A menu is a popup (or pull down) list of items, one of which may be selected before the menu goes awa...">wxMenu</a> methods usually construct an object of this class for you.</p>
<p>Also please note that the methods related to fonts and bitmaps are currently only implemented for Windows, Mac and GTK+.</p>
<h2>Events emitted by this class</h2>
<p>The following event handler macros redirect the events to member function handlers '<b>func</b>' with prototypes like: </p>
<div class="eventHandler"><span>void handlerFuncName(<a class="el" href="classwx_command_event.html" title="This event class contains information about command events, which originate from a variety of simple ...">wxCommandEvent</a>& event)</span> or <span>void handlerFuncName(<a class="el" href="classwx_menu_event.html" title="This class is used for a variety of menu-related events.">wxMenuEvent</a>& event)</span></div><p>Event macros for events emitted by this class:</p>
<div> </div><ul>
<li><span class="event">EVT_MENU(id, func)</span>:<div class="eventDesc"> Process a <code>wxEVT_MENU</code> command, which is generated by a menu item. This type of event is sent as <a class="el" href="classwx_command_event.html" title="This event class contains information about command events, which originate from a variety of simple ...">wxCommandEvent</a>. </div></li>
<li><span class="event">EVT_MENU_RANGE(id1, id2, func)</span>:<div class="eventDesc"> Process a <code>wxEVT_MENU</code> command, which is generated by a range of menu items. This type of event is sent as <a class="el" href="classwx_command_event.html" title="This event class contains information about command events, which originate from a variety of simple ...">wxCommandEvent</a>. </div></li>
<li><span class="event">EVT_MENU_OPEN(func)</span>:<div class="eventDesc"> A menu is about to be opened. On Windows, this is only sent once for each navigation of the menubar (up until all menus have closed). This type of event is sent as <a class="el" href="classwx_menu_event.html" title="This class is used for a variety of menu-related events.">wxMenuEvent</a>. </div></li>
<li><span class="event">EVT_MENU_CLOSE(func)</span>:<div class="eventDesc"> A menu has been just closed. This type of event is sent as <a class="el" href="classwx_menu_event.html" title="This class is used for a variety of menu-related events.">wxMenuEvent</a>. </div></li>
<li><span class="event">EVT_MENU_HIGHLIGHT(id, func)</span>:<div class="eventDesc"> The menu item with the specified id has been highlighted: used to show help prompts in the status bar by <a class="el" href="classwx_frame.html" title="A frame is a window whose size and position can (usually) be changed by the user.">wxFrame</a> This type of event is sent as <a class="el" href="classwx_menu_event.html" title="This class is used for a variety of menu-related events.">wxMenuEvent</a>. </div></li>
<li><span class="event">EVT_MENU_HIGHLIGHT_ALL(func)</span>:<div class="eventDesc"> A menu item has been highlighted, i.e. the currently selected menu item has changed. This type of event is sent as <a class="el" href="classwx_menu_event.html" title="This class is used for a variety of menu-related events.">wxMenuEvent</a>. </div></li>
</ul>
<h2></h2>
<div><span class="lib">Library:</span>  <span class="lib_text"><a class="el" href="page_libs.html#page_libs_wxcore">wxCore</a></span></div><div><span class="category">Category:</span>  <span class="category_text"><a class="el" href="group__group__class__menus.html">Menus</a></span></div><dl class="section see"><dt>See Also</dt><dd><a class="el" href="classwx_menu_bar.html" title="A menu bar is a series of menus accessible from the top of a frame.">wxMenuBar</a>, <a class="el" href="classwx_menu.html" title="A menu is a popup (or pull down) list of items, one of which may be selected before the menu goes awa...">wxMenu</a> </dd></dl>
</div><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="member-group"></a>
Getters</h2></td></tr>
<tr class="memitem:a3e5d1a12cd2553241424368624685b90"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classwx_colour.html">wxColour</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a3e5d1a12cd2553241424368624685b90">GetBackgroundColour</a> () const </td></tr>
<tr class="memdesc:a3e5d1a12cd2553241424368624685b90"><td class="mdescLeft"> </td><td class="mdescRight">Returns the background colour associated with the menu item. <a href="#a3e5d1a12cd2553241424368624685b90"></a><br/></td></tr>
<tr class="separator:a3e5d1a12cd2553241424368624685b90"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a4b119570daa97472c27de231eb4c90d1"><td class="memItemLeft" align="right" valign="top">virtual const <a class="el" href="classwx_bitmap.html">wxBitmap</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a4b119570daa97472c27de231eb4c90d1">GetBitmap</a> (bool checked=true) const </td></tr>
<tr class="memdesc:a4b119570daa97472c27de231eb4c90d1"><td class="mdescLeft"> </td><td class="mdescRight">Returns the checked or unchecked bitmap. <a href="#a4b119570daa97472c27de231eb4c90d1"></a><br/></td></tr>
<tr class="separator:a4b119570daa97472c27de231eb4c90d1"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:aee3c83a50e9d8c69d38faa0210e7f57b"><td class="memItemLeft" align="right" valign="top">virtual const <a class="el" href="classwx_bitmap.html">wxBitmap</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#aee3c83a50e9d8c69d38faa0210e7f57b">GetDisabledBitmap</a> () const </td></tr>
<tr class="memdesc:aee3c83a50e9d8c69d38faa0210e7f57b"><td class="mdescLeft"> </td><td class="mdescRight">Returns the bitmap to be used for disabled items. <a href="#aee3c83a50e9d8c69d38faa0210e7f57b"></a><br/></td></tr>
<tr class="separator:aee3c83a50e9d8c69d38faa0210e7f57b"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:aad2b17eed2726df1d5d5752a40f536da"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classwx_font.html">wxFont</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#aad2b17eed2726df1d5d5752a40f536da">GetFont</a> () const </td></tr>
<tr class="memdesc:aad2b17eed2726df1d5d5752a40f536da"><td class="mdescLeft"> </td><td class="mdescRight">Returns the font associated with the menu item. <a href="#aad2b17eed2726df1d5d5752a40f536da"></a><br/></td></tr>
<tr class="separator:aad2b17eed2726df1d5d5752a40f536da"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a679c3f9a7bd66d82b3a148629fc6cc5c"><td class="memItemLeft" align="right" valign="top">const <a class="el" href="classwx_string.html">wxString</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a679c3f9a7bd66d82b3a148629fc6cc5c">GetHelp</a> () const </td></tr>
<tr class="memdesc:a679c3f9a7bd66d82b3a148629fc6cc5c"><td class="mdescLeft"> </td><td class="mdescRight">Returns the help string associated with the menu item. <a href="#a679c3f9a7bd66d82b3a148629fc6cc5c"></a><br/></td></tr>
<tr class="separator:a679c3f9a7bd66d82b3a148629fc6cc5c"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:aec5349782813e4605158f8eeed9a92eb"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#aec5349782813e4605158f8eeed9a92eb">GetId</a> () const </td></tr>
<tr class="memdesc:aec5349782813e4605158f8eeed9a92eb"><td class="mdescLeft"> </td><td class="mdescRight">Returns the menu item identifier. <a href="#aec5349782813e4605158f8eeed9a92eb"></a><br/></td></tr>
<tr class="separator:aec5349782813e4605158f8eeed9a92eb"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a6fde1e54cf3cecd90853f627fc4f4493"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="classwx_string.html">wxString</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a6fde1e54cf3cecd90853f627fc4f4493">GetItemLabel</a> () const </td></tr>
<tr class="memdesc:a6fde1e54cf3cecd90853f627fc4f4493"><td class="mdescLeft"> </td><td class="mdescRight">Returns the text associated with the menu item including any accelerator characters that were passed to the constructor or <a class="el" href="classwx_menu_item.html#a8b0517fb35e3eada66b51568aa87f261" title="Sets the label associated with the menu item.">SetItemLabel()</a>. <a href="#a6fde1e54cf3cecd90853f627fc4f4493"></a><br/></td></tr>
<tr class="separator:a6fde1e54cf3cecd90853f627fc4f4493"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:acfd765d248029f8c548dc700b03f6198"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="classwx_string.html">wxString</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#acfd765d248029f8c548dc700b03f6198">GetItemLabelText</a> () const </td></tr>
<tr class="memdesc:acfd765d248029f8c548dc700b03f6198"><td class="mdescLeft"> </td><td class="mdescRight">Returns the text associated with the menu item, without any accelerator characters. <a href="#acfd765d248029f8c548dc700b03f6198"></a><br/></td></tr>
<tr class="separator:acfd765d248029f8c548dc700b03f6198"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a759fcdb50560600608446a2099e33d49"><td class="memItemLeft" align="right" valign="top"><a class="el" href="defs_8h.html#abd0c640814a55e4adda3bce698646d2d">wxItemKind</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a759fcdb50560600608446a2099e33d49">GetKind</a> () const </td></tr>
<tr class="memdesc:a759fcdb50560600608446a2099e33d49"><td class="mdescLeft"> </td><td class="mdescRight">Returns the item kind, one of <code>wxITEM_SEPARATOR</code>, <code>wxITEM_NORMAL</code>, <code>wxITEM_CHECK</code> or <code>wxITEM_RADIO</code>. <a href="#a759fcdb50560600608446a2099e33d49"></a><br/></td></tr>
<tr class="separator:a759fcdb50560600608446a2099e33d49"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a97554b69d2ad5948b856b68bfa3e4824"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classwx_string.html">wxString</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a97554b69d2ad5948b856b68bfa3e4824">GetLabel</a> () const </td></tr>
<tr class="memdesc:a97554b69d2ad5948b856b68bfa3e4824"><td class="mdescLeft"> </td><td class="mdescRight">Returns the text associated with the menu item without any accelerator characters it might contain. <a href="#a97554b69d2ad5948b856b68bfa3e4824"></a><br/></td></tr>
<tr class="separator:a97554b69d2ad5948b856b68bfa3e4824"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a22c16a54a88b192f62200bafd598628c"><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a22c16a54a88b192f62200bafd598628c">GetMarginWidth</a> () const </td></tr>
<tr class="memdesc:a22c16a54a88b192f62200bafd598628c"><td class="mdescLeft"> </td><td class="mdescRight">Gets the width of the menu item checkmark bitmap. <a href="#a22c16a54a88b192f62200bafd598628c"></a><br/></td></tr>
<tr class="separator:a22c16a54a88b192f62200bafd598628c"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:aa749549977f23192c9d05c19d87ecbee"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classwx_menu.html">wxMenu</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#aa749549977f23192c9d05c19d87ecbee">GetMenu</a> () const </td></tr>
<tr class="memdesc:aa749549977f23192c9d05c19d87ecbee"><td class="mdescLeft"> </td><td class="mdescRight">Returns the menu this menu item is in, or <span class="literal">NULL</span> if this menu item is not attached. <a href="#aa749549977f23192c9d05c19d87ecbee"></a><br/></td></tr>
<tr class="separator:aa749549977f23192c9d05c19d87ecbee"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:aa1910ae1850b6dc659e008530e3ddb38"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classwx_string.html">wxString</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#aa1910ae1850b6dc659e008530e3ddb38">GetName</a> () const </td></tr>
<tr class="memdesc:aa1910ae1850b6dc659e008530e3ddb38"><td class="mdescLeft"> </td><td class="mdescRight">Returns the text associated with the menu item. <a href="#aa1910ae1850b6dc659e008530e3ddb38"></a><br/></td></tr>
<tr class="separator:aa1910ae1850b6dc659e008530e3ddb38"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a517e8a2c8ce4427eb21999b8b378987b"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classwx_menu.html">wxMenu</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a517e8a2c8ce4427eb21999b8b378987b">GetSubMenu</a> () const </td></tr>
<tr class="memdesc:a517e8a2c8ce4427eb21999b8b378987b"><td class="mdescLeft"> </td><td class="mdescRight">Returns the submenu associated with the menu item, or <span class="literal">NULL</span> if there isn't one. <a href="#a517e8a2c8ce4427eb21999b8b378987b"></a><br/></td></tr>
<tr class="separator:a517e8a2c8ce4427eb21999b8b378987b"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:af81fb6c07a980fc2d8314f0be6f38170"><td class="memItemLeft" align="right" valign="top">const <a class="el" href="classwx_string.html">wxString</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#af81fb6c07a980fc2d8314f0be6f38170">GetText</a> () const </td></tr>
<tr class="memdesc:af81fb6c07a980fc2d8314f0be6f38170"><td class="mdescLeft"> </td><td class="mdescRight">Returns the text associated with the menu item, such as it was passed to the <a class="el" href="classwx_menu_item.html" title="A menu item represents an item in a menu.">wxMenuItem</a> constructor, i.e. <a href="#af81fb6c07a980fc2d8314f0be6f38170"></a><br/></td></tr>
<tr class="separator:af81fb6c07a980fc2d8314f0be6f38170"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a62a0d8dabfec3d2ff25dc03bd7cb1b8c"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classwx_colour.html">wxColour</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a62a0d8dabfec3d2ff25dc03bd7cb1b8c">GetTextColour</a> () const </td></tr>
<tr class="memdesc:a62a0d8dabfec3d2ff25dc03bd7cb1b8c"><td class="mdescLeft"> </td><td class="mdescRight">Returns the text colour associated with the menu item. <a href="#a62a0d8dabfec3d2ff25dc03bd7cb1b8c"></a><br/></td></tr>
<tr class="separator:a62a0d8dabfec3d2ff25dc03bd7cb1b8c"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:aa3e1b22c815c60c3428fa5b7ba4b8c3f"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="classwx_accelerator_entry.html">wxAcceleratorEntry</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#aa3e1b22c815c60c3428fa5b7ba4b8c3f">GetAccel</a> () const </td></tr>
<tr class="memdesc:aa3e1b22c815c60c3428fa5b7ba4b8c3f"><td class="mdescLeft"> </td><td class="mdescRight">Get our accelerator or NULL (caller must delete the pointer) <a href="#aa3e1b22c815c60c3428fa5b7ba4b8c3f"></a><br/></td></tr>
<tr class="separator:aa3e1b22c815c60c3428fa5b7ba4b8c3f"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a410a18a98166338ab196130ffbcf3968"><td class="memItemLeft" align="right" valign="top">static <a class="el" href="classwx_accelerator_entry.html">wxAcceleratorEntry</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a410a18a98166338ab196130ffbcf3968">GetAccelFromString</a> (const <a class="el" href="classwx_string.html">wxString</a> &label)</td></tr>
<tr class="memdesc:a410a18a98166338ab196130ffbcf3968"><td class="mdescLeft"> </td><td class="mdescRight">Extract the accelerator from the given menu string, return NULL if none found. <a href="#a410a18a98166338ab196130ffbcf3968"></a><br/></td></tr>
<tr class="separator:a410a18a98166338ab196130ffbcf3968"><td class="memSeparator" colspan="2"> </td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:a6e9b0e1b786fa84250a42c88d84aed2b"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a6e9b0e1b786fa84250a42c88d84aed2b">wxMenuItem</a> (<a class="el" href="classwx_menu.html">wxMenu</a> *parentMenu=NULL, int id=<a class="el" href="defs_8h.html#ac66d0a09761e7d86b2ac0b2e0c6a8cbba39011729a3d6167afc8007513f21bcd5">wxID_SEPARATOR</a>, const <a class="el" href="classwx_string.html">wxString</a> &text=<a class="el" href="interface_2wx_2string_8h.html#a9a321d587166a30017b608dd2d234033">wxEmptyString</a>, const <a class="el" href="classwx_string.html">wxString</a> &helpString=<a class="el" href="interface_2wx_2string_8h.html#a9a321d587166a30017b608dd2d234033">wxEmptyString</a>, <a class="el" href="defs_8h.html#abd0c640814a55e4adda3bce698646d2d">wxItemKind</a> kind=<a class="el" href="defs_8h.html#abd0c640814a55e4adda3bce698646d2da5281887c1cd68cdd6d4f6a98efc88509">wxITEM_NORMAL</a>, <a class="el" href="classwx_menu.html">wxMenu</a> *subMenu=NULL)</td></tr>
<tr class="memdesc:a6e9b0e1b786fa84250a42c88d84aed2b"><td class="mdescLeft"> </td><td class="mdescRight">Constructs a <a class="el" href="classwx_menu_item.html" title="A menu item represents an item in a menu.">wxMenuItem</a> object. <a href="#a6e9b0e1b786fa84250a42c88d84aed2b"></a><br/></td></tr>
<tr class="separator:a6e9b0e1b786fa84250a42c88d84aed2b"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a61df296959898555031e23d412508323"><td class="memItemLeft" align="right" valign="top">virtual </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a61df296959898555031e23d412508323">~wxMenuItem</a> ()</td></tr>
<tr class="memdesc:a61df296959898555031e23d412508323"><td class="mdescLeft"> </td><td class="mdescRight">Destructor. <a href="#a61df296959898555031e23d412508323"></a><br/></td></tr>
<tr class="separator:a61df296959898555031e23d412508323"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:afcfbb12e302c0528e55efcb1c6f5f7fc"><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#afcfbb12e302c0528e55efcb1c6f5f7fc">Check</a> (bool check=true)</td></tr>
<tr class="memdesc:afcfbb12e302c0528e55efcb1c6f5f7fc"><td class="mdescLeft"> </td><td class="mdescRight">Checks or unchecks the menu item. <a href="#afcfbb12e302c0528e55efcb1c6f5f7fc"></a><br/></td></tr>
<tr class="separator:afcfbb12e302c0528e55efcb1c6f5f7fc"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a1e399da82f486adea3893480bcf66b21"><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a1e399da82f486adea3893480bcf66b21">Enable</a> (bool enable=true)</td></tr>
<tr class="memdesc:a1e399da82f486adea3893480bcf66b21"><td class="mdescLeft"> </td><td class="mdescRight">Enables or disables the menu item. <a href="#a1e399da82f486adea3893480bcf66b21"></a><br/></td></tr>
<tr class="separator:a1e399da82f486adea3893480bcf66b21"><td class="memSeparator" colspan="2"> </td></tr>
<tr><td colspan="2"><div class="groupHeader">Checkers</div></td></tr>
<tr class="memitem:a666a92acb2e1419e2a03f84a883e08af"><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a666a92acb2e1419e2a03f84a883e08af">IsCheck</a> () const </td></tr>
<tr class="memdesc:a666a92acb2e1419e2a03f84a883e08af"><td class="mdescLeft"> </td><td class="mdescRight">Returns <span class="literal">true</span> if the item is a check item. <a href="#a666a92acb2e1419e2a03f84a883e08af"></a><br/></td></tr>
<tr class="separator:a666a92acb2e1419e2a03f84a883e08af"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a66cea3a49d79e241c78443e22ce6e7c1"><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a66cea3a49d79e241c78443e22ce6e7c1">IsCheckable</a> () const </td></tr>
<tr class="memdesc:a66cea3a49d79e241c78443e22ce6e7c1"><td class="mdescLeft"> </td><td class="mdescRight">Returns <span class="literal">true</span> if the item is checkable. <a href="#a66cea3a49d79e241c78443e22ce6e7c1"></a><br/></td></tr>
<tr class="separator:a66cea3a49d79e241c78443e22ce6e7c1"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a629b1b82993b4f654b214cc90f427974"><td class="memItemLeft" align="right" valign="top">virtual bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a629b1b82993b4f654b214cc90f427974">IsChecked</a> () const </td></tr>
<tr class="memdesc:a629b1b82993b4f654b214cc90f427974"><td class="mdescLeft"> </td><td class="mdescRight">Returns <span class="literal">true</span> if the item is checked. <a href="#a629b1b82993b4f654b214cc90f427974"></a><br/></td></tr>
<tr class="separator:a629b1b82993b4f654b214cc90f427974"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a0ec10aa48da0e8d17f057834e791c7c8"><td class="memItemLeft" align="right" valign="top">virtual bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a0ec10aa48da0e8d17f057834e791c7c8">IsEnabled</a> () const </td></tr>
<tr class="memdesc:a0ec10aa48da0e8d17f057834e791c7c8"><td class="mdescLeft"> </td><td class="mdescRight">Returns <span class="literal">true</span> if the item is enabled. <a href="#a0ec10aa48da0e8d17f057834e791c7c8"></a><br/></td></tr>
<tr class="separator:a0ec10aa48da0e8d17f057834e791c7c8"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:accee896dbe5e554afd18245eeff91141"><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#accee896dbe5e554afd18245eeff91141">IsRadio</a> () const </td></tr>
<tr class="memdesc:accee896dbe5e554afd18245eeff91141"><td class="mdescLeft"> </td><td class="mdescRight">Returns <span class="literal">true</span> if the item is a radio button. <a href="#accee896dbe5e554afd18245eeff91141"></a><br/></td></tr>
<tr class="separator:accee896dbe5e554afd18245eeff91141"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:af717c39d2c08161b9b167a7c6ed1fe93"><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#af717c39d2c08161b9b167a7c6ed1fe93">IsSeparator</a> () const </td></tr>
<tr class="memdesc:af717c39d2c08161b9b167a7c6ed1fe93"><td class="mdescLeft"> </td><td class="mdescRight">Returns <span class="literal">true</span> if the item is a separator. <a href="#af717c39d2c08161b9b167a7c6ed1fe93"></a><br/></td></tr>
<tr class="separator:af717c39d2c08161b9b167a7c6ed1fe93"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a8b0f0c3f83c47e4f332c94abd406459f"><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a8b0f0c3f83c47e4f332c94abd406459f">IsSubMenu</a> () const </td></tr>
<tr class="memdesc:a8b0f0c3f83c47e4f332c94abd406459f"><td class="mdescLeft"> </td><td class="mdescRight">Returns <span class="literal">true</span> if the item is a submenu. <a href="#a8b0f0c3f83c47e4f332c94abd406459f"></a><br/></td></tr>
<tr class="separator:a8b0f0c3f83c47e4f332c94abd406459f"><td class="memSeparator" colspan="2"> </td></tr>
<tr><td colspan="2"><div class="groupHeader">Setters</div></td></tr>
<tr class="memitem:a5a4462c00517c5d8470b99fd021c6a9d"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a5a4462c00517c5d8470b99fd021c6a9d">SetBackgroundColour</a> (const <a class="el" href="classwx_colour.html">wxColour</a> &colour)</td></tr>
<tr class="memdesc:a5a4462c00517c5d8470b99fd021c6a9d"><td class="mdescLeft"> </td><td class="mdescRight">Sets the background colour associated with the menu item. <a href="#a5a4462c00517c5d8470b99fd021c6a9d"></a><br/></td></tr>
<tr class="separator:a5a4462c00517c5d8470b99fd021c6a9d"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a2b5d6bcb820b992b1e4709facbf6d4fb"><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a2b5d6bcb820b992b1e4709facbf6d4fb">SetBitmap</a> (const <a class="el" href="classwx_bitmap.html">wxBitmap</a> &bmp, bool checked=true)</td></tr>
<tr class="memdesc:a2b5d6bcb820b992b1e4709facbf6d4fb"><td class="mdescLeft"> </td><td class="mdescRight">Sets the bitmap for the menu item. <a href="#a2b5d6bcb820b992b1e4709facbf6d4fb"></a><br/></td></tr>
<tr class="separator:a2b5d6bcb820b992b1e4709facbf6d4fb"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a62407ad793cb3ef9c59873349558ce5c"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a62407ad793cb3ef9c59873349558ce5c">SetBitmaps</a> (const <a class="el" href="classwx_bitmap.html">wxBitmap</a> &checked, const <a class="el" href="classwx_bitmap.html">wxBitmap</a> &unchecked=<a class="el" href="interface_2wx_2bitmap_8h.html#a2947690e84b8fdb2e37b79a4af8f8a21">wxNullBitmap</a>)</td></tr>
<tr class="memdesc:a62407ad793cb3ef9c59873349558ce5c"><td class="mdescLeft"> </td><td class="mdescRight">Sets the checked/unchecked bitmaps for the menu item. <a href="#a62407ad793cb3ef9c59873349558ce5c"></a><br/></td></tr>
<tr class="separator:a62407ad793cb3ef9c59873349558ce5c"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a2fabe431416d64dcac9e23469fcc5acb"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a2fabe431416d64dcac9e23469fcc5acb">SetDisabledBitmap</a> (const <a class="el" href="classwx_bitmap.html">wxBitmap</a> &disabled)</td></tr>
<tr class="memdesc:a2fabe431416d64dcac9e23469fcc5acb"><td class="mdescLeft"> </td><td class="mdescRight">Sets the to be used for disabled menu items. <a href="#a2fabe431416d64dcac9e23469fcc5acb"></a><br/></td></tr>
<tr class="separator:a2fabe431416d64dcac9e23469fcc5acb"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a5deda3866e4308a965caa2fb78c1ca93"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a5deda3866e4308a965caa2fb78c1ca93">SetFont</a> (const <a class="el" href="classwx_font.html">wxFont</a> &font)</td></tr>
<tr class="memdesc:a5deda3866e4308a965caa2fb78c1ca93"><td class="mdescLeft"> </td><td class="mdescRight">Sets the font associated with the menu item. <a href="#a5deda3866e4308a965caa2fb78c1ca93"></a><br/></td></tr>
<tr class="separator:a5deda3866e4308a965caa2fb78c1ca93"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:af20e2cb1c73892e1c8e86e69b40d9040"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#af20e2cb1c73892e1c8e86e69b40d9040">SetHelp</a> (const <a class="el" href="classwx_string.html">wxString</a> &helpString)</td></tr>
<tr class="memdesc:af20e2cb1c73892e1c8e86e69b40d9040"><td class="mdescLeft"> </td><td class="mdescRight">Sets the help string. <a href="#af20e2cb1c73892e1c8e86e69b40d9040"></a><br/></td></tr>
<tr class="separator:af20e2cb1c73892e1c8e86e69b40d9040"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a8b0517fb35e3eada66b51568aa87f261"><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a8b0517fb35e3eada66b51568aa87f261">SetItemLabel</a> (const <a class="el" href="classwx_string.html">wxString</a> &label)</td></tr>
<tr class="memdesc:a8b0517fb35e3eada66b51568aa87f261"><td class="mdescLeft"> </td><td class="mdescRight">Sets the label associated with the menu item. <a href="#a8b0517fb35e3eada66b51568aa87f261"></a><br/></td></tr>
<tr class="separator:a8b0517fb35e3eada66b51568aa87f261"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:aac2257b03dd2485c72f9398ceb1a76cf"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#aac2257b03dd2485c72f9398ceb1a76cf">SetMarginWidth</a> (int width)</td></tr>
<tr class="memdesc:aac2257b03dd2485c72f9398ceb1a76cf"><td class="mdescLeft"> </td><td class="mdescRight">Sets the width of the menu item checkmark bitmap. <a href="#aac2257b03dd2485c72f9398ceb1a76cf"></a><br/></td></tr>
<tr class="separator:aac2257b03dd2485c72f9398ceb1a76cf"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a41fb81219430a81e7e2a668831868296"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a41fb81219430a81e7e2a668831868296">SetMenu</a> (<a class="el" href="classwx_menu.html">wxMenu</a> *menu)</td></tr>
<tr class="memdesc:a41fb81219430a81e7e2a668831868296"><td class="mdescLeft"> </td><td class="mdescRight">Sets the parent menu which will contain this menu item. <a href="#a41fb81219430a81e7e2a668831868296"></a><br/></td></tr>
<tr class="separator:a41fb81219430a81e7e2a668831868296"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ab222651b8b47653d8890cd3469d5ff5a"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#ab222651b8b47653d8890cd3469d5ff5a">SetSubMenu</a> (<a class="el" href="classwx_menu.html">wxMenu</a> *menu)</td></tr>
<tr class="memdesc:ab222651b8b47653d8890cd3469d5ff5a"><td class="mdescLeft"> </td><td class="mdescRight">Sets the submenu of this menu item. <a href="#ab222651b8b47653d8890cd3469d5ff5a"></a><br/></td></tr>
<tr class="separator:ab222651b8b47653d8890cd3469d5ff5a"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a742aa5bb0d3faa020e7b3bd66e336499"><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a742aa5bb0d3faa020e7b3bd66e336499">SetText</a> (const <a class="el" href="classwx_string.html">wxString</a> &text)</td></tr>
<tr class="memdesc:a742aa5bb0d3faa020e7b3bd66e336499"><td class="mdescLeft"> </td><td class="mdescRight">Sets the text associated with the menu item. <a href="#a742aa5bb0d3faa020e7b3bd66e336499"></a><br/></td></tr>
<tr class="separator:a742aa5bb0d3faa020e7b3bd66e336499"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a695b5f2f1c2325ec01dba5cdd83dd3b5"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a695b5f2f1c2325ec01dba5cdd83dd3b5">SetTextColour</a> (const <a class="el" href="classwx_colour.html">wxColour</a> &colour)</td></tr>
<tr class="memdesc:a695b5f2f1c2325ec01dba5cdd83dd3b5"><td class="mdescLeft"> </td><td class="mdescRight">Sets the text colour associated with the menu item. <a href="#a695b5f2f1c2325ec01dba5cdd83dd3b5"></a><br/></td></tr>
<tr class="separator:a695b5f2f1c2325ec01dba5cdd83dd3b5"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a1deb59611abda8b68cd06c848f48884d"><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#a1deb59611abda8b68cd06c848f48884d">SetAccel</a> (<a class="el" href="classwx_accelerator_entry.html">wxAcceleratorEntry</a> *accel)</td></tr>
<tr class="memdesc:a1deb59611abda8b68cd06c848f48884d"><td class="mdescLeft"> </td><td class="mdescRight">Set the accel for this item - this may also be done indirectly with <a class="el" href="classwx_menu_item.html#a742aa5bb0d3faa020e7b3bd66e336499" title="Sets the text associated with the menu item.">SetText()</a> <a href="#a1deb59611abda8b68cd06c848f48884d"></a><br/></td></tr>
<tr class="separator:a1deb59611abda8b68cd06c848f48884d"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="inherit_header pub_methods_classwx_object"><td colspan="2" onclick="javascript:toggleInherit('pub_methods_classwx_object')"><img src="closed.png" alt="-"/> Public Member Functions inherited from <a class="el" href="classwx_object.html">wxObject</a></td></tr>
<tr class="memitem:acaa378363a28af421ab56ad7b46eadf0 inherit pub_methods_classwx_object"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_object.html#acaa378363a28af421ab56ad7b46eadf0">wxObject</a> ()</td></tr>
<tr class="memdesc:acaa378363a28af421ab56ad7b46eadf0 inherit pub_methods_classwx_object"><td class="mdescLeft"> </td><td class="mdescRight">Default ctor; initializes to <span class="literal">NULL</span> the internal reference data. <a href="#acaa378363a28af421ab56ad7b46eadf0"></a><br/></td></tr>
<tr class="separator:acaa378363a28af421ab56ad7b46eadf0 inherit pub_methods_classwx_object"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a4721b4dc9b7aff0f30904ba2ea3954cf inherit pub_methods_classwx_object"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_object.html#a4721b4dc9b7aff0f30904ba2ea3954cf">wxObject</a> (const <a class="el" href="classwx_object.html">wxObject</a> &other)</td></tr>
<tr class="memdesc:a4721b4dc9b7aff0f30904ba2ea3954cf inherit pub_methods_classwx_object"><td class="mdescLeft"> </td><td class="mdescRight">Copy ctor. <a href="#a4721b4dc9b7aff0f30904ba2ea3954cf"></a><br/></td></tr>
<tr class="separator:a4721b4dc9b7aff0f30904ba2ea3954cf inherit pub_methods_classwx_object"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a2a51aa8bfbab47ca2f051bcf84b3f35b inherit pub_methods_classwx_object"><td class="memItemLeft" align="right" valign="top">virtual </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_object.html#a2a51aa8bfbab47ca2f051bcf84b3f35b">~wxObject</a> ()</td></tr>
<tr class="memdesc:a2a51aa8bfbab47ca2f051bcf84b3f35b inherit pub_methods_classwx_object"><td class="mdescLeft"> </td><td class="mdescRight">Destructor. <a href="#a2a51aa8bfbab47ca2f051bcf84b3f35b"></a><br/></td></tr>
<tr class="separator:a2a51aa8bfbab47ca2f051bcf84b3f35b inherit pub_methods_classwx_object"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:ab3a0c6f723cbaddb47be4e8dd98cc8e2 inherit pub_methods_classwx_object"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="classwx_class_info.html">wxClassInfo</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_object.html#ab3a0c6f723cbaddb47be4e8dd98cc8e2">GetClassInfo</a> () const </td></tr>
<tr class="memdesc:ab3a0c6f723cbaddb47be4e8dd98cc8e2 inherit pub_methods_classwx_object"><td class="mdescLeft"> </td><td class="mdescRight">This virtual function is redefined for every class that requires run-time type information, when using the <a class="el" href="group__group__funcmacro__rtti.html#ga20465fc7e022e29a5dacfad46e152e75" title="Used inside a class declaration to declare that the class should be made known to the class hierarchy...">wxDECLARE_CLASS</a> macro (or similar). <a href="#ab3a0c6f723cbaddb47be4e8dd98cc8e2"></a><br/></td></tr>
<tr class="separator:ab3a0c6f723cbaddb47be4e8dd98cc8e2 inherit pub_methods_classwx_object"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:aabdb4fc957226544a8408167844e4f42 inherit pub_methods_classwx_object"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classwx_object_ref_data.html">wxObjectRefData</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_object.html#aabdb4fc957226544a8408167844e4f42">GetRefData</a> () const </td></tr>
<tr class="memdesc:aabdb4fc957226544a8408167844e4f42 inherit pub_methods_classwx_object"><td class="mdescLeft"> </td><td class="mdescRight">Returns the <a class="el" href="classwx_object.html#a9e31954530a0abd54982effc443ed2b8" title="Pointer to an object which is the object's reference-counted data.">wxObject::m_refData</a> pointer, i.e. the data referenced by this object. <a href="#aabdb4fc957226544a8408167844e4f42"></a><br/></td></tr>
<tr class="separator:aabdb4fc957226544a8408167844e4f42 inherit pub_methods_classwx_object"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:af40d580385cf4f8112fae7713404b01e inherit pub_methods_classwx_object"><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_object.html#af40d580385cf4f8112fae7713404b01e">IsKindOf</a> (const <a class="el" href="classwx_class_info.html">wxClassInfo</a> *info) const </td></tr>
<tr class="memdesc:af40d580385cf4f8112fae7713404b01e inherit pub_methods_classwx_object"><td class="mdescLeft"> </td><td class="mdescRight">Determines whether this class is a subclass of (or the same class as) the given class. <a href="#af40d580385cf4f8112fae7713404b01e"></a><br/></td></tr>
<tr class="separator:af40d580385cf4f8112fae7713404b01e inherit pub_methods_classwx_object"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a80a1a3fda7b14396a9ddd3d7a46a88bd inherit pub_methods_classwx_object"><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_object.html#a80a1a3fda7b14396a9ddd3d7a46a88bd">IsSameAs</a> (const <a class="el" href="classwx_object.html">wxObject</a> &obj) const </td></tr>
<tr class="memdesc:a80a1a3fda7b14396a9ddd3d7a46a88bd inherit pub_methods_classwx_object"><td class="mdescLeft"> </td><td class="mdescRight">Returns <span class="literal">true</span> if this object has the same data pointer as <em>obj</em>. <a href="#a80a1a3fda7b14396a9ddd3d7a46a88bd"></a><br/></td></tr>
<tr class="separator:a80a1a3fda7b14396a9ddd3d7a46a88bd inherit pub_methods_classwx_object"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a2f6f1aa51fe9fc2b1415ca4211a90e9e inherit pub_methods_classwx_object"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_object.html#a2f6f1aa51fe9fc2b1415ca4211a90e9e">Ref</a> (const <a class="el" href="classwx_object.html">wxObject</a> &clone)</td></tr>
<tr class="memdesc:a2f6f1aa51fe9fc2b1415ca4211a90e9e inherit pub_methods_classwx_object"><td class="mdescLeft"> </td><td class="mdescRight">Makes this object refer to the data in <em>clone</em>. <a href="#a2f6f1aa51fe9fc2b1415ca4211a90e9e"></a><br/></td></tr>
<tr class="separator:a2f6f1aa51fe9fc2b1415ca4211a90e9e inherit pub_methods_classwx_object"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:afab780710f2adc1bb33310e27590140b inherit pub_methods_classwx_object"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_object.html#afab780710f2adc1bb33310e27590140b">SetRefData</a> (<a class="el" href="classwx_object_ref_data.html">wxObjectRefData</a> *data)</td></tr>
<tr class="memdesc:afab780710f2adc1bb33310e27590140b inherit pub_methods_classwx_object"><td class="mdescLeft"> </td><td class="mdescRight">Sets the <a class="el" href="classwx_object.html#a9e31954530a0abd54982effc443ed2b8" title="Pointer to an object which is the object's reference-counted data.">wxObject::m_refData</a> pointer. <a href="#afab780710f2adc1bb33310e27590140b"></a><br/></td></tr>
<tr class="separator:afab780710f2adc1bb33310e27590140b inherit pub_methods_classwx_object"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:af51efc6b1ae632fc7f0cd7ebbce9fa36 inherit pub_methods_classwx_object"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_object.html#af51efc6b1ae632fc7f0cd7ebbce9fa36">UnRef</a> ()</td></tr>
<tr class="memdesc:af51efc6b1ae632fc7f0cd7ebbce9fa36 inherit pub_methods_classwx_object"><td class="mdescLeft"> </td><td class="mdescRight">Decrements the reference count in the associated data, and if it is zero, deletes the data. <a href="#af51efc6b1ae632fc7f0cd7ebbce9fa36"></a><br/></td></tr>
<tr class="separator:af51efc6b1ae632fc7f0cd7ebbce9fa36 inherit pub_methods_classwx_object"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a74b40e42d19a4b9e9bec0b57d62a5725 inherit pub_methods_classwx_object"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_object.html#a74b40e42d19a4b9e9bec0b57d62a5725">UnShare</a> ()</td></tr>
<tr class="memdesc:a74b40e42d19a4b9e9bec0b57d62a5725 inherit pub_methods_classwx_object"><td class="mdescLeft"> </td><td class="mdescRight">This is the same of <a class="el" href="classwx_object.html#a60204063f3cc3aa2fa1c7ff5bda9eb13" title="Ensure that this object's data is not shared with any other object.">AllocExclusive()</a> but this method is public. <a href="#a74b40e42d19a4b9e9bec0b57d62a5725"></a><br/></td></tr>
<tr class="separator:a74b40e42d19a4b9e9bec0b57d62a5725 inherit pub_methods_classwx_object"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a07b8f34f5afc5743195c5fed052f55d3 inherit pub_methods_classwx_object"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_object.html#a07b8f34f5afc5743195c5fed052f55d3">operator delete</a> (void *buf)</td></tr>
<tr class="memdesc:a07b8f34f5afc5743195c5fed052f55d3 inherit pub_methods_classwx_object"><td class="mdescLeft"> </td><td class="mdescRight">The <em>delete</em> operator is defined for debugging versions of the library only, when the identifier <code><b>WXDEBUG</b></code> is defined. <a href="#a07b8f34f5afc5743195c5fed052f55d3"></a><br/></td></tr>
<tr class="separator:a07b8f34f5afc5743195c5fed052f55d3 inherit pub_methods_classwx_object"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a96fa423a1dbc212c8227a5d83825971f inherit pub_methods_classwx_object"><td class="memItemLeft" align="right" valign="top">void * </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_object.html#a96fa423a1dbc212c8227a5d83825971f">operator new</a> (size_t size, const <a class="el" href="classwx_string.html">wxString</a> &filename=NULL, int lineNum=0)</td></tr>
<tr class="memdesc:a96fa423a1dbc212c8227a5d83825971f inherit pub_methods_classwx_object"><td class="mdescLeft"> </td><td class="mdescRight">The <em>new</em> operator is defined for debugging versions of the library only, when the identifier <code><b>WXDEBUG</b></code> is defined. <a href="#a96fa423a1dbc212c8227a5d83825971f"></a><br/></td></tr>
<tr class="separator:a96fa423a1dbc212c8227a5d83825971f inherit pub_methods_classwx_object"><td class="memSeparator" colspan="2"> </td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-static-methods"></a>
Static Public Member Functions</h2></td></tr>
<tr class="memitem:af8f7bb0c7ca8808047c3c97b564069ed"><td class="memItemLeft" align="right" valign="top">static <a class="el" href="classwx_string.html">wxString</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#af8f7bb0c7ca8808047c3c97b564069ed">GetLabelFromText</a> (const <a class="el" href="classwx_string.html">wxString</a> &text)</td></tr>
<tr class="separator:af8f7bb0c7ca8808047c3c97b564069ed"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:afed23d53a97171076763385c93207fc0"><td class="memItemLeft" align="right" valign="top">static <a class="el" href="classwx_string.html">wxString</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_menu_item.html#afed23d53a97171076763385c93207fc0">GetLabelText</a> (const <a class="el" href="classwx_string.html">wxString</a> &text)</td></tr>
<tr class="memdesc:afed23d53a97171076763385c93207fc0"><td class="mdescLeft"> </td><td class="mdescRight">Strips all accelerator characters and mnemonics from the given <em>text</em>. <a href="#afed23d53a97171076763385c93207fc0"></a><br/></td></tr>
<tr class="separator:afed23d53a97171076763385c93207fc0"><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 pro_methods_classwx_object"><td colspan="2" onclick="javascript:toggleInherit('pro_methods_classwx_object')"><img src="closed.png" alt="-"/> Protected Member Functions inherited from <a class="el" href="classwx_object.html">wxObject</a></td></tr>
<tr class="memitem:a60204063f3cc3aa2fa1c7ff5bda9eb13 inherit pro_methods_classwx_object"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_object.html#a60204063f3cc3aa2fa1c7ff5bda9eb13">AllocExclusive</a> ()</td></tr>
<tr class="memdesc:a60204063f3cc3aa2fa1c7ff5bda9eb13 inherit pro_methods_classwx_object"><td class="mdescLeft"> </td><td class="mdescRight">Ensure that this object's data is not shared with any other object. <a href="#a60204063f3cc3aa2fa1c7ff5bda9eb13"></a><br/></td></tr>
<tr class="separator:a60204063f3cc3aa2fa1c7ff5bda9eb13 inherit pro_methods_classwx_object"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a95c6a5e4e1e03ff23c7b9efe4cff0c1a inherit pro_methods_classwx_object"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="classwx_object_ref_data.html">wxObjectRefData</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_object.html#a95c6a5e4e1e03ff23c7b9efe4cff0c1a">CreateRefData</a> () const </td></tr>
<tr class="memdesc:a95c6a5e4e1e03ff23c7b9efe4cff0c1a inherit pro_methods_classwx_object"><td class="mdescLeft"> </td><td class="mdescRight">Creates a new instance of the wxObjectRefData-derived class specific to this object and returns it. <a href="#a95c6a5e4e1e03ff23c7b9efe4cff0c1a"></a><br/></td></tr>
<tr class="separator:a95c6a5e4e1e03ff23c7b9efe4cff0c1a inherit pro_methods_classwx_object"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="memitem:a1d39f1d3650fe0982c9a1abe7f9fe7b7 inherit pro_methods_classwx_object"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="classwx_object_ref_data.html">wxObjectRefData</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_object.html#a1d39f1d3650fe0982c9a1abe7f9fe7b7">CloneRefData</a> (const <a class="el" href="classwx_object_ref_data.html">wxObjectRefData</a> *data) const </td></tr>
<tr class="memdesc:a1d39f1d3650fe0982c9a1abe7f9fe7b7 inherit pro_methods_classwx_object"><td class="mdescLeft"> </td><td class="mdescRight">Creates a new instance of the wxObjectRefData-derived class specific to this object and initializes it copying <em>data</em>. <a href="#a1d39f1d3650fe0982c9a1abe7f9fe7b7"></a><br/></td></tr>
<tr class="separator:a1d39f1d3650fe0982c9a1abe7f9fe7b7 inherit pro_methods_classwx_object"><td class="memSeparator" colspan="2"> </td></tr>
<tr class="inherit_header pro_attribs_classwx_object"><td colspan="2" onclick="javascript:toggleInherit('pro_attribs_classwx_object')"><img src="closed.png" alt="-"/> Protected Attributes inherited from <a class="el" href="classwx_object.html">wxObject</a></td></tr>
<tr class="memitem:a9e31954530a0abd54982effc443ed2b8 inherit pro_attribs_classwx_object"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classwx_object_ref_data.html">wxObjectRefData</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="classwx_object.html#a9e31954530a0abd54982effc443ed2b8">m_refData</a></td></tr>
<tr class="memdesc:a9e31954530a0abd54982effc443ed2b8 inherit pro_attribs_classwx_object"><td class="mdescLeft"> </td><td class="mdescRight">Pointer to an object which is the object's reference-counted data. <a href="#a9e31954530a0abd54982effc443ed2b8"></a><br/></td></tr>
<tr class="separator:a9e31954530a0abd54982effc443ed2b8 inherit pro_attribs_classwx_object"><td class="memSeparator" colspan="2"> </td></tr>
</table>
<h2 class="groupheader">Constructor & Destructor Documentation</h2>
<a class="anchor" id="a6e9b0e1b786fa84250a42c88d84aed2b"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">wxMenuItem::wxMenuItem </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classwx_menu.html">wxMenu</a> * </td>
<td class="paramname"><em>parentMenu</em> = <code>NULL</code>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int </td>
<td class="paramname"><em>id</em> = <code><a class="el" href="defs_8h.html#ac66d0a09761e7d86b2ac0b2e0c6a8cbba39011729a3d6167afc8007513f21bcd5">wxID_SEPARATOR</a></code>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const <a class="el" href="classwx_string.html">wxString</a> & </td>
<td class="paramname"><em>text</em> = <code><a class="el" href="interface_2wx_2string_8h.html#a9a321d587166a30017b608dd2d234033">wxEmptyString</a></code>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const <a class="el" href="classwx_string.html">wxString</a> & </td>
<td class="paramname"><em>helpString</em> = <code><a class="el" href="interface_2wx_2string_8h.html#a9a321d587166a30017b608dd2d234033">wxEmptyString</a></code>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="defs_8h.html#abd0c640814a55e4adda3bce698646d2d">wxItemKind</a> </td>
<td class="paramname"><em>kind</em> = <code><a class="el" href="defs_8h.html#abd0c640814a55e4adda3bce698646d2da5281887c1cd68cdd6d4f6a98efc88509">wxITEM_NORMAL</a></code>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="classwx_menu.html">wxMenu</a> * </td>
<td class="paramname"><em>subMenu</em> = <code>NULL</code> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Constructs a <a class="el" href="classwx_menu_item.html" title="A menu item represents an item in a menu.">wxMenuItem</a> object. </p>
<p>Menu items can be standard, or "stock menu items", or custom. For the standard menu items (such as commands to open a file, exit the program and so on, see <a class="el" href="page_stockitems.html">Stock Items</a> for the full list) it is enough to specify just the stock ID and leave <em>text</em> and <em>helpString</em> empty. Some platforms (currently wxGTK only, and see the remark in <a class="el" href="classwx_menu_item.html#a2b5d6bcb820b992b1e4709facbf6d4fb" title="Sets the bitmap for the menu item.">SetBitmap()</a> documentation) will also show standard bitmaps for stock menu items.</p>
<p>Leaving at least <em>text</em> empty for the stock menu items is actually strongly recommended as they will have appearance and keyboard interface (including standard accelerators) familiar to the user.</p>
<p>For the custom (non-stock) menu items, <em>text</em> must be specified and while <em>helpString</em> may be left empty, it's recommended to pass the item description (which is automatically shown by the library in the status bar when the menu item is selected) in this parameter.</p>
<p>Finally note that you can e.g. use a stock menu label without using its stock help string:</p>
<div class="fragment"><div class="line"><span class="comment">// use all stock properties:</span></div>
<div class="line">helpMenu->Append(<a class="code" href="defs_8h.html#ac66d0a09761e7d86b2ac0b2e0c6a8cbba777a4075af4d1bfbbdb6ecfeaa9e8957">wxID_ABOUT</a>);</div>
<div class="line"></div>
<div class="line"><span class="comment">// use the stock label and the stock accelerator but not the stock help string:</span></div>
<div class="line">helpMenu->Append(<a class="code" href="defs_8h.html#ac66d0a09761e7d86b2ac0b2e0c6a8cbba777a4075af4d1bfbbdb6ecfeaa9e8957">wxID_ABOUT</a>, <span class="stringliteral">""</span>, <span class="stringliteral">"My custom help string"</span>);</div>
<div class="line"></div>
<div class="line"><span class="comment">// use all stock properties except for the bitmap:</span></div>
<div class="line"><a class="code" href="classwx_menu_item.html" title="A menu item represents an item in a menu.">wxMenuItem</a> *mymenu = <span class="keyword">new</span> <a class="code" href="classwx_menu_item.html#a6e9b0e1b786fa84250a42c88d84aed2b" title="Constructs a wxMenuItem object.">wxMenuItem</a>(helpMenu, <a class="code" href="defs_8h.html#ac66d0a09761e7d86b2ac0b2e0c6a8cbba777a4075af4d1bfbbdb6ecfeaa9e8957">wxID_ABOUT</a>);</div>
<div class="line">mymenu-><a class="code" href="classwx_menu_item.html#a2b5d6bcb820b992b1e4709facbf6d4fb" title="Sets the bitmap for the menu item.">SetBitmap</a>(<a class="code" href="classwx_art_provider.html#a405ecf7cdead6dbfb092376a51a856c4" title="Query registered providers for bitmap with given ID.">wxArtProvider::GetBitmap</a>(<a class="code" href="artprov_8h.html#a96947921ebc5c5ff7d92f46c99584268">wxART_WARNING</a>));</div>
<div class="line">helpMenu->Append(mymenu);</div>
</div><!-- fragment --><p>that is, stock properties are set independently one from the other.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">parentMenu</td><td>Menu that the menu item belongs to. Can be <span class="literal">NULL</span> if the item is going to be added to the menu later. </td></tr>
<tr><td class="paramname">id</td><td>Identifier for this menu item. May be <code>wxID_SEPARATOR</code>, in which case the given kind is ignored and taken to be <code>wxITEM_SEPARATOR</code> instead. </td></tr>
<tr><td class="paramname">text</td><td>Text for the menu item, as shown on the menu. See <a class="el" href="classwx_menu_item.html#a8b0517fb35e3eada66b51568aa87f261" title="Sets the label associated with the menu item.">SetItemLabel()</a> for more info. </td></tr>
<tr><td class="paramname">helpString</td><td>Optional help string that will be shown on the status bar. </td></tr>
<tr><td class="paramname">kind</td><td>May be <code>wxITEM_SEPARATOR</code>, <code>wxITEM_NORMAL</code>, <code>wxITEM_CHECK</code> or <code>wxITEM_RADIO</code>. </td></tr>
<tr><td class="paramname">subMenu</td><td>If non-<span class="literal">NULL</span>, indicates that the menu item is a submenu. </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a class="anchor" id="a61df296959898555031e23d412508323"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual wxMenuItem::~wxMenuItem </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Destructor. </p>
</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="afcfbb12e302c0528e55efcb1c6f5f7fc"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual void wxMenuItem::Check </td>
<td>(</td>
<td class="paramtype">bool </td>
<td class="paramname"><em>check</em> = <code>true</code></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Checks or unchecks the menu item. </p>
<p>Note that this only works when the item is already appended to a menu. </p>
</div>
</div>
<a class="anchor" id="a1e399da82f486adea3893480bcf66b21"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual void wxMenuItem::Enable </td>
<td>(</td>
<td class="paramtype">bool </td>
<td class="paramname"><em>enable</em> = <code>true</code></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Enables or disables the menu item. </p>
</div>
</div>
<a class="anchor" id="aa3e1b22c815c60c3428fa5b7ba4b8c3f"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual <a class="el" href="classwx_accelerator_entry.html">wxAcceleratorEntry</a>* wxMenuItem::GetAccel </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get our accelerator or NULL (caller must delete the pointer) </p>
</div>
</div>
<a class="anchor" id="a410a18a98166338ab196130ffbcf3968"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">static <a class="el" href="classwx_accelerator_entry.html">wxAcceleratorEntry</a>* wxMenuItem::GetAccelFromString </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classwx_string.html">wxString</a> & </td>
<td class="paramname"><em>label</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Extract the accelerator from the given menu string, return NULL if none found. </p>
</div>
</div>
<a class="anchor" id="a3e5d1a12cd2553241424368624685b90"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classwx_colour.html">wxColour</a>& wxMenuItem::GetBackgroundColour </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the background colour associated with the menu item. </p>
<div><span class="avail">Availability:</span>  only available for the <a class="el" href="page_port.html#page_port_wxmsw">wxMSW</a> port.</div>
</div>
</div>
<a class="anchor" id="a4b119570daa97472c27de231eb4c90d1"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual const <a class="el" href="classwx_bitmap.html">wxBitmap</a>& wxMenuItem::GetBitmap </td>
<td>(</td>
<td class="paramtype">bool </td>
<td class="paramname"><em>checked</em> = <code>true</code></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the checked or unchecked bitmap. </p>
<div><span class="avail">Availability:</span>  only available for the <a class="el" href="page_port.html#page_port_wxmsw">wxMSW</a> port.</div>
</div>
</div>
<a class="anchor" id="aee3c83a50e9d8c69d38faa0210e7f57b"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual const <a class="el" href="classwx_bitmap.html">wxBitmap</a>& wxMenuItem::GetDisabledBitmap </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the bitmap to be used for disabled items. </p>
<div><span class="avail">Availability:</span>  only available for the <a class="el" href="page_port.html#page_port_wxmsw">wxMSW</a> port.</div>
</div>
</div>
<a class="anchor" id="aad2b17eed2726df1d5d5752a40f536da"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classwx_font.html">wxFont</a>& wxMenuItem::GetFont </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the font associated with the menu item. </p>
<div><span class="avail">Availability:</span>  only available for the <a class="el" href="page_port.html#page_port_wxmsw">wxMSW</a> port.</div>
</div>
</div>
<a class="anchor" id="a679c3f9a7bd66d82b3a148629fc6cc5c"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">const <a class="el" href="classwx_string.html">wxString</a>& wxMenuItem::GetHelp </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the help string associated with the menu item. </p>
</div>
</div>
<a class="anchor" id="aec5349782813e4605158f8eeed9a92eb"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int wxMenuItem::GetId </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the menu item identifier. </p>
</div>
</div>
<a class="anchor" id="a6fde1e54cf3cecd90853f627fc4f4493"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual <a class="el" href="classwx_string.html">wxString</a> wxMenuItem::GetItemLabel </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the text associated with the menu item including any accelerator characters that were passed to the constructor or <a class="el" href="classwx_menu_item.html#a8b0517fb35e3eada66b51568aa87f261" title="Sets the label associated with the menu item.">SetItemLabel()</a>. </p>
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classwx_menu_item.html#acfd765d248029f8c548dc700b03f6198" title="Returns the text associated with the menu item, without any accelerator characters.">GetItemLabelText()</a>, <a class="el" href="classwx_menu_item.html#afed23d53a97171076763385c93207fc0" title="Strips all accelerator characters and mnemonics from the given text.">GetLabelText()</a> </dd></dl>
</div>
</div>
<a class="anchor" id="acfd765d248029f8c548dc700b03f6198"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual <a class="el" href="classwx_string.html">wxString</a> wxMenuItem::GetItemLabelText </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the text associated with the menu item, without any accelerator characters. </p>
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classwx_menu_item.html#a6fde1e54cf3cecd90853f627fc4f4493" title="Returns the text associated with the menu item including any accelerator characters that were passed ...">GetItemLabel()</a>, <a class="el" href="classwx_menu_item.html#afed23d53a97171076763385c93207fc0" title="Strips all accelerator characters and mnemonics from the given text.">GetLabelText()</a> </dd></dl>
</div>
</div>
<a class="anchor" id="a759fcdb50560600608446a2099e33d49"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="defs_8h.html#abd0c640814a55e4adda3bce698646d2d">wxItemKind</a> wxMenuItem::GetKind </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the item kind, one of <code>wxITEM_SEPARATOR</code>, <code>wxITEM_NORMAL</code>, <code>wxITEM_CHECK</code> or <code>wxITEM_RADIO</code>. </p>
</div>
</div>
<a class="anchor" id="a97554b69d2ad5948b856b68bfa3e4824"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classwx_string.html">wxString</a> wxMenuItem::GetLabel </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the text associated with the menu item without any accelerator characters it might contain. </p>
<dl class="deprecated"><dt><b><a class="el" href="deprecated.html#_deprecated000038">Deprecated:</a></b></dt><dd>This function is deprecated in favour of <a class="el" href="classwx_menu_item.html#acfd765d248029f8c548dc700b03f6198" title="Returns the text associated with the menu item, without any accelerator characters.">GetItemLabelText()</a>.</dd></dl>
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classwx_menu_item.html#acfd765d248029f8c548dc700b03f6198" title="Returns the text associated with the menu item, without any accelerator characters.">GetItemLabelText()</a> </dd></dl>
</div>
</div>
<a class="anchor" id="af8f7bb0c7ca8808047c3c97b564069ed"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">static <a class="el" href="classwx_string.html">wxString</a> wxMenuItem::GetLabelFromText </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classwx_string.html">wxString</a> & </td>
<td class="paramname"><em>text</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<dl class="deprecated"><dt><b><a class="el" href="deprecated.html#_deprecated000037">Deprecated:</a></b></dt><dd>This function is deprecated; please use <a class="el" href="classwx_menu_item.html#afed23d53a97171076763385c93207fc0" title="Strips all accelerator characters and mnemonics from the given text.">GetLabelText()</a> instead.</dd></dl>
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classwx_menu_item.html#afed23d53a97171076763385c93207fc0" title="Strips all accelerator characters and mnemonics from the given text.">GetLabelText()</a> </dd></dl>
</div>
</div>
<a class="anchor" id="afed23d53a97171076763385c93207fc0"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">static <a class="el" href="classwx_string.html">wxString</a> wxMenuItem::GetLabelText </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classwx_string.html">wxString</a> & </td>
<td class="paramname"><em>text</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Strips all accelerator characters and mnemonics from the given <em>text</em>. </p>
<p>For example:</p>
<div class="fragment"><div class="line">wxMenuItem::GetLabelfromText(<span class="stringliteral">"&Hello\tCtrl-h"</span>);</div>
</div><!-- fragment --><p>will return just <code>"Hello"</code>.</p>
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classwx_menu_item.html#acfd765d248029f8c548dc700b03f6198" title="Returns the text associated with the menu item, without any accelerator characters.">GetItemLabelText()</a>, <a class="el" href="classwx_menu_item.html#a6fde1e54cf3cecd90853f627fc4f4493" title="Returns the text associated with the menu item including any accelerator characters that were passed ...">GetItemLabel()</a> </dd></dl>
</div>
</div>
<a class="anchor" id="a22c16a54a88b192f62200bafd598628c"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int wxMenuItem::GetMarginWidth </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</div><div class="memdoc">
<p>Gets the width of the menu item checkmark bitmap. </p>
<div><span class="avail">Availability:</span>  only available for the <a class="el" href="page_port.html#page_port_wxmsw">wxMSW</a> port.</div>
</div>
</div>
<a class="anchor" id="aa749549977f23192c9d05c19d87ecbee"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classwx_menu.html">wxMenu</a>* wxMenuItem::GetMenu </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the menu this menu item is in, or <span class="literal">NULL</span> if this menu item is not attached. </p>
</div>
</div>
<a class="anchor" id="aa1910ae1850b6dc659e008530e3ddb38"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classwx_string.html">wxString</a> wxMenuItem::GetName </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the text associated with the menu item. </p>
<dl class="deprecated"><dt><b><a class="el" href="deprecated.html#_deprecated000039">Deprecated:</a></b></dt><dd>This function is deprecated. Please use <a class="el" href="classwx_menu_item.html#a6fde1e54cf3cecd90853f627fc4f4493" title="Returns the text associated with the menu item including any accelerator characters that were passed ...">GetItemLabel()</a> or <a class="el" href="classwx_menu_item.html#acfd765d248029f8c548dc700b03f6198" title="Returns the text associated with the menu item, without any accelerator characters.">GetItemLabelText()</a> instead.</dd></dl>
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classwx_menu_item.html#a6fde1e54cf3cecd90853f627fc4f4493" title="Returns the text associated with the menu item including any accelerator characters that were passed ...">GetItemLabel()</a>, <a class="el" href="classwx_menu_item.html#acfd765d248029f8c548dc700b03f6198" title="Returns the text associated with the menu item, without any accelerator characters.">GetItemLabelText()</a> </dd></dl>
</div>
</div>
<a class="anchor" id="a517e8a2c8ce4427eb21999b8b378987b"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classwx_menu.html">wxMenu</a>* wxMenuItem::GetSubMenu </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the submenu associated with the menu item, or <span class="literal">NULL</span> if there isn't one. </p>
</div>
</div>
<a class="anchor" id="af81fb6c07a980fc2d8314f0be6f38170"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">const <a class="el" href="classwx_string.html">wxString</a>& wxMenuItem::GetText </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the text associated with the menu item, such as it was passed to the <a class="el" href="classwx_menu_item.html" title="A menu item represents an item in a menu.">wxMenuItem</a> constructor, i.e. </p>
<p>with any accelerator characters it may contain.</p>
<dl class="deprecated"><dt><b><a class="el" href="deprecated.html#_deprecated000040">Deprecated:</a></b></dt><dd>This function is deprecated in favour of <a class="el" href="classwx_menu_item.html#a6fde1e54cf3cecd90853f627fc4f4493" title="Returns the text associated with the menu item including any accelerator characters that were passed ...">GetItemLabel()</a>.</dd></dl>
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classwx_menu_item.html#af8f7bb0c7ca8808047c3c97b564069ed">GetLabelFromText()</a> </dd></dl>
</div>
</div>
<a class="anchor" id="a62a0d8dabfec3d2ff25dc03bd7cb1b8c"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classwx_colour.html">wxColour</a>& wxMenuItem::GetTextColour </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the text colour associated with the menu item. </p>
<div><span class="avail">Availability:</span>  only available for the <a class="el" href="page_port.html#page_port_wxmsw">wxMSW</a> port.</div>
</div>
</div>
<a class="anchor" id="a666a92acb2e1419e2a03f84a883e08af"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool wxMenuItem::IsCheck </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns <span class="literal">true</span> if the item is a check item. </p>
<p>Unlike <a class="el" href="classwx_menu_item.html#a66cea3a49d79e241c78443e22ce6e7c1" title="Returns true if the item is checkable.">IsCheckable()</a> this doesn't return <span class="literal">true</span> for the radio buttons.</p>
<dl class="section since"><dt>Since</dt><dd>2.9.5 </dd></dl>
</div>
</div>
<a class="anchor" id="a66cea3a49d79e241c78443e22ce6e7c1"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool wxMenuItem::IsCheckable </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns <span class="literal">true</span> if the item is checkable. </p>
<p>Notice that the radio buttons are considered to be checkable as well, so this method returns <span class="literal">true</span> for them too. Use <a class="el" href="classwx_menu_item.html#a666a92acb2e1419e2a03f84a883e08af" title="Returns true if the item is a check item.">IsCheck()</a> if you want to test for the check items only. </p>
</div>
</div>
<a class="anchor" id="a629b1b82993b4f654b214cc90f427974"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual bool wxMenuItem::IsChecked </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns <span class="literal">true</span> if the item is checked. </p>
</div>
</div>
<a class="anchor" id="a0ec10aa48da0e8d17f057834e791c7c8"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual bool wxMenuItem::IsEnabled </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns <span class="literal">true</span> if the item is enabled. </p>
</div>
</div>
<a class="anchor" id="accee896dbe5e554afd18245eeff91141"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool wxMenuItem::IsRadio </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns <span class="literal">true</span> if the item is a radio button. </p>
<dl class="section since"><dt>Since</dt><dd>2.9.5 </dd></dl>
</div>
</div>
<a class="anchor" id="af717c39d2c08161b9b167a7c6ed1fe93"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool wxMenuItem::IsSeparator </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns <span class="literal">true</span> if the item is a separator. </p>
</div>
</div>
<a class="anchor" id="a8b0f0c3f83c47e4f332c94abd406459f"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool wxMenuItem::IsSubMenu </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns <span class="literal">true</span> if the item is a submenu. </p>
</div>
</div>
<a class="anchor" id="a1deb59611abda8b68cd06c848f48884d"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual void wxMenuItem::SetAccel </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classwx_accelerator_entry.html">wxAcceleratorEntry</a> * </td>
<td class="paramname"><em>accel</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Set the accel for this item - this may also be done indirectly with <a class="el" href="classwx_menu_item.html#a742aa5bb0d3faa020e7b3bd66e336499" title="Sets the text associated with the menu item.">SetText()</a> </p>
</div>
</div>
<a class="anchor" id="a5a4462c00517c5d8470b99fd021c6a9d"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void wxMenuItem::SetBackgroundColour </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classwx_colour.html">wxColour</a> & </td>
<td class="paramname"><em>colour</em></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the background colour associated with the menu item. </p>
<div><span class="avail">Availability:</span>  only available for the <a class="el" href="page_port.html#page_port_wxmsw">wxMSW</a> port.</div>
</div>
</div>
<a class="anchor" id="a2b5d6bcb820b992b1e4709facbf6d4fb"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual void wxMenuItem::SetBitmap </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classwx_bitmap.html">wxBitmap</a> & </td>
<td class="paramname"><em>bmp</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">bool </td>
<td class="paramname"><em>checked</em> = <code>true</code> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the bitmap for the menu item. </p>
<p>It is equivalent to wxMenuItem::SetBitmaps(bmp, wxNullBitmap) if <em>checked</em> is <span class="literal">true</span> (default value) or SetBitmaps(wxNullBitmap, bmp) otherwise.</p>
<p><a class="el" href="classwx_menu_item.html#a2b5d6bcb820b992b1e4709facbf6d4fb" title="Sets the bitmap for the menu item.">SetBitmap()</a> must be called before the item is appended to the menu, i.e. appending the item without a bitmap and setting one later is not guaranteed to work. But the bitmap can be changed or reset later if it had been set up initially.</p>
<p>Notice that GTK+ uses a global setting called <code>gtk-menu-images</code> to determine if the images should be shown in the menus at all. If it is off (which is the case in e.g. Gnome 2.28 by default), no images will be shown, consistently with the native behaviour.</p>
<div><span class="avail">Availability:</span>  only available for the <a class="el" href="page_port.html#page_port_wxmsw">wxMSW</a>, <a class="el" href="page_port.html#page_port_wxosx">wxOSX</a>, <a class="el" href="page_port.html#page_port_wxgtk">wxGTK</a> ports.</div>
</div>
</div>
<a class="anchor" id="a62407ad793cb3ef9c59873349558ce5c"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void wxMenuItem::SetBitmaps </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classwx_bitmap.html">wxBitmap</a> & </td>
<td class="paramname"><em>checked</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const <a class="el" href="classwx_bitmap.html">wxBitmap</a> & </td>
<td class="paramname"><em>unchecked</em> = <code><a class="el" href="interface_2wx_2bitmap_8h.html#a2947690e84b8fdb2e37b79a4af8f8a21">wxNullBitmap</a></code> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the checked/unchecked bitmaps for the menu item. </p>
<p>The first bitmap is also used as the single bitmap for uncheckable menu items.</p>
<div><span class="avail">Availability:</span>  only available for the <a class="el" href="page_port.html#page_port_wxmsw">wxMSW</a> port.</div>
</div>
</div>
<a class="anchor" id="a2fabe431416d64dcac9e23469fcc5acb"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void wxMenuItem::SetDisabledBitmap </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classwx_bitmap.html">wxBitmap</a> & </td>
<td class="paramname"><em>disabled</em></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the to be used for disabled menu items. </p>
<div><span class="avail">Availability:</span>  only available for the <a class="el" href="page_port.html#page_port_wxmsw">wxMSW</a> port.</div>
</div>
</div>
<a class="anchor" id="a5deda3866e4308a965caa2fb78c1ca93"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void wxMenuItem::SetFont </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classwx_font.html">wxFont</a> & </td>
<td class="paramname"><em>font</em></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the font associated with the menu item. </p>
<div><span class="avail">Availability:</span>  only available for the <a class="el" href="page_port.html#page_port_wxmsw">wxMSW</a> port.</div>
</div>
</div>
<a class="anchor" id="af20e2cb1c73892e1c8e86e69b40d9040"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void wxMenuItem::SetHelp </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classwx_string.html">wxString</a> & </td>
<td class="paramname"><em>helpString</em></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the help string. </p>
</div>
</div>
<a class="anchor" id="a8b0517fb35e3eada66b51568aa87f261"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual void wxMenuItem::SetItemLabel </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classwx_string.html">wxString</a> & </td>
<td class="paramname"><em>label</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the label associated with the menu item. </p>
<p>Note that if the ID of this menu item corresponds to a stock ID, then it is not necessary to specify a label: wxWidgets will automatically use the stock item label associated with that ID. See the <a class="el" href="classwx_menu_item.html#a6e9b0e1b786fa84250a42c88d84aed2b">constructor</a> for more info.</p>
<p>The label string for the normal menu items (not separators) may include the accelerator which can be used to activate the menu item from keyboard. An accelerator key can be specified using the ampersand <code>&</code> character. In order to embed an ampersand character in the menu item text, the ampersand must be doubled.</p>
<p>Optionally you can specify also an accelerator string appending a tab character <code>\t</code> followed by a valid key combination (e.g. <code>CTRL+V</code>). Its general syntax is any combination of <code>"CTRL"</code>, <code>"RAWCTRL"</code>, <code>"ALT"</code> and <code>"SHIFT"</code> strings (case doesn't matter) separated by either <code>'-'</code> or <code>'+'</code> characters and followed by the accelerator itself. Notice that <code>CTRL</code> corresponds to the "Ctrl" key on most platforms but not under Mac OS where it is mapped to "Cmd" key on Mac keyboard. Usually this is exactly what you want in portable code but if you really need to use the (rarely used for this purpose) "Ctrl" key even under Mac, you may use <code>RAWCTRL</code> to prevent this mapping. Under the other platforms <code>RAWCTRL</code> is the same as plain <code>CTRL</code>.</p>
<p>The accelerator may be any alphanumeric character, any function key (from F1 to F12) or one of the special characters listed in the table below (again, case doesn't matter):</p>
<ul>
<li><code>DEL</code> or <code>DELETE:</code> Delete key</li>
<li><code>BACK</code> : Backspace key</li>
<li><code>INS</code> or <code>INSERT:</code> Insert key</li>
<li><code>ENTER</code> or <code>RETURN:</code> Enter key</li>
<li><code>PGUP:</code> PageUp key</li>
<li><code>PGDN:</code> PageDown key</li>
<li><code>LEFT:</code> Left cursor arrow key</li>
<li><code>RIGHT:</code> Right cursor arrow key</li>
<li><code>UP:</code> Up cursor arrow key</li>
<li><code>DOWN:</code> Down cursor arrow key</li>
<li><code>HOME:</code> Home key</li>
<li><code>END:</code> End key</li>
<li><code>SPACE:</code> Space</li>
<li><code>TAB:</code> Tab key</li>
<li><code>ESC</code> or <code>ESCAPE:</code> Escape key (Windows only)</li>
</ul>
<p>Examples:</p>
<div class="fragment"><div class="line">m_pMyMenuItem->SetItemLabel(<span class="stringliteral">"My &item\tCTRL+I"</span>);</div>
<div class="line">m_pMyMenuItem2->SetItemLabel(<span class="stringliteral">"Clean && build\tF7"</span>);</div>
<div class="line">m_pMyMenuItem3->SetItemLabel(<span class="stringliteral">"Simple item"</span>);</div>
<div class="line">m_pMyMenuItem4->SetItemLabel(<span class="stringliteral">"Item with &accelerator"</span>);</div>
</div><!-- fragment --><dl class="section note"><dt>Note</dt><dd>In wxGTK using <code>"SHIFT"</code> with non-alphabetic characters currently doesn't work, even in combination with other modifiers, due to GTK+ limitation. E.g. <code>Shift+Ctrl+A</code> works but <code>Shift+Ctrl+1</code> or <code>Shift+/</code> do not, so avoid using accelerators of this form in portable code.</dd></dl>
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classwx_menu_item.html#a6fde1e54cf3cecd90853f627fc4f4493" title="Returns the text associated with the menu item including any accelerator characters that were passed ...">GetItemLabel()</a>, <a class="el" href="classwx_menu_item.html#acfd765d248029f8c548dc700b03f6198" title="Returns the text associated with the menu item, without any accelerator characters.">GetItemLabelText()</a> </dd></dl>
</div>
</div>
<a class="anchor" id="aac2257b03dd2485c72f9398ceb1a76cf"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void wxMenuItem::SetMarginWidth </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"><em>width</em></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the width of the menu item checkmark bitmap. </p>
<div><span class="avail">Availability:</span>  only available for the <a class="el" href="page_port.html#page_port_wxmsw">wxMSW</a> port.</div>
</div>
</div>
<a class="anchor" id="a41fb81219430a81e7e2a668831868296"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void wxMenuItem::SetMenu </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classwx_menu.html">wxMenu</a> * </td>
<td class="paramname"><em>menu</em></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the parent menu which will contain this menu item. </p>
</div>
</div>
<a class="anchor" id="ab222651b8b47653d8890cd3469d5ff5a"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void wxMenuItem::SetSubMenu </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classwx_menu.html">wxMenu</a> * </td>
<td class="paramname"><em>menu</em></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the submenu of this menu item. </p>
</div>
</div>
<a class="anchor" id="a742aa5bb0d3faa020e7b3bd66e336499"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">virtual void wxMenuItem::SetText </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classwx_string.html">wxString</a> & </td>
<td class="paramname"><em>text</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the text associated with the menu item. </p>
<dl class="deprecated"><dt><b><a class="el" href="deprecated.html#_deprecated000041">Deprecated:</a></b></dt><dd>This function is deprecated in favour of <a class="el" href="classwx_menu_item.html#a8b0517fb35e3eada66b51568aa87f261" title="Sets the label associated with the menu item.">SetItemLabel()</a>.</dd></dl>
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classwx_menu_item.html#a8b0517fb35e3eada66b51568aa87f261" title="Sets the label associated with the menu item.">SetItemLabel()</a>. </dd></dl>
</div>
</div>
<a class="anchor" id="a695b5f2f1c2325ec01dba5cdd83dd3b5"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void wxMenuItem::SetTextColour </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classwx_colour.html">wxColour</a> & </td>
<td class="paramname"><em>colour</em></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the text colour associated with the menu item. </p>
<div><span class="avail">Availability:</span>  only available for the <a class="el" href="page_port.html#page_port_wxmsw">wxMSW</a> port.</div>
</div>
</div>
</div><!-- contents -->
<address class="footer">
<small>
Generated on Thu Nov 27 2014 13:46:51 for wxWidgets by <a href="http://www.doxygen.org/index.html" target="_new">Doxygen</a> 1.8.2
</small>
</address>
<script src="wxwidgets.js" type="text/javascript"></script>
</div><!-- #page_container -->
</body>
</html>
|