search
HomeDevelopment ToolsnotepadNotepad++ changes the color or background color of selected text

The following tutorial column from notepad will introduce to you how to change the color or background color of selected text in Notepad. I hope it will be helpful to friends in need!

Notepad++ changes the color or background color of selected text

Notepad is a text editing tool. I won’t go into details about its advantages. It is small in size and powerful in functions. However, it is not user-friendly enough in terms of interface customization. A few simple settings such as foreground color, background color, font size, etc.

The solution to the problem seems to be very simple. Just change the background color of the selected text and it will be OK. But after searching for a long time, I couldn't find where to change the background color of the selected text in the Notepad settings. The "Settings" -> "Language Format Settings" option is too simple and does not match the powerful functions of Notepad. . It can definitely be changed, it just depends on where. I searched online and found no ready-made solution. Well, in this case, let’s directly change its configuration file.

Notepad configurations are all saved using xml files. The color scheme is saved in stylesrs.xml. This file is located in the root directory of the notepad installation file and is easy to find. Taking Notepad 6.2.3 as an example, open the styles.xml file. Of course, it is no problem to open it with Notepad. Find line 787 and note that there is this content: name="Selected text color", indicating that this line defines the color of the selected text. Continue to look back, bgColor="c0c0c0", the bgColor parameter is the background color of the selected text, just change it to the color you want. The lily sky is changed to bgColor=”000000″. After selection, it becomes completely black. The effect is good. Just change it to be darker than the global background color to distinguish it. This can be changed at will according to your own needs. Note that you must reopen notepad after saving the modifications for the configuration to take effect.

In addition, the following are some definitions of Notepad interface color settings. If you want to make more detailed color customization modifications, you can refer to the following documents.

Global Styles

Indent guideline style The color of the indent guideline
Brace highlight style The color of the frame when the mouse pointer is around the frame (such as {} in css () in js)
Bad brace color The color of the wrong frame (such as there is an error in {} in js, the color of this {})
Current line background color The background color of the current line pointed by the mouse
Selected text color The color of the selected text
Caret color The color of the mouse pointer
Line number margin The color of the line number
Fold The color of the hidden code button
Fold margin The color of the upper and lower background of the hidden code button
Smart HighLighting Double-click to select the background color of the text
Tags match highlighting The background color of the tag when the mouse pointer is on the current tag
Tags attribute The background color of the attribute and attribute value when the mouse pointer is on the current tag
Active tab focused Appears The background color of the selected document when the two-document interface appears.
Active tab unfocused The background color of the unselected document when the two-document interface appears (the first document in another view)
Active tab text The name of the current document Color
Inactive tabs Tag background color of unselected documents

CSS

DEFAULT Default foreground
TAG Tag name such as span h2
PSEUDOCLASS Pseudo-class style
UNKNOWN _PSEUDOCLASS Unclear pseudo-class style (including unfinished pseudo-class style)
OPERATOR Style punctuation such as {}:;
IDENTIFIER Attribute, identifier
VALUE Attribute value
COMMENT Explanation
IMPORTANT Important

HTML

##DEFAULT Default outlook

COMMENT Explanation
NUMBER Number
DOUBLESTRING Double quote character String
SINGLESTRING Single quote string
TAG Tag name such as span h2
TAGEND End of tag
TAGUNKNOWN Unclear tag (including unfinished tag)
ATTRIBUTE Attribute
ATTRIBUTEUNKNOWN No Explicit attributes (including unfinished attributes)
SGMLDEFAULT The word that declares the document (the top one of the html document)
VALUE The color of the value of the attribute (when this value is not enclosed in single quotes or double quotes)
ENTITY Special characters such as >:

JavaScript

WORD General words
KEYWORD Keywords
DOUBLE STRING Double quotation mark string
SINGLESTRING Single quotation mark string
SYMBOLS Punctuation such as {}:;
COMMENT Explanation
COMMENTLINE Single line Comment
COMMENTDOC Multi-line comment

For more notepad related technical articles, please visit the notepad column!

The above is the detailed content of Notepad++ changes the color or background color of selected text. For more information, please follow other related articles on the PHP Chinese website!

Statement
This article is reproduced at:csdn. If there is any infringement, please contact admin@php.cn delete
What is notepad What software notepadWhat is notepad What software notepadMar 06, 2025 pm 12:21 PM

This article compares Notepad and Notepad , highlighting Notepad 's superior features for coding. Notepad offers syntax highlighting, code completion, and extensive plugin support, unlike the basic functionality of Notepad. Therefore, Notepad

Introduction to Notepad's functionsIntroduction to Notepad's functionsMar 06, 2025 pm 12:19 PM

Notepad is a free, open-source text and code editor offering syntax highlighting, auto-completion, macro recording, powerful search, and a plugin system. Its advantages over other editors include enhanced code readability, efficient search/replace

What is notepad? What is notepad for?What is notepad? What is notepad for?Mar 06, 2025 pm 12:17 PM

This article describes Notepad, a basic Windows text editor. It details its functions—text editing, saving, opening, and searching—and limitations. While usable for simple text tasks, its lack of syntax highlighting, code completion, and debugging

Notepad How to display data in json formatNotepad How to display data in json formatMar 06, 2025 pm 12:15 PM

This article explains how to improve JSON data readability in Notepad . It focuses on using Notepad 's syntax highlighting and suggests external JSON formatters and validators for reliable formatting and syntax checking, as Notepad lacks built-i

Notepad installation detailed tutorialNotepad installation detailed tutorialMar 06, 2025 pm 12:10 PM

This article explains that Notepad is pre-installed in Windows and requires no installation. It addresses common issues accessing or using Notepad, offering troubleshooting steps. It also details installing the separate, more advanced text editor,

Notepad Setting Chinese Notepad How to Setting ChineseNotepad Setting Chinese Notepad How to Setting ChineseMar 06, 2025 pm 12:18 PM

Notepad lacks built-in language settings. To use Chinese, users must change their operating system's language settings to Chinese (Simplified or Traditional), then restart their computer or Notepad . Notepad 's interface language reflects the

How to convert notepad to json notepad to json shortcut keyHow to convert notepad to json notepad to json shortcut keyMar 06, 2025 pm 12:16 PM

This article explains how to convert unstructured Notepad text to JSON format. It highlights the lack of a direct conversion method, emphasizing the need for manual structuring or scripting (Python, JavaScript) for automation. Spreadsheet software

What is notepadWhat is notepadMar 06, 2025 pm 12:08 PM

Notepad is a free, open-source text and code editor. It excels at code editing via syntax highlighting for numerous languages, and also efficiently handles text editing, web development, and file manipulation. Its extensibility through plugins e

See all articles

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
2 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
Repo: How To Revive Teammates
1 months agoBy尊渡假赌尊渡假赌尊渡假赌
Hello Kitty Island Adventure: How To Get Giant Seeds
4 weeks agoBy尊渡假赌尊渡假赌尊渡假赌

Hot Tools

SAP NetWeaver Server Adapter for Eclipse

SAP NetWeaver Server Adapter for Eclipse

Integrate Eclipse with SAP NetWeaver application server.

EditPlus Chinese cracked version

EditPlus Chinese cracked version

Small size, syntax highlighting, does not support code prompt function

Dreamweaver Mac version

Dreamweaver Mac version

Visual web development tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

VSCode Windows 64-bit Download

VSCode Windows 64-bit Download

A free and powerful IDE editor launched by Microsoft