Terminal.Gui.ListWrapper.html 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387
  1. <!DOCTYPE html>
  2. <!--[if IE]><![endif]-->
  3. <html>
  4. <head>
  5. <meta charset="utf-8">
  6. <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
  7. <title>Class ListWrapper
  8. </title>
  9. <meta name="viewport" content="width=device-width">
  10. <meta name="title" content="Class ListWrapper
  11. ">
  12. <meta name="generator" content="docfx 2.59.3.0">
  13. <link rel="shortcut icon" href="../../favicon.ico">
  14. <link rel="stylesheet" href="../../styles/docfx.vendor.css">
  15. <link rel="stylesheet" href="../../styles/docfx.css">
  16. <link rel="stylesheet" href="../../styles/main.css">
  17. <meta property="docfx:navrel" content="../../toc.html">
  18. <meta property="docfx:tocrel" content="toc.html">
  19. <meta property="docfx:rel" content="../../">
  20. </head>
  21. <body data-spy="scroll" data-target="#affix" data-offset="120">
  22. <div id="wrapper">
  23. <header>
  24. <nav id="autocollapse" class="navbar navbar-inverse ng-scope" role="navigation">
  25. <div class="container">
  26. <div class="navbar-header">
  27. <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#navbar">
  28. <span class="sr-only">Toggle navigation</span>
  29. <span class="icon-bar"></span>
  30. <span class="icon-bar"></span>
  31. <span class="icon-bar"></span>
  32. </button>
  33. <a class="navbar-brand" href="../../index.html">
  34. <img id="logo" class="svg" src="../../images/logo48.png" alt="">
  35. </a>
  36. </div>
  37. <div class="collapse navbar-collapse" id="navbar">
  38. <form class="navbar-form navbar-right" role="search" id="search">
  39. <div class="form-group">
  40. <input type="text" class="form-control" id="search-query" placeholder="Search" autocomplete="off">
  41. </div>
  42. </form>
  43. </div>
  44. </div>
  45. </nav>
  46. <div class="subnav navbar navbar-default">
  47. <div class="container hide-when-search" id="breadcrumb">
  48. <ul class="breadcrumb">
  49. <li></li>
  50. </ul>
  51. </div>
  52. </div>
  53. </header>
  54. <div class="container body-content">
  55. <div id="search-results">
  56. <div class="search-list">Search Results for <span></span></div>
  57. <div class="sr-items">
  58. <p><i class="glyphicon glyphicon-refresh index-loading"></i></p>
  59. </div>
  60. <ul id="pagination" data-first="First" data-prev="Previous" data-next="Next" data-last="Last"></ul>
  61. </div>
  62. </div>
  63. <div role="main" class="container body-content hide-when-search">
  64. <div class="sidenav hide-when-search">
  65. <a class="btn toc-toggle collapse" data-toggle="collapse" href="#sidetoggle" aria-expanded="false" aria-controls="sidetoggle">Show / Hide Table of Contents</a>
  66. <div class="sidetoggle collapse" id="sidetoggle">
  67. <div id="sidetoc"></div>
  68. </div>
  69. </div>
  70. <div class="article row grid-right">
  71. <div class="col-md-10">
  72. <article class="content wrap" id="_content" data-uid="Terminal.Gui.ListWrapper">
  73. <h1 id="Terminal_Gui_ListWrapper" data-uid="Terminal.Gui.ListWrapper" class="text-break">Class ListWrapper
  74. </h1>
  75. <div class="markdown level0 summary">
  76. Implements an <a class="xref" href="Terminal.Gui.IListDataSource.html">IListDataSource</a> that renders arbitrary <span class="xref">System.Collections.IList</span> instances for <a class="xref" href="Terminal.Gui.ListView.html">ListView</a>.
  77. </div>
  78. <div class="markdown level0 conceptual"></div>
  79. <div class="inheritance">
  80. <h5>Inheritance</h5>
  81. <div class="level0"><span class="xref">System.Object</span></div>
  82. <div class="level1"><span class="xref">ListWrapper</span></div>
  83. </div>
  84. <div class="implements">
  85. <h5>Implements</h5>
  86. <div><a class="xref" href="Terminal.Gui.IListDataSource.html">IListDataSource</a></div>
  87. </div>
  88. <h6><strong>Namespace</strong>: <a class="xref" href="Terminal.Gui.html">Terminal.Gui</a></h6>
  89. <h6><strong>Assembly</strong>: Terminal.Gui.dll</h6>
  90. <h5 id="Terminal_Gui_ListWrapper_syntax">Syntax</h5>
  91. <div class="codewrapper">
  92. <pre><code class="lang-csharp hljs">public class ListWrapper : Object, IListDataSource</code></pre>
  93. </div>
  94. <h5 id="Terminal_Gui_ListWrapper_remarks"><strong>Remarks</strong></h5>
  95. <div class="markdown level0 remarks">Implements support for rendering marked items.</div>
  96. <h3 id="constructors">Constructors
  97. </h3>
  98. <a id="Terminal_Gui_ListWrapper__ctor_" data-uid="Terminal.Gui.ListWrapper.#ctor*"></a>
  99. <h4 id="Terminal_Gui_ListWrapper__ctor_System_Collections_IList_" data-uid="Terminal.Gui.ListWrapper.#ctor(System.Collections.IList)">ListWrapper(IList)</h4>
  100. <div class="markdown level1 summary">
  101. Initializes a new instance of <a class="xref" href="Terminal.Gui.ListWrapper.html">ListWrapper</a> given an <span class="xref">System.Collections.IList</span>
  102. </div>
  103. <div class="markdown level1 conceptual"></div>
  104. <h5 class="decalaration">Declaration</h5>
  105. <div class="codewrapper">
  106. <pre><code class="lang-csharp hljs">public ListWrapper(IList source)</code></pre>
  107. </div>
  108. <h5 class="parameters">Parameters</h5>
  109. <table class="table table-bordered table-striped table-condensed">
  110. <thead>
  111. <tr>
  112. <th>Type</th>
  113. <th>Name</th>
  114. <th>Description</th>
  115. </tr>
  116. </thead>
  117. <tbody>
  118. <tr>
  119. <td><span class="xref">System.Collections.IList</span></td>
  120. <td><span class="parametername">source</span></td>
  121. <td></td>
  122. </tr>
  123. </tbody>
  124. </table>
  125. <h3 id="properties">Properties
  126. </h3>
  127. <a id="Terminal_Gui_ListWrapper_Count_" data-uid="Terminal.Gui.ListWrapper.Count*"></a>
  128. <h4 id="Terminal_Gui_ListWrapper_Count" data-uid="Terminal.Gui.ListWrapper.Count">Count</h4>
  129. <div class="markdown level1 summary">
  130. Gets the number of items in the <span class="xref">System.Collections.IList</span>.
  131. </div>
  132. <div class="markdown level1 conceptual"></div>
  133. <h5 class="decalaration">Declaration</h5>
  134. <div class="codewrapper">
  135. <pre><code class="lang-csharp hljs">public int Count { get; }</code></pre>
  136. </div>
  137. <h5 class="propertyValue">Property Value</h5>
  138. <table class="table table-bordered table-striped table-condensed">
  139. <thead>
  140. <tr>
  141. <th>Type</th>
  142. <th>Description</th>
  143. </tr>
  144. </thead>
  145. <tbody>
  146. <tr>
  147. <td><span class="xref">System.Int32</span></td>
  148. <td></td>
  149. </tr>
  150. </tbody>
  151. </table>
  152. <a id="Terminal_Gui_ListWrapper_Length_" data-uid="Terminal.Gui.ListWrapper.Length*"></a>
  153. <h4 id="Terminal_Gui_ListWrapper_Length" data-uid="Terminal.Gui.ListWrapper.Length">Length</h4>
  154. <div class="markdown level1 summary">
  155. Gets the maximum item length in the <span class="xref">System.Collections.IList</span>.
  156. </div>
  157. <div class="markdown level1 conceptual"></div>
  158. <h5 class="decalaration">Declaration</h5>
  159. <div class="codewrapper">
  160. <pre><code class="lang-csharp hljs">public int Length { get; }</code></pre>
  161. </div>
  162. <h5 class="propertyValue">Property Value</h5>
  163. <table class="table table-bordered table-striped table-condensed">
  164. <thead>
  165. <tr>
  166. <th>Type</th>
  167. <th>Description</th>
  168. </tr>
  169. </thead>
  170. <tbody>
  171. <tr>
  172. <td><span class="xref">System.Int32</span></td>
  173. <td></td>
  174. </tr>
  175. </tbody>
  176. </table>
  177. <h3 id="methods">Methods
  178. </h3>
  179. <a id="Terminal_Gui_ListWrapper_IsMarked_" data-uid="Terminal.Gui.ListWrapper.IsMarked*"></a>
  180. <h4 id="Terminal_Gui_ListWrapper_IsMarked_System_Int32_" data-uid="Terminal.Gui.ListWrapper.IsMarked(System.Int32)">IsMarked(Int32)</h4>
  181. <div class="markdown level1 summary">
  182. Returns true if the item is marked, false otherwise.
  183. </div>
  184. <div class="markdown level1 conceptual"></div>
  185. <h5 class="decalaration">Declaration</h5>
  186. <div class="codewrapper">
  187. <pre><code class="lang-csharp hljs">public bool IsMarked(int item)</code></pre>
  188. </div>
  189. <h5 class="parameters">Parameters</h5>
  190. <table class="table table-bordered table-striped table-condensed">
  191. <thead>
  192. <tr>
  193. <th>Type</th>
  194. <th>Name</th>
  195. <th>Description</th>
  196. </tr>
  197. </thead>
  198. <tbody>
  199. <tr>
  200. <td><span class="xref">System.Int32</span></td>
  201. <td><span class="parametername">item</span></td>
  202. <td>The item.</td>
  203. </tr>
  204. </tbody>
  205. </table>
  206. <h5 class="returns">Returns</h5>
  207. <table class="table table-bordered table-striped table-condensed">
  208. <thead>
  209. <tr>
  210. <th>Type</th>
  211. <th>Description</th>
  212. </tr>
  213. </thead>
  214. <tbody>
  215. <tr>
  216. <td><span class="xref">System.Boolean</span></td>
  217. <td><code>true</code>If is marked.<code>false</code>otherwise.</td>
  218. </tr>
  219. </tbody>
  220. </table>
  221. <a id="Terminal_Gui_ListWrapper_Render_" data-uid="Terminal.Gui.ListWrapper.Render*"></a>
  222. <h4 id="Terminal_Gui_ListWrapper_Render_Terminal_Gui_ListView_Terminal_Gui_ConsoleDriver_System_Boolean_System_Int32_System_Int32_System_Int32_System_Int32_System_Int32_" data-uid="Terminal.Gui.ListWrapper.Render(Terminal.Gui.ListView,Terminal.Gui.ConsoleDriver,System.Boolean,System.Int32,System.Int32,System.Int32,System.Int32,System.Int32)">Render(ListView, ConsoleDriver, Boolean, Int32, Int32, Int32, Int32, Int32)</h4>
  223. <div class="markdown level1 summary">
  224. Renders a <a class="xref" href="Terminal.Gui.ListView.html">ListView</a> item to the appropriate type.
  225. </div>
  226. <div class="markdown level1 conceptual"></div>
  227. <h5 class="decalaration">Declaration</h5>
  228. <div class="codewrapper">
  229. <pre><code class="lang-csharp hljs">public void Render(ListView container, ConsoleDriver driver, bool marked, int item, int col, int line, int width, int start = 0)</code></pre>
  230. </div>
  231. <h5 class="parameters">Parameters</h5>
  232. <table class="table table-bordered table-striped table-condensed">
  233. <thead>
  234. <tr>
  235. <th>Type</th>
  236. <th>Name</th>
  237. <th>Description</th>
  238. </tr>
  239. </thead>
  240. <tbody>
  241. <tr>
  242. <td><a class="xref" href="Terminal.Gui.ListView.html">ListView</a></td>
  243. <td><span class="parametername">container</span></td>
  244. <td>The ListView.</td>
  245. </tr>
  246. <tr>
  247. <td><a class="xref" href="Terminal.Gui.ConsoleDriver.html">ConsoleDriver</a></td>
  248. <td><span class="parametername">driver</span></td>
  249. <td>The driver used by the caller.</td>
  250. </tr>
  251. <tr>
  252. <td><span class="xref">System.Boolean</span></td>
  253. <td><span class="parametername">marked</span></td>
  254. <td>Informs if it&apos;s marked or not.</td>
  255. </tr>
  256. <tr>
  257. <td><span class="xref">System.Int32</span></td>
  258. <td><span class="parametername">item</span></td>
  259. <td>The item.</td>
  260. </tr>
  261. <tr>
  262. <td><span class="xref">System.Int32</span></td>
  263. <td><span class="parametername">col</span></td>
  264. <td>The col where to move.</td>
  265. </tr>
  266. <tr>
  267. <td><span class="xref">System.Int32</span></td>
  268. <td><span class="parametername">line</span></td>
  269. <td>The line where to move.</td>
  270. </tr>
  271. <tr>
  272. <td><span class="xref">System.Int32</span></td>
  273. <td><span class="parametername">width</span></td>
  274. <td>The item width.</td>
  275. </tr>
  276. <tr>
  277. <td><span class="xref">System.Int32</span></td>
  278. <td><span class="parametername">start</span></td>
  279. <td>The index of the string to be displayed.</td>
  280. </tr>
  281. </tbody>
  282. </table>
  283. <a id="Terminal_Gui_ListWrapper_SetMark_" data-uid="Terminal.Gui.ListWrapper.SetMark*"></a>
  284. <h4 id="Terminal_Gui_ListWrapper_SetMark_System_Int32_System_Boolean_" data-uid="Terminal.Gui.ListWrapper.SetMark(System.Int32,System.Boolean)">SetMark(Int32, Boolean)</h4>
  285. <div class="markdown level1 summary">
  286. Sets the item as marked or unmarked based on the value is true or false, respectively.
  287. </div>
  288. <div class="markdown level1 conceptual"></div>
  289. <h5 class="decalaration">Declaration</h5>
  290. <div class="codewrapper">
  291. <pre><code class="lang-csharp hljs">public void SetMark(int item, bool value)</code></pre>
  292. </div>
  293. <h5 class="parameters">Parameters</h5>
  294. <table class="table table-bordered table-striped table-condensed">
  295. <thead>
  296. <tr>
  297. <th>Type</th>
  298. <th>Name</th>
  299. <th>Description</th>
  300. </tr>
  301. </thead>
  302. <tbody>
  303. <tr>
  304. <td><span class="xref">System.Int32</span></td>
  305. <td><span class="parametername">item</span></td>
  306. <td>The item</td>
  307. </tr>
  308. <tr>
  309. <td><span class="xref">System.Boolean</span></td>
  310. <td><span class="parametername">value</span></td>
  311. <td><true>Marks the item.</true><false>Unmarked the item.</false>The value.</td>
  312. </tr>
  313. </tbody>
  314. </table>
  315. <a id="Terminal_Gui_ListWrapper_ToList_" data-uid="Terminal.Gui.ListWrapper.ToList*"></a>
  316. <h4 id="Terminal_Gui_ListWrapper_ToList" data-uid="Terminal.Gui.ListWrapper.ToList">ToList()</h4>
  317. <div class="markdown level1 summary">
  318. Returns the source as IList.
  319. </div>
  320. <div class="markdown level1 conceptual"></div>
  321. <h5 class="decalaration">Declaration</h5>
  322. <div class="codewrapper">
  323. <pre><code class="lang-csharp hljs">public IList ToList()</code></pre>
  324. </div>
  325. <h5 class="returns">Returns</h5>
  326. <table class="table table-bordered table-striped table-condensed">
  327. <thead>
  328. <tr>
  329. <th>Type</th>
  330. <th>Description</th>
  331. </tr>
  332. </thead>
  333. <tbody>
  334. <tr>
  335. <td><span class="xref">System.Collections.IList</span></td>
  336. <td></td>
  337. </tr>
  338. </tbody>
  339. </table>
  340. <h3 id="implements">Implements</h3>
  341. <div>
  342. <a class="xref" href="Terminal.Gui.IListDataSource.html">IListDataSource</a>
  343. </div>
  344. </article>
  345. </div>
  346. <div class="hidden-sm col-md-2" role="complementary">
  347. <div class="sideaffix">
  348. <nav class="bs-docs-sidebar hidden-print hidden-xs hidden-sm affix" id="affix">
  349. <h5>In This Article</h5>
  350. <div></div>
  351. </nav>
  352. </div>
  353. </div>
  354. </div>
  355. </div>
  356. <footer>
  357. <div class="grad-bottom"></div>
  358. <div class="footer">
  359. <div class="container">
  360. <span class="pull-right">
  361. <a href="#top">Back to top</a>
  362. </span>
  363. <span>Generated by <strong>DocFX</strong></span>
  364. </div>
  365. </div>
  366. </footer>
  367. </div>
  368. <script type="text/javascript" src="../../styles/docfx.vendor.js"></script>
  369. <script type="text/javascript" src="../../styles/docfx.js"></script>
  370. <script type="text/javascript" src="../../styles/main.js"></script>
  371. </body>
  372. </html>