From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: use of `mouse-face' to delimit text zones Date: Tue, 23 Aug 2011 15:22:16 -0400 Message-ID: References: <4E48D309.6050503@acdlabs.ru> <83hb5jujjs.fsf@gnu.org> <874o1j10zv.fsf@fencepost.gnu.org> <8362lyvcli.fsf@gnu.org> <83k4aasnm9.fsf@gnu.org> <838vqmx9tj.fsf@gnu.org> <87ipppjfiq.fsf@gmail.com> <87ei0cjvow.fsf@gmail.com> <77465C28555E49ACA714C9A439EA4396@us.oracle.com> <834o18hznn.fsf@gnu.org> <8339gshsqw.fsf@gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1314127360 28391 80.91.229.12 (23 Aug 2011 19:22:40 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 23 Aug 2011 19:22:40 +0000 (UTC) Cc: stepnem@gmail.com, drew.adams@oracle.com, emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Aug 23 21:22:36 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1QvwYV-0002dW-H3 for ged-emacs-devel@m.gmane.org; Tue, 23 Aug 2011 21:22:35 +0200 Original-Received: from localhost ([::1]:41746 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QvwYU-00057g-DJ for ged-emacs-devel@m.gmane.org; Tue, 23 Aug 2011 15:22:34 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:47432) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QvwYS-00057b-43 for emacs-devel@gnu.org; Tue, 23 Aug 2011 15:22:33 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QvwYQ-0007UU-Sm for emacs-devel@gnu.org; Tue, 23 Aug 2011 15:22:31 -0400 Original-Received: from ironport2-out.teksavvy.com ([206.248.154.181]:64197 helo=ironport2-out.pppoe.ca) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QvwYO-0007UI-W8; Tue, 23 Aug 2011 15:22:29 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av0EAIv9U05Ld+HZ/2dsb2JhbABCp2R4gUABAQQBViMQCzQSFBgNJIgEvXCGSASfd4Q4 X-IronPort-AV: E=Sophos;i="4.68,271,1312171200"; d="scan'208";a="132452052" Original-Received: from 75-119-225-217.dsl.teksavvy.com (HELO ceviche.home) ([75.119.225.217]) by ironport2-out.pppoe.ca with ESMTP/TLS/ADH-AES256-SHA; 23 Aug 2011 15:22:16 -0400 Original-Received: by ceviche.home (Postfix, from userid 20848) id 241776610A; Tue, 23 Aug 2011 15:22:16 -0400 (EDT) In-Reply-To: <8339gshsqw.fsf@gnu.org> (Eli Zaretskii's message of "Tue, 23 Aug 2011 21:45:11 +0300") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 206.248.154.181 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 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-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:143554 Archived-At: >> > How is Joe R. Hacker supposed to know that adding invisible characters >> > to a portion of text covered by mouse-face will break completion?? >> We're talking about a property added *by the completion code* and *for >> the completion code*. I.e. an internal use. > Not entirely true: when the mouse hovers above those parts of the > *Completions* buffer, the candidate under the mouse gets highlighted. > By contrast, a face added for internal purposed would be invisible to > the user. The completion code wants to add a mouse-face property so it gets highlighted when the mouse hovers above it, yes. That's not an internal detail. The internal detail is "how does it figure out the element boundaries": the fact that it uses the mouse-face property for that is an internal detail. >> Joe R. Hacker doesn't need to know about it unless he actually hacks >> on the code that handles minibuffer-completion-help. > Guess what? he just did. Luckily he sent his code for review, so someone knowledgeable in the relevant code pointed out the pitfall he was about to fall into. Stefan