XMCLIPBOARDCANCELCOPY(3)
π XmClipboardCancelCopy π
okay bestie, gather round, because this is the library call for when you started something and you're like... nope. not doing this anymore. it's XmClipboardCancelCopy(library call) and she is here to clean up your mess π§Ήβ¨
πΈ NAME πΈ
XmClipboardCancelCopy β a clipboard function that cancels a copy to the clipboard. she said "never mind" and meant it π
β¨ SYNOPSIS β¨
#include <Xm/CutPaste.h>
int XmClipboardCancelCopy (display, window, item_id)
Display * display;
Window window;
long item_id;
(void)
π¦ DESCRIPTION π¦
okay so, XmClipboardCancelCopy cancels the copy to clipboard that is in progress and frees up temporary storage. the way this whole saga works is:
when a copy is going to be performed, XmClipboardStartCopy allocates temporary storage for the clipboard data. then XmClipboardCopy copies the appropriate data into the the temporary storage (yes, "the the", that's what the original says, i don't make the rules π«Ά). then XmClipboardEndCopy copies the data to the clipboard structure and frees up the temporary storage structures. but here's the thing β if XmClipboardCancelCopy is called, the XmClipboardEndCopy function does not have to be called. you're off the hook, girlie π
β οΈ a call toXmClipboardCancelCopyis valid only after a call toXmClipboardStartCopy. don't try to cancel what was never started, it's giving chaos π
the parameters, let's go:
displayβ Specifies a pointer to theDisplaystructure that was returned in a previous call toXOpenDisplayorXtDisplay. it's literally just your display pointer bestie, hand it over π«΄windowβ Specifies a widget's window ID that relates the application window to the clipboard. The widget's window ID can be obtained throughXtWindow. The same application instance should pass the same window ID to each of the clipboard functions that it calls. consistency is the vibe check here, no cap βitem_idβ Specifies the number assigned to this data item. This number was returned by a previous call toXmClipboardStartCopy. so like, don't invent your own number, use the one she gave you π₯
π RETURN π
XmClipboardSuccessβ The function was successful. we ate and left no crumbs β¨XmClipboardLockedβ The function failed because the clipboard was locked by another application. The application can continue to call the function again with the same parameters until the lock goes away. This gives the application the opportunity to ask if the user wants to keep trying or to give up on the operation. so basically it's not your fault, someone else is hogging the clipboard, and you get to decide: keep knocking or walk away πͺπXmClipboardFailβ The function failed becauseXmClipboardStartCopywas not called or because the data item contains too many formats. yeah that's on you, you skipped a step π
π RELATED π
XmClipboardCopy(3), XmClipboardEndCopy(3), and XmClipboardStartCopy(3). the whole friend group, go read them too π
and that's the whole page, bestie!! thanks for reading all the way to the bottom, you're genuinely the main character π«Ά this was XmClipboardCancelCopy(library call) β that's the title up top and the little signature down at the very bottom, cute right? stay iconic, go cancel some copies, and remember: free your temporary storage before it frees you ππβ¨π¦πΈ
π¦ where this page comes from
- alpine 3.24: motif-doc 2.5.2-r0 Β· LGPL-2.1-or-later
- arch rolling: openmotif 2.3.8-4 Β· LGPL-2.1-or-later
- centos-stream 9: motif-devel 2.3.4-32.el9 Β· LGPLv2+
- centos-stream 9: motif-devel 2.3.4-32.el9 Β· LGPLv2+
- epel 10: motif-devel 2.3.8-2.el10_2 Β· LicenseRef-Callaway-LGPLv2+
- fedora 43: motif-devel 2.3.8-1.fc43 Β· LicenseRef-Callaway-LGPLv2+
- fedora 43: motif-devel 2.3.8-1.fc43 Β· LicenseRef-Callaway-LGPLv2+
- fedora 43: motif-devel 2.3.8-2.fc43 Β· LicenseRef-Callaway-LGPLv2+
- fedora 43: motif-devel 2.3.8-2.fc43 Β· LicenseRef-Callaway-LGPLv2+
- fedora 44: motif-devel 2.3.8-3.fc44 Β· LicenseRef-Callaway-LGPLv2+
- fedora 44: motif-devel 2.3.8-3.fc44 Β· LicenseRef-Callaway-LGPLv2+
- nixos 26.05: motif 2.3.8
- nixpkgs unstable: motif 2.3.8
- opensuse-leap 16.0: motif-devel 2.3.8-bp160.1.1 Β· LGPL-2.1-or-later
- opensuse-leap 16.0: motif-devel 2.3.8-bp160.1.1 Β· LGPL-2.1-or-later
- opensuse-leap 16.0: motif-devel 2.3.8-bp160.1.1 Β· LGPL-2.1-or-later
- opensuse-leap 16.0: motif-devel 2.3.8-bp160.1.1 Β· LGPL-2.1-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms