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

Caret color being fixed to black when using webstorm #44

Closed
gyeoul opened this issue Feb 23, 2024 · 2 comments
Closed

Caret color being fixed to black when using webstorm #44

gyeoul opened this issue Feb 23, 2024 · 2 comments
Assignees
Labels
bug Something isn't working
Milestone

Comments

@gyeoul
Copy link

gyeoul commented Feb 23, 2024

Color scheme I use changes the color of the caret to #FFFFFF, but the color changes to #000000 immediately after exiting the settings window.

Following part of the services/CursorColorService.kt file is expected to cause the problem:

private val originalCursorColor: Color = EditorColorsManager.getInstance()
         .globalScheme
         .getColor(EditorColors.CARET_COLOR)
         ?: JBColor.BLACK
@gyeoul
Copy link
Author

gyeoul commented Feb 23, 2024

Sometimes deactivating & activating plugin it solves the problem, but sometimes error occurs.
Additional error logs:

java.lang.Throwable: An editable copy of Default has not been initialized.
	at com.intellij.openapi.diagnostic.Logger.error(Logger.java:376)
	at com.intellij.openapi.editor.colors.impl.EditorColorsManagerImpl.getDefaultScheme(EditorColorsManagerImpl.kt:369)
	at com.intellij.openapi.editor.colors.impl.EditorColorsManagerImpl.getGlobalScheme(EditorColorsManagerImpl.kt:361)
	at com.github.lauvsong.langcursor.utils.CursorColorUtil.setGlobalCursorColor(CursorColorUtil.kt:10)
	at com.github.lauvsong.langcursor.services.CursorColorService.toOriginalCursorColor(CursorColorService.kt:23)
	at com.github.lauvsong.langcursor.services.LanguageCheckService.switchCursorColorByLanguage(LanguageCheckService.kt:36)
	at com.github.lauvsong.langcursor.services.LanguageCheckService.start$lambda$0(LanguageCheckService.kt:23)
	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539)
	at java.base/java.util.concurrent.FutureTask.runAndReset(FutureTask.java:305)
	at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:305)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
	at java.base/java.lang.Thread.run(Thread.java:840)

@lauvsong lauvsong self-assigned this Feb 25, 2024
@lauvsong lauvsong added the bug Something isn't working label Feb 25, 2024
@lauvsong lauvsong added this to the 2.0.0 milestone Feb 25, 2024
@lauvsong
Copy link
Owner

Thank you for your report!! It will be fixed in version 2.0.0.

  • Removed dependency on originalCursorColor.
  • Added color settings for English status.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants