From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carlos Pita Subject: Agenda todo states autocompletion: suggestion for improvement Date: Thu, 21 Feb 2019 15:47:57 -0300 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Return-path: Received: from eggs.gnu.org ([209.51.188.92]:49888) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gwtOE-0008Cn-IN for emacs-orgmode@gnu.org; Thu, 21 Feb 2019 13:48:11 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gwtOD-0001Lq-Tj for emacs-orgmode@gnu.org; Thu, 21 Feb 2019 13:48:10 -0500 Received: from mail-yb1-xb34.google.com ([2607:f8b0:4864:20::b34]:46639) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gwtOD-0001Ku-Kf for emacs-orgmode@gnu.org; Thu, 21 Feb 2019 13:48:09 -0500 Received: by mail-yb1-xb34.google.com with SMTP id 66so1442540ybo.13 for ; Thu, 21 Feb 2019 10:48:09 -0800 (PST) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: emacs-orgmode Hi all, M-x org-agenda T prompts for a todo keyword. But it builds the completion list while preparing the agenda buffers and this is done *after* prompting. So the first time no completion is presented, the second time completions from previous invocation of org-agenda-prepare-buffers are presented, etc. This has some drawbacks: 1. The first time one has to explicitly type the state. 2. I'm not sure about this but: aren't completions potentially outdated, since the last time the list was built was for a previous agenda? To prepare the buffers before showing the prompt will fix both issues but maybe at a high computational cost, I've not investigated the code in any depth yet. Otherwise, at least the default list of state keywords could be shown when org-todo-keywords-for-agenda is nil, couldn't it? Best regards -- Carlos