I got a super useful snippet from org-hacks: http://orgmode.org/worg/org-hacks.html#unnumbered-66, which can automatically adjust the position of tags to right of the headline and make org-mode looks cleaner.

But since these days, I start to use visual-line-mode, an uncomfortable looks problems appeared. On the folded headline, the tags are wrapped strangely to below the headline, like wrapped to a new line. However, when I unfold the headline, the tags go to the right position, of course, the rightest of the headline. So what is the problem? Since the tags can move according to the windows size, why it can not go well when headline is folded?

  • I don't have an answer to your question, but I'll let you know what I do. I have tags with no alignment -- my title ends with a period, and one space to the right begins the tags. My org-mode buffer has truncated lines -- i.e., (setq truncate-lines t). When I hit a favorite keyboard shortcut, I create what's called an indirect buffer -- I narrow to subtree and then have the entry only in visual-line-mode with some extra stuff going on and a minor mode called org-edit-mode. I do my edits and then press C-c C-c when I'm done and go back to the main buffer (with an auto-reorganize). – lawlist Jan 29 '15 at 9:30
  • 1
    On a side-note, right alignment of tags will naturally conflict with visual-line-mode -- the two are not compatible, and I don't see how they could possibly be made to play nice together. However, there are some really creative geniuses that visit these forums -- so perhaps there will be a creative innovation . . . – lawlist Jan 29 '15 at 9:37
  • @lawlist thanks for your comments. Yes, I always narrow subtree to avoid seeing wrapped tags or codes. But every time I need to hit some keys, which is annoying, I am a very lazy man, so if there is some solution, I would rather do nothing. Sometimes I just want them not to disturb my working process. – Leu_Grady Jan 29 '15 at 9:41
  • @lawlist it is a stubborn problem, so I am afraid if there will be a suitable answer. Maybe someone like you could share a good habit for operating these problems, that is my purpose of this question. Thanks for helping me. – Leu_Grady Jan 29 '15 at 9:49
  • 1
    @user3173715 The tags auto align to the right for me without using any custom code. Just make sure that you use the org default binding C-c C-q for creating the tags. Do NOT manually type :SOMETAG: after the headings. – Kaushal Modi Jan 29 '15 at 11:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.