173 |
detailed description of this mode. |
detailed description of this mode. |
174 |
|
|
175 |
|
|
176 |
--------------------------------------------------------------------- |
+--------------------------------------------------------------+ |
177 |
GDB Toolbar |
| GDB Toolbar | |
178 |
--------------------------------------------------------------------- |
+-------------------------------+------------------------------+ |
179 |
GUD buffer (I/O of GDB) | Locals buffer |
| GUD buffer (I/O of GDB) | Locals buffer | |
180 |
| |
| | | |
181 |
| |
| | | |
182 |
| |
| | | |
183 |
--------------------------------------------------------------------- |
+-------------------------------+------------------------------+ |
184 |
Source buffer | Input/Output (of inferior) buffer |
| Source buffer | I/O buffer (of inferior) | |
185 |
| (comint-mode) |
| | (comint-mode) | |
186 |
| |
| | | |
187 |
| |
| | | |
188 |
| |
| | | |
189 |
| |
| | | |
190 |
| |
| | | |
191 |
| |
| | | |
192 |
--------------------------------------------------------------------- |
+-------------------------------+------------------------------+ |
193 |
Stack buffer | Breakpoints buffer |
| Stack buffer | Breakpoints buffer | |
194 |
RET gdb-frames-select | SPC gdb-toggle-breakpoint |
| RET gdb-frames-select | SPC gdb-toggle-breakpoint | |
195 |
| RET gdb-goto-breakpoint |
| | RET gdb-goto-breakpoint | |
196 |
| d gdb-delete-breakpoint |
| | d gdb-delete-breakpoint | |
197 |
---------------------------------------------------------------------" |
+-------------------------------+------------------------------+" |
198 |
;; |
;; |
199 |
(interactive (list (gud-query-cmdline 'gdba))) |
(interactive (list (gud-query-cmdline 'gdba))) |
200 |
;; |
;; |
1192 |
(let ((buf (gdb-get-buffer ',buf-key))) |
(let ((buf (gdb-get-buffer ',buf-key))) |
1193 |
(and buf |
(and buf |
1194 |
(with-current-buffer buf |
(with-current-buffer buf |
1195 |
(let ((p (window-point (get-buffer-window buf 0))) |
(let* ((window (get-buffer-window buf 0)) |
1196 |
|
(p (window-point window)) |
1197 |
(buffer-read-only nil)) |
(buffer-read-only nil)) |
1198 |
(erase-buffer) |
(erase-buffer) |
1199 |
(insert-buffer-substring (gdb-get-create-buffer |
(insert-buffer-substring (gdb-get-create-buffer |
1200 |
'gdb-partial-output-buffer)) |
'gdb-partial-output-buffer)) |
1201 |
(set-window-point (get-buffer-window buf 0) p))))) |
(set-window-point window p))))) |
1202 |
;; put customisation here |
;; put customisation here |
1203 |
(,custom-defun))) |
(,custom-defun))) |
1204 |
|
|
2126 |
(while (re-search-forward "\\s-*{.*\n" nil t) |
(while (re-search-forward "\\s-*{.*\n" nil t) |
2127 |
(replace-match " (array);\n" nil nil)))) |
(replace-match " (array);\n" nil nil)))) |
2128 |
(let ((buf (gdb-get-buffer 'gdb-locals-buffer))) |
(let ((buf (gdb-get-buffer 'gdb-locals-buffer))) |
2129 |
(and buf (with-current-buffer buf |
(and buf |
2130 |
(let ((p (window-point (get-buffer-window buf 0))) |
(with-current-buffer buf |
2131 |
|
(let* ((window (get-buffer-window buf 0)) |
2132 |
|
(p (window-point window)) |
2133 |
(buffer-read-only nil)) |
(buffer-read-only nil)) |
2134 |
(erase-buffer) |
(erase-buffer) |
2135 |
(insert-buffer-substring (gdb-get-create-buffer |
(insert-buffer-substring (gdb-get-create-buffer |
2136 |
'gdb-partial-output-buffer)) |
'gdb-partial-output-buffer)) |
2137 |
(set-window-point (get-buffer-window buf 0) p))))) |
(set-window-point window p))))) |
2138 |
(run-hooks 'gdb-info-locals-hook)) |
(run-hooks 'gdb-info-locals-hook)) |
2139 |
|
|
2140 |
(defun gdb-info-locals-custom () |
(defun gdb-info-locals-custom () |
2531 |
(when (< left-margin-width 2) |
(when (< left-margin-width 2) |
2532 |
(save-current-buffer |
(save-current-buffer |
2533 |
(setq left-margin-width 2) |
(setq left-margin-width 2) |
2534 |
(if (get-buffer-window (current-buffer) 0) |
(let ((window (get-buffer-window (current-buffer) 0))) |
2535 |
|
(if window |
2536 |
(set-window-margins |
(set-window-margins |
2537 |
(get-buffer-window (current-buffer) 0) |
window left-margin-width right-margin-width))))) |
|
left-margin-width right-margin-width)))) |
|
2538 |
(gdb-put-string |
(gdb-put-string |
2539 |
(propertize putstring |
(propertize putstring |
2540 |
'face (if enabled 'breakpoint-enabled 'breakpoint-disabled)) |
'face (if enabled 'breakpoint-enabled 'breakpoint-disabled)) |
2546 |
(remove-images start end)) |
(remove-images start end)) |
2547 |
(when remove-margin |
(when remove-margin |
2548 |
(setq left-margin-width 0) |
(setq left-margin-width 0) |
2549 |
(if (get-buffer-window (current-buffer) 0) |
(let ((window (get-buffer-window (current-buffer) 0))) |
2550 |
(set-window-margins |
(if window |
2551 |
(get-buffer-window (current-buffer) 0) |
(set-window-margins |
2552 |
left-margin-width right-margin-width)))) |
window left-margin-width right-margin-width))))) |
2553 |
|
|
2554 |
|
|
2555 |
;; |
;; |