Community
Participate
Working Groups
Created attachment 182465 [details] File Search Dear all, I've posted my problem to the forum but get no answer - after a year. http://www.eclipse.org/forums/index.php?t=msg&goto=637192&S=411a787b391ffc151ecd9eae7fa4aa58#msg_637192 I use "File Search" instead of "C/C++ Search", because "C/C++ Search" can't find all the entries, perheps due to the reason we use some Non-ANSI-C Standard keywords, i don't know, whatever. "File Search" is cool, i can specify within which files to search - much better than CodwWright - which i used before. Unfortunately, it doesn't highlight the keywords in "search view", as you can see in the attachment. "C/C++ Search" does. Peopel says it works by them, but not by me. Thanks. Mike P.S.: This effect may be another naiv question for you guys, but it has bothered me for a really long time. :(
The File Search is language-agnostic, so you won't get any syntax coloring in the Search view. But highlighting of the matched characters works for File Search. Just make sure you have "Preferences > General > Appearance > Use mixed fonts and colors for labels" checked.
Hi, Markus, thanks again for your quick answer...:) But it doesn't work...i've checked/unchecked/checked/unchecked this option for many times...but still i can't get them highlighted. Regards, Mike
I see the problem (ugly) when looking at the code: Search uses a color key which is contributed by JDT and I assume in your case JDT is not installed and hence the matches aren't highlighted because the color definition is not available.
Fixed in HEAD. Available in builds >= N20101108-2000. Mike, if you can't switch to the latest build, you can either add JDT to your install or add the following extension to any plugin.xml: <extension point="org.eclipse.ui.themes"> <colorDefinition label="%coloredLabels.match_highlight.label" categoryId="org.eclipse.jdt.ui.presentation" value="206,204,247" id="org.eclipse.jdt.ui.ColoredLabels.match_highlight"> <description> %coloredLabels.match_highlight.description </description> </colorDefinition> </extension>
Created attachment 182626 [details] Conflict CDT - JDT
Hi Dani, thanks for your help. In the solution you provided, something i can't figure out, :( Solution 1: Where can i get N20101108-2000? What is it? Eclipse-Build or CDT-Build or JDT-Build? Solution 2: Add JDT? I've already CDT installed, as i tried to install JDT, i got the error as in attachment. Solution 3: Add extension. I tried add this extension into C:\Programme\eclipse-cpp-helios-win32\eclipse\plugins\org.eclipse.platform_3.6.0.v201006080911\plugin.xml. But it doesn't help. Regards, Mike (In reply to comment #4) > Fixed in HEAD. > Available in builds >= N20101108-2000. > > > Mike, if you can't switch to the latest build, you can either add JDT to your > install or add the following extension to any plugin.xml: > <extension > point="org.eclipse.ui.themes"> > <colorDefinition > label="%coloredLabels.match_highlight.label" > categoryId="org.eclipse.jdt.ui.presentation" > value="206,204,247" > id="org.eclipse.jdt.ui.ColoredLabels.match_highlight"> > <description> > %coloredLabels.match_highlight.description > </description> > </colorDefinition> > </extension>
>Solution 1: Where can i get N20101108-2000? What is it? Eclipse-Build or >CDT-Build or JDT-Build? This is a nightly build for 3.7 which will be produced tonight. It's the Eclipse SDK which contains JDT but not CDT. >Solution 2: Add JDT? I've already CDT installed, as i tried to install JDT, i >got the error as in attachment. Strange. Maybe you mixed versions? You should use the install manager (Help > Install New Software...) to add JDT. I guess for you the simplest fix is to paste the extension into one of the plugin.xml files.
>Maybe you mixed versions? Not 100% sure but it looks like you tried to mix 3.6.0 with 3.6.1.
> Solution 3: Add extension. I tried add this extension into > C:\Programme\eclipse-cpp-helios-win32\eclipse\plugins\org.eclipse.platform_3.6.0.v201006080911\plugin.xml. > But it doesn't help. You probably have to start once with -clean on the command line to refresh the extension registry. Or it failed because the categoryId could not be found. Please try this (should show up on the "Colors and Fonts" preference page in the "Basic" category): <extension point="org.eclipse.ui.themes"> <colorDefinition label="Colored labels - match highlight" categoryId="org.eclipse.ui.workbenchMisc" value="206,204,247" id="org.eclipse.jdt.ui.ColoredLabels.match_highlight"> <description> The background color used to highlight matches in the Search view when colored labels are enabled. </description> </colorDefinition> </extension>
I am so...............oo happy, yes, it works now! Hug, hug, cheer, cheer Many thanks to Dani, to Markus...
> Or it failed because the categoryId could not be found. Please try this FYI: categoryId - the optional id of the themeElementCategory this color belongs to. ;-)
Verified in I20101206-1800.
*** Bug 343880 has been marked as a duplicate of this bug. ***