Jump to content

Paste key "\"


Recommended Posts

I set up a very simple Workflow that allows me to print the back slash key "\" by pressing a keyboard combination.

 

Trigger: Hotkey

-> Copy "\" to clipboard & Automatic paste to front app

 

However, this is pretty slow (takes about 2-3 seconds).

 

Am I doing this the wrong way? Or are there actually options out there that can do this a bit faster?

 

Thanks a lot!

Link to comment

Not sure why that would be a XY Problem.

 

Either way, I've spent more time the last five minutes trying to understand what's wrong with my question, than it took to solve it.

 

The answer was using another application that did it faster. Thanks anyway.

Edited by winterflags
Link to comment

Not sure why that would be a XY Problem.

Because it is a weird request of something to do programatically. It is also somewhat simple to do with Applescript and to figure out, and (as stated) you haven’t specified the use case in an adequate manner. This all suggests low programming experience, and helping novices by just spitting out an answer is harmful, unnecessary, inefficient, and unhelpful.

It is better for everyone when the exact problem is stated and understood. Using an old proverb, simply giving out the answer to this weird question would be like giving you a rotten fish of the kind you don’t even like. It would be much more beneficial to give you a fish of the type you actually want, and in the process explain how it was caught. Even you end up not caring about the fishing technique, at least you’re left with a better fish.

Link to comment

I'm experienced enough when it comes to Q&A sites that I know when it's appropriate to state the raison d'être in the question, and when it's not. It doesn't help the economy of the question to state superfluous information.

 

In this case, I decided that it wasn't necessary, and I still don't believe it is. The question speaks for itself, and why I want to do it shouldn't really be a concern of yours. I wasn't grasping for a general answer, but really just wanted to know if this was the fastest way for Alfred to bind a keyboard command to a character.

 

Besides, I'm not that unexperienced when it comes to programming that I would need to hear proverbs instead of answers to my questions. You're pretty presumptuous.

 

TBH, it's pretty obvious that you're really just projecting an idée fixe of yours about XY problems. Interesting mental preoccupations for you, surely, but not really relevant here, and frankly a waste of time.

Edited by winterflags
Link to comment

It's because your question is a strange one. There's a key for \ on your keyboard, so why would you want a hotkey that does the same as a physical key?

 
To answer your question, a faster way to do it that doesn't mess with the clipboard is:
 
tell application "System Events" to keystroke "\\"
Link to comment

Woah, there, didn’t mean to insult you. The proverb was used as an analogy, not as a way to bring you down or elevate myself. You said you were unclear about something I had stated, so I wanted only to clarify it.

I do find it weird, though, how you believe (by stating “it’s pretty obvious”) it is a valid argument to criticise me making assumptions about you, by you making assumptions about me. Except I never did, as I was careful to say the situation suggests low programming experience and even explained not only why I thought that, but why it is relevant. The fact that you took that as an insult is weirder still. I didn’t learn what I learned about programming without asking questions, and I still do, as I’m far from a master programmer.

If there’s one important lesson I take (present) from all my time asking questions about programming, is that I am never the best judge of what the best question is. If I did know what the best question was, I would’ve found the answer in my googling. When someone trying to help asks for more details, as frustrating as that may seem I must either provide them, or be explicit as to why providing them isn’t relevant, since that also provides context. Saying “none of your business” is a sure way to not get an answer. People are trying to help you; help them do it.

Apologies if I sounded insulting, truly, as that wasn’t my intention. The posts in this forum, github issues, and other avenues on the web should show that I always try to have the best intentions, though naturally you couldn’t have known that automatically.

I still disagree with you, but no reason that shouldn’t be done respectfully, especially in such a small and amicable community.

Edited by Vítor
fixed typo
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...