all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#45839: 28.0.50; Isearch and transient mode wierd behaviour in info-mode!
@ 2021-01-13 11:50 Utkarsh Singh
  2021-01-13 18:06 ` Juri Linkov
  0 siblings, 1 reply; 6+ messages in thread
From: Utkarsh Singh @ 2021-01-13 11:50 UTC (permalink / raw)
  To: 45839

In info-mode do the following:
+ C-SPC :: set mark
+ C-s valid_query :: search for some string
+ RET

By now you can see region is not highlighted and this will affect all
other command such as M-w(kill-ring-save).

In GNU Emacs 28.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.24, cairo version 1.17.4)
 of 2021-01-11 built on archlinux
Repository revision: 8810e1789cce8cb9f2e463fc305c0b6ff12580ba
Repository branch: master
Windowing system distributor 'The X.Org Foundation', version 11.0.12099001
System Description: Arch Linux

Configured features:
XPM JPEG TIFF GIF PNG RSVG CAIRO SOUND GPM DBUS GSETTINGS GLIB NOTIFY
INOTIFY ACL GNUTLS LIBXML2 FREETYPE HARFBUZZ M17N_FLT LIBOTF ZLIB
TOOLKIT_SCROLL_BARS GTK3 X11 XDBE XIM MODULES THREADS LIBSYSTEMD JSON
PDUMPER LCMS2

Important settings:
  value of $LC_COLLATE: C
  value of $LANG: en_IN.UTF-8
  locale-coding-system: utf-8-unix

Major mode: Info

Minor modes in effect:
  semantic-minor-modes-format: ((:eval (if (or semantic-highlight-edits-mode semantic-show-unmatched-syntax-mode)  S)))
  icomplete-vertical-mode: t
  async-bytecomp-package-mode: t
  shell-dirtrack-mode: t
  company-tng-mode: t
  save-place-mode: t
  pdf-occur-global-minor-mode: t
  winner-mode: t
  icomplete-mode: t
  fido-mode: t
  amx-mode: t
  minions-mode: t
  global-auto-revert-mode: t
  delete-selection-mode: t
  recentf-mode: t
  show-paren-mode: t
  electric-pair-mode: t
  override-global-mode: t
  tooltip-mode: t
  global-eldoc-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  buffer-read-only: t
  column-number-mode: t
  line-number-mode: t
  transient-mark-mode: t

Load-path shadows:
/home/utkarsh/.config/emacs/elpa/icomplete-vertical-20210105.500/icomplete-vertical hides /tmp/icomplete-vertical-0R2C0p/icomplete-vertical-20210105.500/icomplete-vertical
/home/utkarsh/.config/emacs/elpa/icomplete-vertical-20210105.500/icomplete-vertical-pkg hides /tmp/icomplete-vertical-0R2C0p/icomplete-vertical-20210105.500/icomplete-vertical-pkg
/home/utkarsh/.config/emacs/elpa/icomplete-vertical-20210105.500/icomplete-vertical-autoloads hides /tmp/icomplete-vertical-0R2C0p/icomplete-vertical-20210105.500/icomplete-vertical-autoloads

Features:
(shadow mail-extr emacsbug timezone dabbrev korea-util org-element
ol-eww eww xdg mm-url ol-rmail ol-mhe ol-irc ol-info ol-gnus nnselect
gnus-search gnus-art mm-uu mml2015 gnus-sum gnus-group gnus-undo
gnus-start gnus-dbus dbus gnus-cloud nnimap nnmail mail-source utf7
netrc nnoo parse-time gnus-spec gnus-int gnus-range gnus-win ol-docview
doc-view ol-bibtex bibtex iso8601 ol-bbdb ol-w3m eieio-opt speedbar
ezimage dframe shortdoc mule-util cl-print ido vc-git
modus-operandi-theme help-fns icomplete-vertical autoload radix-tree
lisp-mnt tar-mode arc-mode archive-mode mm-archive gnutls network-stream
url-http url-gw nsm url-cache url-auth epa-file password-store
auth-source-pass with-editor async-bytecomp async shell minibuf-eldef
two-column misearch multi-isearch flyspell ispell company-oddmuse
company-keywords company-etags etags fileloop xref project company-gtags
company-dabbrev-code company-dabbrev company-files company-clang
company-capf company-cmake company-semantic company-template
company-bbdb company-tng company pcase flycheck rx dash server
modus-vivendi-theme modus-themes gnus nnheader emms-librefm-stream
emms-librefm-scrobbler emms-playlist-limit emms-volume
emms-volume-mixerctl emms-volume-pulse emms-volume-amixer emms-i18n
emms-history emms-score emms-stream-info emms-metaplaylist-mode
emms-bookmarks emms-cue emms-mode-line-icon emms-browser sort
emms-playlist-sort emms-last-played emms-player-xine emms-player-mpd
emms-playing-time emms-lyrics emms-url emms-streams emms-show-all
emms-tag-editor emms-mark emms-mode-line emms-cache emms-info-exiftool
emms-info-tinytag emms-info-metaflac emms-info-opusinfo
emms-info-ogginfo emms-info-mp3info emms-info emms-later-do
emms-playlist-mode emms-player-vlc emms-player-mpv emms-player-mplayer
emms-player-simple emms-source-playlist emms-source-file locate
emms-setup emms emms-compat notmuch hl-line notmuch-tree notmuch-jump
notmuch-hello notmuch-show notmuch-print notmuch-crypto notmuch-mua
notmuch-message notmuch-draft notmuch-maildir-fcc notmuch-address
notmuch-company notmuch-parser notmuch-wash diff-mode coolj
notmuch-query goto-addr icalendar diary-lib diary-loaddefs notmuch-tag
crm notmuch-lib notmuch-version notmuch-compat mm-view mml-smime smime
dig smtpmail sendmail sdcv pos-tip popup showtip esh-module esh-groups
esh-util elfeed-show elfeed-search message rmc rfc822 mml mml-sec epa
derived epg epg-config gnus-util rmail rmail-loaddefs mm-decode
mm-bodies mm-encode mail-parse rfc2231 rfc2047 rfc2045 mm-util
ietf-drums mail-prsvr mailabbrev mail-utils gmm-utils mailheader shr
kinsoku puny svg dom elfeed-csv elfeed elfeed-curl elfeed-log elfeed-db
elfeed-lib thingatpt avl-tree generator url-queue xml-query xml
saveplace-pdf-view saveplace pdf-occur ibuf-ext ibuffer ibuffer-loaddefs
tablist tablist-filter semantic/wisent/comp semantic/wisent
semantic/wisent/wisent semantic/util-modes semantic/util semantic
semantic/tag semantic/lex semantic/fw mode-local cedet pdf-isearch
let-alist pdf-misc imenu pdf-tools compile cus-edit cus-start cus-load
pdf-view bookmark text-property-search pp jka-compr pdf-cache pdf-info
tq pdf-util image-mode exif try winner icomplete amx s minions
autorevert filenotify org ob ob-tangle ob-ref ob-lob ob-table ob-exp
org-macro org-footnote org-src ob-comint org-pcomplete pcomplete comint
ansi-color ring org-list org-faces org-entities time-date noutline
outline org-version ob-emacs-lisp ob-core ob-eval org-table ol org-keys
org-compat advice org-macs org-loaddefs format-spec find-func cal-menu
calendar cal-loaddefs dired-aux dired dired-loaddefs delsel recentf
tree-widget wid-edit paren elec-pair edmacro kmacro cl-extra help-mode
use-package use-package-ensure use-package-delight use-package-diminish
use-package-bind-key bind-key easy-mmode use-package-core finder-inf
info package easymenu browse-url url url-proxy url-privacy url-expand
url-methods url-history url-cookie url-domsuf url-util mailcap
url-handlers url-parse auth-source cl-seq eieio eieio-core cl-macs
eieio-loaddefs password-cache json subr-x map url-vars seq byte-opt gv
bytecomp byte-compile cconv cl-loaddefs cl-lib iso-transl tooltip eldoc
electric uniquify ediff-hook vc-hooks lisp-float-type mwheel term/x-win
x-win term/common-win x-dnd tool-bar dnd fontset image regexp-opt fringe
tabulated-list replace newcomment text-mode elisp-mode lisp-mode
prog-mode register page tab-bar menu-bar rfn-eshadow isearch timer
select scroll-bar mouse jit-lock font-lock syntax facemenu font-core
term/tty-colors frame minibuffer cl-generic cham georgian utf-8-lang
misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms
cp51932 hebrew greek romanian slovak czech european ethiopic indian
cyrillic chinese composite charscript charprop case-table epa-hook
jka-cmpr-hook help simple abbrev obarray cl-preloaded nadvice button
loaddefs faces cus-face macroexp files window text-properties overlay
sha1 md5 base64 format env code-pages mule custom widget
hashtable-print-readable backquote threads dbusbind inotify lcms2
dynamic-setting system-font-setting font-render-setting cairo
move-toolbar gtk x-toolkit x multi-tty make-network-process emacs)

Memory information:
((conses 16 679723 52515)
 (symbols 48 43644 5)
 (strings 32 192833 7458)
 (string-bytes 1 5816298)
 (vectors 16 68758)
 (vector-slots 8 1171046 137243)
 (floats 8 798 2574)
 (intervals 56 13094 1049)
 (buffers 984 25))

-- 
Utkarsh Singh





^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#45839: 28.0.50; Isearch and transient mode wierd behaviour in info-mode!
  2021-01-13 11:50 bug#45839: 28.0.50; Isearch and transient mode wierd behaviour in info-mode! Utkarsh Singh
@ 2021-01-13 18:06 ` Juri Linkov
  2021-01-13 19:20   ` Drew Adams
  0 siblings, 1 reply; 6+ messages in thread
From: Juri Linkov @ 2021-01-13 18:06 UTC (permalink / raw)
  To: Utkarsh Singh; +Cc: 45839

> In info-mode do the following:
> + C-SPC :: set mark
> + C-s valid_query :: search for some string
> + RET
>
> By now you can see region is not highlighted and this will affect all
> other command such as M-w(kill-ring-save).

Please see in the function 'Info-search' that it intentionally
deactivates the active region during the search by calling:

  (deactivate-mark)

This is because when the search arrives in another Info node,
then region highlighting breaks - the region's beginning stays
in the previous node, while the region's end moves to the next node.
To avoid such situation, it deactivates the active region.

If you want to copy the region with M-w, then you can reactivate it with
'C-x C-x'.





^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#45839: 28.0.50; Isearch and transient mode wierd behaviour in info-mode!
  2021-01-13 18:06 ` Juri Linkov
@ 2021-01-13 19:20   ` Drew Adams
  2021-01-13 19:24     ` Drew Adams
  2021-01-14  9:20     ` Juri Linkov
  0 siblings, 2 replies; 6+ messages in thread
From: Drew Adams @ 2021-01-13 19:20 UTC (permalink / raw)
  To: Juri Linkov, Utkarsh Singh; +Cc: 45839

> Please see in the function 'Info-search' that it intentionally
> deactivates the active region during the search by calling:
> 
>   (deactivate-mark)
> 
> This is because when the search arrives in another Info node,
> then region highlighting breaks - the region's beginning stays
> in the previous node, while the region's end moves to the next node.
> To avoid such situation, it deactivates the active region.

FWIW, Info+ doesn't have this problem.  It deactivates
the mark only when search moves to another node.
___

If library Isearch+ is also loaded then when search
stays in the same node the mark is deactivated if
option `isearchp-deactivate-region-flag' is non-nil
(the default).  You can toggle this anytime during
Isearch with `M-= C-SPC'.

So you control the behavior for search within a node,
and deactivation happens when search moves to another
node.






^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#45839: 28.0.50; Isearch and transient mode wierd behaviour in info-mode!
  2021-01-13 19:20   ` Drew Adams
@ 2021-01-13 19:24     ` Drew Adams
  2021-01-14  9:20     ` Juri Linkov
  1 sibling, 0 replies; 6+ messages in thread
From: Drew Adams @ 2021-01-13 19:24 UTC (permalink / raw)
  To: Juri Linkov, Utkarsh Singh; +Cc: 45839

Adding links, for OP -

Info+ description:

https://www.emacswiki.org/emacs/InfoPlus

code:

https://www.emacswiki.org/emacs/download/info%2b.el

___

Isearch+ description:

https://www.emacswiki.org/emacs/IsearchPlus

code:

https://www.emacswiki.org/emacs/download/isearch%2b.el





^ permalink raw reply	[flat|nested] 6+ messages in thread

* bug#45839: 28.0.50; Isearch and transient mode wierd behaviour in info-mode!
  2021-01-13 19:20   ` Drew Adams
  2021-01-13 19:24     ` Drew Adams
@ 2021-01-14  9:20     ` Juri Linkov
       [not found]       ` <87mtxby5t9.fsf@gmail.com>
  1 sibling, 1 reply; 6+ messages in thread
From: Juri Linkov @ 2021-01-14  9:20 UTC (permalink / raw)
  To: Drew Adams; +Cc: 45839, Utkarsh Singh

>> Please see in the function 'Info-search' that it intentionally
>> deactivates the active region during the search by calling:
>>
>>   (deactivate-mark)
>>
>> This is because when the search arrives in another Info node,
>> then region highlighting breaks - the region's beginning stays
>> in the previous node, while the region's end moves to the next node.
>> To avoid such situation, it deactivates the active region.
>
> FWIW, Info+ doesn't have this problem.  It deactivates
> the mark only when search moves to another node.

But this doesn't mean that info.el should not be fixed.
Here is the fix:

diff --git a/lisp/info.el b/lisp/info.el
index 62d7b583ff..dec93928b3 100644
--- a/lisp/info.el
+++ b/lisp/info.el
@@ -1973,7 +1973,6 @@ Info-search
                        "Regexp search%s" (car Info-search-history)
 		       (if case-fold-search "" " case-sensitively"))
 		      nil 'Info-search-history)))
-  (deactivate-mark)
   (when (equal regexp "")
     (setq regexp (car Info-search-history)))
   (when regexp
@@ -2066,6 +2065,7 @@ Info-search
                (< found opoint-max))
           ;; Search landed in the same node
           (goto-char found)
+        (deactivate-mark)
         (widen)
         (goto-char found)
         (save-match-data (Info-select-node)))





^ permalink raw reply related	[flat|nested] 6+ messages in thread

* bug#45839: 28.0.50; Isearch and transient mode wierd behaviour in info-mode!
       [not found]       ` <87mtxby5t9.fsf@gmail.com>
@ 2021-01-14 19:09         ` Juri Linkov
  0 siblings, 0 replies; 6+ messages in thread
From: Juri Linkov @ 2021-01-14 19:09 UTC (permalink / raw)
  To: 45839

tags 45839 fixed
close 45839 28.0.50
thanks

>> @@ -2066,6 +2065,7 @@ Info-search
>>                 (< found opoint-max))
>>            ;; Search landed in the same node
>>            (goto-char found)
>> +        (deactivate-mark)
>>          (widen)
>>          (goto-char found)
>>          (save-match-data (Info-select-node)))
>
> Thanks this works!

Thanks for confirming, now pushed to master.





^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2021-01-14 19:09 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-01-13 11:50 bug#45839: 28.0.50; Isearch and transient mode wierd behaviour in info-mode! Utkarsh Singh
2021-01-13 18:06 ` Juri Linkov
2021-01-13 19:20   ` Drew Adams
2021-01-13 19:24     ` Drew Adams
2021-01-14  9:20     ` Juri Linkov
     [not found]       ` <87mtxby5t9.fsf@gmail.com>
2021-01-14 19:09         ` Juri Linkov

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.