jcubic
jcubic

Reputation: 66518

show repeated selected text in emacs

I don't know which text editor have it but when you select text it show up where the same text appear in text with a box. It's usefull when you select variable and it show up where it's use in the code.

The text can show up with different backgorund when I copy the text and then call the function and dissapear when position of the cursor change.

Is it possible to do this in Emacs (probably is but how)?

Upvotes: 2

Views: 98

Answers (2)

Drew
Drew

Reputation: 30701

Yes, Emacs has that (highlight matches of a given symbol or other pattern). Sounds like any of these correspond to what you are looking for:

  • Incremental search (aka isearch): C-s or C-M-s, then type what you want to match (or use C-w... to pick it up from the buffer).

  • Library highlight-symbol.

  • Library highlight, command hlt-highlight-symbol. (And see option `hlt-auto-faces-flag.) Does what library highlight-symbol does, and more.

  • Emacs 24.4 (i.e., current development snapshot), command hi-lock-face-symbol-at-point.

If you use library mouse3.el then right-clicking the mouse gives you the last two alternatives for the symbol under the mouse pointer.

Upvotes: 2

user1990
user1990

Reputation: 546

You can maybe try to use cedet with ECB on Emacs. You can install it with Meta+x list-packages or you can try another IDE like Kdevelop.

Upvotes: 0

Related Questions