1 /*******************************************************************************
2  * Copyright (c) 2000, 2013 IBM Corporation and others.
3  *
4  * This program and the accompanying materials
5  * are made available under the terms of the Eclipse Public License 2.0
6  * which accompanies this distribution, and is available at
7  * https://www.eclipse.org/legal/epl-2.0/
8  *
9  * SPDX-License-Identifier: EPL-2.0
10  *
11  * Contributors:
12  *     IBM Corporation - initial API and implementation
13  *******************************************************************************/
14 package org.eclipse.jdt.ui.text;
15 
16 /**
17  * Color keys used for syntax highlighting Java
18  * code and Javadoc compliant comments.
19  * A <code>IColorManager</code> is responsible for mapping
20  * concrete colors to these keys.
21  * <p>
22  * This interface declares static final fields only; it is not intended to be
23  * implemented.
24  * </p>
25  *
26  * @see org.eclipse.jdt.ui.text.IColorManager
27  * @see org.eclipse.jdt.ui.text.IColorManagerExtension
28  *
29  * @noimplement This interface is not intended to be implemented by clients.
30  * @noextend This interface is not intended to be extended by clients.
31  */
32 public interface IJavaColorConstants {
33 
34 	/**
35 	 * Note: This constant is for internal use only. Clients should not use this constant. The
36 	 * prefix all color constants start with (value <code>"java_"</code>).
37 	 */
38 	String PREFIX= "java_"; //$NON-NLS-1$
39 
40 	/** The color key for multi-line comments in Java code
41 	 * (value <code>"java_multi_line_comment"</code>).
42 	 */
43 	String JAVA_MULTI_LINE_COMMENT= "java_multi_line_comment"; //$NON-NLS-1$
44 
45 	/** The color key for single-line comments in Java code
46 	 * (value <code>"java_single_line_comment"</code>).
47 	 */
48 	String JAVA_SINGLE_LINE_COMMENT= "java_single_line_comment"; //$NON-NLS-1$
49 
50 	/** The color key for Java keywords in Java code
51 	 * (value <code>"java_keyword"</code>).
52 	 */
53 	String JAVA_KEYWORD= "java_keyword"; //$NON-NLS-1$
54 
55 	/** The color key for string and character literals in Java code
56 	 * (value <code>"java_string"</code>).
57 	 */
58 	String JAVA_STRING= "java_string"; //$NON-NLS-1$
59 
60 	/** The color key for method names in Java code
61 	 * (value <code>"java_method_name"</code>).
62 	 *
63 	 * @since 3.0
64 	 * @deprecated replaced as of 3.1 by an equivalent semantic highlighting, see {@link org.eclipse.jdt.internal.ui.javaeditor.SemanticHighlightings#METHOD}
65 	 */
66 	@Deprecated
67 	String JAVA_METHOD_NAME= "java_method_name"; //$NON-NLS-1$
68 
69 	/** The color key for keyword 'return' in Java code
70 	 * (value <code>"java_keyword_return"</code>).
71 	 *
72 	 * @since 3.0
73 	 */
74 	String JAVA_KEYWORD_RETURN= "java_keyword_return"; //$NON-NLS-1$
75 
76 	/** The color key for operators in Java code
77 	 * (value <code>"java_operator"</code>).
78 	 *
79 	 * @since 3.0
80 	 */
81 	String JAVA_OPERATOR= "java_operator"; //$NON-NLS-1$
82 
83 	/** The color key for brackets in Java code
84 	 * (value <code>"java_bracket"</code>).
85 	 *
86 	 * @since 3.3
87 	 */
88 	String JAVA_BRACKET= "java_bracket"; //$NON-NLS-1$
89 
90 	/**
91 	 * The color key for everything in Java code for which no other color is specified
92 	 * (value <code>"java_default"</code>).
93 	 */
94 	String JAVA_DEFAULT= "java_default"; //$NON-NLS-1$
95 
96 	/**
97 	 * The color key for the Java built-in types such as <code>int</code> and <code>char</code> in Java code
98 	 * (value <code>"java_type"</code>).
99 	 *
100 	 * @deprecated no longer used, replaced by <code>JAVA_KEYWORD</code>
101 	 */
102 	@Deprecated
103 	String JAVA_TYPE= "java_type"; //$NON-NLS-1$
104 
105 	/**
106 	 * The color key for annotations
107 	 * (value <code>"java_annotation"</code>).
108 	 *
109 	 * @since 3.1
110 	 * @deprecated replaced as of 3.2 by an equivalent semantic highlighting, see {@link org.eclipse.jdt.internal.ui.javaeditor.SemanticHighlightings#ANNOTATION}
111 	 */
112 	@Deprecated
113 	String JAVA_ANNOTATION= "java_annotation"; //$NON-NLS-1$
114 
115 	/**
116 	 * The color key for task tags in java comments
117 	 * (value <code>"java_comment_task_tag"</code>).
118 	 *
119 	 * @since 2.1
120 	 */
121 	String TASK_TAG= "java_comment_task_tag"; //$NON-NLS-1$
122 
123 	/**
124 	 * The color key for JavaDoc keywords (<code>@foo</code>) in JavaDoc comments
125 	 * (value <code>"java_doc_keyword"</code>).
126 	 */
127 	String JAVADOC_KEYWORD= "java_doc_keyword"; //$NON-NLS-1$
128 
129 	/**
130 	 * The color key for HTML tags (<code>&lt;foo&gt;</code>) in JavaDoc comments
131 	 * (value <code>"java_doc_tag"</code>).
132 	 */
133 	String JAVADOC_TAG= "java_doc_tag"; //$NON-NLS-1$
134 
135 	/**
136 	 * The color key for JavaDoc links (<code>{foo}</code>) in JavaDoc comments
137 	 * (value <code>"java_doc_link"</code>).
138 	 */
139 	String JAVADOC_LINK= "java_doc_link"; //$NON-NLS-1$
140 
141 	/**
142 	 * The color key for everything in JavaDoc comments for which no other color is specified
143 	 * (value <code>"java_doc_default"</code>).
144 	 */
145 	String JAVADOC_DEFAULT= "java_doc_default"; //$NON-NLS-1$
146 
147 	//---------- Properties File Editor ----------
148 
149 	/**
150 	 * The color key for keys in a properties file
151 	 * (value <code>"pf_coloring_key"</code>).
152 	 *
153 	 * @since 3.1
154 	 */
155 	String PROPERTIES_FILE_COLORING_KEY= "pf_coloring_key"; //$NON-NLS-1$
156 
157 	/**
158 	 * The color key for comments in a properties file
159 	 * (value <code>"pf_coloring_comment"</code>).
160 	 *
161 	 * @since 3.1
162 	 */
163 
164 	String PROPERTIES_FILE_COLORING_COMMENT= "pf_coloring_comment"; //$NON-NLS-1$
165 
166 	/**
167 	 * The color key for values in a properties file
168 	 * (value <code>"pf_coloring_value"</code>).
169 	 *
170 	 * @since 3.1
171 	 */
172 	String PROPERTIES_FILE_COLORING_VALUE= "pf_coloring_value"; //$NON-NLS-1$
173 
174 	/**
175 	 * The color key for assignment in a properties file.
176 	 * (value <code>"pf_coloring_assignment"</code>).
177 	 *
178 	 * @since 3.1
179 	 */
180 	String PROPERTIES_FILE_COLORING_ASSIGNMENT= "pf_coloring_assignment"; //$NON-NLS-1$
181 
182 	/**
183 	 * The color key for arguments in values in a properties file.
184 	 * (value <code>"pf_coloring_argument"</code>).
185 	 *
186 	 * @since 3.1
187 	 */
188 	String PROPERTIES_FILE_COLORING_ARGUMENT= "pf_coloring_argument"; //$NON-NLS-1$
189 }
190