Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
4cf1d7e3
Commit
4cf1d7e3
authored
Nov 15, 2009
by
Chong Yidong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* register.el (jump-to-register, insert-register): Handle Semantic
tags. From commented-out advice in semantic/senator.el.
parent
6616006b
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
20 deletions
+18
-20
lisp/ChangeLog
lisp/ChangeLog
+5
-0
lisp/cedet/semantic/senator.el
lisp/cedet/semantic/senator.el
+0
-20
lisp/register.el
lisp/register.el
+13
-0
No files found.
lisp/ChangeLog
View file @
4cf1d7e3
2009-11-15 Chong Yidong <cyd@stupidchicken.com>
* register.el (jump-to-register, insert-register): Handle Semantic
tags. From commented-out advice in semantic/senator.el.
2009-11-15 Dan Nicolaescu <dann@ics.uci.edu>
* vc.el (vc-log-show-limit): New variable.
...
...
lisp/cedet/semantic/senator.el
View file @
4cf1d7e3
...
...
@@ -857,26 +857,6 @@ Use a senator search function when semantic isearch mode is enabled."
;; [(control ?,)]
;; 'senator-isearch-toggle-semantic-mode)
;; (defadvice insert-register (around senator activate)
;; "Insert contents of register REGISTER as a tag.
;; If senator is not active, use the original mechanism."
;; (let ((val (get-register (ad-get-arg 0))))
;; (if (and senator-minor-mode (interactive-p)
;; (semantic-foreign-tag-p val))
;; (semantic-insert-foreign-tag val)
;; ad-do-it)))
;; (defadvice jump-to-register (around senator activate)
;; "Insert contents of register REGISTER as a tag.
;; If senator is not active, use the original mechanism."
;; (let ((val (get-register (ad-get-arg 0))))
;; (if (and senator-minor-mode (interactive-p)
;; (semantic-foreign-tag-p val))
;; (progn
;; (switch-to-buffer (semantic-tag-buffer val))
;; (goto-char (semantic-tag-start val)))
;; ad-do-it)))
(
provide
'semantic/senator
)
;; Local variables:
...
...
lisp/register.el
View file @
4cf1d7e3
...
...
@@ -28,6 +28,10 @@
;; pieces of buffer state to named variables. The entry points are
;; documented in the Emacs user's manual.
(
declare-function
semantic-insert-foreign-tag
"semantic/tag"
(
foreign-tag
))
(
declare-function
semantic-tag-buffer
"semantic/tag"
(
tag
))
(
declare-function
semantic-tag-start
"semantic/tag"
(
tag
))
;;; Global key bindings
(
define-key
ctl-x-r-map
"\C-@"
'point-to-register
)
...
...
@@ -135,6 +139,11 @@ delete any existing frames that the frame configuration doesn't mention.
(
error
"Register access aborted"
))
(
find-file
(
nth
1
val
))
(
goto-char
(
nth
2
val
)))
((
and
(
fboundp
'semantic-foreign-tag-p
)
semantic-mode
(
semantic-foreign-tag-p
val
))
(
switch-to-buffer
(
semantic-tag-buffer
val
))
(
goto-char
(
semantic-tag-start
val
)))
(
t
(
error
"Register doesn't contain a buffer position or configuration"
)))))
...
...
@@ -284,6 +293,10 @@ Interactively, second arg is non-nil if prefix arg is supplied."
(
princ
val
(
current-buffer
)))
((
and
(
markerp
val
)
(
marker-position
val
))
(
princ
(
marker-position
val
)
(
current-buffer
)))
((
and
(
fboundp
'semantic-foreign-tag-p
)
semantic-mode
(
semantic-foreign-tag-p
val
))
(
semantic-insert-foreign-tag
val
))
(
t
(
error
"Register does not contain text"
))))
(
if
(
not
arg
)
(
exchange-point-and-mark
)))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment