[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#38485: Customizing glyph widths
From: |
Clément Pit-Claudel |
Subject: |
bug#38485: Customizing glyph widths |
Date: |
Wed, 4 Dec 2019 11:57:12 -0500 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.2.1 |
On 2019-12-04 10:52, Eli Zaretskii wrote:
>
>> Now that I think of it, though, I could see the use for a text property.
>> For example, prettify-symbols-mode could have an option to make each
>> n-characters prettification n-characters wide, so that composing ~~> into ⟿
>> would produce a wide arrow occupying the exact same amount of space as the
>> original uncomposed characters.
>
> So what kind of text property would that be, and where and how will it
> come into play in the above scenario?
I'm thinking something like `:display-width 3' or maybe `display-width "~~>"'
(the former would mean "as wide as three spaces in the default font"; the
later, "as wide as `~~>' in the default font").
These properties would be applied by prettify-symbols-mode in addition to
composition.
An interesting related feature is the ability to move the cursor inside
composed characters. For example, when composing -> into →, assuming a font
such as Fira code with a two-characters wide → symbol, it would be nice to be
able to position the point in the middle of the composed symbol. I often have
this problem in Emacs with ||; I compose it into ‖, but I sometimes want to
type |a|, and in those cases I tend to type || then press left and type a, but
this doesn't work when || has been composed into ‖.
Other editors have this feature, but I'm not sure how they handle the
distinction between a composition that shouldn't be "separable" (such as é = e
+ ') and one that should be (such as ↝ = ~ + >).
Clément.
- bug#38485: Customizing glyph widths, Clément Pit-Claudel, 2019/12/03
- bug#38485: Customizing glyph widths, Eli Zaretskii, 2019/12/04
- bug#38485: Customizing glyph widths,
Clément Pit-Claudel <=
- bug#38485: Customizing glyph widths, Eli Zaretskii, 2019/12/04
- bug#38485: Customizing glyph widths, Clément Pit-Claudel, 2019/12/04
- bug#38485: Customizing glyph widths, Eli Zaretskii, 2019/12/04
- bug#38485: Customizing glyph widths, Clément Pit-Claudel, 2019/12/04
- bug#38485: Customizing glyph widths, Eli Zaretskii, 2019/12/04
- bug#38485: Customizing glyph widths, Clément Pit-Claudel, 2019/12/05
- bug#38485: Customizing glyph widths, Eli Zaretskii, 2019/12/05
- bug#38485: Customizing glyph widths, Clément Pit-Claudel, 2019/12/05
- bug#38485: Customizing glyph widths, Eli Zaretskii, 2019/12/05
- bug#38485: Customizing glyph widths, Clément Pit-Claudel, 2019/12/05