Jump to content
kongjie

Snippet inserts last paste instead of desired text

Recommended Posts

Alfred 4.0.3 on OS 10.14.6 in Word Mac 16.29.

 

This bug is random as far as I can tell; it may occur in other apps but I've specificially noticed it in Word, and for a while at that.

 

I type a snippet and there is a slight delay in expansion, a stutter, and instead of expanding the snippet to the desired text, instead the last copied and pasted text (presumably whatever was on the clipboard) is pasted.

 

I cannot figure out if it happens under particular circumstances; it seems intermittent. But I can usually force it to happen by clicking to another part of the document, then copying and pasting a couple of times. You can view a screen recording of it happening here (https://www.dropbox.com/s/efu3mx06x833a8v/expansion_error.mov?dl=0)--I copy the text "diabetes mellitus" then delete a percent sign and type "pct" to expand to "percent," but what expands is  "diabetes mellitus."

Share this post


Link to post

Go into "Alfred Preferences > Features > Snippets > Auto Expansion Options > Tweaking" and increase the "Restore after" delay.

 

Alfred uses the clipboard to insert snippets. It puts the snippet on the clipboard, then sends a "paste" signal to the active application. Unfortunately, there's no way Alfred can tell when (or even if) the application actually performs the paste, so it just has to wait for a bit to give the app time to do the paste, and then Alfred restores the previous clipboard contents.

 

So if an application is responding slowly, it might not get around to performing the paste until after Alfred has already restored the clipboard.

 

Increasing the "Restore after" delay gives the slow application more time to respond to the "paste" command.

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...