summaryrefslogtreecommitdiffstats
path: root/macosx
diff options
context:
space:
mode:
authorDamiano Galassi <[email protected]>2018-06-07 14:28:07 +0200
committerDamiano Galassi <[email protected]>2018-06-07 14:28:07 +0200
commit86997ab85d5e967d3afb858d84d86d3d5886afe3 (patch)
tree7d1d6e59059ac2756674d9325630ff65cc52291b /macosx
parentd74a67e6ec258cb4c821908cd8e669dc61fac3de (diff)
MaGui: fix activity text color in dark mode.
Diffstat (limited to 'macosx')
-rw-r--r--macosx/HBOutputPanelController.m7
1 files changed, 6 insertions, 1 deletions
diff --git a/macosx/HBOutputPanelController.m b/macosx/HBOutputPanelController.m
index 4b09f3cc4..1150e1939 100644
--- a/macosx/HBOutputPanelController.m
+++ b/macosx/HBOutputPanelController.m
@@ -29,6 +29,8 @@
/// Path to log text file.
@property (nonatomic, copy, readonly) HBOutputFileWriter *outputFile;
+@property (nonatomic, readonly) NSDictionary *textAttributes;
+
@end
@implementation HBOutputPanelController
@@ -64,6 +66,9 @@
[[textView enclosingScrollView] setLineScroll:10];
[[textView enclosingScrollView] setPageScroll:20];
+ // Text attributes
+ _textAttributes = @{NSForegroundColorAttributeName: [NSColor textColor]};
+
// Add ourself as stderr/stdout listener
[[HBOutputRedirect stderrRedirect] addListener:self];
[[HBOutputRedirect stdoutRedirect] addListener:self];
@@ -100,7 +105,7 @@
*/
- (void)stderrRedirect:(NSString *)text
{
- NSAttributedString *attributedString = [[NSAttributedString alloc] initWithString:text];
+ NSAttributedString *attributedString = [[NSAttributedString alloc] initWithString:text attributes:_textAttributes];
/* Actually write the libhb output to the text view (outputTextStorage) */
[outputTextStorage appendAttributedString:attributedString];