HowTo change the PHP CodeSniffer marker icon¶
- Choose a new icon, for example
- Copy this image icon to <path to your Eclipse>/plugins/org.phpsrc.eclipse.pti.tools.codesniffer_X.X.X.RXXXXXXXXXXXXXX/icons
- Open <path to your Eclipse>/plugins/org.phpsrc.eclipse.pti.tools.codesniffer_X.X.X.RXXXXXXXXXXXXXX/plugins.xml with a text editor
- Add the following code to the end of plugin.xml file, but before the closing plugin tag
<extension point="org.eclipse.ui.editors.annotationTypes"> <type name="org.phpsrc.eclipse.pti.tools.codesniffer.validator.phpToolCodeSnifferAnnotation" super="org.eclipse.ui.workbench.texteditor.error" markerType="org.phpsrc.eclipse.pti.tools.codesniffer.validator.phpToolCodeSnifferMarker" markerSeverity="2"> </type> </extension> <extension point="org.eclipse.ui.editors.markerAnnotationSpecification"> <specification annotationType="org.phpsrc.eclipse.pti.tools.codesniffer.validator.phpToolCodeSnifferAnnotation" icon="icons/exc_catch.gif" quickFixIcon="icons/exc_catch.gif" textPreferenceKey="highlight.text" colorPreferenceKey="highlight.color" highlightPreferenceKey="highlight.background" overviewRulerPreferenceKey="highlight.rulers.overview" presentationLayer="4" label="PHP_CodeSniffer Error" textStylePreferenceKey="highlight.text.style"> </specification> </extension> - Change the icon and quickFixIcon attributes to your icon filename
- Save the plugin.xml file
- Restart your Eclipse with the -clean start-up flag
For more information about annotation specification options see http://help.eclipse.org/helios/index.jsp?topic=/org.eclipse.platform.doc.isv/reference/extension-points/org_eclipse_ui_editors_markerAnnotationSpecification.html