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

Autocomplete popup position #21

Open
bogdancss opened this issue Feb 27, 2020 · 2 comments
Open

Autocomplete popup position #21

bogdancss opened this issue Feb 27, 2020 · 2 comments

Comments

@bogdancss
Copy link

For a while now, the Autocomplete popup has been misaligned:

Screenshot 2020-02-27 at 16 06 18

I tested this on a fresh install of Atom only with this syntax theme installed.

@bogdancss
Copy link
Author

bogdancss commented Feb 27, 2020

I uninstalled the theme and copied over the theme styles over to the local styles.less file. By commenting out the lines that handle the filter, seems to prevent the autocomplete popup from being misaligned:

Screenshot 2020-02-27 at 16 32 21

Screenshot 2020-02-27 at 16 34 19

But now the glow is gone ☹️

@ochen1
Copy link

ochen1 commented Jul 30, 2020

Hey, I was looking for a solution to this too, and I found out that the following code worked.

Replace the lines at the top of base.less with:

atom-text-editor span {
  -webkit-filter: contrast(@contrast);
  -webkit-filter: saturate(@saturation);
}

atom-text-editor {
  background-color: @syntax-background-color;
  color: @syntax-text-color;

  .invisible-character {
    color: @syntax-invisible-character-color;
  }

  .indent-guide {
    color: @syntax-indent-guide-color;
  }

  .wrap-guide {
    color: @syntax-wrap-guide-color;
  }

  .gutter {
    background-color: @syntax-gutter-background-color;
    color: @syntax-gutter-text-color;

    .line-number {
      &.cursor-line {
        background-color: @syntax-gutter-background-color-selected;
        color: @syntax-gutter-text-color-selected;
      }

      &.cursor-line-no-selection {
        color: @syntax-gutter-text-color-selected;
      }
    }
  }

  .search-results .syntax--marker .region {
    background-color: transparent;
    border: @syntax-result-marker-color;
  }

  .search-results .syntax--marker.current-result .region {
    border: @syntax-result-marker-color-selected;
  }
}

The problem was probably the filter being applied to everything inside of the editor, when it only needs to be applied to the main text content inside the editor.

However, you may experience some performance issues, because it is applying the filter to more elements now.

This is a quick hack to temporarily resolve the issue.

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

No branches or pull requests

2 participants