Can I set the mime type of my clipboard content?

If you're familiar with xclip, I need the functionality of it's -t flag, which set the mime type of some data. I'd like to do this without using X, so that eliminates installing xclip.
4 Replies
zeb (ping me on replies)
I'd also like to see what formats are available in the clipboard.
NyaNyaCutie
NyaNyaCutie2y ago
AFAIK, Termux currently can only read from & write to the Android clipboard in plain text. Ofher formats would require a command-breaking rework if termux-clipboard-get as-is would return binary data
zeb (ping me on replies)
I see. It may not require a complete rework to alter the set command though? Because that's what important to me. My use case is putting HTML inside the clipboard. Formatted text. Would it be possible to write a program in C or C++ that can touch the system clipboard? If so could someone like give me some pointers as to how to do it? Like what header files what I have to include for interfacing with Android stuff? I'm bringing up C++ because I don't know Java and I'm not looking to learn it.
NyaNyaCutie
NyaNyaCutie15mo ago
@zeb (ping me on replies) You'd be better off asking in a Discord or something that is more focused on Android app development.
Want results from more Discord servers?
Add your server