Jump to content

flome

Member
  • Posts

    38
  • Joined

  • Last visited

  • Days Won

    1

Posts posted by flome

  1. @vitor Thank you for the help. I added a feature to split all text into paragraphs and I limited the "find" text selection feature to the original document/window/tab. I think it works rather well. Here's the final workflow, or at least as far as it works for me.

     

    Canceling can be done with a separate hotkey. I wanted to make it the same hotkey (to toggle off if no selection), but since the osascript is set to run sequentially, it'll run the pkill at the end which won't work.

     

    Here it is.

     

    I'm still new to both AS and Workflows, and so if you notice anything quirky with it feel free to let me know.

     

     

  2. 15 hours ago, vitor said:

    Try this one. The code it uses is instead AppleScript

     

    Thanks for this. I didn't know you could invoke say directly with AppleScript. However, the reason I was trying to avoid doing a direct "Keystroke" of the query was due to the delay it created. I have to wait until the whole paragraph is scrolled through, which makes the use of the workflow much more cumbersome. This is why I was attempting to use copy/paste which is much quicker. 

     

    The workflow you sent works, but there are two issue I have:

    1. The aforementioned delay. Is there any way we could use the clipboard or an external file?

    2. The keystroke makes a sound after it completes, it uses the default mac alert sound. I'd like to figure out how to remove that sound. 

     

    The first question may lead to this possibility: Obviously this would be down the road, and first things first, but I'd like to eventually enhance this workflow to be able to select a whole block of text, be it an article or chapter for example, and have the workflow parse out the text for sentences using the period as a delimiter. Then perform the "say" command on each sentence, highlighting each sentence using the method we're talking about here. 

     

    Thanks again for your help. 

  3. I'm trying create a workflow to utilize the MacOS Say command. With this command, I'd like to queue up several paragraphs for it to speak and highlight the spoken paragraph. I'm close, but I'm running into issue with the clipboard management. It was my understanding that the /bin/bash scripts can queue commands up in sequence. In which case the below code should execute like this; 

     

    1. Copy the query (which in my workflow is the selected text).

    2. Open find in Safari

    3. Paste the clipboard contents.

    4. Say the selected text.

     

    It looks like the LAST copied text ends up being pasted, instead of in sequence. The say command adheres to the sequence properly. The other commands do not, what am I missing?

     

    screenshot of the workflow is attached.

     

    pbcopy < "{query}"
    osascript -e 'tell application "System Events" to keystroke "f" using command down'
    osascript -e 'tell application "System Events" to keystroke "v" using command down'
    say "{query}" -r 250

     

    2017-03-20_15-02-06.png

  4. 1 hour ago, surrealroad said:

    Please see the first post. *Only* creating reminders are supported. in Mac OS 10.12.

     

    Thanks, I see you mention that the "bug" may never be fixed by Apple. Do you think it's worth adding a clause to the subtext in the workflow to avoid repetitive questions from people who can't read (like me?)

  5. I have the same issue. Any command other than creating a reminder shows "command not recognized" I'm running MacOS Sierrra 10.12.1 (which could be the problem). 

     

    Also, when running "r this" I can't seem to set a time for my reminder and sometimes the title I set won't stick. It will give it the subject name of the mail item or the title of the chrome window instead. It's a little inconsistent there.

×
×
  • Create New...