<!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"/> <title>Wt: Wt::WCalendar Class Reference</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <link href="doxygen.css" rel="stylesheet" type="text/css" /> <link href="search/search.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="jquery.js"></script> <script type="text/javascript" src="search/search.js"></script> <script type="text/javascript"> $(document).ready(function() { searchBox.OnSelectItem(0); }); </script> </head> <body> <div id="top"><!-- do not remove this div! --> <div id="titlearea"> <table cellspacing="0" cellpadding="0"> <tbody> <tr style="height: 56px;"> <td style="padding-left: 0.5em;"> <div id="projectname">Wt  <span id="projectnumber">3.2.3</span> </div> </td> </tr> </tbody> </table> </div> <!-- Generated by Doxygen 1.7.5.1 --> <script type="text/javascript"> var searchBox = new SearchBox("searchBox", "search",false,'Search'); </script> <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>Modules</span></a></li> <li><a href="namespaces.html"><span>Namespaces</span></a></li> <li class="current"><a href="annotated.html"><span>Classes</span></a></li> <li><a href="files.html"><span>Files</span></a></li> <li> <div id="MSearchBox" class="MSearchBoxInactive"> <span class="left"> <img id="MSearchSelect" src="search/mag_sel.png" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()" alt=""/> <input type="text" id="MSearchField" value="Search" accesskey="S" onfocus="searchBox.OnSearchFieldFocus(true)" onblur="searchBox.OnSearchFieldFocus(false)" onkeyup="searchBox.OnSearchFieldChange(event)"/> </span><span class="right"> <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a> </span> </div> </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="inherits.html"><span>Class Hierarchy</span></a></li> <li><a href="functions.html"><span>Class Members</span></a></li> </ul> </div> <div id="nav-path" class="navpath"> <ul> <li class="navelem"><a class="el" href="namespaceWt.html">Wt</a> </li> <li class="navelem"><a class="el" href="classWt_1_1WCalendar.html">WCalendar</a> </li> </ul> </div> </div> <div class="header"> <div class="summary"> <a href="#pub-types">Public Types</a> | <a href="#pub-methods">Public Member Functions</a> | <a href="#pro-methods">Protected Member Functions</a> </div> <div class="headertitle"> <div class="title">Wt::WCalendar Class Reference</div> </div> </div> <div class="contents"> <!-- doxytag: class="Wt::WCalendar" --><!-- doxytag: inherits="Wt::WCompositeWidget" --> <p>A calendar. <a href="classWt_1_1WCalendar.html#details">More...</a></p> <p><code>#include <Wt/WCalendar></code></p> <div class="dynheader"> Inheritance diagram for Wt::WCalendar:</div> <div class="dyncontent"> <div class="center"><img src="classWt_1_1WCalendar__inherit__graph.png" border="0" usemap="#Wt_1_1WCalendar_inherit__map" alt="Inheritance graph"/></div> <map name="Wt_1_1WCalendar_inherit__map" id="Wt_1_1WCalendar_inherit__map"> <area shape="rect" href="classWt_1_1WCompositeWidget.html" title="A widget that hides the implementation of composite widgets." alt="" coords="5,155,168,181"/><area shape="rect" href="classWt_1_1WWidget.html" title="The abstract base class for a user-interface component." alt="" coords="37,80,136,107"/><area shape="rect" href="classWt_1_1WObject.html" title="A base class for objects that participate in the signal/slot system." alt="" coords="39,5,135,32"/></map> <center><span class="legend">[<a href="graph_legend.html">legend</a>]</span></center></div> <p><a href="classWt_1_1WCalendar-members.html">List of all members.</a></p> <table class="memberdecls"> <tr><td colspan="2"><h2><a name="pub-types"></a> Public Types</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top">enum  </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#a1e3120d5177a5f29412f55cd7c65b1d4">HorizontalHeaderFormat</a> { <a class="el" href="classWt_1_1WCalendar.html#a1e3120d5177a5f29412f55cd7c65b1d4a6738f5146a720e0df6138950213245eb">SingleLetterDayNames</a>, <a class="el" href="classWt_1_1WCalendar.html#a1e3120d5177a5f29412f55cd7c65b1d4a58ae7bf27446ad315f2c18f494ef46ef">ShortDayNames</a>, <a class="el" href="classWt_1_1WCalendar.html#a1e3120d5177a5f29412f55cd7c65b1d4a481f2bc7524b368484f44d0ba6d74e72">LongDayNames</a> }</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">The format of the horizontal header. <a href="classWt_1_1WCalendar.html#a1e3120d5177a5f29412f55cd7c65b1d4">More...</a><br/></td></tr> <tr><td colspan="2"><h2><a name="pub-methods"></a> Public Member Functions</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#a62a4817cfb3da910bee0b0c7a27dfd73">WCalendar</a> (<a class="el" href="classWt_1_1WContainerWidget.html">WContainerWidget</a> *parent=0)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Creates a new calendar. <a href="#a62a4817cfb3da910bee0b0c7a27dfd73"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#a42e800f304acd0e6ed55258149354b9d">setSelectionMode</a> (<a class="el" href="namespaceWt.html#a74b3f7eb1689a3cbf0ea514ffd20bccc">SelectionMode</a> mode)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Sets the selection mode. <a href="#a42e800f304acd0e6ed55258149354b9d"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#aa60744e2ecaeda40a2a9b0a401010470">browseToPreviousYear</a> ()</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Browses to the same month in the previous year. <a href="#aa60744e2ecaeda40a2a9b0a401010470"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#a99c57c17f6afab4a0aa3a74ee9b19289">browseToPreviousMonth</a> ()</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Browses to the previous month. <a href="#a99c57c17f6afab4a0aa3a74ee9b19289"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#abe866003ddb73b9fed91f35b7383e8ee">browseToNextYear</a> ()</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Browses to the same month in the next year. <a href="#abe866003ddb73b9fed91f35b7383e8ee"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#a4e77a4335ac8891a4d51441ce0f9e626">browseToNextMonth</a> ()</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Browses to the next month. <a href="#a4e77a4335ac8891a4d51441ce0f9e626"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#a59949bcc20f604fd96a73aa342157b8d">browseTo</a> (const <a class="el" href="classWt_1_1WDate.html">WDate</a> &date)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Browses to a date. <a href="#a59949bcc20f604fd96a73aa342157b8d"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#a28bf4605a51c67258ee8e9182a1e27a9">currentMonth</a> () const </td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Returns the current month displayed. <a href="#a28bf4605a51c67258ee8e9182a1e27a9"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#a95a1fdb04b8b21bfb473dcf509e5d864">currentYear</a> () const </td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Returns the current year displayed. <a href="#a95a1fdb04b8b21bfb473dcf509e5d864"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#aff46e84192787483ec4f00c5b1410a8d">clearSelection</a> ()</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Clears the current selection. <a href="#aff46e84192787483ec4f00c5b1410a8d"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#ab3b72e0e5a76f3e365d94d056465453f">select</a> (const <a class="el" href="classWt_1_1WDate.html">WDate</a> &date)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Selects a date. <a href="#ab3b72e0e5a76f3e365d94d056465453f"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#aa128787a7b96264b5e755712e720f928">select</a> (const std::set< <a class="el" href="classWt_1_1WDate.html">WDate</a> > &dates)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Selects multiple dates. <a href="#aa128787a7b96264b5e755712e720f928"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#a3475efa36daca79a4ce976202dd9a1fc">setHorizontalHeaderFormat</a> (<a class="el" href="classWt_1_1WCalendar.html#a1e3120d5177a5f29412f55cd7c65b1d4">HorizontalHeaderFormat</a> format)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Sets the horizontal header format. <a href="#a3475efa36daca79a4ce976202dd9a1fc"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classWt_1_1WCalendar.html#a1e3120d5177a5f29412f55cd7c65b1d4">HorizontalHeaderFormat</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#afde4624cf1ff320b547e68691b4d4d46">horizontalHeaderFormat</a> ()</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Returns the horizontal header format. <a href="#afde4624cf1ff320b547e68691b4d4d46"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#a741e177dd86d834956a65343fefd14d0">setFirstDayOfWeek</a> (int dayOfWeek)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Sets the first day of the week. <a href="#a741e177dd86d834956a65343fefd14d0"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">const std::set< <a class="el" href="classWt_1_1WDate.html">WDate</a> > & </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#ade00a32163a903b22bd441179c95d9d3">selection</a> () const </td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Returns the current selection. <a href="#ade00a32163a903b22bd441179c95d9d3"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classWt_1_1Signal.html">Signal</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#a317d3018608bbeed934e1823969a3a7f">selectionChanged</a> ()</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Signal emitted when the user changes the selection. <a href="#a317d3018608bbeed934e1823969a3a7f"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classWt_1_1Signal.html">Signal</a>< <a class="el" href="classWt_1_1WDate.html">WDate</a> > & </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#a8675afd38f2b773d0945af207d7639f9">activated</a> ()</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Signal emitted when the user double-clicks a date. <a href="#a8675afd38f2b773d0945af207d7639f9"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classWt_1_1Signal.html">Signal</a>< <a class="el" href="classWt_1_1WDate.html">WDate</a> > & </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#a51ad8160985f49f5ff0e726df8103921">clicked</a> ()</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Signal emitted when the user clicks a date. <a href="#a51ad8160985f49f5ff0e726df8103921"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classWt_1_1Signal.html">Signal</a>< int, int > & </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#a5dc6d29c25661c665e0110dd0dcaaca6">currentPageChanged</a> ()</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Signal emitted when the current month is changed. <a href="#a5dc6d29c25661c665e0110dd0dcaaca6"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#a075e2a4c5c39f8b6144865cfd0ae07f0">setMultipleSelection</a> (bool multiple)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Configures single or multiple selection mode (<b> deprecated </b>). <a href="#a075e2a4c5c39f8b6144865cfd0ae07f0"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classWt_1_1Signal.html">Signal</a>< <a class="el" href="classWt_1_1WDate.html">WDate</a> > & </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#aab0005ad0c245d06895848a5b12d6050">selected</a> ()</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Signal emitted when the user has double clicked on a date (<b>deprecated</b>). <a href="#aab0005ad0c245d06895848a5b12d6050"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#ad33dba722cbddf4b9feff69d4ca744f2">setSingleClickSelect</a> (bool single)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Configures the calendar to use single click for activation (<b>deprecated</b>) <a href="#ad33dba722cbddf4b9feff69d4ca744f2"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#aae58d984894182574f60f17645e3533f">setDayOfWeekLength</a> (int chars)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Sets the length for the abbreviated day of week (<b> deprecated </b>). <a href="#aae58d984894182574f60f17645e3533f"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#a5d5237e806862564ba9a8c9f5b8f5272">setBottom</a> (const <a class="el" href="classWt_1_1WDate.html">WDate</a> &bottom)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Sets the bottom of the valid date range. <a href="#a5d5237e806862564ba9a8c9f5b8f5272"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="abf97eba163e425c000b8d260bd1285ea"></a><!-- doxytag: member="Wt::WCalendar::bottom" ref="abf97eba163e425c000b8d260bd1285ea" args="() const " --> const <a class="el" href="classWt_1_1WDate.html">WDate</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#abf97eba163e425c000b8d260bd1285ea">bottom</a> () const </td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Returns the bottom date of the valid range. <br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#a6a45200e082a7178d7060bdb9f960a17">setTop</a> (const <a class="el" href="classWt_1_1WDate.html">WDate</a> &top)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Sets the top of the valid date range. <a href="#a6a45200e082a7178d7060bdb9f960a17"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a6293a873cab2d27413b05c98546d8f26"></a><!-- doxytag: member="Wt::WCalendar::top" ref="a6293a873cab2d27413b05c98546d8f26" args="() const " --> const <a class="el" href="classWt_1_1WDate.html">WDate</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#a6293a873cab2d27413b05c98546d8f26">top</a> () const </td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Returns the top date of the valid range. <br/></td></tr> <tr><td colspan="2"><h2><a name="pro-methods"></a> Protected Member Functions</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="classWt_1_1WWidget.html">WWidget</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#a3513147b88fa57ac287ab2546d00dd96">renderCell</a> (<a class="el" href="classWt_1_1WWidget.html">WWidget</a> *widget, const <a class="el" href="classWt_1_1WDate.html">WDate</a> &date)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Creates or updates a widget that renders a cell. <a href="#a3513147b88fa57ac287ab2546d00dd96"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="classWt_1_1WCalendar.html#acea26f984bfced2b060abd119e42d547">isSelected</a> (const <a class="el" href="classWt_1_1WDate.html">WDate</a> &date) const </td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Returns whether a date is selected. <a href="#acea26f984bfced2b060abd119e42d547"></a><br/></td></tr> </table> <hr/><a name="details" id="details"></a><h2>Detailed Description</h2> <div class="textblock"><p>A calendar. </p> <p>The calendar provides navigation by month and year, and indicates the current day.</p> <p>You can listen for single click or double click events on a calendar cell using the <a class="el" href="classWt_1_1WCalendar.html#a51ad8160985f49f5ff0e726df8103921" title="Signal emitted when the user clicks a date.">clicked()</a> and <a class="el" href="classWt_1_1WCalendar.html#a8675afd38f2b773d0945af207d7639f9" title="Signal emitted when the user double-clicks a date.">activated()</a> methods.</p> <p>The calendar may be configured to allow selection of single or multiple days using <a class="el" href="classWt_1_1WCalendar.html#a42e800f304acd0e6ed55258149354b9d" title="Sets the selection mode.">setSelectionMode()</a>, and you may listen for changes in the selection using the <a class="el" href="classWt_1_1WCalendar.html#a317d3018608bbeed934e1823969a3a7f" title="Signal emitted when the user changes the selection.">selectionChanged()</a> signals. Selection can also be entirely disabled in which case you can implement your own selection handling by listening for cell click events.</p> <p>Cell rendering may be customized by reimplementing <a class="el" href="classWt_1_1WCalendar.html#a3513147b88fa57ac287ab2546d00dd96" title="Creates or updates a widget that renders a cell.">renderCell()</a>.</p> <p>Internationalization is provided by the internationalization features of the <a class="el" href="classWt_1_1WDate.html" title="A value class that represents a date on the Gregorian calendar.">Wt::WDate</a> class.</p> <p>Usage example: </p> <div class="fragment"><pre class="fragment"> <a class="code" href="classWt_1_1WDate.html" title="A value class that represents a date on the Gregorian calendar.">Wt::WDate</a> today = <a class="code" href="classWt_1_1WDate.html#a6221e680cd7b1f7d324f1f1932e4a3db" title="Reports the current client date.">Wt::WDate::currentDate</a>(); <a class="code" href="classWt_1_1WCalendar.html" title="A calendar.">Wt::WCalendar</a> *calendar = <span class="keyword">new</span> <a class="code" href="classWt_1_1WCalendar.html#a62a4817cfb3da910bee0b0c7a27dfd73" title="Creates a new calendar.">Wt::WCalendar</a>(<span class="keyword">this</span>); calendar-><a class="code" href="classWt_1_1WCalendar.html#a59949bcc20f604fd96a73aa342157b8d" title="Browses to a date.">browseTo</a>(today.<a class="code" href="classWt_1_1WDate.html#ad85d82a3aa5c2613550e9cf52983d66b" title="Adds months.">addMonths</a>(1)); calendar-><a class="code" href="classWt_1_1WCalendar.html#ab3b72e0e5a76f3e365d94d056465453f" title="Selects a date.">select</a>(today.<a class="code" href="classWt_1_1WDate.html#ad85d82a3aa5c2613550e9cf52983d66b" title="Adds months.">addMonths</a>(1).addDays(3)); calendar-><a class="code" href="classWt_1_1WCalendar.html#aab0005ad0c245d06895848a5b12d6050" title="Signal emitted when the user has double clicked on a date (deprecated).">selected</a>().connect(<span class="keyword">this</span>, &MyWidget::daySelected); </pre></div><p>Here is a snapshot, taken on 19/01/2010 (shown as today), and 14/01/2010 currently selected. </p> <table border="0" align="center"> <tr> <td><div class="image"> <img src="WCalendar-default-1.png" alt="WCalendar-default-1.png"/> <div class="caption"> WCalendar with default look</div></div> </td><td><div class="image"> <img src="WCalendar-polished-1.png" alt="WCalendar-polished-1.png"/> <div class="caption"> WCalendar with polished look</div></div> </td></tr> </table> <h3>CSS</h3> <p>The calendar is styled by the current CSS theme. The look can be overridden using the <code>Wt-calendar</code> CSS class and the following selectors:</p> <div class="fragment"><pre class="fragment"> .Wt-cal table : The table .Wt-cal table.d1 : The table (single letter day headers) .Wt-cal table.d3 : The table (three letter day headers) .Wt-cal table.dlong : The table (long day headers) .Wt-cal caption : The caption (containing the navigation buttons) .Wt-cal-year : The caption year in-place-edit .Wt-cal th : Header cell (week day) .Wt-cal td : Day cell .Wt-cal-oom : Out-of-month day .Wt-cal-oor : Out-of-range day (day < bottom or day > top) .Wt-cal-sel : Selected day .Wt-cal-now : Today day </pre></div> </div><hr/><h2>Member Enumeration Documentation</h2> <a class="anchor" id="a1e3120d5177a5f29412f55cd7c65b1d4"></a><!-- doxytag: member="Wt::WCalendar::HorizontalHeaderFormat" ref="a1e3120d5177a5f29412f55cd7c65b1d4" args="" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">enum <a class="el" href="classWt_1_1WCalendar.html#a1e3120d5177a5f29412f55cd7c65b1d4">Wt::WCalendar::HorizontalHeaderFormat</a></td> </tr> </table> </div> <div class="memdoc"> <p>The format of the horizontal header. </p> <dl><dt><b>Enumerator: </b></dt><dd><table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"><em><a class="anchor" id="a1e3120d5177a5f29412f55cd7c65b1d4a6738f5146a720e0df6138950213245eb"></a><!-- doxytag: member="SingleLetterDayNames" ref="a1e3120d5177a5f29412f55cd7c65b1d4a6738f5146a720e0df6138950213245eb" args="" -->SingleLetterDayNames</em> </td><td> <p>First letter of a day (e.g. 'M' for Monday) </p> </td></tr> <tr><td valign="top"><em><a class="anchor" id="a1e3120d5177a5f29412f55cd7c65b1d4a58ae7bf27446ad315f2c18f494ef46ef"></a><!-- doxytag: member="ShortDayNames" ref="a1e3120d5177a5f29412f55cd7c65b1d4a58ae7bf27446ad315f2c18f494ef46ef" args="" -->ShortDayNames</em> </td><td> <p>First 3 letters of a day (e.g. 'Mon' for Monday) </p> </td></tr> <tr><td valign="top"><em><a class="anchor" id="a1e3120d5177a5f29412f55cd7c65b1d4a481f2bc7524b368484f44d0ba6d74e72"></a><!-- doxytag: member="LongDayNames" ref="a1e3120d5177a5f29412f55cd7c65b1d4a481f2bc7524b368484f44d0ba6d74e72" args="" -->LongDayNames</em> </td><td> <p>Full day name. </p> </td></tr> </table> </dd> </dl> </div> </div> <hr/><h2>Constructor & Destructor Documentation</h2> <a class="anchor" id="a62a4817cfb3da910bee0b0c7a27dfd73"></a><!-- doxytag: member="Wt::WCalendar::WCalendar" ref="a62a4817cfb3da910bee0b0c7a27dfd73" args="(WContainerWidget *parent=0)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">Wt::WCalendar::WCalendar </td> <td>(</td> <td class="paramtype"><a class="el" href="classWt_1_1WContainerWidget.html">WContainerWidget</a> * </td> <td class="paramname"><em>parent</em> = <code>0</code></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Creates a new calendar. </p> <p>Constructs a new calendar with English day/month names. The calendar shows the current day, and has an empty selection. </p> </div> </div> <hr/><h2>Member Function Documentation</h2> <a class="anchor" id="a8675afd38f2b773d0945af207d7639f9"></a><!-- doxytag: member="Wt::WCalendar::activated" ref="a8675afd38f2b773d0945af207d7639f9" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="classWt_1_1Signal.html">Signal</a><<a class="el" href="classWt_1_1WDate.html">WDate</a>>& Wt::WCalendar::activated </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Signal emitted when the user double-clicks a date. </p> <p>You may want to connect to this signal to treat a double click as the selection of a date. </p> </div> </div> <a class="anchor" id="a59949bcc20f604fd96a73aa342157b8d"></a><!-- doxytag: member="Wt::WCalendar::browseTo" ref="a59949bcc20f604fd96a73aa342157b8d" args="(const WDate &date)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void Wt::WCalendar::browseTo </td> <td>(</td> <td class="paramtype">const <a class="el" href="classWt_1_1WDate.html">WDate</a> & </td> <td class="paramname"><em>date</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Browses to a date. </p> <p>Displays the month which contains the given date. This does not change the current selection.</p> <p>This will emit the <a class="el" href="classWt_1_1WCalendar.html#a5dc6d29c25661c665e0110dd0dcaaca6" title="Signal emitted when the current month is changed.">currentPageChanged()</a> signal if another month is displayed. </p> </div> </div> <a class="anchor" id="a4e77a4335ac8891a4d51441ce0f9e626"></a><!-- doxytag: member="Wt::WCalendar::browseToNextMonth" ref="a4e77a4335ac8891a4d51441ce0f9e626" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void Wt::WCalendar::browseToNextMonth </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Browses to the next month. </p> <p>Displays the next month. This does not change the current selection.</p> <p>This will emit the <a class="el" href="classWt_1_1WCalendar.html#a5dc6d29c25661c665e0110dd0dcaaca6" title="Signal emitted when the current month is changed.">currentPageChanged()</a> singal. </p> </div> </div> <a class="anchor" id="abe866003ddb73b9fed91f35b7383e8ee"></a><!-- doxytag: member="Wt::WCalendar::browseToNextYear" ref="abe866003ddb73b9fed91f35b7383e8ee" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void Wt::WCalendar::browseToNextYear </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Browses to the same month in the next year. </p> <p>Displays the same month in the next year. This does not change the current selection.</p> <p>This will emit the <a class="el" href="classWt_1_1WCalendar.html#a5dc6d29c25661c665e0110dd0dcaaca6" title="Signal emitted when the current month is changed.">currentPageChanged()</a> singal. </p> </div> </div> <a class="anchor" id="a99c57c17f6afab4a0aa3a74ee9b19289"></a><!-- doxytag: member="Wt::WCalendar::browseToPreviousMonth" ref="a99c57c17f6afab4a0aa3a74ee9b19289" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void Wt::WCalendar::browseToPreviousMonth </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Browses to the previous month. </p> <p>Displays the previous month. This does not affect the selection.</p> <p>This will emit the <a class="el" href="classWt_1_1WCalendar.html#a5dc6d29c25661c665e0110dd0dcaaca6" title="Signal emitted when the current month is changed.">currentPageChanged()</a> singal. </p> </div> </div> <a class="anchor" id="aa60744e2ecaeda40a2a9b0a401010470"></a><!-- doxytag: member="Wt::WCalendar::browseToPreviousYear" ref="aa60744e2ecaeda40a2a9b0a401010470" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void Wt::WCalendar::browseToPreviousYear </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Browses to the same month in the previous year. </p> <p>Displays the same month in the previous year. This does not affect the selection.</p> <p>This will emit the <a class="el" href="classWt_1_1WCalendar.html#a5dc6d29c25661c665e0110dd0dcaaca6" title="Signal emitted when the current month is changed.">currentPageChanged()</a> singal. </p> </div> </div> <a class="anchor" id="aff46e84192787483ec4f00c5b1410a8d"></a><!-- doxytag: member="Wt::WCalendar::clearSelection" ref="aff46e84192787483ec4f00c5b1410a8d" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void Wt::WCalendar::clearSelection </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Clears the current selection. </p> <p>Clears the current selection. Will result in a <a class="el" href="classWt_1_1WCalendar.html#ade00a32163a903b22bd441179c95d9d3" title="Returns the current selection.">selection()</a> that is empty(). </p> </div> </div> <a class="anchor" id="a51ad8160985f49f5ff0e726df8103921"></a><!-- doxytag: member="Wt::WCalendar::clicked" ref="a51ad8160985f49f5ff0e726df8103921" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="classWt_1_1Signal.html">Signal</a><<a class="el" href="classWt_1_1WDate.html">WDate</a>>& Wt::WCalendar::clicked </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Signal emitted when the user clicks a date. </p> <p>You may want to connect to this signal if you want to provide a custom selection handling. </p> </div> </div> <a class="anchor" id="a28bf4605a51c67258ee8e9182a1e27a9"></a><!-- doxytag: member="Wt::WCalendar::currentMonth" ref="a28bf4605a51c67258ee8e9182a1e27a9" args="() const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int Wt::WCalendar::currentMonth </td> <td>(</td> <td class="paramname"></td><td>)</td> <td> const</td> </tr> </table> </div> <div class="memdoc"> <p>Returns the current month displayed. </p> <p>Returns the month (1-12) that is currently displayed. </p> </div> </div> <a class="anchor" id="a5dc6d29c25661c665e0110dd0dcaaca6"></a><!-- doxytag: member="Wt::WCalendar::currentPageChanged" ref="a5dc6d29c25661c665e0110dd0dcaaca6" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="classWt_1_1Signal.html">Signal</a><int, int>& Wt::WCalendar::currentPageChanged </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Signal emitted when the current month is changed. </p> <p>The method is emitted both when the change is done through the user interface or via the public API. The two parameters are respectively the new year and month. </p> </div> </div> <a class="anchor" id="a95a1fdb04b8b21bfb473dcf509e5d864"></a><!-- doxytag: member="Wt::WCalendar::currentYear" ref="a95a1fdb04b8b21bfb473dcf509e5d864" args="() const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int Wt::WCalendar::currentYear </td> <td>(</td> <td class="paramname"></td><td>)</td> <td> const</td> </tr> </table> </div> <div class="memdoc"> <p>Returns the current year displayed. </p> <p>Returns the year that is currently displayed. </p> </div> </div> <a class="anchor" id="afde4624cf1ff320b547e68691b4d4d46"></a><!-- doxytag: member="Wt::WCalendar::horizontalHeaderFormat" ref="afde4624cf1ff320b547e68691b4d4d46" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="classWt_1_1WCalendar.html#a1e3120d5177a5f29412f55cd7c65b1d4">HorizontalHeaderFormat</a> Wt::WCalendar::horizontalHeaderFormat </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Returns the horizontal header format. </p> <dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WCalendar.html#a3475efa36daca79a4ce976202dd9a1fc" title="Sets the horizontal header format.">setHorizontalHeaderFormat()</a> </dd></dl> </div> </div> <a class="anchor" id="acea26f984bfced2b060abd119e42d547"></a><!-- doxytag: member="Wt::WCalendar::isSelected" ref="acea26f984bfced2b060abd119e42d547" args="(const WDate &date) const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">bool Wt::WCalendar::isSelected </td> <td>(</td> <td class="paramtype">const <a class="el" href="classWt_1_1WDate.html">WDate</a> & </td> <td class="paramname"><em>date</em></td><td>)</td> <td> const<code> [protected]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Returns whether a date is selected. </p> <p>This is a convenience method that can be used when reimplementing <a class="el" href="classWt_1_1WCalendar.html#a3513147b88fa57ac287ab2546d00dd96" title="Creates or updates a widget that renders a cell.">renderCell()</a>. </p> </div> </div> <a class="anchor" id="a3513147b88fa57ac287ab2546d00dd96"></a><!-- doxytag: member="Wt::WCalendar::renderCell" ref="a3513147b88fa57ac287ab2546d00dd96" args="(WWidget *widget, const WDate &date)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="classWt_1_1WWidget.html">WWidget</a> * Wt::WCalendar::renderCell </td> <td>(</td> <td class="paramtype"><a class="el" href="classWt_1_1WWidget.html">WWidget</a> * </td> <td class="paramname"><em>widget</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">const <a class="el" href="classWt_1_1WDate.html">WDate</a> & </td> <td class="paramname"><em>date</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td><code> [protected, virtual]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Creates or updates a widget that renders a cell. </p> <p>The default implementation creates a <a class="el" href="classWt_1_1WText.html" title="A widget that renders (XHTML) text.">WText</a></p> <p>You may want to reimplement this method if you wish to customize how a cell is rendered. When <code>widget</code> is <code>0</code>, a new widget should be created and returned. Otherwise, you may either modify the passed <code>widget</code>, or return a new widget. If you return a new widget, the prevoius widget will be deleted. </p> </div> </div> <a class="anchor" id="ab3b72e0e5a76f3e365d94d056465453f"></a><!-- doxytag: member="Wt::WCalendar::select" ref="ab3b72e0e5a76f3e365d94d056465453f" args="(const WDate &date)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void Wt::WCalendar::select </td> <td>(</td> <td class="paramtype">const <a class="el" href="classWt_1_1WDate.html">WDate</a> & </td> <td class="paramname"><em>date</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Selects a date. </p> <p>Select one date. Both in single or multiple selection mode, this results in a <a class="el" href="classWt_1_1WCalendar.html#ade00a32163a903b22bd441179c95d9d3" title="Returns the current selection.">selection()</a> that contains exactly one date. </p> </div> </div> <a class="anchor" id="aa128787a7b96264b5e755712e720f928"></a><!-- doxytag: member="Wt::WCalendar::select" ref="aa128787a7b96264b5e755712e720f928" args="(const std::set< WDate > &dates)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void Wt::WCalendar::select </td> <td>(</td> <td class="paramtype">const std::set< <a class="el" href="classWt_1_1WDate.html">WDate</a> > & </td> <td class="paramname"><em>dates</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Selects multiple dates. </p> <p>Select multiple dates. In multiple selection mode, this results in a <a class="el" href="classWt_1_1WCalendar.html#ade00a32163a903b22bd441179c95d9d3" title="Returns the current selection.">selection()</a> that contains exactly the given dates. In single selection mode, at most one date is set. </p> </div> </div> <a class="anchor" id="aab0005ad0c245d06895848a5b12d6050"></a><!-- doxytag: member="Wt::WCalendar::selected" ref="aab0005ad0c245d06895848a5b12d6050" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="classWt_1_1Signal.html">Signal</a><<a class="el" href="classWt_1_1WDate.html">WDate</a>>& Wt::WCalendar::selected </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Signal emitted when the user has double clicked on a date (<b>deprecated</b>). </p> <p>This signal indicates that he user has selected a new date, which is only available when in single selection mode.</p> <dl class="deprecated"><dt><b><a class="el" href="deprecated.html#_deprecated000020">Deprecated:</a></b></dt><dd>use <a class="el" href="classWt_1_1WCalendar.html#a8675afd38f2b773d0945af207d7639f9" title="Signal emitted when the user double-clicks a date.">activated()</a> instead. </dd></dl> </div> </div> <a class="anchor" id="ade00a32163a903b22bd441179c95d9d3"></a><!-- doxytag: member="Wt::WCalendar::selection" ref="ade00a32163a903b22bd441179c95d9d3" args="() const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">const std::set<<a class="el" href="classWt_1_1WDate.html">WDate</a>>& Wt::WCalendar::selection </td> <td>(</td> <td class="paramname"></td><td>)</td> <td> const</td> </tr> </table> </div> <div class="memdoc"> <p>Returns the current selection. </p> <p>Returns the set of dates currently selected. In single selection mode, this set contains 0 or 1 dates. </p> </div> </div> <a class="anchor" id="a317d3018608bbeed934e1823969a3a7f"></a><!-- doxytag: member="Wt::WCalendar::selectionChanged" ref="a317d3018608bbeed934e1823969a3a7f" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="classWt_1_1Signal.html">Signal</a>& Wt::WCalendar::selectionChanged </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Signal emitted when the user changes the selection. </p> <p>Emitted after the user has changed the current selection. </p> </div> </div> <a class="anchor" id="a5d5237e806862564ba9a8c9f5b8f5272"></a><!-- doxytag: member="Wt::WCalendar::setBottom" ref="a5d5237e806862564ba9a8c9f5b8f5272" args="(const WDate &bottom)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void Wt::WCalendar::setBottom </td> <td>(</td> <td class="paramtype">const <a class="el" href="classWt_1_1WDate.html">WDate</a> & </td> <td class="paramname"><em>bottom</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Sets the bottom of the valid date range. </p> <p>The default is a null date constructed using WDate(). </p> </div> </div> <a class="anchor" id="aae58d984894182574f60f17645e3533f"></a><!-- doxytag: member="Wt::WCalendar::setDayOfWeekLength" ref="aae58d984894182574f60f17645e3533f" args="(int chars)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void Wt::WCalendar::setDayOfWeekLength </td> <td>(</td> <td class="paramtype">int </td> <td class="paramname"><em>chars</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Sets the length for the abbreviated day of week (<b> deprecated </b>). </p> <p>The <code>chars</code> may be 1 or 3, which render "Monday" as respectively "M" or "Mon".</p> <p>The default length is 3.</p> <dl class="deprecated"><dt><b><a class="el" href="deprecated.html#_deprecated000022">Deprecated:</a></b></dt><dd>use <a class="el" href="classWt_1_1WCalendar.html#a3475efa36daca79a4ce976202dd9a1fc" title="Sets the horizontal header format.">setHorizontalHeaderFormat()</a> instead. </dd></dl> </div> </div> <a class="anchor" id="a741e177dd86d834956a65343fefd14d0"></a><!-- doxytag: member="Wt::WCalendar::setFirstDayOfWeek" ref="a741e177dd86d834956a65343fefd14d0" args="(int dayOfWeek)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void Wt::WCalendar::setFirstDayOfWeek </td> <td>(</td> <td class="paramtype">int </td> <td class="paramname"><em>dayOfWeek</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Sets the first day of the week. </p> <p>Possible values or 1 to 7, as accepted by <a class="el" href="classWt_1_1WDate.html#a342672cb868912660f60bb51ef99c6ca" title="Returns the short day name.">WDate::shortDayName()</a>.</p> <p>The default value is 1 ("Monday"). </p> </div> </div> <a class="anchor" id="a3475efa36daca79a4ce976202dd9a1fc"></a><!-- doxytag: member="Wt::WCalendar::setHorizontalHeaderFormat" ref="a3475efa36daca79a4ce976202dd9a1fc" args="(HorizontalHeaderFormat format)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void Wt::WCalendar::setHorizontalHeaderFormat </td> <td>(</td> <td class="paramtype"><a class="el" href="classWt_1_1WCalendar.html#a1e3120d5177a5f29412f55cd7c65b1d4">HorizontalHeaderFormat</a> </td> <td class="paramname"><em>format</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Sets the horizontal header format. </p> <p>The default horizontal header format is <a class="el" href="classWt_1_1WCalendar.html#a1e3120d5177a5f29412f55cd7c65b1d4a58ae7bf27446ad315f2c18f494ef46ef" title="First 3 letters of a day (e.g. 'Mon' for Monday)">WCalendar::ShortDayNames</a>. </p> </div> </div> <a class="anchor" id="a075e2a4c5c39f8b6144865cfd0ae07f0"></a><!-- doxytag: member="Wt::WCalendar::setMultipleSelection" ref="a075e2a4c5c39f8b6144865cfd0ae07f0" args="(bool multiple)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void Wt::WCalendar::setMultipleSelection </td> <td>(</td> <td class="paramtype">bool </td> <td class="paramname"><em>multiple</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Configures single or multiple selection mode (<b> deprecated </b>). </p> <p>In single selection mode, only one date may be selected: the <a class="el" href="classWt_1_1WCalendar.html#ade00a32163a903b22bd441179c95d9d3" title="Returns the current selection.">selection()</a> will be empty or contain exactly one item.</p> <dl class="deprecated"><dt><b><a class="el" href="deprecated.html#_deprecated000019">Deprecated:</a></b></dt><dd>use <a class="el" href="classWt_1_1WCalendar.html#a42e800f304acd0e6ed55258149354b9d" title="Sets the selection mode.">setSelectionMode()</a> instead. </dd></dl> </div> </div> <a class="anchor" id="a42e800f304acd0e6ed55258149354b9d"></a><!-- doxytag: member="Wt::WCalendar::setSelectionMode" ref="a42e800f304acd0e6ed55258149354b9d" args="(SelectionMode mode)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void Wt::WCalendar::setSelectionMode </td> <td>(</td> <td class="paramtype"><a class="el" href="namespaceWt.html#a74b3f7eb1689a3cbf0ea514ffd20bccc">SelectionMode</a> </td> <td class="paramname"><em>mode</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Sets the selection mode. </p> <p>The default selection mode is <a class="el" href="namespaceWt.html#a74b3f7eb1689a3cbf0ea514ffd20bccca4fd3c5ba6ce5289a1e732d85f002882a">SingleSelection</a>. </p> </div> </div> <a class="anchor" id="ad33dba722cbddf4b9feff69d4ca744f2"></a><!-- doxytag: member="Wt::WCalendar::setSingleClickSelect" ref="ad33dba722cbddf4b9feff69d4ca744f2" args="(bool single)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void Wt::WCalendar::setSingleClickSelect </td> <td>(</td> <td class="paramtype">bool </td> <td class="paramname"><em>single</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Configures the calendar to use single click for activation (<b>deprecated</b>) </p> <p>By default, double click will trigger activate(). Use this method if you want a single click to trigger activate() (and the now deprecated <a class="el" href="classWt_1_1WCalendar.html#aab0005ad0c245d06895848a5b12d6050" title="Signal emitted when the user has double clicked on a date (deprecated).">selected()</a> method). This only applies to a single-selection calendar.</p> <dl class="deprecated"><dt><b><a class="el" href="deprecated.html#_deprecated000021">Deprecated:</a></b></dt><dd>listen to the <a class="el" href="classWt_1_1WCalendar.html#a51ad8160985f49f5ff0e726df8103921" title="Signal emitted when the user clicks a date.">clicked()</a> signal if you want to react to a single click, or <a class="el" href="classWt_1_1WCalendar.html#a8675afd38f2b773d0945af207d7639f9" title="Signal emitted when the user double-clicks a date.">activated()</a> signal if you want to react to a double click.</dd></dl> <dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="classWt_1_1WCalendar.html#a075e2a4c5c39f8b6144865cfd0ae07f0" title="Configures single or multiple selection mode ( deprecated ).">setMultipleSelection()</a> </dd></dl> </div> </div> <a class="anchor" id="a6a45200e082a7178d7060bdb9f960a17"></a><!-- doxytag: member="Wt::WCalendar::setTop" ref="a6a45200e082a7178d7060bdb9f960a17" args="(const WDate &top)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void Wt::WCalendar::setTop </td> <td>(</td> <td class="paramtype">const <a class="el" href="classWt_1_1WDate.html">WDate</a> & </td> <td class="paramname"><em>top</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Sets the top of the valid date range. </p> <p>The default is a null date constructed using WDate(). </p> </div> </div> </div> <!-- window showing the filter options --> <div id="MSearchSelectWindow" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()" onkeydown="return searchBox.OnSearchSelectKey(event)"> <a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark"> </span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark"> </span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark"> </span>Namespaces</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark"> </span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark"> </span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark"> </span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark"> </span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark"> </span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark"> </span>Enumerator</a></div> <!-- iframe showing the search results (closed by default) --> <div id="MSearchResultsWindow"> <iframe src="javascript:void(0)" frameborder="0" name="MSearchResults" id="MSearchResults"> </iframe> </div> <hr size="1"><address style="text-align: right; margin: 3px"><small> Generated on Thu Nov 1 2012 for <a href="http://www.webtoolkit.eu/wt">the C++ Web Toolkit (Wt)</a> by <a href="http://www.doxygen.org/index.html"><img src="doxygen.png" alt="doxygen" border="0" style="vertical-align: middle; display: inline-block; height: 2em"></a> 1.7.5.1</small></address> </body> </html>