Subject: bug#37199: 27.0.50; widget-browse-at fails at the end of editable-field text

From: Mauro Aranda <[email-masked]>
Date: Tue, 27 Aug 2019 12:06:00 -0300

severity 37199 minor
tags 37199 patch
thanks

The attached patch should do the trick.

Best regards,
Mauro
From 7ae3c2e4031382d179c95544e8e6710e3df5131d Mon Sep 17 00:00:00 2001
From: Mauro Aranda <[email-masked]>
Date: Tue, 27 Aug 2019 11:47:51 -0300
Subject: [PATCH] Make widget-browse-at always detect an editable-field

* lisp/wid-browse.el (widget-browse-at): Also look for the real-field
property when detecting a field.  (Bug#37199)
---
 lisp/wid-browse.el | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/lisp/wid-browse.el b/lisp/wid-browse.el
index dbc4100..3124a9c 100644
--- a/lisp/wid-browse.el
+++ b/lisp/wid-browse.el
@@ -89,7 +89,11 @@ widget-browse-mode
 (defun widget-browse-at (pos)
   "Browse the widget under point."
   (interactive "d")
-  (let* ((field (get-char-property pos 'field))
+  (let* ((field (or
+                 ;; See comments in `widget-specify-field' to know why we
+                 ;; need this.
+                 (get-char-property pos 'real-field)
+                 (get-char-property pos 'field)))
 	 (button (get-char-property pos 'button))
 	 (doc (get-char-property pos 'widget-doc))
 	 (text (cond (field "This is an editable text area.")
-- 
2.7.4