Function: magit-thing-at-point
magit-thing-at-point is a byte-compiled function defined in
magit-section.el.
Signature
(magit-thing-at-point THING &optional NO-PROPERTIES)
Documentation
Return the THING at point or where the context menu was invoked.
When using the context menu, return the thing the user clicked
on, provided the current buffer is the buffer in which the click
occurred. Otherwise return the same value as thing-at-point.
For the meaning of THING and NO-PROPERTIES see that function.
Source Code
;; Defined in ~/.emacs.d/elpa/magit-section-20260330.1102/magit-section.el
(defun magit-thing-at-point (thing &optional no-properties)
"Return the THING at point or where the context menu was invoked.
When using the context menu, return the thing the user clicked
on, provided the current buffer is the buffer in which the click
occurred. Otherwise return the same value as `thing-at-point'.
For the meaning of THING and NO-PROPERTIES see that function."
(if-let ((pos (magit-menu-position)))
(save-excursion
(goto-char pos)
(thing-at-point thing no-properties))
(thing-at-point thing no-properties)))