Tags: patch The substring completion style completes "foo-bar" as "*foo-bar*". The partial-completion completion style completes "foo-bar" as "foo*bar*". It is currently not possible to get completion as "*foo*bar*", e.g. combining the two. This patch adds a completion style that combines the two. (It's a bit rough right now, just a quick implementation, will clean it up with feedback) It's preferable for this to be a separate style from partial-completion rather than a customization for partial-completion, because completing with a leading glob is inefficient: it doesn't allow the completion table to do any filtering at all. So, for example, one might want the regular partial-completion style to run first, and if it doesn't find anything then the substring-partial-completion style can run. Further claim: I think the substring completion style should be replaced with the substring-partial-completion style in most places. But that may be a bit more controversial. In GNU Emacs 29.2.50 (build 6, x86_64-pc-linux-gnu, X toolkit, cairo version 1.15.12, Xaw scroll bars) of 2024-03-25 built on igm-qws-u22796a Repository revision: 5d867aca5ea016c07fe9e8b60f55345f83012333 Repository branch: emacs-29 Windowing system distributor 'The X.Org Foundation', version 11.0.12011000 System Description: Rocky Linux 8.9 (Green Obsidian) Configured using: 'configure -C --with-x-toolkit=lucid --with-native-compilation --with-gif=ifavailable'