1. Set the eclipse color in Windows> preferences, as shown in 1.
Figure 1. preferences
2. General> appearance> colors and font, as shown in 2.
Figure 2. colors and font
You can set the font here.
3. General> editors> text editors, as shown in 3.
Figure 3. Text editors
The detailed description is as follows:
Line number foreground row number foreground color settings
Current line highlight current line highlight color settings
Print margin print margin color settings
Find scope color settings
Selection foreground color specifies the foreground color of the selected content.
Selection background color specifies the background color of the selected content.
Background color background color settings
Foreground color settings
Hyperlink hyperlink color settings
4. General> editors> text editors> annotations, as shown in figure 4.
Figure 4 annotations
C/C ++ occurrences C/C ++ variable highlight color setting at the cursor
5. C/C ++-> Editor, as shown in Figure 5.
Figure 5 Editor
The detailed description is as follows:
Matching brackets highlight matching bracket highlighted color settings
Inactive code highlight non-active code highlighting (for example, # statements with an if condition not met)
Completion proposal Background: Automatically complete the background color settings of the window
Completion proposal foreground automatically fills in the foreground color settings of the window
Parameter hint background
Parameter hint foreground
Source hover background source hover window background color settings
6. C/C ++-> Editor-> syntax coloring, as shown in 6.
Figure 6. Syntax coloring
The detailed description is as follows:
C/C ++
----- Editor Editor
----------- Syntax coloring
-------------------------- Enable semantic highlighting enable syntax highlighting
-------------------------- Element
--------------------------------- Code
------------------------------------- Braces brackets
------------------------------------- Built-in types built-in type name
------------------------------------- Classes, structs, unions class, struct, Consortium
------------------------------------- Enumerators enumeration Element
------------------------------------- Enums Enumeration type
------------------------------------- External sdk cils external software development kit call (for example, printf in stdio. h)
------------------------------------- Fields bit-field (bit-fields)
------------------------------------- Function declarations function name Declaration (Definition)
------------------------------------- Functions function name (reference)
------------------------------------- Global variables global variable
------------------------------------- Keywords (excluding built-in type names)
------------------------------------- Labels label
------------------------------------- Local variable declarations local variable definition
------------------------------------- Local variable references local variable reference
------------------------------------- Macro definitions macro definition
------------------------------------- Macro reference of macro references
------------------------------------- Method declaration in the method declarations class
------------------------------------- Methods method reference
------------------------------------- Namespaces
------------------------------------- Numbers Value
------------------------------------- Operators Operator
------------------------------------- Others ---- I don't know why the struct name actually belongs to another
------------------------------------- Overloaded operators
------------------------------------- Parameter variables function
------------------------------------- Problems
------------------------------------- Static fields static bit field (static bit-fields)
------------------------------------- Static method invocations
------------------------------------- Strings character and string
------------------------------------- Template parameters
------------------------------------- Type declared by typedefs
--------------------------------- Assembly Language
----------------------------------------- Directives command
----------------------------------------- Labels label
--------------------------------- Comments
----------------------------------------- Multi-line comment
----------------------------------------- Single-line comment single row comment
----------------------------------------- Task tags task tag
--------------------------------- Preprocessor preprocessing
------------------------------------------- Ctives command (preprocessing command starting)
--------------------------------------------- Headers header file
--------------------------------------------- Others
--------------------------------- Doxygen
---------------------------------------- Doxygen multi-line comment
---------------------------------------- Doxygen single-line comment
---------------------------------------- Doxygen tag
1. Braces brackets
() [] {}
2. Built-in types built-in type name
Char double
Float int
Long
Short signed
Unsigned void
_ Bool
_ Complex _ imaginary
3. Classes, structs, unions class, struct, Consortium (C ++)
4. Enumerators enumeration Elements
Enum test {zero, one, two} test;
In this example, zero, one, and two are enumeration elements.
5. enums Enumeration type
Enum test {zero, one, two} test;
In this example, test is of the enumeration type.
6. External sdk cils external software development kit call
For example, call the printf function in stdio. h.
7. Fields domain
A member variable defined in struct or union.
8. Function declarations function name and definition
9. Call the functions function name
10. global variables
11. Keywords keywords (excluding built-in type names)
Auto break
Case const
Continue
Default do
Else Enum
Extern
For GOTO
If inline
Register
Restrict return
Sizeof static
Struct
Switch typedef
Union volatile
While
12. Labels label
13. Local variable declarations local variable definition
14. Local variable references local variable reference
15. macro definitions macro definition
16. Macro references macro reference
17. method declarations class method declaration (C ++)
18. Method reference of the Methods class (C ++)
19. namespaces (C ++)
20. Numbers Value
21. Operators Operator
22. Others (I don't know why the struct name actually belongs to others)
23. overloaded operators overload operator (C ++)
24. parameter variables function
25. Problems (I don't know what it is)
26. static fields static domain
A member variable defined using static in struct or union.
27. static method invocations (C ++)
28. Strings characters and strings
29. template parameters (C ++)
30. typedefs uses the type declared by typedef