mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-06-01 11:41:56 +00:00
Merge 1750a1ed8c
into 43feefce68
This commit is contained in:
commit
a9bf2ddbc1
2 changed files with 15 additions and 0 deletions
|
@ -783,6 +783,15 @@ APPKIT_EXPORT_CLASS
|
||||||
*/
|
*/
|
||||||
- (NSString*) license;
|
- (NSString*) license;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns YES if in dark mode, or NO, if not. The reasoning behind this
|
||||||
|
* is that some applications may display on the screen in dark mode, but
|
||||||
|
* print with the colors reversed. This method allows GUI and the backend
|
||||||
|
* to understand when we are using a dark theme and render accordingly when
|
||||||
|
* printing. The default is NO, as the default theme is not a dark theme.
|
||||||
|
*/
|
||||||
|
- (BOOL) isDarkMode;
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -1339,6 +1339,12 @@ typedef struct {
|
||||||
return [[self infoDictionary] objectForKey: @"GSThemeLicense"];
|
return [[self infoDictionary] objectForKey: @"GSThemeLicense"];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
- (BOOL) isDarkMode
|
||||||
|
{
|
||||||
|
return [[[self infoDictionary] objectForKey: @"GSThemeDarkMode"]
|
||||||
|
isEqualToString: @"YES"];
|
||||||
|
}
|
||||||
|
|
||||||
@end
|
@end
|
||||||
|
|
||||||
@implementation GSTheme (Private)
|
@implementation GSTheme (Private)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue