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

Multi-line error message when validating regex in search #130

Open
fedejeanne opened this issue Oct 14, 2024 · 3 comments
Open

Multi-line error message when validating regex in search #130

fedejeanne opened this issue Oct 14, 2024 · 3 comments
Assignees
Labels
Enhancement A Request for an Enhancement of an Existing Feature Platform UI Issue for Platform UI Student An Issue to be Addressed By a Student

Comments

@fedejeanne
Copy link

Problem

Some important information is lost when the error message of the regex validation of the search is done, namely the offending character.

After applying eclipse-platform/eclipse.platform.ui#2373, the error message will look like this:

Image

...when it could look more like this:

Image

In the screenshot, you can see that the ^ is off: it should be right under the [

Goal

  1. Show the multi-line error like the one in the last screenshot but place the ^ correctly.

  2. In other multi-line error messages where the extra line does not add any value, the error message should have only 1 line.

Image

This can be easily spotted by the fact that there is no ^ in the error message.

@fedejeanne fedejeanne added Platform UI Issue for Platform UI Enhancement A Request for an Enhancement of an Existing Feature Student An Issue to be Addressed By a Student labels Oct 14, 2024
@jannisCode jannisCode self-assigned this Oct 14, 2024
@jannisCode
Copy link

it is very hard to get the position of ^ right, because the " " is smaller (les wide) than some characters. If you type a lot of i´s for example you need a different amount of spaces compared to a lot of a´s. Based on that and how often the letters of the alphabet are used on average, I found out that it is "most accurate" to always add two spaces (" " compared to " ") and for every third character only one space.
This is obviously not a good solution, which is why I want to propose the following: Instead of putting the arrow in the line below, why don´t we put it in the respective line like so:
image
image
This ensures that the arrow always points on the right character.

Until now i did not find a solution for the arrow in the line below. If there is anything i can try, i am very open to suggestions on how i could implement it.

@jannisCode
Copy link

jannisCode commented Oct 15, 2024

I now have a solution for the initial goal with the "^" character, which is a little bit more extensive than the "<--" solution, but i believe the output is much better with this "^" .
How can i get the github branch in this issue?

@fedejeanne
Copy link
Author

How can i get the github branch in this issue?

You need to create an "official" issue in the official repo. This discussion (#130 (comment)) should take place there and not here in vi-eclipse :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement A Request for an Enhancement of an Existing Feature Platform UI Issue for Platform UI Student An Issue to be Addressed By a Student
Projects
Status: 👀 In Review
Development

No branches or pull requests

2 participants