DTWSMREMOVEWORKSPACEFUNCTIONS(3)

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

πŸ’… DtWsmRemoveWorkspaceFunctions β€” a library call moment, bestie

Okay so picture this: it's a library call, right, and it's about taking a window's workspace functions away. That's the whole gig. Let's get into it ✨


🌸 NAME 🌸

DtWsmRemoveWorkspaceFunctions β€” literally removes a window's workspace functions. That's it, that's the vibe πŸŽ€


πŸ¦‹ SYNOPSIS πŸ¦‹

#include <Dt/Wsm.h>
void DtWsmRemoveWorkspaceFunctions(
Display *display,
Window window);

πŸ’– DESCRIPTION πŸ’–

So the DtWsmRemoveWorkspaceFunctions function does exactly what it says on the tin: it removes a window's workspace functions. Iconic, no notes πŸ’…

Now here's the tea β€” when DtWsmRemoveWorkspaceFunctions removes those workspace functions, the window menu that the XCDE workspace manager, dtwm(1), displays for that window? It just doesn't have the entries anymore. You know the ones:

  • the entry that lets the window occupy a different set of workspaces
  • the entry that lets it occupy all the workspaces
  • the entry that lets it be removed from the current workspace

Poof. Gone. Not in the menu. The menu is not giving workspace-flexibility energy anymore, and honestly? That was the point 🫢

A couple of arguments to keep in your notes app:

  • The display argument is the X display. You know her, you love her.
  • The window argument is the window that's getting its workspace functions disabled. Sorry bestie, it's not personal 😭

⭐ RETURN VALUE ⭐

The DtWsmRemoveWorkspaceFunctions function returns no value. Nothing. Nada. It's giving silent-but-confident main character energy β€” it does the thing and doesn't need a receipt πŸ‘‘


🧚 APPLICATION USAGE 🧚

Listen up, because this part is so important, like actually important:

The application must call DtWsmRemoveWorkspaceFunctions before the window is mapped.

Fr fr. The XCDE workspace manager, dtwm(1), only looks at the workspace function information at the time the workspace manager manages the window. That's the only moment it checks. It's not coming back for a second look, iykyk πŸ™ˆ

So if the XCDE workspace manager, dtwm(1), is already managing the window? Then you've got a little three-step choreography, and you gotta do all of it:

  1. The application must withdraw the window (see XWithdrawWindow(3))
  2. Then remove the workspace functions
  3. Then map the window once again

Withdraw, remove, remap. Slay in sequence, not out of order 🌈


πŸ”₯ SEE ALSO πŸ”₯


And that's the whole page, bestie! This little library call gem is brought to you by the DtWsmRemov...ceFunctions(library call) crew β€” mwah, love her, go remove some workspace functions responsibly πŸ’œπŸŽ€πŸ¦‹

πŸ“¦ where this page comes from