From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Augusto Stoffel Newsgroups: gmane.emacs.devel Subject: Re: Simple isearch concerns Date: Thu, 03 Mar 2022 17:36:35 +0100 Message-ID: <87v8wvc7sc.fsf@gmail.com> References: <878s5tc0rn.fsf@mail.linkov.net> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="40948"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: juri@linkov.net, gregory@heytings.org, spacibba@aol.com Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu Mar 03 17:38:05 2022 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nPoSr-000ANO-EQ for ged-emacs-devel@m.gmane-mx.org; Thu, 03 Mar 2022 17:38:05 +0100 Original-Received: from localhost ([::1]:49570 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nPoSq-0001Yb-8E for ged-emacs-devel@m.gmane-mx.org; Thu, 03 Mar 2022 11:38:04 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:41298) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nPoRc-0000gB-Ti for emacs-devel@gnu.org; Thu, 03 Mar 2022 11:36:49 -0500 Original-Received: from [2a00:1450:4864:20::632] (port=39520 helo=mail-ej1-x632.google.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nPoRa-0006M0-Ar for emacs-devel@gnu.org; Thu, 03 Mar 2022 11:36:47 -0500 Original-Received: by mail-ej1-x632.google.com with SMTP id dr20so11848450ejc.6 for ; Thu, 03 Mar 2022 08:36:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:in-reply-to:date:message-id:mime-version; bh=nqDh3Qhqt5+fRogyfPLiZWSNvm60R6zaKBjjvO+L1ow=; b=RvHNguzEeB5CFl4tBZnACSfdVkKuZLMzQf7b2PUGs6GzGKMyigWrN35oG7hnutMxxn n13S4cAK7SecttpR2M0tzzmA1ho+NRzlo21u9x77roiQAsXE7X8YizZCCgyrLfIJFn9v csbvOXtkwfWS/Htp8iRSNSwL63LZdLwYVnSyb8VPkWySGBN2A8VkLH5PfwJFlDFB/OY9 QidqGX0hFY7rIsVX7ONEddo9tfb4JYK5gclJaJyC2HRhYHo6HOwwKtH4YZ0GlWwN/rwp 9bYciJ2K2gi2Pqs2kMGSjjY2CxIJ7izfKwnNU4hcZROLouMs5WYIAaBQ1+IjyJTshwx7 ua4A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:in-reply-to:date:message-id :mime-version; bh=nqDh3Qhqt5+fRogyfPLiZWSNvm60R6zaKBjjvO+L1ow=; b=7tv2eh0ZcEV0TdHFIeTwPGlygCpc3gMevQCSIB8ROD+BK7T7obkQw5ZtOuKqsJLCgm 665ETSA7KW/TEULAFWkDAUFQTrtQaF4Qn1nXw/BgDTXqpEGJUckban5Q7GSxWbxxg2qr L98CoaNuK4ZJiv9yRDSz1pi0D5FpyeHhGmmEP01ENOuyo2l2ww66DskkV+XgqYx4HMb7 OdJ1MX4Bfke5bYBzv2oGg5iMOrSuUX1hQqsAAa8tU2Z6d//8YU5m7JZBD+kaqcdiUR/z sTsR72Qys/5ft7KR10ILczgZG3ZQouVwIeHyMIIuDPtHN0JePqMHk6t7lmZqW6SsaGvl sNrA== X-Gm-Message-State: AOAM533yzsbvM0SX5RnesU3qutU3befK5R+K1am7Mm35rrJt9nZPqE8d lrrOwWMkiQlUyiZ1Dl/9+ETZDs7m56M= X-Google-Smtp-Source: ABdhPJwHir4yo++joGjuisbuX57andNB60UHoW9EKb67c8MaNUFpogWBfkqF1zfVKe7uAfe+eHFVNg== X-Received: by 2002:a17:906:2699:b0:6d0:9f3b:a6a7 with SMTP id t25-20020a170906269900b006d09f3ba6a7mr27617063ejc.397.1646325396973; Thu, 03 Mar 2022 08:36:36 -0800 (PST) Original-Received: from ars3 ([2a02:8109:8ac0:56d0::758e]) by smtp.gmail.com with ESMTPSA id rh13-20020a17090720ed00b006da69254082sm843751ejb.135.2022.03.03.08.36.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 03 Mar 2022 08:36:36 -0800 (PST) In-Reply-To: <878s5tc0rn.fsf@mail.linkov.net> X-Host-Lookup-Failed: Reverse DNS lookup failed for 2a00:1450:4864:20::632 (failed) Received-SPF: pass client-ip=2a00:1450:4864:20::632; envelope-from=arstoffel@gmail.com; helo=mail-ej1-x632.google.com X-Spam_score_int: -6 X-Spam_score: -0.7 X-Spam_bar: / X-Spam_report: (-0.7 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, PDS_HP_HELO_NORDNS=0.659, RCVD_IN_DNSWL_NONE=-0.0001, RDNS_NONE=0.793, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:286790 Archived-At: The non-quitting scroll commands in isearch are an extremely useful addition. But I looked at the implementation now and I'm finding it problematic. At some point it was decided that instead of just defining 'isearch-scroll-up' and 'isearch-scroll-down commands', some pre-command-hook trickery would be used. Presumably this is so that an user option, 'isearch-allow-scroll', could be provided (that's what I gather from the parent message of this email). But this has several disadvantages: you can't assign different keys for the quitting and non-quitting versions of the scroll commands; you can't put the (nonexistent) isearch-scroll-up/down commands in a repeat map; you can't activate the feature selectively, e.g. so that scrolling doesn't quit isearch but beginning/end of buffer does; you can't advice or redefine isearch-scroll-up/down, because they don't exist; it's harder for external package to integrate (I had to copy a piece of the isearch-pre-command-hook into isearch-mb.el). The obvious and natural way to implement this feature would be to define isearch-scroll-up/down commands, bind them in the M-s prefix, and let whoever wants it by default to rebind the keys. Perhaps it's not too late to fix this. Sorry I didn't bring this up at the time of the discussion.