clipboard

    Dark Mode
Search:
Group by:

clipboard.nim

Include file for SDL clipboard handling.

Procs

proc setClipboardText*(text: cstring): cint {...}{.cdecl,
    importc: "SDL_SetClipboardText", dynlib: SDL2_LIB.}

Put UTF-8 text into the clipboard.

See also:

getClipboardText()

proc getClipboardText*(): cstring {...}{.cdecl, importc: "SDL_GetClipboardText",
                                    dynlib: SDL2_LIB.}

Get UTF-8 text from the clipboard, which must be freed with free().

See also:

setClipboardText()

proc hasClipboardText*(): bool {...}{.cdecl, importc: "SDL_HasClipboardText",
                                 dynlib: SDL2_LIB.}

Returns a flag indicating whether the clipboard exists and contains a text string that is non-empty.

getClipboardText()