23👍
✅
You navigate to the top of the file using Ctrl+Home. It moves cursor too. So does navigating via Page Up and Page Down keys.
Ctrl+Up and Ctrl+Down move the view without moving cursor but scrolling the long file takes some time.
Additionally You can change the keymap (Settings > Keymap). There is ‘Scroll to Top’ in ‘Editor Actions’. You can use Your own key binding for this action, by default (in PyCharm 4 and later) it is not set.
- [Django]-What is @permalink and get_absolute_url in Django?
- [Django]-How should I write tests for Forms in Django?
- [Django]-With DEBUG=False, how can I log django exceptions to a log file
1👍
Another way is to navigate to the first line using goto line: Ctrl–G and then 1. But this will move the cursor to the first line.
A small disadvantage is it is a two step process and adds a navigation step. Moving back to your previous location with CtrlAlt–< will have to be done in two steps if you do an edit.
- [Django]-Django – Site matching query does not exist
- [Django]-Django – form has no errors but form.is_valid() doesn't validate
- [Django]-How to stream an HttpResponse with Django
Source:stackexchange.com