[xmonad] Per-workspace Application Instances

Chris Bell cwbell at mail.usf.edu
Mon Aug 25 17:11:25 UTC 2014


Hi all,

I started using xmonad last week, and encountered very few problems
during configuration and use. It's nearly perfect for how I work. But
I've run into a bothersome issue.

There are times when I need to have dozens of PDFs readily available.
Since I started using xmonad, I switched to qpdfview for its tabbed
interface. Whenever I open a PDF from a file manager (xfe), qpdfview
is called with the --unique option, so that all new windows open as
tabs in the main window. The problem is that, if I want to then open a
PDF on a different workspace, I either need to create a new instance
of qpdfview, or use a different PDF viewer. A minor inconvenience, to
be sure. But then I realized that qpdfview has a --instance <name>
option, which I imagine could be used with xmonad's workspace
identifiers. So, any instance started in workspace 3 would be named
'd3', and qpdfview would be called with '--unique --instance d3'.

The problem is, I don't know where to start with this. My idea was to
use environment variables to identify the current workspace, but I'm
not sure how to. Any suggestions/ideas are greatly appreciated!

Regards,

Chris


More information about the xmonad mailing list