     
     private var orientationObserver: AnyCancellable?
     
+    private var stackView: NSStackView?  { self.view as? NSStackView }
+    
     @IBOutlet private weak var lineNumberView: LineNumberView?
     
     

    // MARK: -
    // MARK: Lifecycle
    
    override func viewWillAppear() {
        
        super.viewWillAppear()
        
        // observe text orientation for line number view
        self.orientationObserver = self.textView!.publisher(for: \.layoutOrientation, options: .initial)

                
                self.lineNumberView?.orientation = orientation
            }
    }
    
    
