blt::cutbuffer(3tcl)

πŸ’– blt::cutbuffer β€” the Tcl manual, but make it cute πŸ’–

okay bestie, so this one lives in the BLT Built-In Commands section of the Tcl manual, and it's called blt::cutbuffer. it's giving clipboard-adjacent main character energy and i'm obsessed. let's get into it 🫢


✨ NAME ✨

cutbuffer β€” manipulate X cut buffer properties 🌈


✨ SYNOPSIS ✨

cutbuffer get ?number?
cutbuffer rotate ?count?
cutbuffer set value ?number?

like, three whole operations, three whole moods. slay. πŸ’…


✨ DESCRIPTION ✨

so the cutbuffer command lets you read or modify the eight X cut buffer properties. that's right, bestie β€” eight of them, not seven, not nine, eight ✨

and because that's not enough chaos for one command, you can also rotate the buffer properties. no cap. the buffers just... spin. πŸŒ€


✨ OPERATIONS ✨

these are the operations available for the cutbuffer command, and yes we're going through every single one, i don't skip πŸ‘‘

  • cutbuffer get ?number? β€” returns the value of cutbuffer number. number has to be a number between 0 and 7, and if you don't say anything the default is 0. the cutbuffer comes back to you exactly, with one lil exception: NUL bytes get converted to '@' characters. wild, i know 😭 and if a cut buffer number doesn't exist? you get "" back. nothing. silence. a void. πŸ’€
  • cutbuffer rotate ?count? β€” rotates the cut buffers by count. count has to be a number between -7 and 7, and the default is 1. note the negative numbers are valid here, so you can spin it either way, iconique πŸŽ€
  • cutbuffer set value ?number? β€” sets the cutbuffer number to value. number has to be a number between 0 and 7, and yeah, default is 0. simple, clean, ate πŸ”₯
heads up bestie: the 0 to 7 range on number is not a suggestion, it's the law, and count living between -7 and 7 is equally non-negotiable. don't test it πŸ™ˆ

✨ KEYWORDS ✨

cut buffer, property πŸ¦‹


and that's the whole thing! this page came to you from BLT 2.5, dated back in the day, in the blt::cutbuffer(3tcl) manual section. mwah, go read a cut buffer or something πŸ’œβœ¨πŸŒΈ

πŸ“¦ where this page comes from