Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Show number of items in group headings #260

Open
rytswd opened this issue May 30, 2024 · 2 comments
Open

Show number of items in group headings #260

rytswd opened this issue May 30, 2024 · 2 comments

Comments

@rytswd
Copy link

rytswd commented May 30, 2024

I checked into the code but couldn't figure out how I would go about showing a number of items in the group (e.g. "Important [42]" as header instead of just "Important"). I originally thought I may be able to use org-super-agenda-header-prefix, but didn't see a way to compute the item count as prefix. Perhaps it would be better if it can be a computed suffix, which could be turned on with an extra config?

@alphapapa
Copy link
Owner

That isn't implemented. It could be, but I'd rather put my time toward fixing up this branch which would offer a similar feature by using magit-section: alphapapa/org-ql#331

However, I'm not against this idea here, either, so patches are welcome.

@alphapapa alphapapa added this to the Future milestone May 31, 2024
@alphapapa alphapapa changed the title Is there a way to show count for each group? Show number of items in group headings May 31, 2024
@rytswd
Copy link
Author

rytswd commented Jun 2, 2024

I took a quick stab at this, and could make it work for my basic needs. The change is around the org-super-agenda--make-agenda-header function to take in the items list, and append the item length to the header. However, this adds extra header on timegrid as well, leading to meaningless count for that.

Although I'm pretty sure the implementation here is quite crude, I could send a PR if you would be able to check it out at some point 🙏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants