Get text from the clipboard.
(self)
| 171 | |
| 172 | |
| 173 | def clipboard_get(self): |
| 174 | """ Get text from the clipboard. |
| 175 | """ |
| 176 | from ..lib.clipboard import ( |
| 177 | osx_clipboard_get, tkinter_clipboard_get, |
| 178 | win32_clipboard_get |
| 179 | ) |
| 180 | if sys.platform == 'win32': |
| 181 | chain = [win32_clipboard_get, tkinter_clipboard_get] |
| 182 | elif sys.platform == 'darwin': |
| 183 | chain = [osx_clipboard_get, tkinter_clipboard_get] |
| 184 | else: |
| 185 | chain = [tkinter_clipboard_get] |
| 186 | dispatcher = CommandChainDispatcher() |
| 187 | for func in chain: |
| 188 | dispatcher.add(func) |
| 189 | text = dispatcher() |
| 190 | return text |
nothing calls this directly
no test coverage detected