[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH] Improve org-mouse support for checkboxes

From: Jim Porter
Subject: [PATCH] Improve org-mouse support for checkboxes
Date: Sat, 18 Sep 2021 12:38:29 -0700

While trying out `org-mouse', I noticed two semi-related issues with checkboxes. First, intermediate-state checkboxes (like [-]) aren't clickable. Second, if the checkboxes are inside a block and the theme gives the block a background color, the block's background is removed behind the checkbox. To see both of these in action:

  $ cat file.org
  * Regular
  - [X] Checked.
  - [-] Half-checked.
  - [ ] Not checked.
  * In block
  #+begin_src org
  - [X] Checked.
  - [-] Half-checked.
  - [ ] Not checked.

$ emacs -Q --eval '(progn (setq org-modules '"'"'(org-mouse)) (custom-set-faces '"'"'(org-block ((t :background "green")))))' file.org

The attached patch fixes both of these issues. For the first problem, maybe it would be useful to put the regexp for checkboxes in a variable somewhere so it doesn't get out of sync. I wasn't sure though, so I went with the simpler solution for now.

My FSF copyright assignment should be on file, but let me know if there are any issues there.

Attachment: 0001-org-mouse-Support-intermediate-state-checkboxes.patch
Description: Text document

reply via email to

[Prev in Thread] Current Thread [Next in Thread]