Typing Speed?

I wan to simulate a user typing a string. There is Text/Insert Text by Typing, but that types so fast that it more resembles pasting then typing. Is there a way to control the speed of the typing?

Hey George,

Use an Insert Text by Typing action for each character and begin the macro with a Set Action Delay action.

Set Action Delay has a bunch of options, so you can get pretty specific.

-Chris

Thanks for your answer Chris. Your suggestion works just fine for small amounts of text, but I am using the typing for simulating a user that enters one line at a time (containing something like 30 characters), and he has many hundreds of lines to enter. So to take 1 character at a time and put a delay after it would just not work.

I have all my text i a text file. On a hot key trigger I am going to that text file and copying one line, then I go back automatically to my target application and insert that line of text by simulating typing. I works fine except that the speed of typing is too high.

Is there some way to use your trick, or some other trick to do simulate slow typing of large amount of text automatically?

Why not just use the normal Insert Text by Typing, and put whatever delay you like in the loop between getting one line and typing it?

Hi Michael, My problem is NOT that I need delay between the lines, since I am controlling it myself (each time i press on my hot key F9). The problem is that I need delay between the single characters. But maybe I do not understand you correctly. You are talking about a loop. What kind of loop are you referring to?

You see I am creating a Mathematica tutorial that I want to put on the YouTube. And I want to simulate what I would normally type in Mathematica, by getting the text from a text file and simulating typing. Here is the KM script I'm using now.

Here is a small video that shows how the text is typed in. Each type I press on the F9 a new line is pasted. As you can see the TYPING speed is to fast.

Hey George,

You don't have to use multiple delays. The one Set Action Delay sets the delay between ALL actions in the macro.

But you're right. For large amounts of text that's still impractical.

However – this works:

Generic-Test 01.kmmacros (2.0 KB)

I didn't try it before, because there's only 1 Insert Text by Typing action – but apparently KM is seeing each keystroke as an "action" in this context.

Hopefully Peter will provide a more specific explanation.

-Chris

George, sorry, but I have to ask.
Do you really think the user cares if the typing looks too fast?
IMO, they don’t need to see “normal” typing speed.
They just need to see what was typed, and then a brief delay so they can read it.

Your tutorial will go much faster (and I think the users will like it) if you just do the normal Insert Text by typing, one line at a time, with a brief delay between lines.

That’s just my opinion. But you might test this on a few users (in a short sample) to get their feedback.

IAC, looks like Chris has a solution for you, so you have the option to go either way.

Good luck!

Hey George,

I suggest you use TextWrangler rather than TextMate, because it is scriptable – so you can leave it in the background.

Each activation will insert the next line from the front TextWrangler document by typing into the front application.

The timing of the macro works pretty well with TextEdit, but you'll have to adjust for Mathmatica.

-Chris


Macro edited 2015/12/05 17:50 CST to prevent repeat insertions of text in the saved variable after the last line of text is inserted.

Text edited 2015/12/06 06:11 for clarity.


Generic-Test 01.kmmacros (3.3 KB)

Macro edited 2015/12/05 17:50 CST. -ccs

Huzzah, thanks Chris,

I found your “simulate Normal Keystroke delay” under

Keyboard Maestro/Set Action Delay

and it works like a charm.

I am rather new to using KM, but nowhere in the world would I come up with looking in Keyboard Maestro/Set Action Delay. It seems that KM is much more powerful than I thought. KM is like a castle full of secret rooms and it takes time until one gets to know them. But thanks to this forum and people like yourself those secrets places can be revealed.

Text of post 9 edited 2015/12/06 06:11 for clarity.  -ccs

As usual, the most amazing tool in my many years of using computers comes through again, thanks for this post!

2 Likes

I know this is an old post, but I wanted to thank you all for this solution. "Set Action Delay" pulled up an option for "Simulate Normal Keystroke Delay". I set mine to 0.03 to be extra cautious and it works like a charm. In my case I'm trying to paste specifically created and copied names for files into save dialog boxes, and in some apps locked out of pasting. Without this delay KM was missing characters while "typing the clipboard" resulting in incorrect file names being created/saved.