ctrl+alt+L格式化不换行 打开“Settings”窗口 > 选择“Editor” > “Code Style”> “Python” > “Wrapping and Braces” > Hard wrap at 选项卡