您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

290 行
11KB

  1. <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  2. <html>
  3. <!-- Copyright (C) 1988-2020 Free Software Foundation, Inc.
  4. Permission is granted to copy, distribute and/or modify this document
  5. under the terms of the GNU Free Documentation License, Version 1.3 or
  6. any later version published by the Free Software Foundation; with the
  7. Invariant Sections being "Free Software" and "Free Software Needs
  8. Free Documentation", with the Front-Cover Texts being "A GNU Manual,"
  9. and with the Back-Cover Texts as in (a) below.
  10. (a) The FSF's Back-Cover Text is: "You are free to copy and modify
  11. this GNU Manual. Buying copies from GNU Press supports the FSF in
  12. developing GNU and promoting software freedom." -->
  13. <!-- Created by GNU Texinfo 6.5, http://www.gnu.org/software/texinfo/ -->
  14. <head>
  15. <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  16. <title>TUI Commands (Debugging with GDB)</title>
  17. <meta name="description" content="TUI Commands (Debugging with GDB)">
  18. <meta name="keywords" content="TUI Commands (Debugging with GDB)">
  19. <meta name="resource-type" content="document">
  20. <meta name="distribution" content="global">
  21. <meta name="Generator" content="makeinfo">
  22. <link href="index.html#Top" rel="start" title="Top">
  23. <link href="Concept-Index.html#Concept-Index" rel="index" title="Concept Index">
  24. <link href="index.html#SEC_Contents" rel="contents" title="Table of Contents">
  25. <link href="TUI.html#TUI" rel="up" title="TUI">
  26. <link href="TUI-Configuration.html#TUI-Configuration" rel="next" title="TUI Configuration">
  27. <link href="TUI-Single-Key-Mode.html#TUI-Single-Key-Mode" rel="prev" title="TUI Single Key Mode">
  28. <style type="text/css">
  29. <!--
  30. a.summary-letter {text-decoration: none}
  31. blockquote.indentedblock {margin-right: 0em}
  32. blockquote.smallindentedblock {margin-right: 0em; font-size: smaller}
  33. blockquote.smallquotation {font-size: smaller}
  34. div.display {margin-left: 3.2em}
  35. div.example {margin-left: 3.2em}
  36. div.lisp {margin-left: 3.2em}
  37. div.smalldisplay {margin-left: 3.2em}
  38. div.smallexample {margin-left: 3.2em}
  39. div.smalllisp {margin-left: 3.2em}
  40. kbd {font-style: oblique}
  41. pre.display {font-family: inherit}
  42. pre.format {font-family: inherit}
  43. pre.menu-comment {font-family: serif}
  44. pre.menu-preformatted {font-family: serif}
  45. pre.smalldisplay {font-family: inherit; font-size: smaller}
  46. pre.smallexample {font-size: smaller}
  47. pre.smallformat {font-family: inherit; font-size: smaller}
  48. pre.smalllisp {font-size: smaller}
  49. span.nolinebreak {white-space: nowrap}
  50. span.roman {font-family: initial; font-weight: normal}
  51. span.sansserif {font-family: sans-serif; font-weight: normal}
  52. ul.no-bullet {list-style: none}
  53. -->
  54. </style>
  55. </head>
  56. <body lang="en">
  57. <a name="TUI-Commands"></a>
  58. <div class="header">
  59. <p>
  60. Next: <a href="TUI-Configuration.html#TUI-Configuration" accesskey="n" rel="next">TUI Configuration</a>, Previous: <a href="TUI-Single-Key-Mode.html#TUI-Single-Key-Mode" accesskey="p" rel="prev">TUI Single Key Mode</a>, Up: <a href="TUI.html#TUI" accesskey="u" rel="up">TUI</a> &nbsp; [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="Concept-Index.html#Concept-Index" title="Index" rel="index">Index</a>]</p>
  61. </div>
  62. <hr>
  63. <a name="TUI_002dspecific-Commands"></a>
  64. <h3 class="section">25.4 TUI-specific Commands</h3>
  65. <a name="index-TUI-commands"></a>
  66. <p>The TUI has specific commands to control the text windows.
  67. These commands are always available, even when <small>GDB</small> is not in
  68. the TUI mode. When <small>GDB</small> is in the standard mode, most
  69. of these commands will automatically switch to the TUI mode.
  70. </p>
  71. <p>Note that if <small>GDB</small>&rsquo;s <code>stdout</code> is not connected to a
  72. terminal, or <small>GDB</small> has been started with the machine interface
  73. interpreter (see <a href="GDB_002fMI.html#GDB_002fMI">The <small>GDB/MI</small> Interface</a>), most of
  74. these commands will fail with an error, because it would not be
  75. possible or desirable to enable curses window management.
  76. </p>
  77. <dl compact="compact">
  78. <dt><code>tui enable</code></dt>
  79. <dd><a name="index-tui-enable"></a>
  80. <p>Activate TUI mode. The last active TUI window layout will be used if
  81. TUI mode has previously been used in the current debugging session,
  82. otherwise a default layout is used.
  83. </p>
  84. </dd>
  85. <dt><code>tui disable</code></dt>
  86. <dd><a name="index-tui-disable"></a>
  87. <p>Disable TUI mode, returning to the console interpreter.
  88. </p>
  89. </dd>
  90. <dt><code>info win</code></dt>
  91. <dd><a name="index-info-win"></a>
  92. <p>List and give the size of all displayed windows.
  93. </p>
  94. </dd>
  95. <dt><code>tui new-layout <var>name</var> <var>window</var> <var>weight</var> <span class="roman">[</span><var>window</var> <var>weight</var>&hellip;<span class="roman">]</span></code></dt>
  96. <dd><a name="index-tui-new_002dlayout"></a>
  97. <p>Create a new TUI layout. The new layout will be named <var>name</var>, and
  98. can be accessed using the <code>layout</code> command (see below).
  99. </p>
  100. <p>Each <var>window</var> parameter is either the name of a window to display,
  101. or a window description. The windows will be displayed from top to
  102. bottom in the order listed.
  103. </p>
  104. <p>The names of the windows are the same as the ones given to the
  105. <code>focus</code> command (see below); additional, the <code>status</code>
  106. window can be specified. Note that, because it is of fixed height,
  107. the weight assigned to the status window is of no importance. It is
  108. conventional to use &lsquo;<samp>0</samp>&rsquo; here.
  109. </p>
  110. <p>A window description looks a bit like an invocation of <code>tui
  111. new-layout</code>, and is of the form
  112. {<span class="roman">[</span><code>-horizontal</code><span class="roman">]</span><var>window</var> <var>weight</var> <span class="roman">[</span><var>window</var> <var>weight</var>&hellip;<span class="roman">]</span>}.
  113. </p>
  114. <p>This specifies a sub-layout. If <code>-horizontal</code> is given, the
  115. windows in this description will be arranged side-by-side, rather than
  116. top-to-bottom.
  117. </p>
  118. <p>Each <var>weight</var> is an integer. It is the weight of this window
  119. relative to all the other windows in the layout. These numbers are
  120. used to calculate how much of the screen is given to each window.
  121. </p>
  122. <p>For example:
  123. </p>
  124. <div class="example">
  125. <pre class="example">(gdb) tui new-layout example src 1 regs 1 status 0 cmd 1
  126. </pre></div>
  127. <p>Here, the new layout is called &lsquo;<samp>example</samp>&rsquo;. It shows the source
  128. and register windows, followed by the status window, and then finally
  129. the command window. The non-status windows all have the same weight,
  130. so the terminal will be split into three roughly equal sections.
  131. </p>
  132. <p>Here is a more complex example, showing a horizontal layout:
  133. </p>
  134. <div class="example">
  135. <pre class="example">(gdb) tui new-layout example {-horizontal src 1 asm 1} 2 status 0 cmd 1
  136. </pre></div>
  137. <p>This will result in side-by-side source and assembly windows; with the
  138. status and command window being beneath these, filling the entire
  139. width of the terminal. Because they have weight 2, the source and
  140. assembly windows will be twice the height of the command window.
  141. </p>
  142. </dd>
  143. <dt><code>layout <var>name</var></code></dt>
  144. <dd><a name="index-layout"></a>
  145. <p>Changes which TUI windows are displayed. The <var>name</var> parameter
  146. controls which layout is shown. It can be either one of the built-in
  147. layout names, or the name of a layout defined by the user using
  148. <code>tui new-layout</code>.
  149. </p>
  150. <p>The built-in layouts are as follows:
  151. </p>
  152. <dl compact="compact">
  153. <dt><code>next</code></dt>
  154. <dd><p>Display the next layout.
  155. </p>
  156. </dd>
  157. <dt><code>prev</code></dt>
  158. <dd><p>Display the previous layout.
  159. </p>
  160. </dd>
  161. <dt><code>src</code></dt>
  162. <dd><p>Display the source and command windows.
  163. </p>
  164. </dd>
  165. <dt><code>asm</code></dt>
  166. <dd><p>Display the assembly and command windows.
  167. </p>
  168. </dd>
  169. <dt><code>split</code></dt>
  170. <dd><p>Display the source, assembly, and command windows.
  171. </p>
  172. </dd>
  173. <dt><code>regs</code></dt>
  174. <dd><p>When in <code>src</code> layout display the register, source, and command
  175. windows. When in <code>asm</code> or <code>split</code> layout display the
  176. register, assembler, and command windows.
  177. </p></dd>
  178. </dl>
  179. </dd>
  180. <dt><code>focus <var>name</var></code></dt>
  181. <dd><a name="index-focus"></a>
  182. <p>Changes which TUI window is currently active for scrolling. The
  183. <var>name</var> parameter can be any of the following:
  184. </p>
  185. <dl compact="compact">
  186. <dt><code>next</code></dt>
  187. <dd><p>Make the next window active for scrolling.
  188. </p>
  189. </dd>
  190. <dt><code>prev</code></dt>
  191. <dd><p>Make the previous window active for scrolling.
  192. </p>
  193. </dd>
  194. <dt><code>src</code></dt>
  195. <dd><p>Make the source window active for scrolling.
  196. </p>
  197. </dd>
  198. <dt><code>asm</code></dt>
  199. <dd><p>Make the assembly window active for scrolling.
  200. </p>
  201. </dd>
  202. <dt><code>regs</code></dt>
  203. <dd><p>Make the register window active for scrolling.
  204. </p>
  205. </dd>
  206. <dt><code>cmd</code></dt>
  207. <dd><p>Make the command window active for scrolling.
  208. </p></dd>
  209. </dl>
  210. </dd>
  211. <dt><code>refresh</code></dt>
  212. <dd><a name="index-refresh"></a>
  213. <p>Refresh the screen. This is similar to typing <kbd>C-L</kbd>.
  214. </p>
  215. </dd>
  216. <dt><code>tui reg <var>group</var></code></dt>
  217. <dd><a name="index-tui-reg"></a>
  218. <p>Changes the register group displayed in the tui register window to
  219. <var>group</var>. If the register window is not currently displayed this
  220. command will cause the register window to be displayed. The list of
  221. register groups, as well as their order is target specific. The
  222. following groups are available on most targets:
  223. </p><dl compact="compact">
  224. <dt><code>next</code></dt>
  225. <dd><p>Repeatedly selecting this group will cause the display to cycle
  226. through all of the available register groups.
  227. </p>
  228. </dd>
  229. <dt><code>prev</code></dt>
  230. <dd><p>Repeatedly selecting this group will cause the display to cycle
  231. through all of the available register groups in the reverse order to
  232. <var>next</var>.
  233. </p>
  234. </dd>
  235. <dt><code>general</code></dt>
  236. <dd><p>Display the general registers.
  237. </p></dd>
  238. <dt><code>float</code></dt>
  239. <dd><p>Display the floating point registers.
  240. </p></dd>
  241. <dt><code>system</code></dt>
  242. <dd><p>Display the system registers.
  243. </p></dd>
  244. <dt><code>vector</code></dt>
  245. <dd><p>Display the vector registers.
  246. </p></dd>
  247. <dt><code>all</code></dt>
  248. <dd><p>Display all registers.
  249. </p></dd>
  250. </dl>
  251. </dd>
  252. <dt><code>update</code></dt>
  253. <dd><a name="index-update"></a>
  254. <p>Update the source window and the current execution point.
  255. </p>
  256. </dd>
  257. <dt><code>winheight <var>name</var> +<var>count</var></code></dt>
  258. <dt><code>winheight <var>name</var> -<var>count</var></code></dt>
  259. <dd><a name="index-winheight"></a>
  260. <p>Change the height of the window <var>name</var> by <var>count</var>
  261. lines. Positive counts increase the height, while negative counts
  262. decrease it. The <var>name</var> parameter can be one of <code>src</code> (the
  263. source window), <code>cmd</code> (the command window), <code>asm</code> (the
  264. disassembly window), or <code>regs</code> (the register display window).
  265. </p></dd>
  266. </dl>
  267. <hr>
  268. <div class="header">
  269. <p>
  270. Next: <a href="TUI-Configuration.html#TUI-Configuration" accesskey="n" rel="next">TUI Configuration</a>, Previous: <a href="TUI-Single-Key-Mode.html#TUI-Single-Key-Mode" accesskey="p" rel="prev">TUI Single Key Mode</a>, Up: <a href="TUI.html#TUI" accesskey="u" rel="up">TUI</a> &nbsp; [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="Concept-Index.html#Concept-Index" title="Index" rel="index">Index</a>]</p>
  271. </div>
  272. </body>
  273. </html>