📐 Auto Indent Tool

選項

📋 結果

請輸入文本...

📚 深度解析:文本縮排

💡 常見使用場景

  • 程式碼格式化:為選中塊統一加 2/4 空格或 Tab 縮排。
  • 引用與列表排版:給段落批次加懸掛縮排。
  • 多級結構展示:按層級加縮排,呈現樹狀層級。
給 3 行加 4 空格
貼上 3 行文字,設縮排 4 空格,每行前補「 」,輸出整齊縮排塊;用於把草稿快速變程式碼註釋或引用樣式。

❓ 常見問題(FAQ)

空格和 Tab 怎麼選?
團隊規範優先;Python 一般 4 空格、Makefile 必須 Tab。建議統一一種,混用會導致部分語言縮排報錯。
已有縮排會疊加嗎?
預設在原有基礎上加;如需「設為固定縮排」請先去舊縮排或用「替換模式」,避免越縮越深。

Formula & Standard References

Item Formula / Note Source / Standard
Indent unit indentation uses spaces or tabs whose tab width changes alignment ECMA-262, white space
Level detection indent levels follow bracket depth so structure must be parsed first ISO/IEC 9899:2018, C language
Mixed indentation mixing spaces and tabs misaligns code across editors PEP 8, style guide for Python
⚠️ 使用說明與注意事項