Terminal.Gui.TreeView-1.html 81 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078
  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 TreeView&lt;T&gt;
  8. </title>
  9. <meta name="viewport" content="width=device-width">
  10. <meta name="title" content="Class TreeView&lt;T&gt;
  11. ">
  12. <meta name="generator" content="docfx 2.58.5.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.TreeView`1">
  73. <h1 id="Terminal_Gui_TreeView_1" data-uid="Terminal.Gui.TreeView`1" class="text-break">Class TreeView&lt;T&gt;
  74. </h1>
  75. <div class="markdown level0 summary">
  76. Hierarchical tree view with expandable branches. Branch objects are dynamically determined
  77. when expanded using a user defined <a class="xref" href="Terminal.Gui.Trees.ITreeBuilder-1.html">ITreeBuilder&lt;T&gt;</a>
  78. <a href="https://migueldeicaza.github.io/gui.cs/articles/treeview.html">See TreeView Deep Dive for more information</a>.
  79. </div>
  80. <div class="markdown level0 conceptual"></div>
  81. <div class="inheritance">
  82. <h5>Inheritance</h5>
  83. <div class="level0"><span class="xref">System.Object</span></div>
  84. <div class="level1"><a class="xref" href="Terminal.Gui.Responder.html">Responder</a></div>
  85. <div class="level2"><a class="xref" href="Terminal.Gui.View.html">View</a></div>
  86. <div class="level3"><span class="xref">TreeView&lt;T&gt;</span></div>
  87. <div class="level4"><a class="xref" href="Terminal.Gui.TreeView.html">TreeView</a></div>
  88. </div>
  89. <div classs="implements">
  90. <h5>Implements</h5>
  91. <div><span class="xref">System.IDisposable</span></div>
  92. <div><span class="xref">System.ComponentModel.ISupportInitializeNotification</span></div>
  93. <div><span class="xref">System.ComponentModel.ISupportInitialize</span></div>
  94. <div><a class="xref" href="Terminal.Gui.ITreeView.html">ITreeView</a></div>
  95. </div>
  96. <div class="inheritedMembers">
  97. <h5>Inherited Members</h5>
  98. <div>
  99. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Added">View.Added</a>
  100. </div>
  101. <div>
  102. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Removed">View.Removed</a>
  103. </div>
  104. <div>
  105. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Enter">View.Enter</a>
  106. </div>
  107. <div>
  108. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Leave">View.Leave</a>
  109. </div>
  110. <div>
  111. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_MouseEnter">View.MouseEnter</a>
  112. </div>
  113. <div>
  114. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_MouseLeave">View.MouseLeave</a>
  115. </div>
  116. <div>
  117. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_MouseClick">View.MouseClick</a>
  118. </div>
  119. <div>
  120. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_CanFocusChanged">View.CanFocusChanged</a>
  121. </div>
  122. <div>
  123. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_EnabledChanged">View.EnabledChanged</a>
  124. </div>
  125. <div>
  126. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_VisibleChanged">View.VisibleChanged</a>
  127. </div>
  128. <div>
  129. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_HotKey">View.HotKey</a>
  130. </div>
  131. <div>
  132. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_HotKeySpecifier">View.HotKeySpecifier</a>
  133. </div>
  134. <div>
  135. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Shortcut">View.Shortcut</a>
  136. </div>
  137. <div>
  138. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_ShortcutTag">View.ShortcutTag</a>
  139. </div>
  140. <div>
  141. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_ShortcutAction">View.ShortcutAction</a>
  142. </div>
  143. <div>
  144. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Data">View.Data</a>
  145. </div>
  146. <div>
  147. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Driver">View.Driver</a>
  148. </div>
  149. <div>
  150. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Subviews">View.Subviews</a>
  151. </div>
  152. <div>
  153. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_TabIndexes">View.TabIndexes</a>
  154. </div>
  155. <div>
  156. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_TabIndex">View.TabIndex</a>
  157. </div>
  158. <div>
  159. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_TabStop">View.TabStop</a>
  160. </div>
  161. <div>
  162. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_CanFocus">View.CanFocus</a>
  163. </div>
  164. <div>
  165. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Id">View.Id</a>
  166. </div>
  167. <div>
  168. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_IsCurrentTop">View.IsCurrentTop</a>
  169. </div>
  170. <div>
  171. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_WantMousePositionReports">View.WantMousePositionReports</a>
  172. </div>
  173. <div>
  174. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_WantContinuousButtonPressed">View.WantContinuousButtonPressed</a>
  175. </div>
  176. <div>
  177. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Frame">View.Frame</a>
  178. </div>
  179. <div>
  180. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_LayoutStyle">View.LayoutStyle</a>
  181. </div>
  182. <div>
  183. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Bounds">View.Bounds</a>
  184. </div>
  185. <div>
  186. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_X">View.X</a>
  187. </div>
  188. <div>
  189. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Y">View.Y</a>
  190. </div>
  191. <div>
  192. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Width">View.Width</a>
  193. </div>
  194. <div>
  195. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Height">View.Height</a>
  196. </div>
  197. <div>
  198. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_SuperView">View.SuperView</a>
  199. </div>
  200. <div>
  201. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_SetNeedsDisplay">View.SetNeedsDisplay()</a>
  202. </div>
  203. <div>
  204. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_ClearLayoutNeeded">View.ClearLayoutNeeded()</a>
  205. </div>
  206. <div>
  207. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_SetNeedsDisplay_Terminal_Gui_Rect_">View.SetNeedsDisplay(Rect)</a>
  208. </div>
  209. <div>
  210. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_SetChildNeedsDisplay">View.SetChildNeedsDisplay()</a>
  211. </div>
  212. <div>
  213. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Add_Terminal_Gui_View_">View.Add(View)</a>
  214. </div>
  215. <div>
  216. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Add_Terminal_Gui_View___">View.Add(View[])</a>
  217. </div>
  218. <div>
  219. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_RemoveAll">View.RemoveAll()</a>
  220. </div>
  221. <div>
  222. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Remove_Terminal_Gui_View_">View.Remove(View)</a>
  223. </div>
  224. <div>
  225. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_BringSubviewToFront_Terminal_Gui_View_">View.BringSubviewToFront(View)</a>
  226. </div>
  227. <div>
  228. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_SendSubviewToBack_Terminal_Gui_View_">View.SendSubviewToBack(View)</a>
  229. </div>
  230. <div>
  231. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_SendSubviewBackwards_Terminal_Gui_View_">View.SendSubviewBackwards(View)</a>
  232. </div>
  233. <div>
  234. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_BringSubviewForward_Terminal_Gui_View_">View.BringSubviewForward(View)</a>
  235. </div>
  236. <div>
  237. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Clear">View.Clear()</a>
  238. </div>
  239. <div>
  240. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Clear_Terminal_Gui_Rect_">View.Clear(Rect)</a>
  241. </div>
  242. <div>
  243. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_ScreenToView_System_Int32_System_Int32_">View.ScreenToView(Int32, Int32)</a>
  244. </div>
  245. <div>
  246. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_ClipToBounds">View.ClipToBounds()</a>
  247. </div>
  248. <div>
  249. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_SetClip_Terminal_Gui_Rect_">View.SetClip(Rect)</a>
  250. </div>
  251. <div>
  252. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_DrawFrame_Terminal_Gui_Rect_System_Int32_System_Boolean_">View.DrawFrame(Rect, Int32, Boolean)</a>
  253. </div>
  254. <div>
  255. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_DrawHotString_NStack_ustring_Terminal_Gui_Attribute_Terminal_Gui_Attribute_">View.DrawHotString(ustring, Attribute, Attribute)</a>
  256. </div>
  257. <div>
  258. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_DrawHotString_NStack_ustring_System_Boolean_Terminal_Gui_ColorScheme_">View.DrawHotString(ustring, Boolean, ColorScheme)</a>
  259. </div>
  260. <div>
  261. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Move_System_Int32_System_Int32_">View.Move(Int32, Int32)</a>
  262. </div>
  263. <div>
  264. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_HasFocus">View.HasFocus</a>
  265. </div>
  266. <div>
  267. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_OnAdded_Terminal_Gui_View_">View.OnAdded(View)</a>
  268. </div>
  269. <div>
  270. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_OnRemoved_Terminal_Gui_View_">View.OnRemoved(View)</a>
  271. </div>
  272. <div>
  273. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_OnEnter_Terminal_Gui_View_">View.OnEnter(View)</a>
  274. </div>
  275. <div>
  276. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_OnLeave_Terminal_Gui_View_">View.OnLeave(View)</a>
  277. </div>
  278. <div>
  279. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Focused">View.Focused</a>
  280. </div>
  281. <div>
  282. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_MostFocused">View.MostFocused</a>
  283. </div>
  284. <div>
  285. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_ColorScheme">View.ColorScheme</a>
  286. </div>
  287. <div>
  288. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_AddRune_System_Int32_System_Int32_System_Rune_">View.AddRune(Int32, Int32, Rune)</a>
  289. </div>
  290. <div>
  291. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_ClearNeedsDisplay">View.ClearNeedsDisplay()</a>
  292. </div>
  293. <div>
  294. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_DrawContent">View.DrawContent</a>
  295. </div>
  296. <div>
  297. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_OnDrawContent_Terminal_Gui_Rect_">View.OnDrawContent(Rect)</a>
  298. </div>
  299. <div>
  300. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_SetFocus">View.SetFocus()</a>
  301. </div>
  302. <div>
  303. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_KeyPress">View.KeyPress</a>
  304. </div>
  305. <div>
  306. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_ProcessHotKey_Terminal_Gui_KeyEvent_">View.ProcessHotKey(KeyEvent)</a>
  307. </div>
  308. <div>
  309. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_ProcessColdKey_Terminal_Gui_KeyEvent_">View.ProcessColdKey(KeyEvent)</a>
  310. </div>
  311. <div>
  312. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_KeyDown">View.KeyDown</a>
  313. </div>
  314. <div>
  315. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_OnKeyDown_Terminal_Gui_KeyEvent_">View.OnKeyDown(KeyEvent)</a>
  316. </div>
  317. <div>
  318. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_KeyUp">View.KeyUp</a>
  319. </div>
  320. <div>
  321. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_OnKeyUp_Terminal_Gui_KeyEvent_">View.OnKeyUp(KeyEvent)</a>
  322. </div>
  323. <div>
  324. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_EnsureFocus">View.EnsureFocus()</a>
  325. </div>
  326. <div>
  327. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_FocusFirst">View.FocusFirst()</a>
  328. </div>
  329. <div>
  330. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_FocusLast">View.FocusLast()</a>
  331. </div>
  332. <div>
  333. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_FocusPrev">View.FocusPrev()</a>
  334. </div>
  335. <div>
  336. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_FocusNext">View.FocusNext()</a>
  337. </div>
  338. <div>
  339. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_LayoutStarted">View.LayoutStarted</a>
  340. </div>
  341. <div>
  342. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_LayoutComplete">View.LayoutComplete</a>
  343. </div>
  344. <div>
  345. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Initialized">View.Initialized</a>
  346. </div>
  347. <div>
  348. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_LayoutSubviews">View.LayoutSubviews()</a>
  349. </div>
  350. <div>
  351. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Text">View.Text</a>
  352. </div>
  353. <div>
  354. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_AutoSize">View.AutoSize</a>
  355. </div>
  356. <div>
  357. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_TextAlignment">View.TextAlignment</a>
  358. </div>
  359. <div>
  360. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_VerticalTextAlignment">View.VerticalTextAlignment</a>
  361. </div>
  362. <div>
  363. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_TextDirection">View.TextDirection</a>
  364. </div>
  365. <div>
  366. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_IsInitialized">View.IsInitialized</a>
  367. </div>
  368. <div>
  369. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Enabled">View.Enabled</a>
  370. </div>
  371. <div>
  372. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Visible">View.Visible</a>
  373. </div>
  374. <div>
  375. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Border">View.Border</a>
  376. </div>
  377. <div>
  378. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_ToString">View.ToString()</a>
  379. </div>
  380. <div>
  381. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_OnMouseEnter_Terminal_Gui_MouseEvent_">View.OnMouseEnter(MouseEvent)</a>
  382. </div>
  383. <div>
  384. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_OnMouseLeave_Terminal_Gui_MouseEvent_">View.OnMouseLeave(MouseEvent)</a>
  385. </div>
  386. <div>
  387. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_OnMouseEvent_Terminal_Gui_MouseEvent_">View.OnMouseEvent(MouseEvent)</a>
  388. </div>
  389. <div>
  390. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_OnMouseClick_Terminal_Gui_View_MouseEventArgs_">View.OnMouseClick(View.MouseEventArgs)</a>
  391. </div>
  392. <div>
  393. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_OnCanFocusChanged">View.OnCanFocusChanged()</a>
  394. </div>
  395. <div>
  396. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_OnEnabledChanged">View.OnEnabledChanged()</a>
  397. </div>
  398. <div>
  399. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_OnVisibleChanged">View.OnVisibleChanged()</a>
  400. </div>
  401. <div>
  402. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Dispose_System_Boolean_">View.Dispose(Boolean)</a>
  403. </div>
  404. <div>
  405. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_BeginInit">View.BeginInit()</a>
  406. </div>
  407. <div>
  408. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_EndInit">View.EndInit()</a>
  409. </div>
  410. <div>
  411. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_SetWidth_System_Int32_System_Int32__">View.SetWidth(Int32, Int32)</a>
  412. </div>
  413. <div>
  414. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_SetHeight_System_Int32_System_Int32__">View.SetHeight(Int32, Int32)</a>
  415. </div>
  416. <div>
  417. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_GetCurrentWidth_System_Int32__">View.GetCurrentWidth(Int32)</a>
  418. </div>
  419. <div>
  420. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_GetCurrentHeight_System_Int32__">View.GetCurrentHeight(Int32)</a>
  421. </div>
  422. <div>
  423. <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_GetNormalColor">View.GetNormalColor()</a>
  424. </div>
  425. <div>
  426. <a class="xref" href="Terminal.Gui.Responder.html#Terminal_Gui_Responder_Dispose">Responder.Dispose()</a>
  427. </div>
  428. <div>
  429. <span class="xref">System.Object.Equals(System.Object)</span>
  430. </div>
  431. <div>
  432. <span class="xref">System.Object.Equals(System.Object, System.Object)</span>
  433. </div>
  434. <div>
  435. <span class="xref">System.Object.GetHashCode()</span>
  436. </div>
  437. <div>
  438. <span class="xref">System.Object.GetType()</span>
  439. </div>
  440. <div>
  441. <span class="xref">System.Object.MemberwiseClone()</span>
  442. </div>
  443. <div>
  444. <span class="xref">System.Object.ReferenceEquals(System.Object, System.Object)</span>
  445. </div>
  446. </div>
  447. <h6><strong>Namespace</strong>: <a class="xref" href="Terminal.Gui.html">Terminal.Gui</a></h6>
  448. <h6><strong>Assembly</strong>: Terminal.Gui.dll</h6>
  449. <h5 id="Terminal_Gui_TreeView_1_syntax">Syntax</h5>
  450. <div class="codewrapper">
  451. <pre><code class="lang-csharp hljs">public class TreeView&lt;T&gt; : View, IDisposable, ISupportInitializeNotification, ISupportInitialize, ITreeView where T : class</code></pre>
  452. </div>
  453. <h5 class="typeParameters">Type Parameters</h5>
  454. <table class="table table-bordered table-striped table-condensed">
  455. <thead>
  456. <tr>
  457. <th>Name</th>
  458. <th>Description</th>
  459. </tr>
  460. </thead>
  461. <tbody>
  462. <tr>
  463. <td><span class="parametername">T</span></td>
  464. <td></td>
  465. </tr>
  466. </tbody>
  467. </table>
  468. <h3 id="constructors">Constructors
  469. </h3>
  470. <a id="Terminal_Gui_TreeView_1__ctor_" data-uid="Terminal.Gui.TreeView`1.#ctor*"></a>
  471. <h4 id="Terminal_Gui_TreeView_1__ctor" data-uid="Terminal.Gui.TreeView`1.#ctor">TreeView()</h4>
  472. <div class="markdown level1 summary">
  473. Creates a new tree view with absolute positioning.
  474. Use <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_AddObjects_System_Collections_Generic_IEnumerable__0__">AddObjects(IEnumerable&lt;T&gt;)</a> to set set root objects for the tree.
  475. Children will not be rendered until you set <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_TreeBuilder">TreeBuilder</a>
  476. </div>
  477. <div class="markdown level1 conceptual"></div>
  478. <h5 class="decalaration">Declaration</h5>
  479. <div class="codewrapper">
  480. <pre><code class="lang-csharp hljs">public TreeView()</code></pre>
  481. </div>
  482. <a id="Terminal_Gui_TreeView_1__ctor_" data-uid="Terminal.Gui.TreeView`1.#ctor*"></a>
  483. <h4 id="Terminal_Gui_TreeView_1__ctor_Terminal_Gui_Trees_ITreeBuilder__0__" data-uid="Terminal.Gui.TreeView`1.#ctor(Terminal.Gui.Trees.ITreeBuilder{`0})">TreeView(ITreeBuilder&lt;T&gt;)</h4>
  484. <div class="markdown level1 summary">
  485. Initialises <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_TreeBuilder">TreeBuilder</a>.Creates a new tree view with absolute
  486. positioning. Use <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_AddObjects_System_Collections_Generic_IEnumerable__0__">AddObjects(IEnumerable&lt;T&gt;)</a> to set set root
  487. objects for the tree.
  488. </div>
  489. <div class="markdown level1 conceptual"></div>
  490. <h5 class="decalaration">Declaration</h5>
  491. <div class="codewrapper">
  492. <pre><code class="lang-csharp hljs">public TreeView(ITreeBuilder&lt;T&gt; builder)</code></pre>
  493. </div>
  494. <h5 class="parameters">Parameters</h5>
  495. <table class="table table-bordered table-striped table-condensed">
  496. <thead>
  497. <tr>
  498. <th>Type</th>
  499. <th>Name</th>
  500. <th>Description</th>
  501. </tr>
  502. </thead>
  503. <tbody>
  504. <tr>
  505. <td><a class="xref" href="Terminal.Gui.Trees.ITreeBuilder-1.html">ITreeBuilder</a>&lt;T&gt;</td>
  506. <td><span class="parametername">builder</span></td>
  507. <td></td>
  508. </tr>
  509. </tbody>
  510. </table>
  511. <h3 id="fields">Fields
  512. </h3>
  513. <h4 id="Terminal_Gui_TreeView_1_NoBuilderError" data-uid="Terminal.Gui.TreeView`1.NoBuilderError">NoBuilderError</h4>
  514. <div class="markdown level1 summary">
  515. Error message to display when the control is not properly initialized at draw time
  516. (nodes added but no tree builder set)
  517. </div>
  518. <div class="markdown level1 conceptual"></div>
  519. <h5 class="decalaration">Declaration</h5>
  520. <div class="codewrapper">
  521. <pre><code class="lang-csharp hljs">public static ustring NoBuilderError</code></pre>
  522. </div>
  523. <h5 class="fieldValue">Field Value</h5>
  524. <table class="table table-bordered table-striped table-condensed">
  525. <thead>
  526. <tr>
  527. <th>Type</th>
  528. <th>Description</th>
  529. </tr>
  530. </thead>
  531. <tbody>
  532. <tr>
  533. <td><span class="xref">NStack.ustring</span></td>
  534. <td></td>
  535. </tr>
  536. </tbody>
  537. </table>
  538. <h3 id="properties">Properties
  539. </h3>
  540. <a id="Terminal_Gui_TreeView_1_AllowLetterBasedNavigation_" data-uid="Terminal.Gui.TreeView`1.AllowLetterBasedNavigation*"></a>
  541. <h4 id="Terminal_Gui_TreeView_1_AllowLetterBasedNavigation" data-uid="Terminal.Gui.TreeView`1.AllowLetterBasedNavigation">AllowLetterBasedNavigation</h4>
  542. <div class="markdown level1 summary">
  543. True makes a letter key press navigate to the next visible branch that begins with
  544. that letter/digit
  545. </div>
  546. <div class="markdown level1 conceptual"></div>
  547. <h5 class="decalaration">Declaration</h5>
  548. <div class="codewrapper">
  549. <pre><code class="lang-csharp hljs">public bool AllowLetterBasedNavigation { get; set; }</code></pre>
  550. </div>
  551. <h5 class="propertyValue">Property Value</h5>
  552. <table class="table table-bordered table-striped table-condensed">
  553. <thead>
  554. <tr>
  555. <th>Type</th>
  556. <th>Description</th>
  557. </tr>
  558. </thead>
  559. <tbody>
  560. <tr>
  561. <td><span class="xref">System.Boolean</span></td>
  562. <td></td>
  563. </tr>
  564. </tbody>
  565. </table>
  566. <a id="Terminal_Gui_TreeView_1_AspectGetter_" data-uid="Terminal.Gui.TreeView`1.AspectGetter*"></a>
  567. <h4 id="Terminal_Gui_TreeView_1_AspectGetter" data-uid="Terminal.Gui.TreeView`1.AspectGetter">AspectGetter</h4>
  568. <div class="markdown level1 summary">
  569. Returns the string representation of model objects hosted in the tree. Default
  570. implementation is to call <span class="xref">System.Object.ToString()</span>
  571. </div>
  572. <div class="markdown level1 conceptual"></div>
  573. <h5 class="decalaration">Declaration</h5>
  574. <div class="codewrapper">
  575. <pre><code class="lang-csharp hljs">public AspectGetterDelegate&lt;T&gt; AspectGetter { get; set; }</code></pre>
  576. </div>
  577. <h5 class="propertyValue">Property Value</h5>
  578. <table class="table table-bordered table-striped table-condensed">
  579. <thead>
  580. <tr>
  581. <th>Type</th>
  582. <th>Description</th>
  583. </tr>
  584. </thead>
  585. <tbody>
  586. <tr>
  587. <td><a class="xref" href="Terminal.Gui.Trees.AspectGetterDelegate-1.html">AspectGetterDelegate</a>&lt;T&gt;</td>
  588. <td></td>
  589. </tr>
  590. </tbody>
  591. </table>
  592. <a id="Terminal_Gui_TreeView_1_ContentHeight_" data-uid="Terminal.Gui.TreeView`1.ContentHeight*"></a>
  593. <h4 id="Terminal_Gui_TreeView_1_ContentHeight" data-uid="Terminal.Gui.TreeView`1.ContentHeight">ContentHeight</h4>
  594. <div class="markdown level1 summary">
  595. The current number of rows in the tree (ignoring the controls bounds)
  596. </div>
  597. <div class="markdown level1 conceptual"></div>
  598. <h5 class="decalaration">Declaration</h5>
  599. <div class="codewrapper">
  600. <pre><code class="lang-csharp hljs">public int ContentHeight { get; }</code></pre>
  601. </div>
  602. <h5 class="propertyValue">Property Value</h5>
  603. <table class="table table-bordered table-striped table-condensed">
  604. <thead>
  605. <tr>
  606. <th>Type</th>
  607. <th>Description</th>
  608. </tr>
  609. </thead>
  610. <tbody>
  611. <tr>
  612. <td><span class="xref">System.Int32</span></td>
  613. <td></td>
  614. </tr>
  615. </tbody>
  616. </table>
  617. <a id="Terminal_Gui_TreeView_1_MultiSelect_" data-uid="Terminal.Gui.TreeView`1.MultiSelect*"></a>
  618. <h4 id="Terminal_Gui_TreeView_1_MultiSelect" data-uid="Terminal.Gui.TreeView`1.MultiSelect">MultiSelect</h4>
  619. <div class="markdown level1 summary">
  620. True to allow multiple objects to be selected at once
  621. </div>
  622. <div class="markdown level1 conceptual"></div>
  623. <h5 class="decalaration">Declaration</h5>
  624. <div class="codewrapper">
  625. <pre><code class="lang-csharp hljs">public bool MultiSelect { get; set; }</code></pre>
  626. </div>
  627. <h5 class="propertyValue">Property Value</h5>
  628. <table class="table table-bordered table-striped table-condensed">
  629. <thead>
  630. <tr>
  631. <th>Type</th>
  632. <th>Description</th>
  633. </tr>
  634. </thead>
  635. <tbody>
  636. <tr>
  637. <td><span class="xref">System.Boolean</span></td>
  638. <td></td>
  639. </tr>
  640. </tbody>
  641. </table>
  642. <a id="Terminal_Gui_TreeView_1_ObjectActivationButton_" data-uid="Terminal.Gui.TreeView`1.ObjectActivationButton*"></a>
  643. <h4 id="Terminal_Gui_TreeView_1_ObjectActivationButton" data-uid="Terminal.Gui.TreeView`1.ObjectActivationButton">ObjectActivationButton</h4>
  644. <div class="markdown level1 summary">
  645. Mouse event to trigger <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_ObjectActivated">ObjectActivated</a>.
  646. Defaults to double click (<a class="xref" href="Terminal.Gui.MouseFlags.html#Terminal_Gui_MouseFlags_Button1DoubleClicked">Button1DoubleClicked</a>).
  647. Set to null to disable this feature.
  648. </div>
  649. <div class="markdown level1 conceptual"></div>
  650. <h5 class="decalaration">Declaration</h5>
  651. <div class="codewrapper">
  652. <pre><code class="lang-csharp hljs">public MouseFlags? ObjectActivationButton { get; set; }</code></pre>
  653. </div>
  654. <h5 class="propertyValue">Property Value</h5>
  655. <table class="table table-bordered table-striped table-condensed">
  656. <thead>
  657. <tr>
  658. <th>Type</th>
  659. <th>Description</th>
  660. </tr>
  661. </thead>
  662. <tbody>
  663. <tr>
  664. <td><span class="xref">System.Nullable</span>&lt;<a class="xref" href="Terminal.Gui.MouseFlags.html">MouseFlags</a>&gt;</td>
  665. <td></td>
  666. </tr>
  667. </tbody>
  668. </table>
  669. <a id="Terminal_Gui_TreeView_1_ObjectActivationKey_" data-uid="Terminal.Gui.TreeView`1.ObjectActivationKey*"></a>
  670. <h4 id="Terminal_Gui_TreeView_1_ObjectActivationKey" data-uid="Terminal.Gui.TreeView`1.ObjectActivationKey">ObjectActivationKey</h4>
  671. <div class="markdown level1 summary">
  672. Key which when pressed triggers <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_ObjectActivated">ObjectActivated</a>.
  673. Defaults to Enter
  674. </div>
  675. <div class="markdown level1 conceptual"></div>
  676. <h5 class="decalaration">Declaration</h5>
  677. <div class="codewrapper">
  678. <pre><code class="lang-csharp hljs">public Key ObjectActivationKey { get; set; }</code></pre>
  679. </div>
  680. <h5 class="propertyValue">Property Value</h5>
  681. <table class="table table-bordered table-striped table-condensed">
  682. <thead>
  683. <tr>
  684. <th>Type</th>
  685. <th>Description</th>
  686. </tr>
  687. </thead>
  688. <tbody>
  689. <tr>
  690. <td><a class="xref" href="Terminal.Gui.Key.html">Key</a></td>
  691. <td></td>
  692. </tr>
  693. </tbody>
  694. </table>
  695. <a id="Terminal_Gui_TreeView_1_Objects_" data-uid="Terminal.Gui.TreeView`1.Objects*"></a>
  696. <h4 id="Terminal_Gui_TreeView_1_Objects" data-uid="Terminal.Gui.TreeView`1.Objects">Objects</h4>
  697. <div class="markdown level1 summary">
  698. The root objects in the tree, note that this collection is of root objects only
  699. </div>
  700. <div class="markdown level1 conceptual"></div>
  701. <h5 class="decalaration">Declaration</h5>
  702. <div class="codewrapper">
  703. <pre><code class="lang-csharp hljs">public IEnumerable&lt;T&gt; Objects { get; }</code></pre>
  704. </div>
  705. <h5 class="propertyValue">Property Value</h5>
  706. <table class="table table-bordered table-striped table-condensed">
  707. <thead>
  708. <tr>
  709. <th>Type</th>
  710. <th>Description</th>
  711. </tr>
  712. </thead>
  713. <tbody>
  714. <tr>
  715. <td><span class="xref">System.Collections.Generic.IEnumerable</span>&lt;T&gt;</td>
  716. <td></td>
  717. </tr>
  718. </tbody>
  719. </table>
  720. <a id="Terminal_Gui_TreeView_1_ScrollOffsetHorizontal_" data-uid="Terminal.Gui.TreeView`1.ScrollOffsetHorizontal*"></a>
  721. <h4 id="Terminal_Gui_TreeView_1_ScrollOffsetHorizontal" data-uid="Terminal.Gui.TreeView`1.ScrollOffsetHorizontal">ScrollOffsetHorizontal</h4>
  722. <div class="markdown level1 summary">
  723. The amount of tree view that has been scrolled to the right (horizontally)
  724. </div>
  725. <div class="markdown level1 conceptual"></div>
  726. <h5 class="decalaration">Declaration</h5>
  727. <div class="codewrapper">
  728. <pre><code class="lang-csharp hljs">public int ScrollOffsetHorizontal { get; set; }</code></pre>
  729. </div>
  730. <h5 class="propertyValue">Property Value</h5>
  731. <table class="table table-bordered table-striped table-condensed">
  732. <thead>
  733. <tr>
  734. <th>Type</th>
  735. <th>Description</th>
  736. </tr>
  737. </thead>
  738. <tbody>
  739. <tr>
  740. <td><span class="xref">System.Int32</span></td>
  741. <td></td>
  742. </tr>
  743. </tbody>
  744. </table>
  745. <h5 id="Terminal_Gui_TreeView_1_ScrollOffsetHorizontal_remarks">Remarks</h5>
  746. <div class="markdown level1 remarks">Setting a value of less than 0 will result in a offset of 0. To see changes
  747. in the UI call <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_SetNeedsDisplay">SetNeedsDisplay()</a></div>
  748. <a id="Terminal_Gui_TreeView_1_ScrollOffsetVertical_" data-uid="Terminal.Gui.TreeView`1.ScrollOffsetVertical*"></a>
  749. <h4 id="Terminal_Gui_TreeView_1_ScrollOffsetVertical" data-uid="Terminal.Gui.TreeView`1.ScrollOffsetVertical">ScrollOffsetVertical</h4>
  750. <div class="markdown level1 summary">
  751. The amount of tree view that has been scrolled off the top of the screen (by the user
  752. scrolling down)
  753. </div>
  754. <div class="markdown level1 conceptual"></div>
  755. <h5 class="decalaration">Declaration</h5>
  756. <div class="codewrapper">
  757. <pre><code class="lang-csharp hljs">public int ScrollOffsetVertical { get; set; }</code></pre>
  758. </div>
  759. <h5 class="propertyValue">Property Value</h5>
  760. <table class="table table-bordered table-striped table-condensed">
  761. <thead>
  762. <tr>
  763. <th>Type</th>
  764. <th>Description</th>
  765. </tr>
  766. </thead>
  767. <tbody>
  768. <tr>
  769. <td><span class="xref">System.Int32</span></td>
  770. <td></td>
  771. </tr>
  772. </tbody>
  773. </table>
  774. <h5 id="Terminal_Gui_TreeView_1_ScrollOffsetVertical_remarks">Remarks</h5>
  775. <div class="markdown level1 remarks">Setting a value of less than 0 will result in a offset of 0. To see changes
  776. in the UI call <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_SetNeedsDisplay">SetNeedsDisplay()</a></div>
  777. <a id="Terminal_Gui_TreeView_1_SelectedObject_" data-uid="Terminal.Gui.TreeView`1.SelectedObject*"></a>
  778. <h4 id="Terminal_Gui_TreeView_1_SelectedObject" data-uid="Terminal.Gui.TreeView`1.SelectedObject">SelectedObject</h4>
  779. <div class="markdown level1 summary">
  780. The currently selected object in the tree. When <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_MultiSelect">MultiSelect</a> is true this
  781. is the object at which the cursor is at
  782. </div>
  783. <div class="markdown level1 conceptual"></div>
  784. <h5 class="decalaration">Declaration</h5>
  785. <div class="codewrapper">
  786. <pre><code class="lang-csharp hljs">public T SelectedObject { get; set; }</code></pre>
  787. </div>
  788. <h5 class="propertyValue">Property Value</h5>
  789. <table class="table table-bordered table-striped table-condensed">
  790. <thead>
  791. <tr>
  792. <th>Type</th>
  793. <th>Description</th>
  794. </tr>
  795. </thead>
  796. <tbody>
  797. <tr>
  798. <td><span class="xref">T</span></td>
  799. <td></td>
  800. </tr>
  801. </tbody>
  802. </table>
  803. <a id="Terminal_Gui_TreeView_1_Style_" data-uid="Terminal.Gui.TreeView`1.Style*"></a>
  804. <h4 id="Terminal_Gui_TreeView_1_Style" data-uid="Terminal.Gui.TreeView`1.Style">Style</h4>
  805. <div class="markdown level1 summary">
  806. Contains options for changing how the tree is rendered
  807. </div>
  808. <div class="markdown level1 conceptual"></div>
  809. <h5 class="decalaration">Declaration</h5>
  810. <div class="codewrapper">
  811. <pre><code class="lang-csharp hljs">public TreeStyle Style { get; set; }</code></pre>
  812. </div>
  813. <h5 class="propertyValue">Property Value</h5>
  814. <table class="table table-bordered table-striped table-condensed">
  815. <thead>
  816. <tr>
  817. <th>Type</th>
  818. <th>Description</th>
  819. </tr>
  820. </thead>
  821. <tbody>
  822. <tr>
  823. <td><a class="xref" href="Terminal.Gui.Trees.TreeStyle.html">TreeStyle</a></td>
  824. <td></td>
  825. </tr>
  826. </tbody>
  827. </table>
  828. <a id="Terminal_Gui_TreeView_1_TreeBuilder_" data-uid="Terminal.Gui.TreeView`1.TreeBuilder*"></a>
  829. <h4 id="Terminal_Gui_TreeView_1_TreeBuilder" data-uid="Terminal.Gui.TreeView`1.TreeBuilder">TreeBuilder</h4>
  830. <div class="markdown level1 summary">
  831. Determines how sub branches of the tree are dynamically built at runtime as the user
  832. expands root nodes
  833. </div>
  834. <div class="markdown level1 conceptual"></div>
  835. <h5 class="decalaration">Declaration</h5>
  836. <div class="codewrapper">
  837. <pre><code class="lang-csharp hljs">public ITreeBuilder&lt;T&gt; TreeBuilder { get; set; }</code></pre>
  838. </div>
  839. <h5 class="propertyValue">Property Value</h5>
  840. <table class="table table-bordered table-striped table-condensed">
  841. <thead>
  842. <tr>
  843. <th>Type</th>
  844. <th>Description</th>
  845. </tr>
  846. </thead>
  847. <tbody>
  848. <tr>
  849. <td><a class="xref" href="Terminal.Gui.Trees.ITreeBuilder-1.html">ITreeBuilder</a>&lt;T&gt;</td>
  850. <td></td>
  851. </tr>
  852. </tbody>
  853. </table>
  854. <h3 id="methods">Methods
  855. </h3>
  856. <a id="Terminal_Gui_TreeView_1_AddObject_" data-uid="Terminal.Gui.TreeView`1.AddObject*"></a>
  857. <h4 id="Terminal_Gui_TreeView_1_AddObject__0_" data-uid="Terminal.Gui.TreeView`1.AddObject(`0)">AddObject(T)</h4>
  858. <div class="markdown level1 summary">
  859. Adds a new root level object unless it is already a root of the tree
  860. </div>
  861. <div class="markdown level1 conceptual"></div>
  862. <h5 class="decalaration">Declaration</h5>
  863. <div class="codewrapper">
  864. <pre><code class="lang-csharp hljs">public void AddObject(T o)</code></pre>
  865. </div>
  866. <h5 class="parameters">Parameters</h5>
  867. <table class="table table-bordered table-striped table-condensed">
  868. <thead>
  869. <tr>
  870. <th>Type</th>
  871. <th>Name</th>
  872. <th>Description</th>
  873. </tr>
  874. </thead>
  875. <tbody>
  876. <tr>
  877. <td><span class="xref">T</span></td>
  878. <td><span class="parametername">o</span></td>
  879. <td></td>
  880. </tr>
  881. </tbody>
  882. </table>
  883. <a id="Terminal_Gui_TreeView_1_AddObjects_" data-uid="Terminal.Gui.TreeView`1.AddObjects*"></a>
  884. <h4 id="Terminal_Gui_TreeView_1_AddObjects_System_Collections_Generic_IEnumerable__0__" data-uid="Terminal.Gui.TreeView`1.AddObjects(System.Collections.Generic.IEnumerable{`0})">AddObjects(IEnumerable&lt;T&gt;)</h4>
  885. <div class="markdown level1 summary">
  886. Adds many new root level objects. Objects that are already root objects are ignored
  887. </div>
  888. <div class="markdown level1 conceptual"></div>
  889. <h5 class="decalaration">Declaration</h5>
  890. <div class="codewrapper">
  891. <pre><code class="lang-csharp hljs">public void AddObjects(IEnumerable&lt;T&gt; collection)</code></pre>
  892. </div>
  893. <h5 class="parameters">Parameters</h5>
  894. <table class="table table-bordered table-striped table-condensed">
  895. <thead>
  896. <tr>
  897. <th>Type</th>
  898. <th>Name</th>
  899. <th>Description</th>
  900. </tr>
  901. </thead>
  902. <tbody>
  903. <tr>
  904. <td><span class="xref">System.Collections.Generic.IEnumerable</span>&lt;T&gt;</td>
  905. <td><span class="parametername">collection</span></td>
  906. <td>Objects to add as new root level objects</td>
  907. </tr>
  908. </tbody>
  909. </table>
  910. <a id="Terminal_Gui_TreeView_1_AdjustSelection_" data-uid="Terminal.Gui.TreeView`1.AdjustSelection*"></a>
  911. <h4 id="Terminal_Gui_TreeView_1_AdjustSelection_System_Int32_System_Boolean_" data-uid="Terminal.Gui.TreeView`1.AdjustSelection(System.Int32,System.Boolean)">AdjustSelection(Int32, Boolean)</h4>
  912. <div class="markdown level1 summary">
  913. The number of screen lines to move the currently selected object by. Supports negative
  914. <code data-dev-comment-type="paramref" class="paramref">offset</code>. Each branch occupies 1 line on screen
  915. </div>
  916. <div class="markdown level1 conceptual"></div>
  917. <h5 class="decalaration">Declaration</h5>
  918. <div class="codewrapper">
  919. <pre><code class="lang-csharp hljs">public void AdjustSelection(int offset, bool expandSelection = false)</code></pre>
  920. </div>
  921. <h5 class="parameters">Parameters</h5>
  922. <table class="table table-bordered table-striped table-condensed">
  923. <thead>
  924. <tr>
  925. <th>Type</th>
  926. <th>Name</th>
  927. <th>Description</th>
  928. </tr>
  929. </thead>
  930. <tbody>
  931. <tr>
  932. <td><span class="xref">System.Int32</span></td>
  933. <td><span class="parametername">offset</span></td>
  934. <td>Positive to move the selection down the screen, negative to move it up</td>
  935. </tr>
  936. <tr>
  937. <td><span class="xref">System.Boolean</span></td>
  938. <td><span class="parametername">expandSelection</span></td>
  939. <td>True to expand the selection (assuming
  940. <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_MultiSelect">MultiSelect</a> is enabled). False to replace</td>
  941. </tr>
  942. </tbody>
  943. </table>
  944. <h5 id="Terminal_Gui_TreeView_1_AdjustSelection_System_Int32_System_Boolean__remarks">Remarks</h5>
  945. <div class="markdown level1 remarks">If nothing is currently selected or the selected object is no longer in the tree
  946. then the first object in the tree is selected instead</div>
  947. <a id="Terminal_Gui_TreeView_1_AdjustSelectionToBranchEnd_" data-uid="Terminal.Gui.TreeView`1.AdjustSelectionToBranchEnd*"></a>
  948. <h4 id="Terminal_Gui_TreeView_1_AdjustSelectionToBranchEnd" data-uid="Terminal.Gui.TreeView`1.AdjustSelectionToBranchEnd">AdjustSelectionToBranchEnd()</h4>
  949. <div class="markdown level1 summary">
  950. Moves the selection to the last child in the currently selected level
  951. </div>
  952. <div class="markdown level1 conceptual"></div>
  953. <h5 class="decalaration">Declaration</h5>
  954. <div class="codewrapper">
  955. <pre><code class="lang-csharp hljs">public void AdjustSelectionToBranchEnd()</code></pre>
  956. </div>
  957. <a id="Terminal_Gui_TreeView_1_AdjustSelectionToBranchStart_" data-uid="Terminal.Gui.TreeView`1.AdjustSelectionToBranchStart*"></a>
  958. <h4 id="Terminal_Gui_TreeView_1_AdjustSelectionToBranchStart" data-uid="Terminal.Gui.TreeView`1.AdjustSelectionToBranchStart">AdjustSelectionToBranchStart()</h4>
  959. <div class="markdown level1 summary">
  960. Moves the selection to the first child in the currently selected level
  961. </div>
  962. <div class="markdown level1 conceptual"></div>
  963. <h5 class="decalaration">Declaration</h5>
  964. <div class="codewrapper">
  965. <pre><code class="lang-csharp hljs">public void AdjustSelectionToBranchStart()</code></pre>
  966. </div>
  967. <a id="Terminal_Gui_TreeView_1_CanExpand_" data-uid="Terminal.Gui.TreeView`1.CanExpand*"></a>
  968. <h4 id="Terminal_Gui_TreeView_1_CanExpand__0_" data-uid="Terminal.Gui.TreeView`1.CanExpand(`0)">CanExpand(T)</h4>
  969. <div class="markdown level1 summary">
  970. Returns true if the given object <code data-dev-comment-type="paramref" class="paramref">o</code> is exposed in the tree and can be
  971. expanded otherwise false
  972. </div>
  973. <div class="markdown level1 conceptual"></div>
  974. <h5 class="decalaration">Declaration</h5>
  975. <div class="codewrapper">
  976. <pre><code class="lang-csharp hljs">public bool CanExpand(T o)</code></pre>
  977. </div>
  978. <h5 class="parameters">Parameters</h5>
  979. <table class="table table-bordered table-striped table-condensed">
  980. <thead>
  981. <tr>
  982. <th>Type</th>
  983. <th>Name</th>
  984. <th>Description</th>
  985. </tr>
  986. </thead>
  987. <tbody>
  988. <tr>
  989. <td><span class="xref">T</span></td>
  990. <td><span class="parametername">o</span></td>
  991. <td></td>
  992. </tr>
  993. </tbody>
  994. </table>
  995. <h5 class="returns">Returns</h5>
  996. <table class="table table-bordered table-striped table-condensed">
  997. <thead>
  998. <tr>
  999. <th>Type</th>
  1000. <th>Description</th>
  1001. </tr>
  1002. </thead>
  1003. <tbody>
  1004. <tr>
  1005. <td><span class="xref">System.Boolean</span></td>
  1006. <td></td>
  1007. </tr>
  1008. </tbody>
  1009. </table>
  1010. <a id="Terminal_Gui_TreeView_1_ClearObjects_" data-uid="Terminal.Gui.TreeView`1.ClearObjects*"></a>
  1011. <h4 id="Terminal_Gui_TreeView_1_ClearObjects" data-uid="Terminal.Gui.TreeView`1.ClearObjects">ClearObjects()</h4>
  1012. <div class="markdown level1 summary">
  1013. Removes all objects from the tree and clears <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_SelectedObject">SelectedObject</a>
  1014. </div>
  1015. <div class="markdown level1 conceptual"></div>
  1016. <h5 class="decalaration">Declaration</h5>
  1017. <div class="codewrapper">
  1018. <pre><code class="lang-csharp hljs">public void ClearObjects()</code></pre>
  1019. </div>
  1020. <a id="Terminal_Gui_TreeView_1_Collapse_" data-uid="Terminal.Gui.TreeView`1.Collapse*"></a>
  1021. <h4 id="Terminal_Gui_TreeView_1_Collapse__0_" data-uid="Terminal.Gui.TreeView`1.Collapse(`0)">Collapse(T)</h4>
  1022. <div class="markdown level1 summary">
  1023. Collapses the supplied object if it is currently expanded
  1024. </div>
  1025. <div class="markdown level1 conceptual"></div>
  1026. <h5 class="decalaration">Declaration</h5>
  1027. <div class="codewrapper">
  1028. <pre><code class="lang-csharp hljs">public void Collapse(T toCollapse)</code></pre>
  1029. </div>
  1030. <h5 class="parameters">Parameters</h5>
  1031. <table class="table table-bordered table-striped table-condensed">
  1032. <thead>
  1033. <tr>
  1034. <th>Type</th>
  1035. <th>Name</th>
  1036. <th>Description</th>
  1037. </tr>
  1038. </thead>
  1039. <tbody>
  1040. <tr>
  1041. <td><span class="xref">T</span></td>
  1042. <td><span class="parametername">toCollapse</span></td>
  1043. <td>The object to collapse</td>
  1044. </tr>
  1045. </tbody>
  1046. </table>
  1047. <a id="Terminal_Gui_TreeView_1_CollapseAll_" data-uid="Terminal.Gui.TreeView`1.CollapseAll*"></a>
  1048. <h4 id="Terminal_Gui_TreeView_1_CollapseAll" data-uid="Terminal.Gui.TreeView`1.CollapseAll">CollapseAll()</h4>
  1049. <div class="markdown level1 summary">
  1050. Collapses all root nodes in the tree
  1051. </div>
  1052. <div class="markdown level1 conceptual"></div>
  1053. <h5 class="decalaration">Declaration</h5>
  1054. <div class="codewrapper">
  1055. <pre><code class="lang-csharp hljs">public void CollapseAll()</code></pre>
  1056. </div>
  1057. <a id="Terminal_Gui_TreeView_1_CollapseAll_" data-uid="Terminal.Gui.TreeView`1.CollapseAll*"></a>
  1058. <h4 id="Terminal_Gui_TreeView_1_CollapseAll__0_" data-uid="Terminal.Gui.TreeView`1.CollapseAll(`0)">CollapseAll(T)</h4>
  1059. <div class="markdown level1 summary">
  1060. Collapses the supplied object if it is currently expanded. Also collapses all children
  1061. branches (this will only become apparent when/if the user expands it again)
  1062. </div>
  1063. <div class="markdown level1 conceptual"></div>
  1064. <h5 class="decalaration">Declaration</h5>
  1065. <div class="codewrapper">
  1066. <pre><code class="lang-csharp hljs">public void CollapseAll(T toCollapse)</code></pre>
  1067. </div>
  1068. <h5 class="parameters">Parameters</h5>
  1069. <table class="table table-bordered table-striped table-condensed">
  1070. <thead>
  1071. <tr>
  1072. <th>Type</th>
  1073. <th>Name</th>
  1074. <th>Description</th>
  1075. </tr>
  1076. </thead>
  1077. <tbody>
  1078. <tr>
  1079. <td><span class="xref">T</span></td>
  1080. <td><span class="parametername">toCollapse</span></td>
  1081. <td>The object to collapse</td>
  1082. </tr>
  1083. </tbody>
  1084. </table>
  1085. <a id="Terminal_Gui_TreeView_1_CollapseImpl_" data-uid="Terminal.Gui.TreeView`1.CollapseImpl*"></a>
  1086. <h4 id="Terminal_Gui_TreeView_1_CollapseImpl__0_System_Boolean_" data-uid="Terminal.Gui.TreeView`1.CollapseImpl(`0,System.Boolean)">CollapseImpl(T, Boolean)</h4>
  1087. <div class="markdown level1 summary">
  1088. Implementation of <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_Collapse__0_">Collapse(T)</a> and <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_CollapseAll__0_">CollapseAll(T)</a>. Performs
  1089. operation and updates selection if disapeared
  1090. </div>
  1091. <div class="markdown level1 conceptual"></div>
  1092. <h5 class="decalaration">Declaration</h5>
  1093. <div class="codewrapper">
  1094. <pre><code class="lang-csharp hljs">protected void CollapseImpl(T toCollapse, bool all)</code></pre>
  1095. </div>
  1096. <h5 class="parameters">Parameters</h5>
  1097. <table class="table table-bordered table-striped table-condensed">
  1098. <thead>
  1099. <tr>
  1100. <th>Type</th>
  1101. <th>Name</th>
  1102. <th>Description</th>
  1103. </tr>
  1104. </thead>
  1105. <tbody>
  1106. <tr>
  1107. <td><span class="xref">T</span></td>
  1108. <td><span class="parametername">toCollapse</span></td>
  1109. <td></td>
  1110. </tr>
  1111. <tr>
  1112. <td><span class="xref">System.Boolean</span></td>
  1113. <td><span class="parametername">all</span></td>
  1114. <td></td>
  1115. </tr>
  1116. </tbody>
  1117. </table>
  1118. <a id="Terminal_Gui_TreeView_1_CursorLeft_" data-uid="Terminal.Gui.TreeView`1.CursorLeft*"></a>
  1119. <h4 id="Terminal_Gui_TreeView_1_CursorLeft_System_Boolean_" data-uid="Terminal.Gui.TreeView`1.CursorLeft(System.Boolean)">CursorLeft(Boolean)</h4>
  1120. <div class="markdown level1 summary">
  1121. Determines systems behaviour when the left arrow key is pressed. Default behaviour is
  1122. to collapse the current tree node if possible otherwise changes selection to current
  1123. branches parent
  1124. </div>
  1125. <div class="markdown level1 conceptual"></div>
  1126. <h5 class="decalaration">Declaration</h5>
  1127. <div class="codewrapper">
  1128. <pre><code class="lang-csharp hljs">protected virtual void CursorLeft(bool ctrl)</code></pre>
  1129. </div>
  1130. <h5 class="parameters">Parameters</h5>
  1131. <table class="table table-bordered table-striped table-condensed">
  1132. <thead>
  1133. <tr>
  1134. <th>Type</th>
  1135. <th>Name</th>
  1136. <th>Description</th>
  1137. </tr>
  1138. </thead>
  1139. <tbody>
  1140. <tr>
  1141. <td><span class="xref">System.Boolean</span></td>
  1142. <td><span class="parametername">ctrl</span></td>
  1143. <td></td>
  1144. </tr>
  1145. </tbody>
  1146. </table>
  1147. <a id="Terminal_Gui_TreeView_1_EnsureVisible_" data-uid="Terminal.Gui.TreeView`1.EnsureVisible*"></a>
  1148. <h4 id="Terminal_Gui_TreeView_1_EnsureVisible__0_" data-uid="Terminal.Gui.TreeView`1.EnsureVisible(`0)">EnsureVisible(T)</h4>
  1149. <div class="markdown level1 summary">
  1150. Adjusts the <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_ScrollOffsetVertical">ScrollOffsetVertical</a> to ensure the given
  1151. <code data-dev-comment-type="paramref" class="paramref">model</code> is visible. Has no effect if already visible
  1152. </div>
  1153. <div class="markdown level1 conceptual"></div>
  1154. <h5 class="decalaration">Declaration</h5>
  1155. <div class="codewrapper">
  1156. <pre><code class="lang-csharp hljs">public void EnsureVisible(T model)</code></pre>
  1157. </div>
  1158. <h5 class="parameters">Parameters</h5>
  1159. <table class="table table-bordered table-striped table-condensed">
  1160. <thead>
  1161. <tr>
  1162. <th>Type</th>
  1163. <th>Name</th>
  1164. <th>Description</th>
  1165. </tr>
  1166. </thead>
  1167. <tbody>
  1168. <tr>
  1169. <td><span class="xref">T</span></td>
  1170. <td><span class="parametername">model</span></td>
  1171. <td></td>
  1172. </tr>
  1173. </tbody>
  1174. </table>
  1175. <a id="Terminal_Gui_TreeView_1_Expand_" data-uid="Terminal.Gui.TreeView`1.Expand*"></a>
  1176. <h4 id="Terminal_Gui_TreeView_1_Expand__0_" data-uid="Terminal.Gui.TreeView`1.Expand(`0)">Expand(T)</h4>
  1177. <div class="markdown level1 summary">
  1178. Expands the supplied object if it is contained in the tree (either as a root object or
  1179. as an exposed branch object)
  1180. </div>
  1181. <div class="markdown level1 conceptual"></div>
  1182. <h5 class="decalaration">Declaration</h5>
  1183. <div class="codewrapper">
  1184. <pre><code class="lang-csharp hljs">public void Expand(T toExpand)</code></pre>
  1185. </div>
  1186. <h5 class="parameters">Parameters</h5>
  1187. <table class="table table-bordered table-striped table-condensed">
  1188. <thead>
  1189. <tr>
  1190. <th>Type</th>
  1191. <th>Name</th>
  1192. <th>Description</th>
  1193. </tr>
  1194. </thead>
  1195. <tbody>
  1196. <tr>
  1197. <td><span class="xref">T</span></td>
  1198. <td><span class="parametername">toExpand</span></td>
  1199. <td>The object to expand</td>
  1200. </tr>
  1201. </tbody>
  1202. </table>
  1203. <a id="Terminal_Gui_TreeView_1_ExpandAll_" data-uid="Terminal.Gui.TreeView`1.ExpandAll*"></a>
  1204. <h4 id="Terminal_Gui_TreeView_1_ExpandAll" data-uid="Terminal.Gui.TreeView`1.ExpandAll">ExpandAll()</h4>
  1205. <div class="markdown level1 summary">
  1206. Fully expands all nodes in the tree, if the tree is very big and built dynamically this
  1207. may take a while (e.g. for file system)
  1208. </div>
  1209. <div class="markdown level1 conceptual"></div>
  1210. <h5 class="decalaration">Declaration</h5>
  1211. <div class="codewrapper">
  1212. <pre><code class="lang-csharp hljs">public void ExpandAll()</code></pre>
  1213. </div>
  1214. <a id="Terminal_Gui_TreeView_1_ExpandAll_" data-uid="Terminal.Gui.TreeView`1.ExpandAll*"></a>
  1215. <h4 id="Terminal_Gui_TreeView_1_ExpandAll__0_" data-uid="Terminal.Gui.TreeView`1.ExpandAll(`0)">ExpandAll(T)</h4>
  1216. <div class="markdown level1 summary">
  1217. Expands the supplied object and all child objects
  1218. </div>
  1219. <div class="markdown level1 conceptual"></div>
  1220. <h5 class="decalaration">Declaration</h5>
  1221. <div class="codewrapper">
  1222. <pre><code class="lang-csharp hljs">public void ExpandAll(T toExpand)</code></pre>
  1223. </div>
  1224. <h5 class="parameters">Parameters</h5>
  1225. <table class="table table-bordered table-striped table-condensed">
  1226. <thead>
  1227. <tr>
  1228. <th>Type</th>
  1229. <th>Name</th>
  1230. <th>Description</th>
  1231. </tr>
  1232. </thead>
  1233. <tbody>
  1234. <tr>
  1235. <td><span class="xref">T</span></td>
  1236. <td><span class="parametername">toExpand</span></td>
  1237. <td>The object to expand</td>
  1238. </tr>
  1239. </tbody>
  1240. </table>
  1241. <a id="Terminal_Gui_TreeView_1_GetAllSelectedObjects_" data-uid="Terminal.Gui.TreeView`1.GetAllSelectedObjects*"></a>
  1242. <h4 id="Terminal_Gui_TreeView_1_GetAllSelectedObjects" data-uid="Terminal.Gui.TreeView`1.GetAllSelectedObjects">GetAllSelectedObjects()</h4>
  1243. <div class="markdown level1 summary">
  1244. Returns <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_SelectedObject">SelectedObject</a> (if not null) and all multi selected objects if
  1245. <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_MultiSelect">MultiSelect</a> is true
  1246. </div>
  1247. <div class="markdown level1 conceptual"></div>
  1248. <h5 class="decalaration">Declaration</h5>
  1249. <div class="codewrapper">
  1250. <pre><code class="lang-csharp hljs">public IEnumerable&lt;T&gt; GetAllSelectedObjects()</code></pre>
  1251. </div>
  1252. <h5 class="returns">Returns</h5>
  1253. <table class="table table-bordered table-striped table-condensed">
  1254. <thead>
  1255. <tr>
  1256. <th>Type</th>
  1257. <th>Description</th>
  1258. </tr>
  1259. </thead>
  1260. <tbody>
  1261. <tr>
  1262. <td><span class="xref">System.Collections.Generic.IEnumerable</span>&lt;T&gt;</td>
  1263. <td></td>
  1264. </tr>
  1265. </tbody>
  1266. </table>
  1267. <a id="Terminal_Gui_TreeView_1_GetChildren_" data-uid="Terminal.Gui.TreeView`1.GetChildren*"></a>
  1268. <h4 id="Terminal_Gui_TreeView_1_GetChildren__0_" data-uid="Terminal.Gui.TreeView`1.GetChildren(`0)">GetChildren(T)</h4>
  1269. <div class="markdown level1 summary">
  1270. Returns the currently expanded children of the passed object. Returns an empty
  1271. collection if the branch is not exposed or not expanded
  1272. </div>
  1273. <div class="markdown level1 conceptual"></div>
  1274. <h5 class="decalaration">Declaration</h5>
  1275. <div class="codewrapper">
  1276. <pre><code class="lang-csharp hljs">public IEnumerable&lt;T&gt; GetChildren(T o)</code></pre>
  1277. </div>
  1278. <h5 class="parameters">Parameters</h5>
  1279. <table class="table table-bordered table-striped table-condensed">
  1280. <thead>
  1281. <tr>
  1282. <th>Type</th>
  1283. <th>Name</th>
  1284. <th>Description</th>
  1285. </tr>
  1286. </thead>
  1287. <tbody>
  1288. <tr>
  1289. <td><span class="xref">T</span></td>
  1290. <td><span class="parametername">o</span></td>
  1291. <td>An object in the tree</td>
  1292. </tr>
  1293. </tbody>
  1294. </table>
  1295. <h5 class="returns">Returns</h5>
  1296. <table class="table table-bordered table-striped table-condensed">
  1297. <thead>
  1298. <tr>
  1299. <th>Type</th>
  1300. <th>Description</th>
  1301. </tr>
  1302. </thead>
  1303. <tbody>
  1304. <tr>
  1305. <td><span class="xref">System.Collections.Generic.IEnumerable</span>&lt;T&gt;</td>
  1306. <td></td>
  1307. </tr>
  1308. </tbody>
  1309. </table>
  1310. <a id="Terminal_Gui_TreeView_1_GetContentWidth_" data-uid="Terminal.Gui.TreeView`1.GetContentWidth*"></a>
  1311. <h4 id="Terminal_Gui_TreeView_1_GetContentWidth_System_Boolean_" data-uid="Terminal.Gui.TreeView`1.GetContentWidth(System.Boolean)">GetContentWidth(Boolean)</h4>
  1312. <div class="markdown level1 summary">
  1313. Returns the maximum width line in the tree including prefix and expansion symbols
  1314. </div>
  1315. <div class="markdown level1 conceptual"></div>
  1316. <h5 class="decalaration">Declaration</h5>
  1317. <div class="codewrapper">
  1318. <pre><code class="lang-csharp hljs">public int GetContentWidth(bool visible)</code></pre>
  1319. </div>
  1320. <h5 class="parameters">Parameters</h5>
  1321. <table class="table table-bordered table-striped table-condensed">
  1322. <thead>
  1323. <tr>
  1324. <th>Type</th>
  1325. <th>Name</th>
  1326. <th>Description</th>
  1327. </tr>
  1328. </thead>
  1329. <tbody>
  1330. <tr>
  1331. <td><span class="xref">System.Boolean</span></td>
  1332. <td><span class="parametername">visible</span></td>
  1333. <td>True to consider only rows currently visible (based on window
  1334. bounds and <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_ScrollOffsetVertical">ScrollOffsetVertical</a>. False to calculate the width of
  1335. every exposed branch in the tree</td>
  1336. </tr>
  1337. </tbody>
  1338. </table>
  1339. <h5 class="returns">Returns</h5>
  1340. <table class="table table-bordered table-striped table-condensed">
  1341. <thead>
  1342. <tr>
  1343. <th>Type</th>
  1344. <th>Description</th>
  1345. </tr>
  1346. </thead>
  1347. <tbody>
  1348. <tr>
  1349. <td><span class="xref">System.Int32</span></td>
  1350. <td></td>
  1351. </tr>
  1352. </tbody>
  1353. </table>
  1354. <a id="Terminal_Gui_TreeView_1_GetParent_" data-uid="Terminal.Gui.TreeView`1.GetParent*"></a>
  1355. <h4 id="Terminal_Gui_TreeView_1_GetParent__0_" data-uid="Terminal.Gui.TreeView`1.GetParent(`0)">GetParent(T)</h4>
  1356. <div class="markdown level1 summary">
  1357. Returns the parent object of <code data-dev-comment-type="paramref" class="paramref">o</code> in the tree. Returns null if
  1358. the object is not exposed in the tree
  1359. </div>
  1360. <div class="markdown level1 conceptual"></div>
  1361. <h5 class="decalaration">Declaration</h5>
  1362. <div class="codewrapper">
  1363. <pre><code class="lang-csharp hljs">public T GetParent(T o)</code></pre>
  1364. </div>
  1365. <h5 class="parameters">Parameters</h5>
  1366. <table class="table table-bordered table-striped table-condensed">
  1367. <thead>
  1368. <tr>
  1369. <th>Type</th>
  1370. <th>Name</th>
  1371. <th>Description</th>
  1372. </tr>
  1373. </thead>
  1374. <tbody>
  1375. <tr>
  1376. <td><span class="xref">T</span></td>
  1377. <td><span class="parametername">o</span></td>
  1378. <td>An object in the tree</td>
  1379. </tr>
  1380. </tbody>
  1381. </table>
  1382. <h5 class="returns">Returns</h5>
  1383. <table class="table table-bordered table-striped table-condensed">
  1384. <thead>
  1385. <tr>
  1386. <th>Type</th>
  1387. <th>Description</th>
  1388. </tr>
  1389. </thead>
  1390. <tbody>
  1391. <tr>
  1392. <td><span class="xref">T</span></td>
  1393. <td></td>
  1394. </tr>
  1395. </tbody>
  1396. </table>
  1397. <a id="Terminal_Gui_TreeView_1_GetScrollOffsetOf_" data-uid="Terminal.Gui.TreeView`1.GetScrollOffsetOf*"></a>
  1398. <h4 id="Terminal_Gui_TreeView_1_GetScrollOffsetOf__0_" data-uid="Terminal.Gui.TreeView`1.GetScrollOffsetOf(`0)">GetScrollOffsetOf(T)</h4>
  1399. <div class="markdown level1 summary">
  1400. Returns the index of the object <code data-dev-comment-type="paramref" class="paramref">o</code> if it is currently exposed (it&apos;s
  1401. parent(s) have been expanded). This can be used with <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_ScrollOffsetVertical">ScrollOffsetVertical</a>
  1402. and <a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_SetNeedsDisplay">SetNeedsDisplay()</a> to scroll to a specific object
  1403. </div>
  1404. <div class="markdown level1 conceptual"></div>
  1405. <h5 class="decalaration">Declaration</h5>
  1406. <div class="codewrapper">
  1407. <pre><code class="lang-csharp hljs">public int GetScrollOffsetOf(T o)</code></pre>
  1408. </div>
  1409. <h5 class="parameters">Parameters</h5>
  1410. <table class="table table-bordered table-striped table-condensed">
  1411. <thead>
  1412. <tr>
  1413. <th>Type</th>
  1414. <th>Name</th>
  1415. <th>Description</th>
  1416. </tr>
  1417. </thead>
  1418. <tbody>
  1419. <tr>
  1420. <td><span class="xref">T</span></td>
  1421. <td><span class="parametername">o</span></td>
  1422. <td>An object that appears in your tree and is currently exposed</td>
  1423. </tr>
  1424. </tbody>
  1425. </table>
  1426. <h5 class="returns">Returns</h5>
  1427. <table class="table table-bordered table-striped table-condensed">
  1428. <thead>
  1429. <tr>
  1430. <th>Type</th>
  1431. <th>Description</th>
  1432. </tr>
  1433. </thead>
  1434. <tbody>
  1435. <tr>
  1436. <td><span class="xref">System.Int32</span></td>
  1437. <td>The index the object was found at or -1 if it is not currently revealed or
  1438. not in the tree at all</td>
  1439. </tr>
  1440. </tbody>
  1441. </table>
  1442. <h5 id="Terminal_Gui_TreeView_1_GetScrollOffsetOf__0__remarks">Remarks</h5>
  1443. <div class="markdown level1 remarks">Uses the Equals method and returns the first index at which the object is found
  1444. or -1 if it is not found</div>
  1445. <a id="Terminal_Gui_TreeView_1_GoTo_" data-uid="Terminal.Gui.TreeView`1.GoTo*"></a>
  1446. <h4 id="Terminal_Gui_TreeView_1_GoTo__0_" data-uid="Terminal.Gui.TreeView`1.GoTo(`0)">GoTo(T)</h4>
  1447. <div class="markdown level1 summary">
  1448. Changes the <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_SelectedObject">SelectedObject</a> to <code data-dev-comment-type="paramref" class="paramref">toSelect</code> and scrolls to ensure
  1449. it is visible. Has no effect if <code data-dev-comment-type="paramref" class="paramref">toSelect</code> is not exposed in the tree (e.g.
  1450. its parents are collapsed)
  1451. </div>
  1452. <div class="markdown level1 conceptual"></div>
  1453. <h5 class="decalaration">Declaration</h5>
  1454. <div class="codewrapper">
  1455. <pre><code class="lang-csharp hljs">public void GoTo(T toSelect)</code></pre>
  1456. </div>
  1457. <h5 class="parameters">Parameters</h5>
  1458. <table class="table table-bordered table-striped table-condensed">
  1459. <thead>
  1460. <tr>
  1461. <th>Type</th>
  1462. <th>Name</th>
  1463. <th>Description</th>
  1464. </tr>
  1465. </thead>
  1466. <tbody>
  1467. <tr>
  1468. <td><span class="xref">T</span></td>
  1469. <td><span class="parametername">toSelect</span></td>
  1470. <td></td>
  1471. </tr>
  1472. </tbody>
  1473. </table>
  1474. <a id="Terminal_Gui_TreeView_1_GoToEnd_" data-uid="Terminal.Gui.TreeView`1.GoToEnd*"></a>
  1475. <h4 id="Terminal_Gui_TreeView_1_GoToEnd" data-uid="Terminal.Gui.TreeView`1.GoToEnd">GoToEnd()</h4>
  1476. <div class="markdown level1 summary">
  1477. Changes the <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_SelectedObject">SelectedObject</a> to the last object in the tree and scrolls so
  1478. that it is visible
  1479. </div>
  1480. <div class="markdown level1 conceptual"></div>
  1481. <h5 class="decalaration">Declaration</h5>
  1482. <div class="codewrapper">
  1483. <pre><code class="lang-csharp hljs">public void GoToEnd()</code></pre>
  1484. </div>
  1485. <a id="Terminal_Gui_TreeView_1_GoToFirst_" data-uid="Terminal.Gui.TreeView`1.GoToFirst*"></a>
  1486. <h4 id="Terminal_Gui_TreeView_1_GoToFirst" data-uid="Terminal.Gui.TreeView`1.GoToFirst">GoToFirst()</h4>
  1487. <div class="markdown level1 summary">
  1488. Changes the <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_SelectedObject">SelectedObject</a> to the first root object and resets
  1489. the <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_ScrollOffsetVertical">ScrollOffsetVertical</a> to 0
  1490. </div>
  1491. <div class="markdown level1 conceptual"></div>
  1492. <h5 class="decalaration">Declaration</h5>
  1493. <div class="codewrapper">
  1494. <pre><code class="lang-csharp hljs">public void GoToFirst()</code></pre>
  1495. </div>
  1496. <a id="Terminal_Gui_TreeView_1_InvalidateLineMap_" data-uid="Terminal.Gui.TreeView`1.InvalidateLineMap*"></a>
  1497. <h4 id="Terminal_Gui_TreeView_1_InvalidateLineMap" data-uid="Terminal.Gui.TreeView`1.InvalidateLineMap">InvalidateLineMap()</h4>
  1498. <div class="markdown level1 summary">
  1499. Clears any cached results of <span class="xref">Terminal.Gui.TreeView`1.BuildLineMap</span>
  1500. </div>
  1501. <div class="markdown level1 conceptual"></div>
  1502. <h5 class="decalaration">Declaration</h5>
  1503. <div class="codewrapper">
  1504. <pre><code class="lang-csharp hljs">protected void InvalidateLineMap()</code></pre>
  1505. </div>
  1506. <a id="Terminal_Gui_TreeView_1_IsExpanded_" data-uid="Terminal.Gui.TreeView`1.IsExpanded*"></a>
  1507. <h4 id="Terminal_Gui_TreeView_1_IsExpanded__0_" data-uid="Terminal.Gui.TreeView`1.IsExpanded(`0)">IsExpanded(T)</h4>
  1508. <div class="markdown level1 summary">
  1509. Returns true if the given object <code data-dev-comment-type="paramref" class="paramref">o</code> is exposed in the tree and
  1510. expanded otherwise false
  1511. </div>
  1512. <div class="markdown level1 conceptual"></div>
  1513. <h5 class="decalaration">Declaration</h5>
  1514. <div class="codewrapper">
  1515. <pre><code class="lang-csharp hljs">public bool IsExpanded(T o)</code></pre>
  1516. </div>
  1517. <h5 class="parameters">Parameters</h5>
  1518. <table class="table table-bordered table-striped table-condensed">
  1519. <thead>
  1520. <tr>
  1521. <th>Type</th>
  1522. <th>Name</th>
  1523. <th>Description</th>
  1524. </tr>
  1525. </thead>
  1526. <tbody>
  1527. <tr>
  1528. <td><span class="xref">T</span></td>
  1529. <td><span class="parametername">o</span></td>
  1530. <td></td>
  1531. </tr>
  1532. </tbody>
  1533. </table>
  1534. <h5 class="returns">Returns</h5>
  1535. <table class="table table-bordered table-striped table-condensed">
  1536. <thead>
  1537. <tr>
  1538. <th>Type</th>
  1539. <th>Description</th>
  1540. </tr>
  1541. </thead>
  1542. <tbody>
  1543. <tr>
  1544. <td><span class="xref">System.Boolean</span></td>
  1545. <td></td>
  1546. </tr>
  1547. </tbody>
  1548. </table>
  1549. <a id="Terminal_Gui_TreeView_1_IsSelected_" data-uid="Terminal.Gui.TreeView`1.IsSelected*"></a>
  1550. <h4 id="Terminal_Gui_TreeView_1_IsSelected__0_" data-uid="Terminal.Gui.TreeView`1.IsSelected(`0)">IsSelected(T)</h4>
  1551. <div class="markdown level1 summary">
  1552. Returns true if the <code data-dev-comment-type="paramref" class="paramref">model</code> is either the
  1553. <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_SelectedObject">SelectedObject</a> or part of a <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_MultiSelect">MultiSelect</a>
  1554. </div>
  1555. <div class="markdown level1 conceptual"></div>
  1556. <h5 class="decalaration">Declaration</h5>
  1557. <div class="codewrapper">
  1558. <pre><code class="lang-csharp hljs">public bool IsSelected(T model)</code></pre>
  1559. </div>
  1560. <h5 class="parameters">Parameters</h5>
  1561. <table class="table table-bordered table-striped table-condensed">
  1562. <thead>
  1563. <tr>
  1564. <th>Type</th>
  1565. <th>Name</th>
  1566. <th>Description</th>
  1567. </tr>
  1568. </thead>
  1569. <tbody>
  1570. <tr>
  1571. <td><span class="xref">T</span></td>
  1572. <td><span class="parametername">model</span></td>
  1573. <td></td>
  1574. </tr>
  1575. </tbody>
  1576. </table>
  1577. <h5 class="returns">Returns</h5>
  1578. <table class="table table-bordered table-striped table-condensed">
  1579. <thead>
  1580. <tr>
  1581. <th>Type</th>
  1582. <th>Description</th>
  1583. </tr>
  1584. </thead>
  1585. <tbody>
  1586. <tr>
  1587. <td><span class="xref">System.Boolean</span></td>
  1588. <td></td>
  1589. </tr>
  1590. </tbody>
  1591. </table>
  1592. <a id="Terminal_Gui_TreeView_1_MouseEvent_" data-uid="Terminal.Gui.TreeView`1.MouseEvent*"></a>
  1593. <h4 id="Terminal_Gui_TreeView_1_MouseEvent_Terminal_Gui_MouseEvent_" data-uid="Terminal.Gui.TreeView`1.MouseEvent(Terminal.Gui.MouseEvent)">MouseEvent(MouseEvent)</h4>
  1594. <div class="markdown level1 summary"></div>
  1595. <div class="markdown level1 conceptual"></div>
  1596. <h5 class="decalaration">Declaration</h5>
  1597. <div class="codewrapper">
  1598. <pre><code class="lang-csharp hljs">public override bool MouseEvent(MouseEvent me)</code></pre>
  1599. </div>
  1600. <h5 class="parameters">Parameters</h5>
  1601. <table class="table table-bordered table-striped table-condensed">
  1602. <thead>
  1603. <tr>
  1604. <th>Type</th>
  1605. <th>Name</th>
  1606. <th>Description</th>
  1607. </tr>
  1608. </thead>
  1609. <tbody>
  1610. <tr>
  1611. <td><a class="xref" href="Terminal.Gui.MouseEvent.html">MouseEvent</a></td>
  1612. <td><span class="parametername">me</span></td>
  1613. <td></td>
  1614. </tr>
  1615. </tbody>
  1616. </table>
  1617. <h5 class="returns">Returns</h5>
  1618. <table class="table table-bordered table-striped table-condensed">
  1619. <thead>
  1620. <tr>
  1621. <th>Type</th>
  1622. <th>Description</th>
  1623. </tr>
  1624. </thead>
  1625. <tbody>
  1626. <tr>
  1627. <td><span class="xref">System.Boolean</span></td>
  1628. <td></td>
  1629. </tr>
  1630. </tbody>
  1631. </table>
  1632. <h5 class="overrides">Overrides</h5>
  1633. <div><a class="xref" href="Terminal.Gui.Responder.html#Terminal_Gui_Responder_MouseEvent_Terminal_Gui_MouseEvent_">Responder.MouseEvent(MouseEvent)</a></div>
  1634. <a id="Terminal_Gui_TreeView_1_OnObjectActivated_" data-uid="Terminal.Gui.TreeView`1.OnObjectActivated*"></a>
  1635. <h4 id="Terminal_Gui_TreeView_1_OnObjectActivated_Terminal_Gui_Trees_ObjectActivatedEventArgs__0__" data-uid="Terminal.Gui.TreeView`1.OnObjectActivated(Terminal.Gui.Trees.ObjectActivatedEventArgs{`0})">OnObjectActivated(ObjectActivatedEventArgs&lt;T&gt;)</h4>
  1636. <div class="markdown level1 summary">
  1637. Raises the <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_ObjectActivated">ObjectActivated</a> event
  1638. </div>
  1639. <div class="markdown level1 conceptual"></div>
  1640. <h5 class="decalaration">Declaration</h5>
  1641. <div class="codewrapper">
  1642. <pre><code class="lang-csharp hljs">protected virtual void OnObjectActivated(ObjectActivatedEventArgs&lt;T&gt; e)</code></pre>
  1643. </div>
  1644. <h5 class="parameters">Parameters</h5>
  1645. <table class="table table-bordered table-striped table-condensed">
  1646. <thead>
  1647. <tr>
  1648. <th>Type</th>
  1649. <th>Name</th>
  1650. <th>Description</th>
  1651. </tr>
  1652. </thead>
  1653. <tbody>
  1654. <tr>
  1655. <td><a class="xref" href="Terminal.Gui.Trees.ObjectActivatedEventArgs-1.html">ObjectActivatedEventArgs</a>&lt;T&gt;</td>
  1656. <td><span class="parametername">e</span></td>
  1657. <td></td>
  1658. </tr>
  1659. </tbody>
  1660. </table>
  1661. <a id="Terminal_Gui_TreeView_1_OnSelectionChanged_" data-uid="Terminal.Gui.TreeView`1.OnSelectionChanged*"></a>
  1662. <h4 id="Terminal_Gui_TreeView_1_OnSelectionChanged_Terminal_Gui_Trees_SelectionChangedEventArgs__0__" data-uid="Terminal.Gui.TreeView`1.OnSelectionChanged(Terminal.Gui.Trees.SelectionChangedEventArgs{`0})">OnSelectionChanged(SelectionChangedEventArgs&lt;T&gt;)</h4>
  1663. <div class="markdown level1 summary">
  1664. Raises the SelectionChanged event
  1665. </div>
  1666. <div class="markdown level1 conceptual"></div>
  1667. <h5 class="decalaration">Declaration</h5>
  1668. <div class="codewrapper">
  1669. <pre><code class="lang-csharp hljs">protected virtual void OnSelectionChanged(SelectionChangedEventArgs&lt;T&gt; e)</code></pre>
  1670. </div>
  1671. <h5 class="parameters">Parameters</h5>
  1672. <table class="table table-bordered table-striped table-condensed">
  1673. <thead>
  1674. <tr>
  1675. <th>Type</th>
  1676. <th>Name</th>
  1677. <th>Description</th>
  1678. </tr>
  1679. </thead>
  1680. <tbody>
  1681. <tr>
  1682. <td><a class="xref" href="Terminal.Gui.Trees.SelectionChangedEventArgs-1.html">SelectionChangedEventArgs</a>&lt;T&gt;</td>
  1683. <td><span class="parametername">e</span></td>
  1684. <td></td>
  1685. </tr>
  1686. </tbody>
  1687. </table>
  1688. <a id="Terminal_Gui_TreeView_1_PositionCursor_" data-uid="Terminal.Gui.TreeView`1.PositionCursor*"></a>
  1689. <h4 id="Terminal_Gui_TreeView_1_PositionCursor" data-uid="Terminal.Gui.TreeView`1.PositionCursor">PositionCursor()</h4>
  1690. <div class="markdown level1 summary">
  1691. Positions the cursor at the start of the selected objects line (if visible)
  1692. </div>
  1693. <div class="markdown level1 conceptual"></div>
  1694. <h5 class="decalaration">Declaration</h5>
  1695. <div class="codewrapper">
  1696. <pre><code class="lang-csharp hljs">public override void PositionCursor()</code></pre>
  1697. </div>
  1698. <h5 class="overrides">Overrides</h5>
  1699. <div><a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_PositionCursor">View.PositionCursor()</a></div>
  1700. <a id="Terminal_Gui_TreeView_1_ProcessKey_" data-uid="Terminal.Gui.TreeView`1.ProcessKey*"></a>
  1701. <h4 id="Terminal_Gui_TreeView_1_ProcessKey_Terminal_Gui_KeyEvent_" data-uid="Terminal.Gui.TreeView`1.ProcessKey(Terminal.Gui.KeyEvent)">ProcessKey(KeyEvent)</h4>
  1702. <div class="markdown level1 summary"></div>
  1703. <div class="markdown level1 conceptual"></div>
  1704. <h5 class="decalaration">Declaration</h5>
  1705. <div class="codewrapper">
  1706. <pre><code class="lang-csharp hljs">public override bool ProcessKey(KeyEvent keyEvent)</code></pre>
  1707. </div>
  1708. <h5 class="parameters">Parameters</h5>
  1709. <table class="table table-bordered table-striped table-condensed">
  1710. <thead>
  1711. <tr>
  1712. <th>Type</th>
  1713. <th>Name</th>
  1714. <th>Description</th>
  1715. </tr>
  1716. </thead>
  1717. <tbody>
  1718. <tr>
  1719. <td><a class="xref" href="Terminal.Gui.KeyEvent.html">KeyEvent</a></td>
  1720. <td><span class="parametername">keyEvent</span></td>
  1721. <td></td>
  1722. </tr>
  1723. </tbody>
  1724. </table>
  1725. <h5 class="returns">Returns</h5>
  1726. <table class="table table-bordered table-striped table-condensed">
  1727. <thead>
  1728. <tr>
  1729. <th>Type</th>
  1730. <th>Description</th>
  1731. </tr>
  1732. </thead>
  1733. <tbody>
  1734. <tr>
  1735. <td><span class="xref">System.Boolean</span></td>
  1736. <td></td>
  1737. </tr>
  1738. </tbody>
  1739. </table>
  1740. <h5 class="overrides">Overrides</h5>
  1741. <div><a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_ProcessKey_Terminal_Gui_KeyEvent_">View.ProcessKey(KeyEvent)</a></div>
  1742. <a id="Terminal_Gui_TreeView_1_RebuildTree_" data-uid="Terminal.Gui.TreeView`1.RebuildTree*"></a>
  1743. <h4 id="Terminal_Gui_TreeView_1_RebuildTree" data-uid="Terminal.Gui.TreeView`1.RebuildTree">RebuildTree()</h4>
  1744. <div class="markdown level1 summary">
  1745. Rebuilds the tree structure for all exposed objects starting with the root objects.
  1746. Call this method when you know there are changes to the tree but don&apos;t know which
  1747. objects have changed (otherwise use <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_RefreshObject__0_System_Boolean_">RefreshObject(T, Boolean)</a>)
  1748. </div>
  1749. <div class="markdown level1 conceptual"></div>
  1750. <h5 class="decalaration">Declaration</h5>
  1751. <div class="codewrapper">
  1752. <pre><code class="lang-csharp hljs">public void RebuildTree()</code></pre>
  1753. </div>
  1754. <a id="Terminal_Gui_TreeView_1_Redraw_" data-uid="Terminal.Gui.TreeView`1.Redraw*"></a>
  1755. <h4 id="Terminal_Gui_TreeView_1_Redraw_Terminal_Gui_Rect_" data-uid="Terminal.Gui.TreeView`1.Redraw(Terminal.Gui.Rect)">Redraw(Rect)</h4>
  1756. <div class="markdown level1 summary"></div>
  1757. <div class="markdown level1 conceptual"></div>
  1758. <h5 class="decalaration">Declaration</h5>
  1759. <div class="codewrapper">
  1760. <pre><code class="lang-csharp hljs">public override void Redraw(Rect bounds)</code></pre>
  1761. </div>
  1762. <h5 class="parameters">Parameters</h5>
  1763. <table class="table table-bordered table-striped table-condensed">
  1764. <thead>
  1765. <tr>
  1766. <th>Type</th>
  1767. <th>Name</th>
  1768. <th>Description</th>
  1769. </tr>
  1770. </thead>
  1771. <tbody>
  1772. <tr>
  1773. <td><a class="xref" href="Terminal.Gui.Rect.html">Rect</a></td>
  1774. <td><span class="parametername">bounds</span></td>
  1775. <td></td>
  1776. </tr>
  1777. </tbody>
  1778. </table>
  1779. <h5 class="overrides">Overrides</h5>
  1780. <div><a class="xref" href="Terminal.Gui.View.html#Terminal_Gui_View_Redraw_Terminal_Gui_Rect_">View.Redraw(Rect)</a></div>
  1781. <a id="Terminal_Gui_TreeView_1_RefreshObject_" data-uid="Terminal.Gui.TreeView`1.RefreshObject*"></a>
  1782. <h4 id="Terminal_Gui_TreeView_1_RefreshObject__0_System_Boolean_" data-uid="Terminal.Gui.TreeView`1.RefreshObject(`0,System.Boolean)">RefreshObject(T, Boolean)</h4>
  1783. <div class="markdown level1 summary">
  1784. Refreshes the state of the object <code data-dev-comment-type="paramref" class="paramref">o</code> in the tree. This will
  1785. recompute children, string representation etc
  1786. </div>
  1787. <div class="markdown level1 conceptual"></div>
  1788. <h5 class="decalaration">Declaration</h5>
  1789. <div class="codewrapper">
  1790. <pre><code class="lang-csharp hljs">public void RefreshObject(T o, bool startAtTop = false)</code></pre>
  1791. </div>
  1792. <h5 class="parameters">Parameters</h5>
  1793. <table class="table table-bordered table-striped table-condensed">
  1794. <thead>
  1795. <tr>
  1796. <th>Type</th>
  1797. <th>Name</th>
  1798. <th>Description</th>
  1799. </tr>
  1800. </thead>
  1801. <tbody>
  1802. <tr>
  1803. <td><span class="xref">T</span></td>
  1804. <td><span class="parametername">o</span></td>
  1805. <td></td>
  1806. </tr>
  1807. <tr>
  1808. <td><span class="xref">System.Boolean</span></td>
  1809. <td><span class="parametername">startAtTop</span></td>
  1810. <td>True to also refresh all ancestors of the objects branch
  1811. (starting with the root). False to refresh only the passed node</td>
  1812. </tr>
  1813. </tbody>
  1814. </table>
  1815. <h5 id="Terminal_Gui_TreeView_1_RefreshObject__0_System_Boolean__remarks">Remarks</h5>
  1816. <div class="markdown level1 remarks">This has no effect if the object is not exposed in the tree.</div>
  1817. <a id="Terminal_Gui_TreeView_1_Remove_" data-uid="Terminal.Gui.TreeView`1.Remove*"></a>
  1818. <h4 id="Terminal_Gui_TreeView_1_Remove__0_" data-uid="Terminal.Gui.TreeView`1.Remove(`0)">Remove(T)</h4>
  1819. <div class="markdown level1 summary">
  1820. Removes the given root object from the tree
  1821. </div>
  1822. <div class="markdown level1 conceptual"></div>
  1823. <h5 class="decalaration">Declaration</h5>
  1824. <div class="codewrapper">
  1825. <pre><code class="lang-csharp hljs">public void Remove(T o)</code></pre>
  1826. </div>
  1827. <h5 class="parameters">Parameters</h5>
  1828. <table class="table table-bordered table-striped table-condensed">
  1829. <thead>
  1830. <tr>
  1831. <th>Type</th>
  1832. <th>Name</th>
  1833. <th>Description</th>
  1834. </tr>
  1835. </thead>
  1836. <tbody>
  1837. <tr>
  1838. <td><span class="xref">T</span></td>
  1839. <td><span class="parametername">o</span></td>
  1840. <td></td>
  1841. </tr>
  1842. </tbody>
  1843. </table>
  1844. <h5 id="Terminal_Gui_TreeView_1_Remove__0__remarks">Remarks</h5>
  1845. <div class="markdown level1 remarks">If <code data-dev-comment-type="paramref" class="paramref">o</code> is the currently <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_SelectedObject">SelectedObject</a> then the
  1846. selection is cleared</div>
  1847. <a id="Terminal_Gui_TreeView_1_SelectAll_" data-uid="Terminal.Gui.TreeView`1.SelectAll*"></a>
  1848. <h4 id="Terminal_Gui_TreeView_1_SelectAll" data-uid="Terminal.Gui.TreeView`1.SelectAll">SelectAll()</h4>
  1849. <div class="markdown level1 summary">
  1850. Selects all objects in the tree when <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_MultiSelect">MultiSelect</a> is enabled otherwise
  1851. does nothing
  1852. </div>
  1853. <div class="markdown level1 conceptual"></div>
  1854. <h5 class="decalaration">Declaration</h5>
  1855. <div class="codewrapper">
  1856. <pre><code class="lang-csharp hljs">public void SelectAll()</code></pre>
  1857. </div>
  1858. <h3 id="events">Events
  1859. </h3>
  1860. <h4 id="Terminal_Gui_TreeView_1_ObjectActivated" data-uid="Terminal.Gui.TreeView`1.ObjectActivated">ObjectActivated</h4>
  1861. <div class="markdown level1 summary">
  1862. This event is raised when an object is activated e.g. by double clicking or
  1863. pressing <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_ObjectActivationKey">ObjectActivationKey</a>
  1864. </div>
  1865. <div class="markdown level1 conceptual"></div>
  1866. <h5 class="decalaration">Declaration</h5>
  1867. <div class="codewrapper">
  1868. <pre><code class="lang-csharp hljs">public event Action&lt;ObjectActivatedEventArgs&lt;T&gt;&gt; ObjectActivated</code></pre>
  1869. </div>
  1870. <h5 class="eventType">Event Type</h5>
  1871. <table class="table table-bordered table-striped table-condensed">
  1872. <thead>
  1873. <tr>
  1874. <th>Type</th>
  1875. <th>Description</th>
  1876. </tr>
  1877. </thead>
  1878. <tbody>
  1879. <tr>
  1880. <td><span class="xref">System.Action</span>&lt;<a class="xref" href="Terminal.Gui.Trees.ObjectActivatedEventArgs-1.html">ObjectActivatedEventArgs</a>&lt;T&gt;&gt;</td>
  1881. <td></td>
  1882. </tr>
  1883. </tbody>
  1884. </table>
  1885. <h4 id="Terminal_Gui_TreeView_1_SelectionChanged" data-uid="Terminal.Gui.TreeView`1.SelectionChanged">SelectionChanged</h4>
  1886. <div class="markdown level1 summary">
  1887. Called when the <a class="xref" href="Terminal.Gui.TreeView-1.html#Terminal_Gui_TreeView_1_SelectedObject">SelectedObject</a> changes
  1888. </div>
  1889. <div class="markdown level1 conceptual"></div>
  1890. <h5 class="decalaration">Declaration</h5>
  1891. <div class="codewrapper">
  1892. <pre><code class="lang-csharp hljs">public event EventHandler&lt;SelectionChangedEventArgs&lt;T&gt;&gt; SelectionChanged</code></pre>
  1893. </div>
  1894. <h5 class="eventType">Event Type</h5>
  1895. <table class="table table-bordered table-striped table-condensed">
  1896. <thead>
  1897. <tr>
  1898. <th>Type</th>
  1899. <th>Description</th>
  1900. </tr>
  1901. </thead>
  1902. <tbody>
  1903. <tr>
  1904. <td><span class="xref">System.EventHandler</span>&lt;<a class="xref" href="Terminal.Gui.Trees.SelectionChangedEventArgs-1.html">SelectionChangedEventArgs</a>&lt;T&gt;&gt;</td>
  1905. <td></td>
  1906. </tr>
  1907. </tbody>
  1908. </table>
  1909. <h3 id="implements">Implements</h3>
  1910. <div>
  1911. <span class="xref">System.IDisposable</span>
  1912. </div>
  1913. <div>
  1914. <span class="xref">System.ComponentModel.ISupportInitializeNotification</span>
  1915. </div>
  1916. <div>
  1917. <span class="xref">System.ComponentModel.ISupportInitialize</span>
  1918. </div>
  1919. <div>
  1920. <a class="xref" href="Terminal.Gui.ITreeView.html">ITreeView</a>
  1921. </div>
  1922. </article>
  1923. </div>
  1924. <div class="hidden-sm col-md-2" role="complementary">
  1925. <div class="sideaffix">
  1926. <div class="contribution">
  1927. <ul class="nav">
  1928. </ul>
  1929. </div>
  1930. <nav class="bs-docs-sidebar hidden-print hidden-xs hidden-sm affix" id="affix">
  1931. <h5>In This Article</h5>
  1932. <div></div>
  1933. </nav>
  1934. </div>
  1935. </div>
  1936. </div>
  1937. </div>
  1938. <footer>
  1939. <div class="grad-bottom"></div>
  1940. <div class="footer">
  1941. <div class="container">
  1942. <span class="pull-right">
  1943. <a href="#top">Back to top</a>
  1944. </span>
  1945. <span>Generated by <strong>DocFX</strong></span>
  1946. </div>
  1947. </div>
  1948. </footer>
  1949. </div>
  1950. <script type="text/javascript" src="../../styles/docfx.vendor.js"></script>
  1951. <script type="text/javascript" src="../../styles/docfx.js"></script>
  1952. <script type="text/javascript" src="../../styles/main.js"></script>
  1953. </body>
  1954. </html>