Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

make exwm-workspace-switch-to-buffer switch workspaces #201

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

fjl
Copy link
Contributor

@fjl fjl commented Oct 2, 2016

As per discussion in #200, I'd like to propose that exwm-workspace-switch-to-buffer should switch workspaces instead of pulling the buffer to the current workspace.

@ch11ng
Copy link
Owner

ch11ng commented Oct 2, 2016

Thanks! I've just tried this and it seems working for me. But I think it'd be better if you can make this a new command or some users may get confused by the change (and exwm-workspace-switch-to-buffer is naturally analogous to switch-to-buffer).

@fjl
Copy link
Contributor Author

fjl commented Oct 30, 2016

Sorry didn't have much time last few weeks.

What should it be renamed to? I thought exwm-workspace-switch-to-buffer made sense because of the analogy to exwm-workspace-switch. The best I can come up with is exwm-workspace-switch-by-buffer but then they're too similar...

@ch11ng
Copy link
Owner

ch11ng commented Oct 31, 2016

Perhaps simply exwm-workspace-switch-to-buffer-1?

@medranocalvo
Copy link
Collaborator

I'd say exwm-workspace-select-buffer, in analogy with select-* functions, particularly the interactive command select-frame-by-name.

Best regards,
Adrián.

@madnificent
Copy link

Is there interest in reviving this?

@timor
Copy link

timor commented Nov 13, 2020

Is there interest in reviving this?

I would be interested. Common use case for me: S-f switches to web browser buffer on my setup. Most of the time, I don't want to pull the browser into my workspace if it visible on another one. Since I do that quite often, it would save quite a bit of key strokes.

@2ndemosthenes
Copy link

@medranocalvo Any plans on merging this?
It's quite annoying.

@medranocalvo
Copy link
Collaborator

@2ndemosthenes, thank you for bringing this up.

I think it is a fine use case.

I don't think this should be implemented in EXWM (necessarily, see below).

In my view, a key feature of EXWM is that it lets us treat X windows as Emacs' buffers, thus apply Emacs' window management to X windows. With that I mean not only Emacs' default window management (other-window, etc.), but also evil or avy or shackle... To each their own.

The feature proposed here is the ability to select the window displaying a buffer in another frame instead of displaying the buffer in current window (where the buffer is an exwm-mode buffer, i.e., an X window).

Does Emacs already offer a way to do this?

If it does, we should write about it in the Cookbook, or showcase it in exwm-config-example. Maybe we should offer a function in order to ease configuration or discoverability, or maybe we should tailor the function to EXWM (for example, search only in EXWM workspaces).

If Emacs doesn't: it should! We should patch Emacs to support this.


...checks Emacs...

It seems to me that the following is Emacs' way of doing this:

(pop-to-buffer
 (read-buffer "Select buffer: " (other-buffer))
 '((display-buffer-reuse-window) . ((reusable-frames . visible))))

See also display-buffer-alist.


@2ndemosthenes
Copy link

Thanks you.

@medranocalvo
Copy link
Collaborator

@2ndemosthenes (and everyone else): I would appreciate your thoughts on the following:

If it does, we should write about it in the Cookbook, or showcase it in exwm-config-example. Maybe we should offer a function in order to ease configuration or discoverability, or maybe we should tailor the function to EXWM (for example, search only in EXWM workspaces).

@2ndemosthenes
Copy link

@medranocalvo
Yes, I think it would be very helpful to add it Cookbook or the config since many may want to do this but dont know how (or maybe think it can't be done)

@cherryramatisdev
Copy link

Do we have any workarounds to get this functionality right now? I would love to select an EXWM buffer and navigate to it's workspace properly

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants