reftex-index-selection-or-word

reftex-index-selection-or-word is an interactive autoloaded Lisp function in `reftex-index.el'.


(reftex-index-selection-or-word &optional ARG PHRASE)

Put selection or the word near point into the default index macro.
This uses the information in `reftex-index-default-macro' to make an index
entry. The phrase indexed is the current selection or the word near point.
When called with one `C-u' prefix, let the user have a chance to edit the
index entry. When called with 2 `C-u' as prefix, also ask for the index
macro and other stuff.
When called inside TeX math mode as determined by the `texmathp.el' library
which is part of AUCTeX, the string is first processed with the
`reftex-index-math-format', which see.