unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#25575: Make ido respect completions-common-part face
@ 2017-01-29 22:22 Luis Gerhorst
  2017-02-09  1:23 ` Dmitry Gutov
  0 siblings, 1 reply; 3+ messages in thread
From: Luis Gerhorst @ 2017-01-29 22:22 UTC (permalink / raw)
  To: 25575

Hi,
This would allow the user to customize the display of the common part of completions, e.g. remove the decorators around it and only distinguish it by using a different face (which looks much cleaner). Company also display the common part this way (see the `company-preview-common` face).

Here's a advice based snippet that does what I want. It does not seem to handle colors properly but since completions-common-part just underlines text for me, it's ok:

(defun luis-propertize-ido-common-match-string (&rest _)
  (when ido-common-match-string
    (setq ido-common-match-string
          (propertize ido-common-match-string
                      'face 'completions-common-part))))

(defun luis-unpropertize-ido-common-match-string (&rest _)
  (when ido-common-match-string
    (setq ido-common-match-string
          (propertize ido-common-match-string
                      'face nil))))

(advice-add 'ido-completions :before
            #'luis-propertize-ido-common-match-string)
(advice-add 'ido-completions :after
            #'luis-unpropertize-ido-common-match-string)

Best regards,
Luis





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

* bug#25575: Make ido respect completions-common-part face
  2017-01-29 22:22 bug#25575: Make ido respect completions-common-part face Luis Gerhorst
@ 2017-02-09  1:23 ` Dmitry Gutov
  2021-02-05 13:26   ` Lars Ingebrigtsen
  0 siblings, 1 reply; 3+ messages in thread
From: Dmitry Gutov @ 2017-02-09  1:23 UTC (permalink / raw)
  To: Luis Gerhorst, 25575

Hey Luis,

On 30.01.2017 00:22, Luis Gerhorst wrote:

> This would allow the user to customize the display of the common part of completions, e.g. remove the decorators around it and only distinguish it by using a different face (which looks much cleaner). Company also display the common part this way (see the `company-preview-common` face).

Could you post a screenshot of the result that you see?





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

* bug#25575: Make ido respect completions-common-part face
  2017-02-09  1:23 ` Dmitry Gutov
@ 2021-02-05 13:26   ` Lars Ingebrigtsen
  0 siblings, 0 replies; 3+ messages in thread
From: Lars Ingebrigtsen @ 2021-02-05 13:26 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: 25575, Luis Gerhorst

Dmitry Gutov <dgutov@yandex.ru> writes:

> On 30.01.2017 00:22, Luis Gerhorst wrote:
>
>> This would allow the user to customize the display of the common
>> part of completions, e.g. remove the decorators around it and only
>> distinguish it by using a different face (which looks much
>> cleaner). Company also display the common part this way (see the
>> `company-preview-common` face).
>
> Could you post a screenshot of the result that you see?

More information was requested, but no response was given within a few
years, so I'm closing this bug report.  If this is something that should
still be worked on, please respond to this email and we'll reopen the
bug report.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





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

end of thread, other threads:[~2021-02-05 13:26 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-01-29 22:22 bug#25575: Make ido respect completions-common-part face Luis Gerhorst
2017-02-09  1:23 ` Dmitry Gutov
2021-02-05 13:26   ` Lars Ingebrigtsen

Code repositories for project(s) associated with this public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).