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

"SS20" (splashtidy) does not work in general cases #197

Open
singularitti opened this issue Dec 28, 2023 · 5 comments
Open

"SS20" (splashtidy) does not work in general cases #197

singularitti opened this issue Dec 28, 2023 · 5 comments
Labels
enhancement may be implemented as an enhancement

Comments

@singularitti
Copy link

I tried to turn feature code "SS20" (splashtidy) on in VSCode with JuliaMono, but in general it does not work for a lot of cases:

__init__()
__()__
(_)(__)(___)
@groupby(_.a) |>
@map({a = key(_), b = mean(_.b)}) |>
image

As you can see, for functions like __init__(), and for code with more than one _ in () or (_.x), it will break.

I suppose a possible fix would be: whenever there is one or more _ next to a ( or a ), _ should be pulled down a little and ( or ) will be stretched.

@cormullion
Copy link
Owner

Hi! Yes, it was a quick hack to get the Julia start-up banner to look a bit tidier (think t-shirts 😀) and it would be ideal if we could switch SS20 off automatically once the banner had been displayed... I have thought about removing SS20 - but perhaps it's fixable with some more effort on my part.

@cormullion cormullion added the enhancement may be implemented as an enhancement label Dec 28, 2023
@singularitti
Copy link
Author

I think at least (_.a) should be a quick fix. Perhaps only allow (_) working.

@cormullion
Copy link
Owner

I had another look at this; there are some technical problems that stop me from doing the job properly: I can't find patterns that span the ANSI color escapes, and I can't use space as part of the search pattern. Not to mention that the stylistic sets aren't supported in every application...

So I've ended up with just (_) and a few continuous runs of glyphs that can be tweaked:

In Wezterm:

Screenshot 2024-01-06 at 10 27 39

In VSCode Editor:

Screenshot 2024-01-06 at 10 40 05

@singularitti
Copy link
Author

singularitti commented Jan 8, 2024

Why not just pull down all _ when turning on SS20? I know Iosevka does this with "cv99"=3.

@cormullion
Copy link
Owner

current master:

Screenshot 2024-01-08 at 15 57 33

your "why not...""

Screenshot 2024-01-08 at 15 57 03

I don't really mind either way...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement may be implemented as an enhancement
Projects
None yet
Development

No branches or pull requests

2 participants