Give access to the system clipboard.
sf.Clipboard provides an interface for getting and setting the contents of the system clipboard.
It is important to note that due to limitations on some operating systems, setting the clipboard contents is only guaranteed to work if there is currently an open window for which events are being handled.
Usage example:
// get the clipboard content as a string
var string = sf.Clipboard.getString();
// or use it in the event loop
sf.Event event;
while(window.pollEvent(event))
{
if(event.type == sf.EventType.Closed)
window.close();
if(event.type == sf.EventType.KeyPressed)
{
// Using Ctrl + V to paste a string into SFML
if(event.key.control && event.key.code == sf.KeyCode.V)
string = sf.Clipboard.getString();
// Using Ctrl + C to copy a string out of SFML
if(event.key.control && event.key.code == sf.KeyCode.C)
sf.Clipboard.setString("Hello World!");
}
}