Open mikesmithgh opened 1 year ago
I looked into this a bit more, this functionality does work but the issue is that all ligatures aren't implemented with calt. For example, :=
<$>
</>
--
work as expected. So this feature request is an ask to implement all ligatures with calt.
There is no standard for which characters belong to calt
and it's up to each typeface author to decide which go in.
Can you provide an exhaustive list of the missing combinations?
Note that on MonoLisa only spacing altering combinations are behind calt
. The rest of the ligatures are behind liga
so may have to enable that set separately in your terminal to access them all.
Hi @bebraw thank you for the quick reply. I now have a new found respect for fonts 😄 . I looked into FiraCode a bit and ended up forking the repo to provide a list of the ligatures which belong to calt. The documentation and video demo is here: https://github.com/mikesmithgh/FiraCode/blob/calt-test/calt-test/README.md. I have the files attached with the characters for the ligatures and calts in the forked repo. But, I'll provide the list below as well.
[w w w] w w w www
[hyphen hyphen] - - --
[hyphen asciitilde] - ~ -~
[braceleft bar] { | {|
[bracketleft bar] [ | [|
[bracketright numbersign] ] # ]#
[period period] . . ..
[period period period] . . . ...
[period period equal] . . = ..=
[period period less] . . < ..<
[period question] . ? .?
[colon colon] : : ::
[colon colon colon] : : : :::
[colon colon equal] : : = ::=
[colon equal] : = :=
[semicolon semicolon] ; ; ;;
[exclam exclam] ! ! !!
[exclam exclam period] ! ! . !!.
[exclam equal] ! = !=
[exclam equal equal] ! = = !==
[question period] ? . ?.
[question question] ? ? ??
[question equal] ? = ?=
[asterisk asterisk] * * **
[asterisk asterisk asterisk] * * * ***
[asterisk greater] * > *>
[asterisk slash] * / */
[numbersign parenleft] # ( #(
[numbersign braceleft] # { #{
[numbersign bracketleft] # [ #[
[numbersign colon] # : #:
[numbersign exclam] # ! #!
[numbersign question] # ? #?
[numbersign equal] # = #=
[numbersign underscore] # _ #_
[numbersign underscore parenleft] # _ ( #_(
[slash asterisk] / * /*
[slash greater] / > />
[slash slash] / / //
[slash slash slash] / / / ///
[slash backslash] / \ /\
[backslash slash] \ / \/
[ampersand ampersand] & & &&
[bar braceright] | } |}
[bar bracketright] | ] |]
[bar bar] | | ||
[bar bar bar] | | | |||
[bar bar bar greater] | | | > |||>
[bar bar greater] | | > ||>
[bar greater] | > |>
[dollar greater] $ > $>
[plus plus] + + ++
[plus plus plus] + + + +++
[plus greater] + > +>
[equal equal] = = ==
[equal equal equal] = = = ===
[greater equal] > = >=
[greater greater] > > >>
[greater greater greater] > > > >>>
[less exclam hyphen hyphen] < ! - - <!--
[less asterisk] < * <*
[less asterisk greater] < * > <*>
[less bar] < | <|
[less bar bar] < | | <||
[less bar bar bar] < | | | <|||
[less bar greater] < | > <|>
[less dollar] < $ <$
[less dollar greater] < $ > <$>
[less plus] < + <+
[less plus greater] < + > <+>
[less equal] < = <=
[less greater] < > <>
[less less] < < <<
[less less less] < < < <<<
[less asciitilde] < ~ <~
[less asciitilde greater] < ~ > <~>
[less asciitilde asciitilde] < ~ ~ <~~
[less slash] < / </
[less slash greater] < / > </>
[asciitilde hyphen] ~ - ~-
[asciitilde at] ~ @ ~@
[asciitilde greater] ~ > ~>
[asciitilde asciitilde] ~ ~ ~~
[asciitilde asciitilde greater] ~ ~ > ~~>
[asciicircum equal] ^ = ^=
[percent percent] % % %%
Please let me know if you need any additional information or if I can help in anyway.
We had a quick chat about this. A couple of notes:
liga
to calt
as this would help with targets like MacOS Terminal.Great, thank you!
I'd like to request that "all ligatures are turned on when calt
is on" not be the default.
I juggle both MonoLisa and Monaspace Neon in my Visual Studio config, and the editor picks the first one in the list:
"editor.fontFamily": "MonoLisa, 'Monaspace Neon', …, monospace",
For ligature settings, I settled on
"editor.fontLigatures": "'calt' on, 'liga' off",
This turns on the texture healing provided by Monaspace's calt
, but keeps MonaLisa's ligatures that turn !=
into something that looks more like â‰
off, a feature I've tried and disliked strongly.
If these ligatures were dumped into the calt
feature, then I'd either have to put up with confusing ligatures in MonoLisa or the lack of texture healing in Monaspace, depending on what font I have available.
What feature are you proposing?
Kitty has a feature to disable ligatures only when the cursor is over them. (See https://sw.kovidgoyal.net/kitty/conf/#opt-kitty.disable_ligatures)
I have MonaLisa - Plus installed on OSX and I am using Kitty with the following setting:
When I put my cursor over a ligature, it does not disable it and display the regular characters.
I have tested this with
FiraCode Nerd Font Mono
and it works.FiraCode Nerd Font Mono
:MonaLisa
: