Giter Site home page Giter Site logo

org-fancy-priorities's Issues

org agenda not working in doom emacs + Debian 10

Hi,

I use doom emacs, and am having some issues with fancy-priorities. They work flawlessly in .org buffers. However, the problem is that org agenda does not show the priorities properly. There are two problems that I have noticed:

  1. For todos in the past I can neither see the symbol nor the face. But once I visit the file with the said todo, the symbols become visible. The face still remains hidden.
  2. For todos for the current date and in the future, I can see the symbols, but the correct face does not show.

Versions: Emacs 27.1, doom 2.0.9, org mode 9.5.

By doom syncing the following files you will be able to generate my config (more-or-less). I have only included parts which I think might be relevant, but I can give more info if needed.

;; ~/.doom.d/packages.el
;; Followed this fantastic tutorial for the initial install: https://youtu.be/WSF4EgQqa3Q?t=185
(package! org-fancy-priorities)
;; ~/.doom.d/init.el
(doom! 
       :completion
       (company +tng) 
       ivy                 

       :ui
       doom                
       (emoji +unicode) 
       fill-column       
       hl-todo             
       (ligatures +extra +hasklig)  
       (popup +defaults) 
       treemacs         
       unicode            
       workspaces         

       :editor
       (evil +everywhere)  
       word-wrap          

       :emacs
       (dired +icons)      
       electric         
       (ibuffer +icons)    

       :os
       tty            

       :lang
       (org +dragndrop +pretty)              

       :config
       (default +bindings +smartparens))

;; ~/.doom.d/config.el
(after! org
  (setq!
   org-directory "~/agenda-dir/"
   org-todo-keywords '((sequence "TODO(t)" "DONE(d!)"))
   org-priority-highest '?A
   org-priority-lowest  '?D
   org-priority-default '?D
   org-priority-start-cycle-with-default t
   org-priority-faces '((?A :foreground "#F54768")
                        (?B :foreground "#F5C747")
                        (?C :foreground "#62A6EB")
                        (?D :foreground "#A0A0A0"))
   )
)

;; suggestion from @harrybournis 
(add-hook! 'org-mode-hook 'org-fancy-priorities-mode)
(add-hook! 'org-agenda-mode-hook 'org-fancy-priorities-mode)

(after! org-fancy-priorities
  (setq!
   org-fancy-priorities-list
   '("๐Ÿ…" "๐Ÿ…‘" "๐Ÿ…’" "๐Ÿ…“")
   ))

(after! org-agenda
  (setq!
   org-agenda-files (directory-files-recursively "~/agenda-dir/" "\\.org$")
   ))

Priorities are not shown as intended in org-agenda

Following the discussion in reddit, the priorities are still shown as [#A], [#B], and [#C] if the agenda is opened at the time when the file from org-agenda-files is not yet open and contains #+SETUPFILE.

The recepie for emacs -Q (Org mode 8.2.10):

  1. Create an empty ~/tmp/1.setup
  2. Create the file ~/tmp/6.org with the following content:
#+SETUPFILE: ~/tmp/1.setup

* TODO [#A] check |- (alphapapa/org-super-agenda: Supercharge your Org daily/weekly agenda by grouping items) :BOOKMARK:
:PROPERTIES:
:CREATED: [2018-02-28 Wed 08:18]
:Source: https://github.com/alphapapa/org-super-agenda/
:END:
* TODO report clock report alignment problem when "|" is in the task name
:PROPERTIES:
:CREATED: [2018-02-28 Wed 20:28]
:END:
:LOGBOOK:
CLOCK: [2018-02-28 Wed 20:28]--[2018-02-28 Wed 20:29] =>  0:01
:END:


  1. Insert the following into scratch:
(eval-and-compile
  (require 'package)
  (setq package-archives '(("MELPA" . "http://melpa.org/packages/")
			   ("ELPA" . "http://tromey.com/elpa/")
			   ("gnu"  . "http://elpa.gnu.org/packages/")
			   ("SC"   . "http://joseito.republika.pl/sunrise-commander/")
                           ("org" . "http://orgmode.org/elpa/")
                           )
	load-prefer-newer t
	package-user-dir "~/.emacs.d/elpa"
	package--init-file-ensured t
	package-enable-at-startup nil)
  (unless (file-directory-p package-user-dir)
    (make-directory package-user-dir t))
  (setq load-path (append load-path '("~/.emacs.d/site-lisp/")))
  (setq load-path (append load-path (directory-files "~/.emacs.d/site-lisp/" t "^[^.]" t)))
  (setq load-path (append load-path (directory-files package-user-dir t "^[^.]" t)))
  (package-initialize))

(unless (package-installed-p 'use-package)
  (package-refresh-contents)
  (package-install 'use-package))
(eval-when-compile
  (require 'use-package))
(use-package diminish :ensure t)
(require 'bind-key)


(use-package org-fancy-priorities
  :ensure t
  :hook 
  (org-mode . org-fancy-priorities-mode)
  :config
  (setq org-fancy-priorities-list '("โšก" "โฌ†" "โฌ‡" "โ˜•")))

(use-package org
  :mode ("\\.org$" . org-mode)
  :demand t
  :init
  (setq org-agenda-files '("~/tmp/6.org"))
)

  1. M-x eval-buffer
  2. M-x org-agenda "t"

The priority is still shown as [#A]. Note, that everything is fine if #+SETUPFILE is not there. The recepie also works when setup file is not empty (my real case).

org-fancy-tags?

Hello thanks for this awesome package. Have you thought about making something like
org-fancy-tags? Perhaps you can point me in the right direction. I know you can use org-tag-faces but I haven't figured out yet how to add emojis yet.

I'm looking to replace my tags with emojis, not sure if something already exists. I'm sure
I could tweak the code some but I read text properties were less taxing than overlays?

(defun my/org-fancy-tags ()
  "Description"
  (interactive)
  (save-excursion
    (let (ol)
      (while (re-search-forward ".*:\\(someday\\):" nil t)
	(setq ol (make-overlay (match-beginning 1) (- (match-end 1) 1)))
  ;;(message "...%s" (match-string 2))
	(overlay-put ol 'display (org-fancy-priorities-get-value "โ˜•"))
	(push ol org-fancy-priorities-overlay-list)))))
(my/org-fancy-tags)

The org file:

* Emacs Package           :org:someday:

Create an emacs package as awesome as org-fancy-priorities.

The output:

Emacs Package ๐Ÿฆ„ โ˜•

Create an emacs package as awesome as org-fancy-priorities.

Messed up Shift+Up/Down in agenda

Shiift+Up/Down in agenda cycles the priorities. The typical displayed priority display once you try cycling is, for example, โฌ†Cโฌ†. This is obviously not right.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.