折叠/展开
pycharm设置
点击PyCharm--->Preferences--->Editor--->General--->Code Folding,勾选Show code folding outline
勾选后效果如图
快捷键
如图
行号显示
点击PyCharm--->Preferences--->Editor--->General--->Appearance,勾选Show line numbers
勾选后效果如图所示
点击PyCharm--->Preferences--->Editor--->General--->Code Folding,勾选Show code folding outline
勾选后效果如图
如图
点击PyCharm--->Preferences--->Editor--->General--->Appearance,勾选Show line numbers
勾选后效果如图所示