How to enable syntax highlighting and 4-space indentation for Python in Emacs

  • Thread starter MaxManus
  • Start date
2 replies · 3K views · last reply
MaxManus
Messages
268
Reaction score
1
Hello, does anyone know how to get Emacs to color words like "def, class, or, and" etc.. and to give me the right indentation, 4, when I press TAB?

Is it just save as program_name.py?
 
M-x python-mode? (That's Alt+x and then type "python-mode")