Skip to content

not work GrowingTextViewDelegate #43

@dan085

Description

@dan085

I change this code and reemplace this

` @objc func textDidChange(notification: Notification) {
if let sender = notification.object as? GrowingTextView, sender == self {
if maxLength > 0 && text.count > maxLength {
let endIndex = text.index(text.startIndex, offsetBy: maxLength)
text = String(text[..<endIndex])
undoManager?.removeAllActions()
}

     -->     setNeedsLayout() /// with this line work
   --->   //  setNeedsDisplay() // remove this line
    }
}`

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions