417 |
Insert this hook into `LaTeX-section-hook' to allow the user to change |
Insert this hook into `LaTeX-section-hook' to allow the user to change |
418 |
the name of the sectioning command inserted with `\\[LaTeX-section]'." |
the name of the sectioning command inserted with `\\[LaTeX-section]'." |
419 |
(let ((string (completing-read |
(let ((string (completing-read |
420 |
(concat "Select level: (default " name ") ") |
(concat "Level: (default " name ") ") |
421 |
LaTeX-section-list |
LaTeX-section-list |
422 |
nil nil nil))) |
nil nil nil))) |
423 |
; Update name |
; Update name |
430 |
"Hook to prompt for LaTeX section title. |
"Hook to prompt for LaTeX section title. |
431 |
Insert this hook into `LaTeX-section-hook' to allow the user to change |
Insert this hook into `LaTeX-section-hook' to allow the user to change |
432 |
the title of the section inserted with `\\[LaTeX-section]." |
the title of the section inserted with `\\[LaTeX-section]." |
433 |
(if (zerop (length title)) |
(setq title (read-string "Title: " title)) |
434 |
(setq title (read-string "What title: ")) |
(let ((region (and (TeX-active-mark) |
435 |
(let ((region (and (TeX-active-mark) |
(cons (region-beginning) (region-end))))) |
436 |
(cons (region-beginning) (region-end))))) |
(when region (delete-region (car region) (cdr region))))) |
|
(setq title (read-string "What title: " title)) |
|
|
(if region |
|
|
(delete-region (car region) (cdr region)))))) |
|
437 |
|
|
438 |
(defun LaTeX-section-toc () |
(defun LaTeX-section-toc () |
439 |
"Hook to prompt for the LaTeX section entry in the table of content . |
"Hook to prompt for the LaTeX section entry in the table of content . |