     private let tapGestureRecognizer = UITapGestureRecognizer()
     private let longPressGestureRecognizer = UILongPressGestureRecognizer()
     
-    private let drawingQueue = DispatchQueue(label: "com.knowre.KRMathInputView.drawingQueue",
-                                             qos: DispatchQoS.userInitiated)
-    
     override public init(frame: CGRect) {
         super.init(frame: frame)
         

    }
    
    private func getImage(for charInk: CharacterInk, strokeColor: UIColor) -> UIImage? {
        var image: UIImage?
        DispatchQueue.global(qos: .userInitiated).sync {
            let size = charInk.frame.height - selectionPadding * 2.0
            
            let font = (fontName != nil ?
                UIFont(name: fontName!, size: size) :
                UIFont.systemFont(ofSize: size)) ?? UIFont.systemFont(ofSize: size)
            let attrib = [NSFontAttributeName: font,
                          NSForegroundColorAttributeName: strokeColor] as [String: Any]
            let attribString = NSAttributedString(string: String(charInk.character),
                                                  attributes: attrib)
            
            let line = CTLineCreateWithAttributedString(attribString as CFAttributedString)
            var frame = CTLineGetImageBounds(line, nil)
            
            frame.size.width += abs(frame.origin.x)
            frame.size.height += abs(frame.origin.y)
            
            UIGraphicsBeginImageContextWithOptions(frame.size, false, 0.0)
            guard let fontCtx = UIGraphicsGetCurrentContext() else { return }
            fontCtx.textPosition = CGPoint(x: -frame.origin.x, y: -frame.origin.y)
            
            CTLineDraw(line, fontCtx)
            
            image = UIGraphicsGetImageFromCurrentImageContext()
            UIGraphicsEndImageContext()
        }
        
        return image
    }

                strokeInk.path.stroke()
            } else {
                // TODO: Add error handling
                guard let charInk = ink as? CharacterInk else { return }
                guard rect.intersects(charInk.frame) else { continue }
                
                guard let ctx = UIGraphicsGetCurrentContext() else { return }
                guard let image = getImage(for: charInk, strokeColor: UIColor.black) else { return }
                ctx.draw(image.cgImage!, in: charInk.frame)
            }
        }
