-2

I need to get the clipboard into string, After I getting the string of the clipboard I want to set the clipboard to something else.

2 Answers2

2

Love2D doesn't have functions for accessing clip-board data. It's too platform-specific for it.

Nicol Bolas
  • 449,505
  • 63
  • 781
  • 982
0

One of the strongest points of Lua is its ability to interface easily with C and C++ libraries through bindings. What you would have to do here is to write your own library in C (or find an existing one) that does what you want to do, write a binding for it for Lua and then use it from your love2d code.

Unfortunately, like Nicol said, this is likely going to be platform specific which means you'll need to write a library for each platform you want your game to run on and then use the love._os field to split your game logic.

WuTangTan
  • 1,116
  • 10
  • 12