Jump to content

Is this possible with Alfred? (transforming highlighted text)


Recommended Posts

I use Scrivener, a Mac app for writing.  It lacks an extension/plugin system and has no AppleScript support (unfortunately).

 

I have a Microsoft Word macro kit that will go through a piece of text and highlight weak verbs, overuse of prepositions, and other grammatical faults.

 

I'd like to do the following:

  • Highlight a block of text in Scrivener
  • Invoke Alfred
  • Magic happens
  • Microsoft Word opens, the text is pasted in a new doc, and the macro is run
  • BONUS: Ideally a new section is created in Scrivener with the highlighted text pasted back and Word is closed

Alternatively

  • Highlight a block of text in Scrivener
  • Invoke Alfred
  • Alfred invokes some AppleScript/something I write, does the highlighting work, and pastes the text back

I can browse through Alfred's docs to see if this is possible and how I might do it (and write the AppleScript stuff) but before I go down that path, I'm wondering if this is possible in Alfred/a good candidate for an Alfred workflow.

 

As you can tell, I'm rather new to Alfred :-)

 

I do have the Powerpack if that is significant.

 

Thanks very much for any advice.

 

Link to comment

You might look at the hotkey version of the Case Converter workflow: http://www.alfredforum.com/topic/2180-case-converter-including-title-case/?hl=%20case%20%20converter

 

One possible hitch will relate to loss of formatting in the trip from Scrivener -> Word -> clipboard.  If all of the modification is done in Applescript in Word you might be ok.  But most of the other text conversions out there are based on command line utilities &/or python & other languages that typically don't readily support .rtf or other rich formats to keep the formatting.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...