ghostwriter: Write an Apple script to type some text into RStudio

Description Usage Arguments Value Note

Description

This is used to write an Apple Script that will type some text into RStudio. It's primary purpose is for use in recording videos when I want to show live "typing" without any typos or delays while live typing.

Usage

1
2
ghostwriter(file, lines = NULL, speed = 0.1,
  script = "ghostwrite.scpt", application = "RStudio")

Arguments

file

A file with the desired text to write

lines

A numeric vector specifying which lines to type. If unspecified, the entire file will be typed out.

speed

A number parameterizing the speed at which the script will type.

script

A path to the location where the script will be written. If NULL then no output file will be created.

application

The application where the keyboard input should go.

Value

Returns the script invisibly.

Note

This currently only allows hard returns as special characters. Any other characters will be entered exactly as they appear in the file.


johnsonra/tutorialTK documentation built on May 26, 2019, 6:53 p.m.