DTEDITORCUTTOCLIPBOARD(3)

πŸ“¦
version 2.5.3 Β· 2 versions
, in nixos 26.05

okay so this is the DtEditorCutToClipboard(library call) page, and it's giving β€œcut that selection to the clipboard” energy πŸ’…βœ¨

🌸 NAME 🌸

DtEditorCutToClipboard β€” copy the primary selection in a DtEditor widget to the clipboard and delete the selected text 🫢

✨ SYNOPSIS ✨

       #include &<Dt/Editor.h>
       Boolean DtEditorCutToClipboard(
       Widget widget);

πŸ’– DESCRIPTION πŸ’–

So basically, DtEditorCutToClipboard takes the primary selected text in the DtEditor widget β€” the one you pass as widget, bestie β€” and copies it to the clipboard. Then it deletes the primary selected text. Boom. Cut. Slay. βœ‚οΈβœ¨

Text can be selected and deselected programmatically with DtEditorSelectAll(3) and DtEditorDeselect(3) β€” handy for when you're doing it from code instead of vibes 🧚

The widget argument specifies the DtEditor widget ID. That's the main character here πŸ‘‘

For a complete definition of the DtEditor widget and its associated resources, see DtEditor(3). iykyk πŸ“š

πŸ”₯ RETURN VALUE πŸ”₯

If everything goes off without a hitch, DtEditorCutToClipboard returns True πŸ‘‘.

Otherwise it returns False β€” specifically if the primary selection is NULL, or if the widget doesn't own the primary selection, or if the function is unable to gain ownership of the clipboard selection. No cap, those are the fail conditions 😭

πŸ¦‹ SEE ALSO πŸ¦‹


okay bye bestie 🫢 that was the DtEditorCutToClipboard(library call) page from the library call manual β€” the footer only showed DtEditorCutToClipboard(library call), with no source/version or date printed, so I'm not inventing one, periodt πŸ’œ

πŸ“¦ where this page comes from