-
Notifications
You must be signed in to change notification settings - Fork 119
Emacs built in features
This page describes useful Emacs built-in features for editing PHP code. PHP Mode is designed to work well with these Emacs built-in features.
When you are analyzing a long method in code reading, jumping out of the method by keyword search becomes a noise of understanding. Narrowing is a feature that allows you to display only specific parts of the buffer that you want to focus on.
If you execute M-x narrow-to-defun
while visiting a method/function, you will only see that function on your screen.
Want to see other functions in the same file? please do not worry. Execute M-x widen
to cancel narrowing.
Subword is a concept to treat CamelCase as word delimiter. PHP Mode does not have subword-mode
enabled by default, so run M-x subword-mode
to enable it. In PHP Mode's standard keybindings, pressing C-c C-w
toggles subword-mode
on and off.