Hongmu Notes

🧹 Delete bracket content

Delete the four types of brackets and their contents, and retain the rest of the original text.

Delete bracket content

Instructions for use

  • After pasting the text, click "Start Processing" and the result will appear in the read-only box below.
  • A space will be left in the deleted position to avoid the adhesion of the preceding and following text.
  • The angle brackets will be deleted together with the label. Please back up the code before processing it.

Bracket text cleaning

When organizing text with various annotations into publishable plain text, the bracketed content is often the first part to be cleared.

📌 What to do after cleaning

Usually, extra spaces and consecutive blank lines need to be removed: this page only replaces the content in brackets with a space, and leaves the remaining blank spaces to the site's blank line and space cleaning tool.

📌 delete rule

The tool uses a regular rule to match four types of bracket pairs at the same time: Chinese parentheses, English parentheses, Chinese bookmarks, and angle brackets; each hit (including all characters within the brackets) will be replaced with a space. Therefore, it is a method of "matching paired brackets first, and then replacing them as a whole". Contents with unpaired brackets or across lines will not be processed, and the order of the original text and other characters remain completely unchanged.

🧭 Common uses

It is very easy to remove the supplementary descriptions in parentheses when organizing lists copied from documents or web pages, clean up aliases in "entries (aliases)" in batches, restore web page tagged fragments to plain text, and process citation titles with book titles. Since the change is to replace it with a space on the spot, use the blank line and space cleaning tool to go through it again after processing, and the result will be cleaner.

All keywords and tutorials 12

❓ FAQ

Will the punctuation be changed?
Punctuation outside brackets will not be changed.
Can it handle long documents?
Can. Tens of thousands of characters can be processed at once.
Recommended process for bracket cleaning
Delete the content in brackets → clear the spaces → read through and check, three steps.