Skip to content

fix: Do not skip invisible headings when getting node at point.#1798

Merged
jethrokuan merged 1 commit intoorg-roam:masterfrom
aragaer:master
Aug 21, 2021
Merged

fix: Do not skip invisible headings when getting node at point.#1798
jethrokuan merged 1 commit intoorg-roam:masterfrom
aragaer:master

Conversation

@aragaer
Copy link
Copy Markdown
Contributor

@aragaer aragaer commented Aug 21, 2021

Motivation for this change

I'm using org-roam-node-at-point to fetch the title of the node when building the agenda. Not all my agenda-items are roam-nodes themself and I want to have access to the title of the parent node. However depending on whether the heading tree is visible or collapsed I'm getting different result. Turns out it's just a matter of org-back-to-heading-or-point-min which needed invisible-ok argument.

Example of the file that show different results depending on visibility

:PROPERTIES:
:ID:       dfe77ff7-7e27-4fdd-ad7c-ffd6aadc87bd
:END:
#+title: org-roam
#+startup: overview

* test
** inner
:PROPERTIES:
:ID:       4ced70aa-7b8c-41f0-b43e-3554dbbeeb10
:END:
*** item
SCHEDULED: <2021-08-21 Sat>

The result is either "inner" or "org-roam" depending on visibility.

Comment thread CHANGELOG.md Outdated
Comment thread org-roam-node.el
Copy link
Copy Markdown
Member

@jethrokuan jethrokuan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks :)

@jethrokuan jethrokuan merged commit 04b7780 into org-roam:master Aug 21, 2021
@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Jun 7, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants