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

change colours for Dark Mode #39

Open
sweetppro opened this issue Apr 14, 2019 · 4 comments
Open

change colours for Dark Mode #39

sweetppro opened this issue Apr 14, 2019 · 4 comments

Comments

@sweetppro
Copy link

sweetppro commented Apr 14, 2019

how can I completely redraw the switch to update the _disabledBorderColor?
I tried overriding, and updating the _disabledBorderColor in:
- (void) setNeedsDisplay:(BOOL)needsDisplay

and while, the method is called when Dark Mode is enabled/disabled - the _disabledBorderColor in the switch does not change

@iluuu1994
Copy link
Owner

This project doesn't support dark mode. I don't develop for MacOS anymore. I will accept PRs though.

@sweetppro
Copy link
Author

its seems to not work with the color I have chosen: disabledControlTextColor. controlAccentColor works just fine like this:

- (void) setNeedsDisplay:(BOOL)needsDisplay
{
    [super setNeedsDisplay:needsDisplay];    
    [self setUpLayers];
}

@iluuu1994
Copy link
Owner

There is no property called disabledControlTextColor. Not every color in this project is configurable. Sorry, you're on your own.

@sweetppro
Copy link
Author

ah, thats an NSColor.
I managed to get it working how I like using this fork:
https://github.com/Tibbs/ITSwitch

and adding this for immediate updating when Dark Mode is activated/deactivated:

- (void) setNeedsDisplay:(BOOL)needsDisplay
{
    [super setNeedsDisplay:needsDisplay];
    [self setUpLayers];
}

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