+ // explicit text type?
+ if (arg == "html") {
+ // Do not enable for PlainTextType, since some tidying in the
+ // frontend is needed for HTML, which is too unsafe for plain text.
+ enable = theClipboard().hasTextContents(Clipboard::HtmlTextType);
+ break;
+ } else if (arg == "latex") {
+ // LaTeX is usually not available on the clipboard with
+ // the correct MIME type, but in plain text.
+ enable = theClipboard().hasTextContents(Clipboard::PlainTextType) ||
+ theClipboard().hasTextContents(Clipboard::LaTeXTextType);
+ break;
+ }
+