From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Narendra Joshi Newsgroups: gmane.emacs.devel Subject: Re: Face text property for `minor-mode-alist` item. Date: Mon, 28 Dec 2020 00:46:23 +0100 Message-ID: <87o8ieyfqo.fsf@gmail.com> References: <87im8nz3i9.fsf@gmail.com> <878s9i99zw.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="19775"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: Emacs Devel To: Lars Ingebrigtsen Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon Dec 28 00:48:04 2020 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 1ktflb-00053H-Pu for ged-emacs-devel@m.gmane-mx.org; Mon, 28 Dec 2020 00:48:03 +0100 Original-Received: from localhost ([::1]:42734 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ktfla-00050H-QJ for ged-emacs-devel@m.gmane-mx.org; Sun, 27 Dec 2020 18:48:02 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:48442) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ktfk4-0003r0-R2 for emacs-devel@gnu.org; Sun, 27 Dec 2020 18:46:28 -0500 Original-Received: from mail-ej1-x62f.google.com ([2a00:1450:4864:20::62f]:34743) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ktfk3-0001ui-3F for emacs-devel@gnu.org; Sun, 27 Dec 2020 18:46:28 -0500 Original-Received: by mail-ej1-x62f.google.com with SMTP id g20so12304062ejb.1 for ; Sun, 27 Dec 2020 15:46:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=g5V2+7v6ikDxXAm9BsWSyQ9J4WSpaPbiT4y3wOnPnys=; b=NCxu5y1XocRGAQwwppLBjMLq8IwmxY+j1k1gM7m7VfIMsboRtSLeov8S0WMbtZKcxA q9qTvoIZwUHZ2WOefC+0sEYQJlC6LoxnsJbZJ5g3dRDDBwdoKYotcm/OH8YakZR9uCh6 Lvphb2nixZhjOI7WGOC0qcOJKhGHVMlkqUSCnq/lZBiAF8vvlaO7b8ExM27JPItKUyh1 A5KEu3J5TLlwz28TUvN3jSu1aD0smXkYVtZMxLVKGljU17ce55fWFQeVISKQ0Nj6dhht 7ZGS4O/XbU7sZpVAiL7n6lVOESCizFIDtvt6mSWJZtcpjMChq/cHUjEcMeOxfi9dDiZY reoQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=g5V2+7v6ikDxXAm9BsWSyQ9J4WSpaPbiT4y3wOnPnys=; b=fwz2gE2HPHiz7Lv/MXVP5b8Y4V6bYSo+1pui0NYPUySjmg9wJTfDXFFAYF7UKg4qm9 0fT5yhrdYUvqPEa6VWX3dOhNVT9GObLkC9ghOEqPs8/aALDlTirgDGs4sTXOEKlPEGxx v0NGsjOv1wonZsMmIh1la0Bbg3EZHglmsYSTGcEfu6umb/SGKJMR74PEGbnxVxE+a7Xk GMldczoE22vjhA3f5QssUL6tyoNTFQM8ZDGSmfNtFsJWgeP6Q2kAbj14+rBEmYBS9NPx KHDNGKSEA5hiUWEZobNu5jVv/cu2vkrjIYRgItHghecNklckg0BkCw8E43iqIlNRe5v+ H8VQ== X-Gm-Message-State: AOAM532NgeAvlyuJyjhY89/vFMRQtXwI3muK8PEyo2hJfAqRUsGyZU1/ bYSRPcVupljBtIRREAmvMg3gdZr2xiNpAHY= X-Google-Smtp-Source: ABdhPJyff3ov77Z80HdDyJK/geS9Othkt5/DRtAYvJNHcXCiHtSR8Ah+N2kVXbEdHB4YhGn7T53TZw== X-Received: by 2002:a17:906:a3c7:: with SMTP id ca7mr40748756ejb.523.1609112785115; Sun, 27 Dec 2020 15:46:25 -0800 (PST) Original-Received: from vicarie ([2a02:8109:b640:2344::4d4d]) by smtp.gmail.com with ESMTPSA id lz17sm16406037ejb.19.2020.12.27.15.46.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 27 Dec 2020 15:46:24 -0800 (PST) In-Reply-To: <878s9i99zw.fsf@gnus.org> (Lars Ingebrigtsen's message of "Sun, 27 Dec 2020 23:09:39 +0100") Received-SPF: pass client-ip=2a00:1450:4864:20::62f; envelope-from=narendraj9@gmail.com; helo=mail-ej1-x62f.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 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_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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:261955 Archived-At: Lars Ingebrigtsen writes: > Narendra Joshi writes: > >> Is this a bug in Emacs or is this expected behaviour? > > It's expected (but possibly under-documented?) behaviour -- the mode > line code tries to be super-efficient, and doesn't allow text to have > different text properties. As you've discovered, it only uses the text > property from the first character, and uses that over the entire text > fragment. Thanks for clarifying this. I did check the Emacs Lisp manual entries for mode line constructs and couldn't find any documentation about this. > You have to use the special (:propertize ...) mode line constructs (and > chop up the text) to get more fine-grained text properties in the mode > line. Best regards, -- Narendra Joshi