RevealTheme logo

文字清理工具

移除多餘的空白字元、正規化換行符、修正彎引號,並清理貼上而來的文字。

如何使用本工具

  1. 1

    Paste your messy text into the input box.

  2. 2

    Toggle the options you want: trim lines, collapse spaces, remove line breaks, replace tabs, and fix smart quotes.

  3. 3

    Read the cleaned result in the lower box, which updates live as you type or change options.

  4. 4

    Click 'Copy clean text' to copy the result to your clipboard.

什麼是文字清理工具?

從PDF、網站或Microsoft Word中貼上的文字,通常會帶有隱藏的雜質:彎引號、長破折號、軟連字號、雙空格、行尾空格,以及定位字元與空格的混用。本工具會將這一切正規化為乾淨的純文字,可直接貼上到程式碼編輯器、CMS表單或其他要求嚴格的環境中。

常見使用場景

  • Cleaning a quote pasted from a Word document before dropping it into source code, where curly apostrophes would cause syntax errors.

  • Flattening multi-line text copied from a PDF into a single line for a spreadsheet cell or search field using the remove-line-breaks toggle.

  • Removing the trailing spaces and tab-indented lines that sneak in when copying from a chat app or rendered web page.

  • Normalizing en-dashes and em-dashes to plain hyphens so a CSV or plain-text export stays ASCII-safe.

  • Tidying marketing copy pasted into a CMS field so double spaces after sentences collapse to single spaces.

  • Preparing a code comment or commit message by stripping the smart quotes and ellipses an editor auto-inserted.

常見問題

為什麼彎引號是不好的?
它們會破壞程式碼語法、損壞CSV匯出,並且在某些環境中無法正確顯示。用於文件沒有問題;但用於技術內容時,請將其替換掉。

相關工具