From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id mA8/Dyt7l2MJqwAAbAwnHQ (envelope-from ) for ; Mon, 12 Dec 2022 20:04:11 +0100 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id YO5SDit7l2M7kQAAG6o9tA (envelope-from ) for ; Mon, 12 Dec 2022 20:04:11 +0100 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 9CAF4E19B for ; Mon, 12 Dec 2022 20:04:10 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p4o5F-0000os-CL; Mon, 12 Dec 2022 14:03:25 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p4o5C-0000oY-3Z for emacs-orgmode@gnu.org; Mon, 12 Dec 2022 14:03:23 -0500 Received: from mail-ej1-x634.google.com ([2a00:1450:4864:20::634]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p4o59-0003Qs-Vh for emacs-orgmode@gnu.org; Mon, 12 Dec 2022 14:03:21 -0500 Received: by mail-ej1-x634.google.com with SMTP id m18so30587298eji.5 for ; Mon, 12 Dec 2022 11:03:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:mime-version:from:to:cc:subject :date:message-id:reply-to; bh=lraXIiiA+j5KQbOsnmy6kY6VVArjidgc2hawMXGeoBg=; b=PmBwOQefziqGZt7T/eJAhZcHm1oIRQQL6i3nQu6ppSnAze1ljQYUxSzbr4PQ9cJBmy 2MpH/ZRP+Fi5JJgnRroPJof+mahagYwL1Ypn8jIsuHrAojnZULpp6sEbh/l0hM4jBxb/ c67tVMC3zs0SIe9n5IoPn+OER1c7p6MvzLz1Xo4iMZhz13FNUL6lx0SODusQ6hF0C/w9 VUAYCltzDLc5M9nBrd8djyVOhka1PrJTz9roWphPiXoCOFZq7haMBJNOdZ0UxuMr+72/ 0SAIrconjoFvuZgoDDs9IlFczy+hIjzAJs/xK8aRDZ980evfy/7JAiV7zZtc+P1Nr/HT QCMA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:mime-version:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=lraXIiiA+j5KQbOsnmy6kY6VVArjidgc2hawMXGeoBg=; b=Tt4cXdaTEQ+WYlb9DNheC2Kw+L3bgsiiuJujZ91aXC4wryKTx+0N+Ss4bKk8T5EvW/ K9qtVAsRwOUunKo0U/qGtKJbSBibw2sLUbVY9bNnhEqHO4A0LC57KDe1g6PNxBXzwnB6 sh7H+oZiBpx9OpjREPdlVPKAmCmisH3+DQ3aNSAIbTADcH61QQS1SLe0iVXuyxuMGvJx ialiOJcFfT7+4N1x3/tNMsCNNPxq43KnjusRhvBIImtEe2o2ryGraOcIIAc3OQzqCnZb 6tnLJpbRPCNfnVGDGmvO5r9MKax1Fnc52aXG0TvQqOka+aCphkE97vmmLYNICJs1CGZh 4dVg== X-Gm-Message-State: ANoB5pkwHnOKii3SJdUJu+NePEriIy3TDfmiaOF5E5m0zOm/ItZViEXt zerg77sRffwwzYOPh95MZ4a3yrJlgUzqEclG3TU= X-Google-Smtp-Source: AA0mqf44ireazKHEtK4KGFeAcQlAESOIXiomCjWH6AP0u8x2ZiPUvdYjP+nEix4/wcaIV47qhhoXD4kgeHyddWTs/Kk= X-Received: by 2002:a17:906:382:b0:7bc:87b8:e6de with SMTP id b2-20020a170906038200b007bc87b8e6demr48338850eja.256.1670871798076; Mon, 12 Dec 2022 11:03:18 -0800 (PST) MIME-Version: 1.0 From: Mark Kerr Date: Mon, 12 Dec 2022 14:02:42 -0500 Message-ID: Subject: Re: org-agenda-dim-blocked-tasks don't use org-todo face To: yantar92@posteo.net Cc: emacs-orgmode@gnu.org, Mark Kerr Content-Type: text/plain; charset="UTF-8" Received-SPF: pass client-ip=2a00:1450:4864:20::634; envelope-from=mkerr23@gmail.com; helo=mail-ej1-x634.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-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1670871851; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=lraXIiiA+j5KQbOsnmy6kY6VVArjidgc2hawMXGeoBg=; b=AyURetFv9Cw98QnwCIBzft6Wf66uR8Ig8K+4CEp804Dwd2nYrKVPql9KL0o5Ff1ZhIDjSH Fss/qhVetgwjd9sbPEuRff1qraX+aNTEFyo/kdww5mvaTdHhxO2TnVW9g41WKDJViJagPo umc9F/fU/72g9jQI4PfajcvQBTSUtgW7xAA6mu+yZr8b+XFsaKdqx2m305LMVpzuDT8LZH Rrq3ne/OTkoV/GwEcVgQhb+J+yVGVPI1pZqTj8YzxPIrCPhAU/qb0FOM4gKadB+/pl/Yb4 gVauXgE7mXzTSVCiDIeJGrQYcG8JayYUk7tdhTqjxZVkr9e7e3WFoNurf75cxQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=PmBwOQef; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=gmail.com ARC-Seal: i=1; s=key1; d=yhetil.org; t=1670871851; a=rsa-sha256; cv=none; b=AqsSPXqvtlsPc7cghWUdEJBHrkdH8i/ZC1J5WTOt7R6bVhV4cqzNp9Virq+0JAeKHYZ0c9 dUyd39r7qW66GrQrRmPEqpSGwb7V+lZ6G+uPOh55kCIebjg2IbWislKgbSUTg41726OcUu 7ZMl0dT+WyOT3sHF4S+DVyrfZxIo9IQrWVH4l+q0KFUuxJfagKzFqDdItCxiW406wzR9sK 2/oIDTrOJedGpiMA9aj02qBIme+jCh3Z36XQtM8xJK0ZfEJ8RaN7J2zJP2PEL36NGqQAq2 iOE1naoDFOAMbiD79wwyyFifMMkBCTfVTpeDkEEWyLzDkJBYeEx4O9SL8dZy3w== X-Migadu-Spam-Score: -4.92 X-Spam-Score: -4.92 X-Migadu-Queue-Id: 9CAF4E19B X-Migadu-Scanner: scn0.migadu.com Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=PmBwOQef; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=gmail.com X-TUID: cl8VZeFsvQnP From: Ihor Radchenko > [-- Attachment #1: Type: text/plain, Size: 534 bytes --] > > Mark Kerr writes: > > > The org-todo face is used for todo keywords in non-blocked items. > > > > When org-agenda-dim-blocked-tasks is set to true, however, the todo keyword > > is instead displayed using org-agenda-dimmed-todo-face. > > > > The org-priority face, however, is still used for blocked tasks. > > > > Is this by design or due to an error on my part? Is there a possible > > workaround? > > This appears to be an omission on Org part, related some overlay > implementation details in Emacs. > > Can you try the attached patch? > > > [-- Warning: decoded text below may be mangled, UTF-8 assumed --] > [-- Attachment #2: 0001-org-agenda-dim-blocked-tasks-Prioritize-face-over-ot.patch --] > [-- Type: text/x-patch, Size: 1422 bytes --] > > From 1bd6d8bd13deb9e7f57826ea492bbc88fddf5ee3 Mon Sep 17 00:00:00 2001 > Message-Id: <1bd6d8bd13deb9e7f57826ea492bbc88fddf5ee3.1670839095.git.yantar92@posteo.net> > From: Ihor Radchenko > Date: Mon, 12 Dec 2022 12:56:11 +0300 > Subject: [PATCH] org-agenda-dim-blocked-tasks: Prioritize face over other > overlays > > * lisp/org-agenda.el (org-agenda-dim-blocked-tasks): Use high overlays > priority when adding dimmed face. Otherwise, contained overlays, like > created by `org-agenda-fontify-priorities', will take > priority (default Emacs behavior). > > Reported-by: Mark Kerr > Link: https://orgmode.org/list/CAM9qJ5+C3nvbNaJyq6ofRgPsuAMcaBD=2UN-n96Kb68NBbX3Dg@mail.gmail.com > --- > lisp/org-agenda.el | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > > diff --git a/lisp/org-agenda.el b/lisp/org-agenda.el > index eda248938..05f2e3669 100644 > --- a/lisp/org-agenda.el > +++ b/lisp/org-agenda.el > @@ -4166,7 +4166,9 @@ (defun org-agenda-dim-blocked-tasks (&optional _invisible) > (line-beginning-position)) > (line-end-position)))) > (when todo-blocked > - (overlay-put ov 'face 'org-agenda-dimmed-todo-face)) > + (overlay-put ov 'face 'org-agenda-dimmed-todo-face) > + ;; Override other overlays. > + (overlay-put ov 'priority 50)) > (when invisible > (org-agenda-filter-hide-line 'todo-blocked))) > (if (= (point-max) (line-end-position)) > -- > 2.38.1 > > > [-- Attachment #3: Type: text/plain, Size: 224 bytes --] > > > -- > Ihor Radchenko // yantar92, > Org mode contributor, > Learn more about Org mode at . > Support Org development at , > or support my work at This is my first time applying a patch, so I hope I did it properly. Thank you. I may have been unclear but the result seems to be the opposite of what I was hoping for. I was hoping to be able to gain the ability to use the org-todo face with blocked tasks, while retaining the org-priority face which was previously working.. Now blocked tasks are entirely rendered with org-agenda-dimmed-todo-face, including the priority. In case I messed up the patch, here is the patched function: -- (defun org-agenda-dim-blocked-tasks (&optional _invisible) "Dim currently blocked TODOs in the agenda display. When INVISIBLE is non-nil, hide currently blocked TODO instead of dimming them." ;FIXME: The arg isn't used, actually! (interactive "P") (when (called-interactively-p 'interactive) (message "Dim or hide blocked tasks...")) (dolist (o (overlays-in (point-min) (point-max))) (when (eq (overlay-get o 'face) 'org-agenda-dimmed-todo-face) (delete-overlay o))) (save-excursion (let ((inhibit-read-only t)) (goto-char (point-min)) (while (let ((pos (text-property-not-all (point) (point-max) 'org-todo-blocked nil))) (when pos (goto-char pos))) (let* ((invisible (eq (org-get-at-bol 'org-todo-blocked) 'invisible)) (todo-blocked (eq (org-get-at-bol 'org-filter-type) 'todo-blocked)) (ov (make-overlay (if invisible (line-end-position 0) (line-beginning-position)) (line-end-position)))) (when todo-blocked (overlay-put ov 'face 'org-agenda-dimmed-todo-face) ;; Override other overlays. (overlay-put ov 'priority 50)) (when invisible (org-agenda-filter-hide-line 'todo-blocked))) (if (= (point-max) (line-end-position)) (goto-char (point-max)) (move-beginning-of-line 2))))) (when (called-interactively-p 'interactive) (message "Dim or hide blocked tasks...done"))) -- Thank you, Mark