Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

[Q] telling M-x man to no open a split and behave like a normal buffer #7346

Closed
ninrod opened this issue Oct 10, 2016 · 9 comments
Closed

[Q] telling M-x man to no open a split and behave like a normal buffer #7346

ninrod opened this issue Oct 10, 2016 · 9 comments

Comments

@ninrod
Copy link

ninrod commented Oct 10, 2016

how can I tell M-x man to not split up my frame and only take over the current window?
I want also that the man buffer starts with evil-normal-state and not with Man-mode-map.

is that possible?

tks in advance.

@TheBB
Copy link
Collaborator

TheBB commented Oct 10, 2016

Configure it in popwin?

I don't even have an M-x man. What is that?

@TheBB
Copy link
Collaborator

TheBB commented Oct 10, 2016

I want also that the man buffer starts with evil-normal-state and not with Man-mode-map.

evil-set-initial-state

@ninrod
Copy link
Author

ninrod commented Oct 10, 2016

@TheBB, are you sure? because I've just started emacs with emacs -Q and M-x man is shown. edit: my emacs version is: GNU Emacs 25.1.50.1

well, it simply show for you a man page after showing you a searchable list of all the man pages that exist in your machine. really useful.

@ninrod
Copy link
Author

ninrod commented Oct 10, 2016

evil-set-initial-state

I tried this, but did not work:

(evil-set-initial-state 'Man-mode 'evil) (fails with: Warning (initialization): An error occurred while loading ‘/Users/ninrod/.emacs.d/init.el’: Attempt to set a constant symbol: nil

I know that this works, but I don't want emacs. I want evil-normal-state.

(evil-set-initial-state 'Man-mode 'emacs)

@TheBB
Copy link
Collaborator

TheBB commented Oct 10, 2016

If you want evil-normal-state why are you setting the intial state to evil? Set it to normal.

@ninrod
Copy link
Author

ninrod commented Oct 10, 2016

'normal did the trick. update: here is a list of valid evil states.

How I would prevent M-x man to stop opening a new split though. That remains a mistery.

@TheBB
Copy link
Collaborator

TheBB commented Oct 10, 2016

Man-notify-method is a variable defined in ‘man.el’.
Its value is ‘friendly’

Documentation:
Selects the behavior when manpage is ready.
This variable may have one of the following values, where (sf) means
that the frames are switched, so the manpage is displayed in the frame
where the man command was called from:

newframe -- put the manpage in its own frame (see ‘Man-frame-parameters’)
pushy -- make the manpage the current buffer in the current window
bully -- make the manpage the current buffer and only window (sf)
aggressive -- make the manpage the current buffer in the other window (sf)
friendly -- display manpage in the other window but don’t make current (sf)
polite -- don’t display manpage, but prints message and beep when ready
quiet -- like ‘polite’, but don’t beep
meek -- make no indication that the manpage is ready

Looks like you want pushy.

@TheBB
Copy link
Collaborator

TheBB commented Oct 10, 2016

How to find options for man: M-x customize-group man

@ninrod
Copy link
Author

ninrod commented Oct 10, 2016

thank you @TheBB.

@ninrod ninrod closed this as completed Oct 10, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants