Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

primary_selection

Extract the Primary Selection


Description

By default, functions returning a document context will return a list of selections, including both the 'primary' selection and also 'other' selections (e.g. to handle the case where a user might have multiple cursors active). Use primary_selection() to extract the primary selection.

Usage

primary_selection(x, ...)

Arguments

x

A document context, or a selection.

...

Optional arguments (currently ignored).


rstudioapi

Safely Access the RStudio API

v0.13
MIT + file LICENSE
Authors
Kevin Ushey [aut, cre], JJ Allaire [aut], Hadley Wickham [aut], Gary Ritchie [aut], RStudio [cph]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.