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

Add separate marker ring for goto-definition calls #44

Merged
merged 4 commits into from Apr 25, 2013

Conversation

immerrr
Copy link
Collaborator

@immerrr immerrr commented Apr 23, 2013

It's made to to facilitate popping back to where C-. was invoked.
Default keybinding is M-*.

It wasn't too hard, actually.

Feel free to ping me if you insist on having M-* key customized like the rest of the keybindings. Feel free to close the issue in favor of the pull-request (issue #42).

It's made to to facilitate popping back to where `C-.` was invoked.
Default keybinding is `M-*`.
@@ -334,6 +338,7 @@ toolitp when inside of function call.
(define-key map jedi:key-complete 'jedi:complete)
(define-key map jedi:key-goto-definition 'jedi:goto-definition)
(define-key map jedi:key-show-doc 'jedi:show-doc)
(define-key map (kbd "M-*") 'jedi:goto-definition-pop-marker)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add jedi:key-goto-definition-pop-marker so that it is configurable?

Also please document it in jedi:setup-keys and manual (doc/source/tail.rest).

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FWIW, I agree it should be configurable, more over, M-* has a global binding

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@yyr You are right, thank for the info.

How about C-, or C-*? Both are empty in plain Emacs. I took C-. from M-. of SLIME. SLIME binds M-, (and M-*) for pop so I think it makes sense.

(Stricktly speaking we should bind C-c + punctuation for minor mode but that's why I am not enabling it by default anyway.)

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

C-, , C-* are good as we have already C-.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@immerrr let's use C-, then

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@yyr, that's actually intentional. I wanted to provide intuitive transition from tags-based browsing to jedi:goto-definition. And you always can do (define-key jedi-mode-map (kbd "M-*") nil) if you miss those tags and don't like the idea. But if you insist... sure.

@tkf, M-. of SLIME was probably an exact same idea: they rebound find-tag function key (also a global binding) to avoid confusion :)

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@immerrr does this totally replace tag based navitaion.? if so I can vote for such keybinding, But after all nothing wrong in making configurable with a defcustom.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@immerrr If we want jedi:goto-definition-pop-marker to override pop-tag-mark, we should change jedi:goto-definition too. As we discussed in #42 (comment), we may change the default keybind and/or how they are configured soon. For the time being, I want make it consistent. What do you think?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tkf sure, no problem

@tkf
Copy link
Owner

tkf commented Apr 23, 2013

Thank you, except the minor points I mentioned it looks fine. I need to check travis failure before merging, though. Probably some package start using functions that are not in 23.

@immerrr
Copy link
Collaborator Author

immerrr commented Apr 24, 2013

Done.

Btw, speaking of key binding conventions, C-c <LETTER> should be reserved for user bindings, AFAIR.

@tkf
Copy link
Owner

tkf commented Apr 24, 2013

That's one of the reason why I am not activating it by default. And the reason why I was using that keybinding was to make it compatible with ropemacs. Probably I shouldn't take that keybinding in the first place.

tkf added a commit that referenced this pull request Apr 25, 2013
Add separate marker ring for goto-definition calls
@tkf tkf merged commit 40c51a6 into tkf:master Apr 25, 2013
@tkf
Copy link
Owner

tkf commented Apr 25, 2013

Merged. Thanks for patience!

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

Successfully merging this pull request may close these issues.

None yet

3 participants