         selectedRange = NSRange(location: selectedRange.location + string.length, length: 0)
         return true
     }
-    
+
+    /// Tries to paste HTML from the clipboard as source, replacing the selected range.
+    ///
+    /// - Returns: True if this method succeeds.
+    ///
     func tryPastingHTML() -> Bool {
         guard let html = UIPasteboard.general.html() else {
             return false

        return true
    }

    /// If there is selected text and a URL is available on the pasteboard,
    /// this method creates a link to the URL using the selected text.
    ///
    /// - returns: True if a link was successfully created
    ///
    private func tryPastingURL() -> Bool {
        guard selectedRange.length > 0,

    
    // MARK: - Try Pasting
    
    /// Tries to paste an attributed string from the clipboard as source, replacing the selected range.
    ///
    /// - Returns: True if this method succeeds.
    ///
    private func tryPastingAttributedString() -> Bool {
        guard let string = UIPasteboard.general.attributedString() else {
            return false
