 	}
 
 	public override func observeValue(forKeyPath keyPath: String?, of object: Any?, change: [NSKeyValueChangeKey : Any]?, context: UnsafeMutableRawPointer?) {
-		CNExecuteInMainThread(doSync: false, execute: { [self]
+		DispatchQueue.main.async {
 			() -> Void in
 			if let key = keyPath, let vals = change {
 				if let _ = vals[.newKey] as? Dictionary<CNInterfaceStyle, CNColor> {

					}
				}
			}
		})
	}

	private func updateForegroundColor() {

					switch key {
					case CNPreference.shared.terminalPreference.WidthItem:
						let newwidth = CNPreference.shared.terminalPreference.width
						if self.mTerminalInfo.width != newwidth {
							self.mTerminalInfo.width = newwidth
							self.invalidateIntrinsicContentSize()
							self.setNeedsLayout()
							self.notify(viewControlEvent: .updateSize)
						}
					case CNPreference.shared.terminalPreference.HeightItem:
						let newheight = CNPreference.shared.terminalPreference.height
						if self.mTerminalInfo.height != newheight {
							self.mTerminalInfo.height = newheight
							self.invalidateIntrinsicContentSize()
							self.setNeedsLayout()
							self.notify(viewControlEvent: .updateSize)
