pv.Mark.html 45 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  2. "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  3. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
  4. <head>
  5. <meta http-equiv="content-type" content="text/html; charset=utf-8" />
  6. <meta name="generator" content="JsDoc Toolkit" />
  7. <title>JsDoc Reference - pv.Mark</title>
  8. <style type="text/css">
  9. /* default.css */
  10. body
  11. {
  12. font: 12px "Lucida Grande", Tahoma, Arial, Helvetica, sans-serif;
  13. width: 800px;
  14. }
  15. .header
  16. {
  17. clear: both;
  18. background-color: #ccc;
  19. padding: 8px;
  20. }
  21. h1
  22. {
  23. font-size: 150%;
  24. font-weight: bold;
  25. padding: 0;
  26. margin: 1em 0 0 .3em;
  27. }
  28. hr
  29. {
  30. border: none 0;
  31. border-top: 1px solid #7F8FB1;
  32. height: 1px;
  33. }
  34. pre.code
  35. {
  36. display: block;
  37. padding: 8px;
  38. border: 1px dashed #ccc;
  39. }
  40. #index
  41. {
  42. margin-top: 24px;
  43. float: left;
  44. width: 160px;
  45. position: absolute;
  46. left: 8px;
  47. background-color: #F3F3F3;
  48. padding: 8px;
  49. }
  50. #content
  51. {
  52. margin-left: 190px;
  53. width: 600px;
  54. }
  55. .classList
  56. {
  57. list-style-type: none;
  58. padding: 0;
  59. margin: 0 0 0 8px;
  60. font-family: arial, sans-serif;
  61. font-size: 1em;
  62. overflow: auto;
  63. }
  64. .classList li
  65. {
  66. padding: 0;
  67. margin: 0 0 8px 0;
  68. }
  69. .summaryTable { width: 100%; }
  70. h1.classTitle
  71. {
  72. font-size:170%;
  73. line-height:130%;
  74. }
  75. h2 { font-size: 110%; }
  76. caption, div.sectionTitle
  77. {
  78. background-color: #7F8FB1;
  79. color: #fff;
  80. font-size:130%;
  81. text-align: left;
  82. padding: 2px 6px 2px 6px;
  83. border: 1px #7F8FB1 solid;
  84. }
  85. div.sectionTitle { margin-bottom: 8px; }
  86. .summaryTable thead { display: none; }
  87. .summaryTable td
  88. {
  89. vertical-align: top;
  90. padding: 4px;
  91. border-bottom: 1px #7F8FB1 solid;
  92. border-right: 1px #7F8FB1 solid;
  93. }
  94. /*col#summaryAttributes {}*/
  95. .summaryTable td.attributes
  96. {
  97. border-left: 1px #7F8FB1 solid;
  98. width: 140px;
  99. text-align: right;
  100. }
  101. td.attributes, .fixedFont
  102. {
  103. line-height: 15px;
  104. color: #002EBE;
  105. font-family: "Courier New",Courier,monospace;
  106. font-size: 13px;
  107. }
  108. .summaryTable td.nameDescription
  109. {
  110. text-align: left;
  111. font-size: 13px;
  112. line-height: 15px;
  113. }
  114. .summaryTable td.nameDescription, .description
  115. {
  116. line-height: 15px;
  117. padding: 4px;
  118. padding-left: 4px;
  119. }
  120. pre
  121. {
  122. border-left: solid 10px #ddd;
  123. padding-left: 1.5em;
  124. }
  125. .summaryTable { margin-bottom: 8px; }
  126. ul.inheritsList
  127. {
  128. list-style: square;
  129. margin-left: 20px;
  130. padding-left: 0;
  131. }
  132. .detailList {
  133. margin-left: 20px;
  134. line-height: 15px;
  135. }
  136. .detailList dt { margin-left: 20px; }
  137. .detailList .heading
  138. {
  139. font-weight: bold;
  140. padding-bottom: 6px;
  141. margin-left: 0;
  142. }
  143. .light, td.attributes, .light a:link, .light a:visited
  144. {
  145. color: #777;
  146. font-style: italic;
  147. }
  148. .fineprint
  149. {
  150. text-align: right;
  151. font-size: 10px;
  152. }
  153. </style>
  154. </head>
  155. <body>
  156. <!-- ============================== header ================================= -->
  157. <!-- begin static/header.html -->
  158. <div id="header">
  159. </div>
  160. <!-- end static/header.html -->
  161. <!-- ============================== classes index ============================ -->
  162. <div id="index">
  163. <!-- begin publish.classesIndex -->
  164. <div align="center"><a href="../index.html">Class Index</a>
  165. | <a href="../files.html">File Index</a></div>
  166. <hr />
  167. <h2>Classes</h2>
  168. <ul class="classList">
  169. <li><i><a href="../symbols/_global_.html">_global_</a></i></li>
  170. <li><a href="../symbols/Array.html">Array</a></li>
  171. <li><a href="../symbols/Date.html">Date</a></li>
  172. <li><a href="../symbols/pv.html">pv</a></li>
  173. <li><a href="../symbols/pv.Anchor.html">pv.Anchor</a></li>
  174. <li><a href="../symbols/pv.Area.html">pv.Area</a></li>
  175. <li><a href="../symbols/pv.Bar.html">pv.Bar</a></li>
  176. <li><a href="../symbols/pv.Color.html">pv.Color</a></li>
  177. <li><a href="../symbols/pv.Color.Hsl.html">pv.Color.Hsl</a></li>
  178. <li><a href="../symbols/pv.Color.Rgb.html">pv.Color.Rgb</a></li>
  179. <li><a href="../symbols/pv.Colors.html">pv.Colors</a></li>
  180. <li><a href="../symbols/pv.Dot.html">pv.Dot</a></li>
  181. <li><a href="../symbols/pv.Flatten.html">pv.Flatten</a></li>
  182. <li><a href="../symbols/pv.Image.html">pv.Image</a></li>
  183. <li><a href="../symbols/pv.Label.html">pv.Label</a></li>
  184. <li><a href="../symbols/pv.Layout.grid.html">pv.Layout.grid</a></li>
  185. <li><a href="../symbols/pv.Layout.icicle.html">pv.Layout.icicle</a></li>
  186. <li><a href="../symbols/pv.Layout.stack.html">pv.Layout.stack</a></li>
  187. <li><a href="../symbols/pv.Layout.sunburst.html">pv.Layout.sunburst</a></li>
  188. <li><a href="../symbols/pv.Layout.treemap.html">pv.Layout.treemap</a></li>
  189. <li><a href="../symbols/pv.Line.html">pv.Line</a></li>
  190. <li><a href="../symbols/pv.Mark.html">pv.Mark</a></li>
  191. <li><a href="../symbols/pv.Nest.html">pv.Nest</a></li>
  192. <li><a href="../symbols/pv.ns.html">pv.ns</a></li>
  193. <li><a href="../symbols/pv.Panel.html">pv.Panel</a></li>
  194. <li><a href="../symbols/pv.Rule.html">pv.Rule</a></li>
  195. <li><a href="../symbols/pv.Scale.linear.html">pv.Scale.linear</a></li>
  196. <li><a href="../symbols/pv.Scale.log.html">pv.Scale.log</a></li>
  197. <li><a href="../symbols/pv.Scale.ordinal.html">pv.Scale.ordinal</a></li>
  198. <li><a href="../symbols/pv.Tree.html">pv.Tree</a></li>
  199. <li><a href="../symbols/pv.Vector.html">pv.Vector</a></li>
  200. <li><a href="../symbols/pv.version.html">pv.version</a></li>
  201. <li><a href="../symbols/pv.Wedge.html">pv.Wedge</a></li>
  202. </ul>
  203. <hr />
  204. <!-- end publish.classesIndex -->
  205. </div>
  206. <div id="content">
  207. <!-- ============================== class title ============================ -->
  208. <h1 class="classTitle">
  209. Class pv.Mark
  210. </h1>
  211. <!-- ============================== class summary ========================== -->
  212. <p class="description">
  213. Represents a data-driven graphical mark. The <tt>Mark</tt> class is
  214. the base class for all graphical marks in Protovis; it does not provide any
  215. specific rendering functionality, but together with Panel establishes
  216. the core framework.
  217. <p>Concrete mark types include familiar visual elements such as bars, lines
  218. and labels. Although a bar mark may be used to construct a bar chart, marks
  219. know nothing about charts; it is only through their specification and
  220. composition that charts are produced. These building blocks permit many
  221. combinatorial possibilities.
  222. <p>Marks are associated with <b>data</b>: a mark is generated once per
  223. associated datum, mapping the datum to visual <b>properties</b> such as
  224. position and color. Thus, a single mark specification represents a set of
  225. visual elements that share the same data and visual encoding. The type of
  226. mark defines the names of properties and their meaning. A property may be
  227. static, ignoring the associated datum and returning a constant; or, it may be
  228. dynamic, derived from the associated datum or index. Such dynamic encodings
  229. can be specified succinctly using anonymous functions. Special properties
  230. called event handlers can be registered to add interactivity.
  231. <p>Protovis uses <b>inheritance</b> to simplify the specification of related
  232. marks: a new mark can be derived from an existing mark, inheriting its
  233. properties. The new mark can then override properties to specify new
  234. behavior, potentially in terms of the old behavior. In this way, the old mark
  235. serves as the <b>prototype</b> for the new mark. Most mark types share the
  236. same basic properties for consistency and to facilitate inheritance.
  237. <p>The prioritization of redundant properties is as follows:<ol>
  238. <li>If the <tt>width</tt> property is not specified (i.e., null), its value
  239. is the width of the parent panel, minus this mark's left and right margins;
  240. the left and right margins are zero if not specified.
  241. <li>Otherwise, if the <tt>right</tt> margin is not specified, its value is
  242. the width of the parent panel, minus this mark's width and left margin; the
  243. left margin is zero if not specified.
  244. <li>Otherwise, if the <tt>left</tt> property is not specified, its value is
  245. the width of the parent panel, minus this mark's width and the right margin.
  246. </ol>This prioritization is then duplicated for the <tt>height</tt>,
  247. <tt>bottom</tt> and <tt>top</tt> properties, respectively.
  248. <p>While most properties are <i>variable</i>, some mark types, such as lines
  249. and areas, generate a single visual element rather than a distinct visual
  250. element per datum. With these marks, some properties may be <b>fixed</b>.
  251. Fixed properties can vary per mark, but not <i>per datum</i>! These
  252. properties are evaluated solely for the first (0-index) datum, and typically
  253. are specified as a constant. However, it is valid to use a function if the
  254. property varies between panels or is dynamically generated.
  255. <p>See also the <a href="../../api/">Protovis guide</a>.
  256. <br /><i>Defined in: </i> <a href="../symbols/src/mark_Mark.js.html">Mark.js</a>.
  257. </p>
  258. <!-- ============================== constructor summary ==================== -->
  259. <table class="summaryTable" cellspacing="0" summary="A summary of the constructor documented in the class pv.Mark.">
  260. <caption>Class Summary</caption>
  261. <thead>
  262. <tr>
  263. <th scope="col">Constructor Attributes</th>
  264. <th scope="col">Constructor Name and Description</th>
  265. </tr>
  266. </thead>
  267. <tbody>
  268. <tr>
  269. <td class="attributes">&nbsp;</td>
  270. <td class="nameDescription" >
  271. <div class="fixedFont">
  272. <b><a href="../symbols/pv.Mark.html#constructor">pv.Mark</a></b>()
  273. </div>
  274. <div class="description">Constructs a new mark with default properties.</div>
  275. </td>
  276. </tr>
  277. </tbody>
  278. </table>
  279. <!-- ============================== properties summary ===================== -->
  280. <table class="summaryTable" cellspacing="0" summary="A summary of the fields documented in the class pv.Mark.">
  281. <caption>Field Summary</caption>
  282. <thead>
  283. <tr>
  284. <th scope="col">Field Attributes</th>
  285. <th scope="col">Field Name and Description</th>
  286. </tr>
  287. </thead>
  288. <tbody>
  289. <tr>
  290. <td class="attributes">&nbsp;</td>
  291. <td class="nameDescription">
  292. <div class="fixedFont">
  293. <b><a href="../symbols/pv.Mark.html#bottom">bottom</a></b>
  294. </div>
  295. <div class="description">The bottom margin; the distance, in pixels, between the bottom edge of the
  296. enclosing panel and the bottom edge of this mark.</div>
  297. </td>
  298. </tr>
  299. <tr>
  300. <td class="attributes">&nbsp;</td>
  301. <td class="nameDescription">
  302. <div class="fixedFont">
  303. <b><a href="../symbols/pv.Mark.html#childIndex">childIndex</a></b>
  304. </div>
  305. <div class="description">The child index.</div>
  306. </td>
  307. </tr>
  308. <tr>
  309. <td class="attributes">&nbsp;</td>
  310. <td class="nameDescription">
  311. <div class="fixedFont">
  312. <b><a href="../symbols/pv.Mark.html#cursor">cursor</a></b>
  313. </div>
  314. <div class="description">The cursor property; corresponds to the CSS cursor property.</div>
  315. </td>
  316. </tr>
  317. <tr>
  318. <td class="attributes">&nbsp;</td>
  319. <td class="nameDescription">
  320. <div class="fixedFont">
  321. <b><a href="../symbols/pv.Mark.html#data">data</a></b>
  322. </div>
  323. <div class="description">The data property; an array of objects.</div>
  324. </td>
  325. </tr>
  326. <tr>
  327. <td class="attributes">&nbsp;</td>
  328. <td class="nameDescription">
  329. <div class="fixedFont">
  330. <b><a href="../symbols/pv.Mark.html#defaults">defaults</a></b>
  331. </div>
  332. <div class="description">Default properties for all mark types.</div>
  333. </td>
  334. </tr>
  335. <tr>
  336. <td class="attributes">&nbsp;</td>
  337. <td class="nameDescription">
  338. <div class="fixedFont">
  339. <b><a href="../symbols/pv.Mark.html#index">index</a></b>
  340. </div>
  341. <div class="description">The mark index.</div>
  342. </td>
  343. </tr>
  344. <tr>
  345. <td class="attributes">&nbsp;</td>
  346. <td class="nameDescription">
  347. <div class="fixedFont">
  348. <b><a href="../symbols/pv.Mark.html#left">left</a></b>
  349. </div>
  350. <div class="description">The left margin; the distance, in pixels, between the left edge of the
  351. enclosing panel and the left edge of this mark.</div>
  352. </td>
  353. </tr>
  354. <tr>
  355. <td class="attributes">&nbsp;</td>
  356. <td class="nameDescription">
  357. <div class="fixedFont">
  358. <b><a href="../symbols/pv.Mark.html#parent">parent</a></b>
  359. </div>
  360. <div class="description">The enclosing parent panel.</div>
  361. </td>
  362. </tr>
  363. <tr>
  364. <td class="attributes">&nbsp;</td>
  365. <td class="nameDescription">
  366. <div class="fixedFont">
  367. <b><a href="../symbols/pv.Mark.html#proto">proto</a></b>
  368. </div>
  369. <div class="description">The mark prototype, possibly undefined, from which to inherit property
  370. functions.</div>
  371. </td>
  372. </tr>
  373. <tr>
  374. <td class="attributes">&nbsp;</td>
  375. <td class="nameDescription">
  376. <div class="fixedFont">
  377. <b><a href="../symbols/pv.Mark.html#reverse">reverse</a></b>
  378. </div>
  379. <div class="description">The reverse property; a boolean determining whether marks are ordered from
  380. front-to-back or back-to-front.</div>
  381. </td>
  382. </tr>
  383. <tr>
  384. <td class="attributes">&nbsp;</td>
  385. <td class="nameDescription">
  386. <div class="fixedFont">
  387. <b><a href="../symbols/pv.Mark.html#right">right</a></b>
  388. </div>
  389. <div class="description">The right margin; the distance, in pixels, between the right edge of the
  390. enclosing panel and the right edge of this mark.</div>
  391. </td>
  392. </tr>
  393. <tr>
  394. <td class="attributes">&nbsp;</td>
  395. <td class="nameDescription">
  396. <div class="fixedFont">
  397. <b><a href="../symbols/pv.Mark.html#root">root</a></b>
  398. </div>
  399. <div class="description">The root parent panel.</div>
  400. </td>
  401. </tr>
  402. <tr>
  403. <td class="attributes">&nbsp;</td>
  404. <td class="nameDescription">
  405. <div class="fixedFont">
  406. <b><a href="../symbols/pv.Mark.html#scene">scene</a></b>
  407. </div>
  408. <div class="description">The scene graph.</div>
  409. </td>
  410. </tr>
  411. <tr>
  412. <td class="attributes">&nbsp;</td>
  413. <td class="nameDescription">
  414. <div class="fixedFont">
  415. <b><a href="../symbols/pv.Mark.html#title">title</a></b>
  416. </div>
  417. <div class="description">The title property; corresponds to the HTML/SVG title property, allowing the
  418. general of simple plain text tooltips.</div>
  419. </td>
  420. </tr>
  421. <tr>
  422. <td class="attributes">&nbsp;</td>
  423. <td class="nameDescription">
  424. <div class="fixedFont">
  425. <b><a href="../symbols/pv.Mark.html#top">top</a></b>
  426. </div>
  427. <div class="description">The top margin; the distance, in pixels, between the top edge of the
  428. enclosing panel and the top edge of this mark.</div>
  429. </td>
  430. </tr>
  431. <tr>
  432. <td class="attributes">&nbsp;</td>
  433. <td class="nameDescription">
  434. <div class="fixedFont">
  435. <b><a href="../symbols/pv.Mark.html#type">type</a></b>
  436. </div>
  437. <div class="description">The mark type; a lower camelCase name.</div>
  438. </td>
  439. </tr>
  440. <tr>
  441. <td class="attributes">&nbsp;</td>
  442. <td class="nameDescription">
  443. <div class="fixedFont">
  444. <b><a href="../symbols/pv.Mark.html#visible">visible</a></b>
  445. </div>
  446. <div class="description">The visible property; a boolean determining whether or not the mark instance
  447. is visible.</div>
  448. </td>
  449. </tr>
  450. </tbody>
  451. </table>
  452. <!-- ============================== methods summary ======================== -->
  453. <table class="summaryTable" cellspacing="0" summary="A summary of the methods documented in the class pv.Mark.">
  454. <caption>Method Summary</caption>
  455. <thead>
  456. <tr>
  457. <th scope="col">Method Attributes</th>
  458. <th scope="col">Method Name and Description</th>
  459. </tr>
  460. </thead>
  461. <tbody>
  462. <tr>
  463. <td class="attributes">&nbsp;</td>
  464. <td class="nameDescription">
  465. <div class="fixedFont"><b><a href="../symbols/pv.Mark.html#add">add</a></b>(type)
  466. </div>
  467. <div class="description">Adds a new mark of the specified type to the enclosing parent panel, whilst
  468. simultaneously setting the prototype of the new mark to be this mark.</div>
  469. </td>
  470. </tr>
  471. <tr>
  472. <td class="attributes">&nbsp;</td>
  473. <td class="nameDescription">
  474. <div class="fixedFont"><b><a href="../symbols/pv.Mark.html#anchor">anchor</a></b>(name)
  475. </div>
  476. <div class="description">Returns an anchor with the specified name.</div>
  477. </td>
  478. </tr>
  479. <tr>
  480. <td class="attributes">&nbsp;</td>
  481. <td class="nameDescription">
  482. <div class="fixedFont"><b><a href="../symbols/pv.Mark.html#anchorTarget">anchorTarget</a></b>()
  483. </div>
  484. <div class="description">Returns the anchor target of this mark, if it is derived from an anchor;
  485. otherwise returns null.</div>
  486. </td>
  487. </tr>
  488. <tr>
  489. <td class="attributes">&nbsp;</td>
  490. <td class="nameDescription">
  491. <div class="fixedFont"><b><a href="../symbols/pv.Mark.html#cousin">cousin</a></b>()
  492. </div>
  493. <div class="description">Returns the current instance in the scene graph of this mark, in the previous
  494. instance of the enclosing parent panel.</div>
  495. </td>
  496. </tr>
  497. <tr>
  498. <td class="attributes">&nbsp;</td>
  499. <td class="nameDescription">
  500. <div class="fixedFont"><b><a href="../symbols/pv.Mark.html#def">def</a></b>(name, value)
  501. </div>
  502. <div class="description">Defines a local variable on this mark.</div>
  503. </td>
  504. </tr>
  505. <tr>
  506. <td class="attributes">&nbsp;</td>
  507. <td class="nameDescription">
  508. <div class="fixedFont"><b><a href="../symbols/pv.Mark.html#event">event</a></b>(type, handler)
  509. </div>
  510. <div class="description">Registers an event handler for the specified event type with this mark.</div>
  511. </td>
  512. </tr>
  513. <tr>
  514. <td class="attributes">&nbsp;</td>
  515. <td class="nameDescription">
  516. <div class="fixedFont"><b><a href="../symbols/pv.Mark.html#extend">extend</a></b>(proto)
  517. </div>
  518. <div class="description">Sets the prototype of this mark to the specified mark.</div>
  519. </td>
  520. </tr>
  521. <tr>
  522. <td class="attributes">&nbsp;</td>
  523. <td class="nameDescription">
  524. <div class="fixedFont"><b><a href="../symbols/pv.Mark.html#first">first</a></b>()
  525. </div>
  526. <div class="description">Returns the first instance of this mark in the scene graph.</div>
  527. </td>
  528. </tr>
  529. <tr>
  530. <td class="attributes">&nbsp;</td>
  531. <td class="nameDescription">
  532. <div class="fixedFont"><b><a href="../symbols/pv.Mark.html#last">last</a></b>()
  533. </div>
  534. <div class="description">Returns the last instance of this mark in the scene graph.</div>
  535. </td>
  536. </tr>
  537. <tr>
  538. <td class="attributes">&nbsp;</td>
  539. <td class="nameDescription">
  540. <div class="fixedFont"><b><a href="../symbols/pv.Mark.html#mouse">mouse</a></b>()
  541. </div>
  542. <div class="description">Returns the current location of the mouse (cursor) relative to this mark's
  543. parent.</div>
  544. </td>
  545. </tr>
  546. <tr>
  547. <td class="attributes">&nbsp;</td>
  548. <td class="nameDescription">
  549. <div class="fixedFont"><b><a href="../symbols/pv.Mark.html#render">render</a></b>()
  550. </div>
  551. <div class="description">Renders this mark, including recursively rendering all child marks if this is
  552. a panel.</div>
  553. </td>
  554. </tr>
  555. <tr>
  556. <td class="attributes">&nbsp;</td>
  557. <td class="nameDescription">
  558. <div class="fixedFont"><b><a href="../symbols/pv.Mark.html#sibling">sibling</a></b>()
  559. </div>
  560. <div class="description">Returns the previous instance of this mark in the scene graph, or null if
  561. this is the first instance.</div>
  562. </td>
  563. </tr>
  564. </tbody>
  565. </table>
  566. <!-- ============================== events summary ======================== -->
  567. <!-- ============================== constructor details ==================== -->
  568. <div class="details"><a name="constructor"> </a>
  569. <div class="sectionTitle">
  570. Class Detail
  571. </div>
  572. <div class="fixedFont">
  573. <b>pv.Mark</b>()
  574. </div>
  575. <div class="description">
  576. Constructs a new mark with default properties. Marks, with the exception of
  577. the root panel, are not typically constructed directly; instead, they are
  578. added to a panel or an existing mark via <a href="../symbols/pv.Mark.html#add">pv.Mark#add</a>.
  579. </div>
  580. </div>
  581. <!-- ============================== field details ========================== -->
  582. <div class="sectionTitle">
  583. Field Detail
  584. </div>
  585. <a name="bottom"> </a>
  586. <div class="fixedFont">
  587. <span class="light">{number}</span>
  588. <b>bottom</b>
  589. </div>
  590. <div class="description">
  591. The bottom margin; the distance, in pixels, between the bottom edge of the
  592. enclosing panel and the bottom edge of this mark. Note that in some cases
  593. this property may be redundant with the top property, or with the conjunction
  594. of top and height.
  595. </div>
  596. <hr />
  597. <a name="childIndex"> </a>
  598. <div class="fixedFont">
  599. <span class="light">{number}</span>
  600. <b>childIndex</b>
  601. </div>
  602. <div class="description">
  603. The child index. -1 if the enclosing parent panel is null; otherwise, the
  604. zero-based index of this mark into the parent panel's <tt>children</tt> array.
  605. </div>
  606. <hr />
  607. <a name="cursor"> </a>
  608. <div class="fixedFont">
  609. <span class="light">{string}</span>
  610. <b>cursor</b>
  611. </div>
  612. <div class="description">
  613. The cursor property; corresponds to the CSS cursor property. This is
  614. typically used in conjunction with event handlers to indicate interactivity.
  615. </div>
  616. <dl class="detailList">
  617. <dt class="heading">See:</dt>
  618. <dd><a href="http://www.w3.org/TR/CSS2/ui.html#propdef-cursor">CSS2 cursor</a></dd>
  619. </dl>
  620. <hr />
  621. <a name="data"> </a>
  622. <div class="fixedFont">
  623. <span class="light">{array}</span>
  624. <b>data</b>
  625. </div>
  626. <div class="description">
  627. The data property; an array of objects. The size of the array determines the
  628. number of marks that will be instantiated; each element in the array will be
  629. passed to property functions to compute the property values. Typically, the
  630. data property is specified as a constant array, such as
  631. <pre>m.data([1, 2, 3, 4, 5]);</pre>
  632. However, it is perfectly acceptable to define the data property as a
  633. function. This function might compute the data dynamically, allowing
  634. different data to be used per enclosing panel. For instance, in the stacked
  635. area graph example (see <a href="#scene">#scene</a>), the data function on the area mark
  636. dereferences each series.
  637. </div>
  638. <hr />
  639. <a name="defaults"> </a>
  640. <div class="fixedFont">
  641. <span class="light">{<a href="../symbols/pv.Mark.html">pv.Mark</a>}</span>
  642. <b>defaults</b>
  643. </div>
  644. <div class="description">
  645. Default properties for all mark types. By default, the data array is the
  646. parent data as a single-element array; if the data property is not specified,
  647. this causes each mark to be instantiated as a singleton with the parents
  648. datum. The visible property is true by default, and the reverse property is
  649. false.
  650. </div>
  651. <hr />
  652. <a name="index"> </a>
  653. <div class="fixedFont">
  654. <span class="light">{number}</span>
  655. <b>index</b>
  656. </div>
  657. <div class="description">
  658. The mark index. The value of this field depends on which instance (i.e.,
  659. which element of the data array) is currently being evaluated. During the
  660. build phase, the index is incremented over each datum; when handling events,
  661. the index is set to the instance that triggered the event.
  662. </div>
  663. <hr />
  664. <a name="left"> </a>
  665. <div class="fixedFont">
  666. <span class="light">{number}</span>
  667. <b>left</b>
  668. </div>
  669. <div class="description">
  670. The left margin; the distance, in pixels, between the left edge of the
  671. enclosing panel and the left edge of this mark. Note that in some cases this
  672. property may be redundant with the right property, or with the conjunction of
  673. right and width.
  674. </div>
  675. <hr />
  676. <a name="parent"> </a>
  677. <div class="fixedFont">
  678. <span class="light">{<a href="../symbols/pv.Panel.html">pv.Panel</a>}</span>
  679. <b>parent</b>
  680. </div>
  681. <div class="description">
  682. The enclosing parent panel. The parent panel is generally undefined only for
  683. the root panel; however, it is possible to create "offscreen" marks that are
  684. used only for inheritance purposes.
  685. </div>
  686. <hr />
  687. <a name="proto"> </a>
  688. <div class="fixedFont">
  689. <span class="light">{<a href="../symbols/pv.Mark.html">pv.Mark</a>}</span>
  690. <b>proto</b>
  691. </div>
  692. <div class="description">
  693. The mark prototype, possibly undefined, from which to inherit property
  694. functions. The mark prototype is not necessarily of the same type as this
  695. mark. Any properties defined on this mark will override properties inherited
  696. either from the prototype or from the type-specific defaults.
  697. </div>
  698. <hr />
  699. <a name="reverse"> </a>
  700. <div class="fixedFont">
  701. <span class="light">{boolean}</span>
  702. <b>reverse</b>
  703. </div>
  704. <div class="description">
  705. The reverse property; a boolean determining whether marks are ordered from
  706. front-to-back or back-to-front. SVG does not support explicit z-ordering;
  707. shapes are rendered in the order they appear. Thus, by default, marks are
  708. rendered in data order. Setting the reverse property to false reverses the
  709. order in which they are rendered; however, the properties are still evaluated
  710. (i.e., built) in forward order.
  711. </div>
  712. <hr />
  713. <a name="right"> </a>
  714. <div class="fixedFont">
  715. <span class="light">{number}</span>
  716. <b>right</b>
  717. </div>
  718. <div class="description">
  719. The right margin; the distance, in pixels, between the right edge of the
  720. enclosing panel and the right edge of this mark. Note that in some cases this
  721. property may be redundant with the left property, or with the conjunction of
  722. left and width.
  723. </div>
  724. <hr />
  725. <a name="root"> </a>
  726. <div class="fixedFont">
  727. <span class="light">{<a href="../symbols/pv.Panel.html">pv.Panel</a>}</span>
  728. <b>root</b>
  729. </div>
  730. <div class="description">
  731. The root parent panel. This may be undefined for "offscreen" marks that are
  732. created for inheritance purposes only.
  733. </div>
  734. <hr />
  735. <a name="scene"> </a>
  736. <div class="fixedFont">
  737. <b>scene</b>
  738. </div>
  739. <div class="description">
  740. The scene graph. The scene graph is an array of objects; each object (or
  741. "node") corresponds to an instance of this mark and an element in the data
  742. array. The scene graph can be traversed to lookup previously-evaluated
  743. properties.
  744. <p>For instance, consider a stacked area chart. The bottom property of the
  745. area can be defined using the <i>cousin</i> instance, which is the current
  746. area instance in the previous instantiation of the parent panel. In this
  747. sample code,
  748. <pre>new pv.Panel()
  749. .width(150).height(150)
  750. .add(pv.Panel)
  751. .data([[1, 1.2, 1.7, 1.5, 1.7],
  752. [.5, 1, .8, 1.1, 1.3],
  753. [.2, .5, .8, .9, 1]])
  754. .add(pv.Area)
  755. .data(function(d) d)
  756. .bottom(function() {
  757. var c = this.cousin();
  758. return c ? (c.bottom + c.height) : 0;
  759. })
  760. .height(function(d) d * 40)
  761. .left(function() this.index * 35)
  762. .root.render();</pre>
  763. the bottom property is computed based on the upper edge of the corresponding
  764. datum in the previous series. The area's parent panel is instantiated once
  765. per series, so the cousin refers to the previous (below) area mark. (Note
  766. that the position of the upper edge is not the same as the top property,
  767. which refers to the top margin: the distance from the top edge of the panel
  768. to the top edge of the mark.)
  769. </div>
  770. <dl class="detailList">
  771. <dt class="heading">See:</dt>
  772. <dd><a href="#first">#first</a></dd>
  773. <dd><a href="#last">#last</a></dd>
  774. <dd><a href="#sibling">#sibling</a></dd>
  775. <dd><a href="#cousin">#cousin</a></dd>
  776. </dl>
  777. <hr />
  778. <a name="title"> </a>
  779. <div class="fixedFont">
  780. <span class="light">{string}</span>
  781. <b>title</b>
  782. </div>
  783. <div class="description">
  784. The title property; corresponds to the HTML/SVG title property, allowing the
  785. general of simple plain text tooltips.
  786. </div>
  787. <hr />
  788. <a name="top"> </a>
  789. <div class="fixedFont">
  790. <span class="light">{number}</span>
  791. <b>top</b>
  792. </div>
  793. <div class="description">
  794. The top margin; the distance, in pixels, between the top edge of the
  795. enclosing panel and the top edge of this mark. Note that in some cases this
  796. property may be redundant with the bottom property, or with the conjunction
  797. of bottom and height.
  798. </div>
  799. <hr />
  800. <a name="type"> </a>
  801. <div class="fixedFont">
  802. <span class="light">{string}</span>
  803. <b>type</b>
  804. </div>
  805. <div class="description">
  806. The mark type; a lower camelCase name. The type name controls rendering
  807. behavior, and unless the rendering engine is extended, must be one of the
  808. built-in concrete mark types: area, bar, dot, image, label, line, panel,
  809. rule, or wedge.
  810. </div>
  811. <hr />
  812. <a name="visible"> </a>
  813. <div class="fixedFont">
  814. <span class="light">{boolean}</span>
  815. <b>visible</b>
  816. </div>
  817. <div class="description">
  818. The visible property; a boolean determining whether or not the mark instance
  819. is visible. If a mark instance is not visible, its other properties will not
  820. be evaluated. Similarly, for panels no child marks will be rendered.
  821. </div>
  822. <!-- ============================== method details ========================= -->
  823. <div class="sectionTitle">
  824. Method Detail
  825. </div>
  826. <a name="add"> </a>
  827. <div class="fixedFont">
  828. <span class="light">{<a href="../symbols/pv.Mark.html">pv.Mark</a>}</span>
  829. <b>add</b>(type)
  830. </div>
  831. <div class="description">
  832. Adds a new mark of the specified type to the enclosing parent panel, whilst
  833. simultaneously setting the prototype of the new mark to be this mark.
  834. </div>
  835. <dl class="detailList">
  836. <dt class="heading">Parameters:</dt>
  837. <dt>
  838. <span class="light fixedFont">{function}</span> <b>type</b>
  839. </dt>
  840. <dd>the type of mark to add; a constructor, such as
  841. <tt>pv.Bar</tt>.</dd>
  842. </dl>
  843. <dl class="detailList">
  844. <dt class="heading">Returns:</dt>
  845. <dd><span class="light fixedFont">{<a href="../symbols/pv.Mark.html">pv.Mark</a>}</span> the new mark.</dd>
  846. </dl>
  847. <dl class="detailList">
  848. <dt class="heading">See:</dt>
  849. <dd><a href="#extend">#extend</a></dd>
  850. </dl>
  851. <hr />
  852. <a name="anchor"> </a>
  853. <div class="fixedFont">
  854. <span class="light">{<a href="../symbols/pv.Anchor.html">pv.Anchor</a>}</span>
  855. <b>anchor</b>(name)
  856. </div>
  857. <div class="description">
  858. Returns an anchor with the specified name. While anchor names are typically
  859. constants, the anchor name is a true property, which means you can specify a
  860. function to compute the anchor name dynamically. See the
  861. <a href="../symbols/pv.Anchor.html#name">pv.Anchor#name</a> property for details.
  862. </div>
  863. <dl class="detailList">
  864. <dt class="heading">Parameters:</dt>
  865. <dt>
  866. <span class="light fixedFont">{string}</span> <b>name</b>
  867. </dt>
  868. <dd>the anchor name; either a string or a property function.</dd>
  869. </dl>
  870. <dl class="detailList">
  871. <dt class="heading">Returns:</dt>
  872. <dd><span class="light fixedFont">{<a href="../symbols/pv.Anchor.html">pv.Anchor</a>}</span> the new anchor.</dd>
  873. </dl>
  874. <hr />
  875. <a name="anchorTarget"> </a>
  876. <div class="fixedFont">
  877. <span class="light">{<a href="../symbols/pv.Mark.html">pv.Mark</a>}</span>
  878. <b>anchorTarget</b>()
  879. </div>
  880. <div class="description">
  881. Returns the anchor target of this mark, if it is derived from an anchor;
  882. otherwise returns null. For example, if a label is derived from a bar anchor,
  883. <pre>bar.anchor("top").add(pv.Label);</pre>
  884. then property functions on the label can refer to the bar via the
  885. <tt>anchorTarget</tt> method. This method is also useful for mark types
  886. defining properties on custom anchors.
  887. </div>
  888. <dl class="detailList">
  889. <dt class="heading">Returns:</dt>
  890. <dd><span class="light fixedFont">{<a href="../symbols/pv.Mark.html">pv.Mark</a>}</span> the anchor target of this mark; possibly null.</dd>
  891. </dl>
  892. <hr />
  893. <a name="cousin"> </a>
  894. <div class="fixedFont">
  895. <b>cousin</b>()
  896. </div>
  897. <div class="description">
  898. Returns the current instance in the scene graph of this mark, in the previous
  899. instance of the enclosing parent panel. May return null if this instance
  900. could not be found. See the <a href="../symbols/pv.Layout.stack.html">pv.Layout.stack</a> function for an example
  901. property function using cousin.
  902. </div>
  903. <dl class="detailList">
  904. <dt class="heading">Returns:</dt>
  905. <dd>a node in the scene graph, or null.</dd>
  906. </dl>
  907. <dl class="detailList">
  908. <dt class="heading">See:</dt>
  909. <dd><a href="../symbols/pv.Layout.stack.html">pv.Layout.stack</a></dd>
  910. </dl>
  911. <hr />
  912. <a name="def"> </a>
  913. <div class="fixedFont">
  914. <b>def</b>(name, value)
  915. </div>
  916. <div class="description">
  917. Defines a local variable on this mark. Local variables are initialized once
  918. per mark (i.e., per parent panel instance), and can be used to store local
  919. state for the mark. Here are a few reasons you might want to use
  920. <tt>def</tt>:
  921. <p>1. To store local state. For example, say you were visualizing employment
  922. statistics, and your root panel had an array of occupations. In a child
  923. panel, you might want to initialize a local scale, and reference it from a
  924. property function:
  925. <pre>.def("y", function(d) pv.Scale.linear(0, pv.max(d.values)).range(0, h))
  926. .height(function(d) this.y()(d))</pre>
  927. In this example, <tt>this.y()</tt> returns the defined local scale. We then
  928. invoke the scale function, passing in the datum, to compute the height. Note
  929. that defs are similar to fixed properties: they are only evaluated once per
  930. parent panel, and <tt>this.y()</tt> returns a function, rather than
  931. automatically evaluating this function as a property.
  932. <p>2. To store temporary state for interaction. Say you have an array of
  933. bars, and you want to color the bar differently if the mouse is over it. Use
  934. <tt>def</tt> to define a local variable, and event handlers to override this
  935. variable interactively:
  936. <pre>.def("i", -1)
  937. .event("mouseover", function() this.i(this.index))
  938. .event("mouseout", function() this.i(-1))
  939. .fillStyle(function() this.i() == this.index ? "red" : "blue")</pre>
  940. Notice that <tt>this.i()</tt> can be used both to set the value of <i>i</i>
  941. (when an argument is specified), and to get the value of <i>i</i> (when no
  942. arguments are specified). In this way, it's like other property methods.
  943. <p>3. To specify fixed properties efficiently. Sometimes, the value of a
  944. property may be locally a constant, but dependent on parent panel data which
  945. is variable. In this scenario, you can use <tt>def</tt> to define a property;
  946. it will only get computed once per mark, rather than once per datum.
  947. </div>
  948. <dl class="detailList">
  949. <dt class="heading">Parameters:</dt>
  950. <dt>
  951. <span class="light fixedFont">{string}</span> <b>name</b>
  952. </dt>
  953. <dd>the name of the local variable.</dd>
  954. <dt>
  955. <span class="light fixedFont">{function}</span> <b>value</b>
  956. <i>Optional</i>
  957. </dt>
  958. <dd>an optional initializer; may be a constant or a
  959. function.</dd>
  960. </dl>
  961. <hr />
  962. <a name="event"> </a>
  963. <div class="fixedFont">
  964. <span class="light">{<a href="../symbols/pv.Mark.html">pv.Mark</a>}</span>
  965. <b>event</b>(type, handler)
  966. </div>
  967. <div class="description">
  968. Registers an event handler for the specified event type with this mark. When
  969. an event of the specified type is triggered, the specified handler will be
  970. invoked. The handler is invoked in a similar method to property functions:
  971. the context is <tt>this</tt> mark instance, and the arguments are the full
  972. data stack. Event handlers can use property methods to manipulate the display
  973. properties of the mark:
  974. <pre>m.event("click", function() this.fillStyle("red"));</pre>
  975. Alternatively, the external data can be manipulated and the visualization
  976. redrawn:
  977. <pre>m.event("click", function(d) {
  978. data = all.filter(function(k) k.name == d);
  979. vis.render();
  980. });</pre>
  981. The return value of the event handler determines which mark gets re-rendered.
  982. Use defs (<a href="#def">#def</a>) to set temporary state from event handlers.
  983. <p>The complete set of event types is defined by SVG; see the reference
  984. below. The set of supported event types is:<ul>
  985. <li>click
  986. <li>mousedown
  987. <li>mouseup
  988. <li>mouseover
  989. <li>mousemove
  990. <li>mouseout
  991. </ul>Since Protovis does not specify any concept of focus, it does not
  992. support key events; these should be handled outside the visualization using
  993. standard JavaScript. In the future, support for interaction may be extended
  994. to support additional event types, particularly those most relevant to
  995. interactive visualization, such as selection.
  996. <p>TODO In the current implementation, event handlers are not inherited from
  997. prototype marks. They must be defined explicitly on each interactive mark. In
  998. addition, only one event handler for a given event type can be defined; when
  999. specifying multiple event handlers for the same type, only the last one will
  1000. be used.
  1001. </div>
  1002. <dl class="detailList">
  1003. <dt class="heading">Parameters:</dt>
  1004. <dt>
  1005. <span class="light fixedFont">{string}</span> <b>type</b>
  1006. </dt>
  1007. <dd>the event type.</dd>
  1008. <dt>
  1009. <span class="light fixedFont">{function}</span> <b>handler</b>
  1010. </dt>
  1011. <dd>the event handler.</dd>
  1012. </dl>
  1013. <dl class="detailList">
  1014. <dt class="heading">Returns:</dt>
  1015. <dd><span class="light fixedFont">{<a href="../symbols/pv.Mark.html">pv.Mark</a>}</span> this.</dd>
  1016. </dl>
  1017. <dl class="detailList">
  1018. <dt class="heading">See:</dt>
  1019. <dd><a href="http://www.w3.org/TR/SVGTiny12/interact.html#SVGEvents">SVG events</a></dd>
  1020. </dl>
  1021. <hr />
  1022. <a name="extend"> </a>
  1023. <div class="fixedFont">
  1024. <span class="light">{<a href="../symbols/pv.Mark.html">pv.Mark</a>}</span>
  1025. <b>extend</b>(proto)
  1026. </div>
  1027. <div class="description">
  1028. Sets the prototype of this mark to the specified mark. Any properties not
  1029. defined on this mark may be inherited from the specified prototype mark, or
  1030. its prototype, and so on. The prototype mark need not be the same type of
  1031. mark as this mark. (Note that for inheritance to be useful, properties with
  1032. the same name on different mark types should have equivalent meaning.)
  1033. </div>
  1034. <dl class="detailList">
  1035. <dt class="heading">Parameters:</dt>
  1036. <dt>
  1037. <span class="light fixedFont">{<a href="../symbols/pv.Mark.html">pv.Mark</a>}</span> <b>proto</b>
  1038. </dt>
  1039. <dd>the new prototype.</dd>
  1040. </dl>
  1041. <dl class="detailList">
  1042. <dt class="heading">Returns:</dt>
  1043. <dd><span class="light fixedFont">{<a href="../symbols/pv.Mark.html">pv.Mark</a>}</span> this mark.</dd>
  1044. </dl>
  1045. <dl class="detailList">
  1046. <dt class="heading">See:</dt>
  1047. <dd><a href="#add">#add</a></dd>
  1048. </dl>
  1049. <hr />
  1050. <a name="first"> </a>
  1051. <div class="fixedFont">
  1052. <b>first</b>()
  1053. </div>
  1054. <div class="description">
  1055. Returns the first instance of this mark in the scene graph. This method can
  1056. only be called when the mark is bound to the scene graph (for example, from
  1057. an event handler, or within a property function).
  1058. </div>
  1059. <dl class="detailList">
  1060. <dt class="heading">Returns:</dt>
  1061. <dd>a node in the scene graph.</dd>
  1062. </dl>
  1063. <hr />
  1064. <a name="last"> </a>
  1065. <div class="fixedFont">
  1066. <b>last</b>()
  1067. </div>
  1068. <div class="description">
  1069. Returns the last instance of this mark in the scene graph. This method can
  1070. only be called when the mark is bound to the scene graph (for example, from
  1071. an event handler, or within a property function). In addition, note that mark
  1072. instances are built sequentially, so the last instance of this mark may not
  1073. yet be constructed.
  1074. </div>
  1075. <dl class="detailList">
  1076. <dt class="heading">Returns:</dt>
  1077. <dd>a node in the scene graph.</dd>
  1078. </dl>
  1079. <hr />
  1080. <a name="mouse"> </a>
  1081. <div class="fixedFont">
  1082. <span class="light">{<a href="../symbols/pv.Vector.html">pv.Vector</a>}</span>
  1083. <b>mouse</b>()
  1084. </div>
  1085. <div class="description">
  1086. Returns the current location of the mouse (cursor) relative to this mark's
  1087. parent. The <i>x</i> coordinate corresponds to the left margin, while the
  1088. <i>y</i> coordinate corresponds to the top margin.
  1089. </div>
  1090. <dl class="detailList">
  1091. <dt class="heading">Returns:</dt>
  1092. <dd><span class="light fixedFont">{<a href="../symbols/pv.Vector.html">pv.Vector</a>}</span> the mouse location.</dd>
  1093. </dl>
  1094. <hr />
  1095. <a name="render"> </a>
  1096. <div class="fixedFont">
  1097. <b>render</b>()
  1098. </div>
  1099. <div class="description">
  1100. Renders this mark, including recursively rendering all child marks if this is
  1101. a panel.
  1102. </div>
  1103. <hr />
  1104. <a name="sibling"> </a>
  1105. <div class="fixedFont">
  1106. <b>sibling</b>()
  1107. </div>
  1108. <div class="description">
  1109. Returns the previous instance of this mark in the scene graph, or null if
  1110. this is the first instance.
  1111. </div>
  1112. <dl class="detailList">
  1113. <dt class="heading">Returns:</dt>
  1114. <dd>a node in the scene graph, or null.</dd>
  1115. </dl>
  1116. <!-- ============================== event details ========================= -->
  1117. <hr />
  1118. </div>
  1119. <!-- ============================== footer ================================= -->
  1120. <div class="fineprint" style="clear:both">
  1121. Documentation generated by <a href="http://code.google.com/p/jsdoc-toolkit/" target="_blank">JsDoc Toolkit</a> 2.3.0 on Tue Oct 06 2009 09:59:02 GMT-0700 (PDT)
  1122. </div>
  1123. </body>
  1124. </html>