From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Drew Adams Newsgroups: gmane.emacs.devel Subject: RE: new-flex-completion-style Date: Thu, 14 Feb 2019 19:20:47 +0000 (UTC) Message-ID: References: <20190202232827.27331.87300@vcs0.savannah.gnu.org> <20190202232828.4AE452159A@vcs0.savannah.gnu.org> <87lg2mynrg.fsf@gmail.com> <871s4czm5n.fsf@gmail.com> <1f4513ab-cd39-4543-9b1a-743e1307dd54@default> <23b6cda2-0f37-4c41-b664-5353505c0cd1@default> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="234062"; mail-complaints-to="usenet@blaine.gmane.org" Cc: Daniel Pittman , Stefan Monnier , emacs-devel To: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Feb 14 20:27:32 2019 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1guMfR-000yjW-IH for ged-emacs-devel@m.gmane.org; Thu, 14 Feb 2019 20:27:29 +0100 Original-Received: from localhost ([127.0.0.1]:53813 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1guMfQ-0006ke-EO for ged-emacs-devel@m.gmane.org; Thu, 14 Feb 2019 14:27:28 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:57721) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1guMZB-0002iE-3y for emacs-devel@gnu.org; Thu, 14 Feb 2019 14:21:02 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1guMZA-00023d-5i for emacs-devel@gnu.org; Thu, 14 Feb 2019 14:21:01 -0500 Original-Received: from aserp2130.oracle.com ([141.146.126.79]:42192) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1guMZ9-0001ys-S1 for emacs-devel@gnu.org; Thu, 14 Feb 2019 14:21:00 -0500 Original-Received: from pps.filterd (aserp2130.oracle.com [127.0.0.1]) by aserp2130.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x1EJEcvt041887; Thu, 14 Feb 2019 19:20:52 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=mime-version : message-id : date : from : sender : to : cc : subject : references : in-reply-to : content-type : content-transfer-encoding; s=corp-2018-07-02; bh=LS9LtXv4VjhwTJGcbt84nz3aya98f5+tAqEtenyzX84=; b=Mcze4xGW9a76ceFho4MGuln73UgfGf8xVMgCGI26fe+xHxtfEJbvNoLRtesoX8gU4ZEK JJsFqs7DHJkeWvUsP3cZsDIDmJLPDsRuF1a+La3O1OXggo5UTN3EO3Q7FdZuy9xfsNGx 1nNskJZSyZ2QMvp84OsT41OcaOObywPwVrE2S47SZRt9gzwyJ66di7U9zhNts5fnDEeU wCFBcjAP/0T9tZGK9kgj44kPd4lCYPfg2+oihPSZoPL1drwhVUNPmiMH3ucXKkPBIMEX 8ho+XuVxUI2mhpdL6pYF0GFE+Jr1+a/4iTsJsVmCvnARvbsrO3dqEA73LPJAZXmWqbrO yw== Original-Received: from userv0021.oracle.com (userv0021.oracle.com [156.151.31.71]) by aserp2130.oracle.com with ESMTP id 2qhre5sx85-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 14 Feb 2019 19:20:52 +0000 Original-Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by userv0021.oracle.com (8.14.4/8.14.4) with ESMTP id x1EJKocJ032298 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 14 Feb 2019 19:20:51 GMT Original-Received: from abhmp0007.oracle.com (abhmp0007.oracle.com [141.146.116.13]) by aserv0122.oracle.com (8.14.4/8.14.4) with ESMTP id x1EJKmP1030874; Thu, 14 Feb 2019 19:20:48 GMT In-Reply-To: X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 16.0.4810.0 (x86)] X-Proofpoint-Virus-Version: vendor=nai engine=5900 definitions=9167 signatures=668683 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1902140128 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] X-Received-From: 141.146.126.79 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 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.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:233343 Archived-At: > > > Tho the equivalent regexp I'm using here is ".*a.*b.*c.*" not > > > "a.*b.*c" as your page states. > > > > With Icicles regexp matching for completion you don't need the > > initial `.*'. And you don't need the final `.*', I should have added (didn't notice it in your pattern). It sounds like you're always trying to match all chars in a line. I'm not. I'm not dealing with lines, in general. I'm matching a pattern against a string, in general. =20 > Let me state it another way. Does your system match "foo" > to "barfoobaz" or does it fail? It matches. > If so, then I think your _equivalent_ regexp is probably .*f.*o.*o.* (string-match-p "f.*o.*o" "barfoobaz") =3D> 3 Scatter-matching is used with "apropos" completion. It's just regexp completion, using the substituted regexp. Substituting regexp `f.*o.*o' for input `foo' just does the above `string-match-p'. > > I don't use any scoring for scatter matching. > > Icicle users usually have a bunch of sort orders they can use >=20 > Right. Which one do you use, when you use scatter-matching? Any of them. Depends on what I'm doing and what I want. Scatter-matching is typically not specific to particular contexts, and thus to any context-specific sort orders. Can you see that some of the following predefined orders might be advantageous in particular contexts/use cases? Can you see that whether matching is scatter, regexp, basic prefix, or others, any of the following can be useful? (As I said, there are a couple of fuzzy-match methods that impose their own sort order, but most do not. Similarly, a few commands impose their own sort order - they don't allow re-sorting.) some of the Icicles sort orders that exist by default: General: alphabetical case-insensitive by last use as input by previous use alphabetically Color completion: by color name (colors) by hue (colors) by purity/saturation (colors) by brightness/value/luminance (colors) by all HSV components, in order (colors) by HSV distance from a base color (colors) by amount of red (colors) by amount of green (colors) by amount of blue (colors) by all RGB components, in order (colors) by RGB distance from a base color (colors) Key completion: by key name, prefix keys first (keys) by key name, local bindings first (keys) Command completion: by command name (commands) by abbrev frequency (commands) Buffer-name completion: by buffer size (buffer names) *=E2=80=A6* buffers last (buffer names) by major mode name (buffer names) by mode-line mode name (buffer names) by file/process name (buffer names) File-name completion: by last file modification time (file names) by file type (extension) (file names) by directories first or last (file names) Other: in book order (Info) special candidates first proxy candidates first extra candidates first by second multi-completion part (multi-completions) turned OFF (does not sort at all)=20