I have a simple status bar app using NSPopover that I'd like to support Mojave Dark Mode. If I use the recommended semantic colors it looks fine in most cases light and dark, unless there's a bright window behind it, in which case the window transparency makes everything look washed out and the one image looks horrible. It looks great if I turn on the system prefs "Reduce transparency". Is there any way to get the no-transparency mode on a per-view basis? I've looked at the vibrancy and alphaValue properties with no success.
I know I can use hard-coded colors for everything and detect dark mode programmatically, but that's exactly the design I'm trying to get away from in switching to semantic colors. I suspect if you're going with the OS theme then you take what you get, I just don't like the OS's choice in this case.
Related
Here's a recurring problem I've had.
I love using a dark theme for my Windows 7 computer. Unfortunately, the only way to get a really dark theme is by choosing the "High Contrast Black" color style, even though I don't really want high contrast, just darkness.
My theme works great, except that once in a while, there's an app that shows terrible colors because of it. Chrome is one example. I managed to fight that off using the Forced Colors setting, but that setting may be removed in the future, and then I'll be in a big problem.
I'm guessing that each app has some kind of API to ask the operating system about the theme colors. Is there any way to intercept that call and change the data, so specific apps will think that I'm on a non-high contrast theme?
Other ideas and solutions would also be interesting to hear.
While developing a menubar app, I am having a hard time finding the preferred method for making the app actually look good. I would have thought that Apple controls would have essentially handled this for the most part, but it appears not.
What is the preferred method for making sure a menubar app looks good in both light and dark mode? Am I missing some control functionality that facilitates this more easily or do I need to manually detect the mode and modify controls appropriately?
I have a menubar app, and I didn't have to do anything to make it look good in the dark theme.
Light theme:
Dark theme:
The most important things you need to do are:
Use system colors (e.g., [NSColor textColor], [NSColor textBackgroundColor]. These automatically adapt with the various themes. See the Color and Typography section of Apple's OS X Human Interface Guidelines.
Use template images. These also adapt to color changes. See the System-Provided Images section of Apple's OS X Human Interface Guidelines.
It's worth noting that Apple has not made it easy to programmatically detect which color theme is running (there are some tricks, but I'm not aware of any sanctioned method). My sense is that they've done this intentionally, so developers don't do custom per-theme stuff. Using system colors and template images, you shouldn't have to.
Update:
Sample project here: https://github.com/zpasternack/MenuBarTest
Well, you haven't explain (or shown) in what way it looks bad. Probably, you are using a normal, non-template image for its icon. You should use a template image, which is an image whose only significant part is the alpha mask. You tell the system that it's a template image either by naming it with a "Template" suffix (e.g. "FooTemplate.png") or by calling -setTemplate: on it.
Surely, this is documented somewhere. I for some reason or another cannot find the answer for this.
Most people are wanting to make their terminals completely transparent, I however want the effects where you see the desktop background. I am certain that this is default for gnome. What is this effect called and How can I get this in XFCE?
I was told that installing something like Terminator would resolve this but its just the true transparency which looks messy with a ton of windows and stuff going on.
Here is an example of what I am wanting for XFCE.
http://i.imgur.com/zy1EBdS.png
Thanks in advance !
The simple way could be opening your xfce4-terminal and going to Edit->Preferences->Appearance->Background and then chose a Background image to show instead of a Solid Color or Transparent. In example.
In the Xubuntu version that I have solved this issue accidentally. I had to go to manage settings menu -> Window Manager Tweaks -> Compositor(tab)
and uncheck Enable Display Compositing
Now I can have the terminal just show the desktop background instead of every thing that is messy behind it.
I am hoping some of you css wizards might have run into the problem I'm about to describe.
I've created css3 buttons for a clients website, in order to replace their current image buttons. The buttons happen to be a light font face on a dark value background (white text on a red background).
On OSX and iOS, the quartz rendering engine kind of freaks out about this, and anti-aliases the font to death. Bold become really really really bold.
The strange thing is, I develop on a Mac, and cannot replicate the rendering problem the client is having across multiple devices. I've made sure I only have system fonts enabled, that my font smoothing is set the same, etc...
I found an article that suggested a fix for webkit based browsers here, and have seperated the text from it's background in order to give just the text an opacity value.
Still, no dice. Anyone have idea what could be the problem here?
Sample image:
I've encountered bolding issues with web fonts on webkit based browsers. I used the following CSS property to remedy it:
-webkit-font-smoothing: antialiased;
Seems like a better solution than messing with opacity to fix font weights... which really just feels like a hack.
I have read the UI Design Guidelines for WP7 development and am actually a fan of Metro (to a point). However, an app I am developing is requiring custom theming regardless of the user's theme settings.
In general, I just manually set each element that I want to be sure uses a specific color (rather than a theme resource). But I can't seem to find settings regarding the system tray (status bar).
I am okay with it showing as long as I can change it's color (failing that though, how can I hide it?). The color I need it to always be is black. Obviously when the dark theme is selected, we are good to go. But it looks terrible in the light theme to have a big white bar at the top of the app.
Hopefully this is an easy question with some easy to earn rep!
It is possible to change that color in mango. SystemTray.BackgroundColor = Colors.Orange; In my case it must be inserted in OnNavidatedTo, in constructor it disappeared after 1 second.
If you want to set this in the xaml you can do something like this:
shell:SystemTray.IsVisible="True"
shell:SystemTray.Opacity="0"
shell:SystemTray.ForegroundColor="Black"
I am not aware of a way to change the theme of the system tray (or status bar). You can hide it using the SystemTray.IsVisible property.
Note that I've had trouble trying to set that property within the page constructor (I think it fails when resuming after tombstoning, don't remember exactly). The solution was to place the code in the page's Loaded or OnNavigatedTo event.