C-Command Software Forum

Feature Request(s) -- 'Import Clipboard...' item to 'File' menu

**(Edited: Title should read… – ADD ‘Import Clipboard…’ item to ‘File’ menu)
Hi Michael,

I have multiple libraries, often import the contents of the clipboard (rich text), and like to do so directly to a specific library rather than whichever library happens to be at the front. So rather than using the Services method, I import via Keyboard Maestro macros, or via AppleScript. (Currently I do this by bringing-to-front the appropriate EF library, then using cmd-shift-v to paste the clipboard contents.

When right-clicking EF’s dock icon there is an ‘Import Clipboard’ option available. Is that something you’d consider adding to EF’s ‘File’ menu? (It could then be targeted by Keyboard Maestro or System Events.)

Alternatively – or additionally – could you add a way to import the clipboard and/or rich text via AppleScript? (Unless I’m missing it amongst the multiple options available to the ‘Import’ command.)

Thanks very much. And, as I haven’t been around these parts for a while, thanks again for all your great work on EagleFiler.****

Command-Shift-V is the keyboard shortcut for File > New Record > From Clipboard. Is there a reason that command doesn’t work for you?

Yes, I’ll add that to the to-do list. Thanks for the suggestion. (Currently you could convert the clipboard to plain text and import that via AppleScript, but you probably don’t want to do that.)

Hah – no, totally missed that. My bad. Got stuck looking at ‘Import’. If I’ve ever used the File > New Record menu item it was too long ago for my mushy mind to remember it. Thanks for pointing that out to me, and apologies for wasting your time on it.

That would be great – glad my entire post wasn’t a bust.

Thanks much, Michael.

I’ve added this in EagleFiler 1.6.5.

Hi Michael – thanks very much for adding this feature. And apologies for the much-delayed reply.

When I import the clipboard via the applescript method, I’m only getting it in plain text, rather than rich text (an rtfd file is being created, but my rich text clipboard contents are being coerced to plain text).

Wondering if I’m missing something. Here’s the script I’m testing:

tell application "EagleFiler"
	tell library document 1
		import text the clipboard
	end tell
end tell

Try “import with clipboard”. Using “the clipboard” means that AppleScript gets the clipboard, converts it to (unstyled) text and then passes it to EagleFiler. (View the event log in Script Editor to see what I mean).

That does it.

I didn’t see that command during my hunt – the only one I could find on the Import Examples page that seemed relevant was the “import text” command.

Thanks very much for the help, nriley – I really appreciate it.

Right. When you use import with clipboard, instead of passing the clipboard contents as a parameter to EagleFiler (which AppleScript doesn’t really support for rich text), you are passing a boolean that tells EagleFiler itself to read the clipboard, which could be RTF, plain text, or an image.