From: Samuel Wales <email@example.com>
To: Jeff Filipovits <firstname.lastname@example.org>
Cc: Protesilaos Stavrou <email@example.com>,
firstname.lastname@example.org, Eric S Fraga <email@example.com>
Subject: Re: variable-pitch-mode misaligns org-mode heading tags
Date: Wed, 16 Sep 2020 14:14:24 -0700 [thread overview]
Message-ID: <CAJcAo8tY4y5Jrue9KFcsq8GOb0KV8eh0GUZYcJ+DHGoZVGSWxw@mail.gmail.com> (raw)
can emacs supply tools that would be useful?
On 9/16/20, Jeff Filipovits <firstname.lastname@example.org> wrote:
> Thanks. You are right of course and I realized the right-align
> issue right after I sent my email.
> Adam Spiers <email@example.com> writes:
>> But the whole point of this exercise is to support
>> fonts. In this case, the correct position for the end of the
>> space is most likely not even a multiple of the fixed column
>> width, so
>> it would probably need to be measured in pixels rather than
>> columns. And in order to calculate it, it is first necessary to
>> calculate the exact width in pixels of the colon-delimited list
>> tags. As I mentioned in the comment linked above, I searched for
>> a way
>> of calculating the pixel width of the tag list, and the best I
>> find was `pos-visible-in-window-p' which has some issues which I
>> mentioned there. If you have thoughts on whether I'm right
>> those, and if so how to solve them, I'd love to hear! Cheers,
> It looks like (window-text-pixel-size) could be used to calculate
> the pixel length of the tags list? I am having trouble deciphering
> the manual
> for pixel specification for spaces, though. The right alignment
> specification for some reason sends the tags to the next line, as
> do most other solutions that I would expect to align the text to
> the right side of the window.
> I can experiment more in a couple days, but in the meantime maybe
> someone smarter than me give some hints on how to use the pixel
> specification properties.
>> BTW I tried your code and for some reason it didn't insert any
>> for me, but I didn't look into that yet.
> The way it’s written it would only reduce the gap between the
> headline and tags to a space, and it assumes there are multiple
> spaces there already. If there’s no space between the two, I don’t
> think it’ll insert one. Probably not the best way as it was thrown
> together to test the text property fix.
> I accepted long ago that the solution to using a variable pitch
> font for org headings was that the tags would not be aligned to
> the right and never looked back, so maybe this is not worth the
> price of fixing it if it is messy. And diving down to calculating
> the pixel width of text seems like it’s getting pretty messy.
> Jeff Filipovits
> Spears & Filipovits, LLC
> 1126 Ponce de Leon Avenue
> Atlanta, GA 30306
> 678.237.9302 (direct)
> All emails confidential to the fullest extent of the law.
The Kafka Pandemic
Please learn what misopathy is.
next prev parent reply other threads:[~2020-09-16 21:15 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-08 19:31 variable-pitch-mode misaligns org-mode heading tags Protesilaos Stavrou
2020-09-09 8:44 ` Bastien
2020-09-09 11:03 ` Eric S Fraga
2020-09-09 14:39 ` Bastien
2020-09-15 17:41 ` Jeff Filipovits
2020-09-16 16:21 ` Adam Spiers
2020-09-16 19:03 ` Jeff Filipovits
2020-09-16 21:14 ` Samuel Wales [this message]
2020-09-16 22:55 ` Adam Spiers
2020-09-17 0:18 ` Adam Spiers
2020-09-17 2:03 ` Jeff Filipovits
2020-09-17 15:36 ` Jeff Filipovits
2020-09-18 12:49 ` Ihor Radchenko
2021-04-27 19:41 ` Bastien
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).