* Insert a chunk of text from the clipboard onto the textbuffer. Get TEXT clipboard * and append this up to the maximum length (either absolute or screenlength). If maxlength * is zero, we don't care about the screenlength but only about the physical length of the string * @return true on successful change of Textbuf, or false otherwise */
| 221 | * @return true on successful change of Textbuf, or false otherwise |
| 222 | */ |
| 223 | bool Textbuf::InsertClipboard() |
| 224 | { |
| 225 | auto contents = GetClipboardContents(); |
| 226 | if (!contents.has_value()) return false; |
| 227 | |
| 228 | return this->InsertString(contents.value(), false); |
| 229 | } |
| 230 | |
| 231 | /** |
| 232 | * Delete a part of the text. |
no test coverage detected