What are these weird boxes in Eclipse/Aptana Studio - eclipse

Does anyone know what these really annoying boxes surrounding random code are in Eclipse? I've seen them come, go, grab the beginning and end of a word, I have no idea what they are supposed to mean. I'd really like to turn off the "feature" or figure out what they mean at least. Thanks!

This is for Aptana 3.2.1 on Mac, working with HTML.
To disable the boxes that encompass entire matching html tags:
preferences > general > editors > html tag pair occurrences; then uncheck "text as box."
Then, to disable the boxes around the matching angle brackets themselves:
preferences > aptana studio > editors; then uncheck "colorize matching character pairs.

If you are working in Windows with Aptana studio 3 you can turn it off this way:
Window > Preferences > General > Editors > Text Editors > Annotations
Inside there you find a box and select HTML Tag Pair Occurrences. Uncheck the box Text as.
However you also loose the good thing you get when you select a tag and it shows the matching tag. That's why I don't uncheck the box. Instead I chose Text as Vertical bar. It is easier to look at. Maybe you will also have to fiddle with Occurrences in the Annotations menu.
I think this is very bad done when they developed Aptana Studio. Who wants those default boxes? But I really do want to have the matching tag selected when I select one of them.

Related

Aptana tab indentation guides

I recently moved from geany to Aptana as I'm working on some bigger projects and felt I would benefit from a full IDE.
One feature I'm really missing is the little grey line every four spaces to help me maintain indentation consistency. Does anything like this exist for Aptana/Eclipse?
get the PDT tools Indent Guide plugin
Under
Preferences -> General -> Editor -> Texteditor you can activate "Show whitespace characters". If you click on "whitespace characters", you can define, which character should be displayed. Here you can active "Tabs". It's not as good as the lines from Notepad++, but better than nothing.
You can set a print margin indicator (vertical line) in Preferences > General > Editors > Text Editors - but this would only be a single line. You could use tabs instead of spaces - there are options to insert spaces when you use the Tab key. In this same menu, you can choose to show whitespace characters, which will help keep your spacing in order. I don't know of any grid options.

Cannot highlight all occurrences of a selected word in Eclipse

I tried using the Toggle mark occurrences (Alt + Shift + O) button and also in Preferences -> General -> Editors -> Text Editor -> Annotations and setting the C/C++ Occurrences and C/C++ Write occurrences. But still when I select a word it won't highlight all occurrences of that specific word.
What I am using is Eclipse Indigo Service Release 2 in XP, with a C++ project.
You can try to activate Toggle Mark Occurrences with icon on Toolbar:
Preferences --> Java --> Editor --> Mark Occurrences
In General > Editors > Text Editors > Annotations
Check out options that are checked in Preferences -> Java -> Editor -> Mark occurrences. Then restart Eclipse.
Find the Preferences under Window,
In General > Editors > Text Editors > Annotations(1)
(5) is to select the color and press apply.
The standard "Mark Occurrences" functionality included in Eclipse that everyone recommends only highlights identifiers in editors of whatever language. For example, it won't highlight int in C editors, and it won't help at all in the Console pane.
So if you want to highlight ALL occurrences on ANY word in ANY Eclipse pane (kinda like Notepad++ does), try the Glance plug-in for Eclipse.
As of November 2017 Glance works for Eclipse Neon and Oxygen. There was a period of time in which Neon was unsupported, and a fork appeared, but it seems unnecessary now (and abandoned).
There are two ways to highlight all occurences. First is using Eclipse options, which is not very reliable, because in many versions of Eclipse it is not supported.
Second is using a plugin called Glance which is available in Eclipse marketplace. This is supereasy and effective.
First Method
In the toolbar, there is button for Toggling Mark Occurrences. So, once you selected the text/word whose occurences you wish to highlight, then click this toggle button.
Let's say this step doesn't work for you. Then, Follow this step:
Goto: Window ==> Preferences ==> General ==> Editors ==> Text Editors ==> Annotations ==> On right Annotations types box: Occurrences ==> Select all check boxes.
You can also go to Window ==> Preferences ==> Java ==> Editor==> Mark Occurrences ==> Check all the checkboxes.
Restart Eclipse and check if highlighting works.
If still doesn't work, then Go to Second Method
Second Method
From Eclipse marketplace, install Glance. Once installed, restart Eclipse.
Now select any word in your eclipse editor
Move focus to component where you want to search
Open Glance using Ctrl + Cmd + F shortcut on Mac or Ctrl + Alt + F on other platforms
Enter text you want to search
Use Enter or **Shift + Enter** to find next/previous match
Close search box using Esc
You can also customize Glance from Window ==> Preferences ==> Glance
For Eclipse Mars:
Window --> Preferences --> Check (Mark occurrences of the selected element in the current file.)
As shown if figure:
Go
Java> Editor > Mark Occurrences
Uncheck "Keep Marks when the section changes" then click Ok
Restart Eclipse.
This work for me.
If you go into the window-prefrences, select the language you want/are working with. Select the editor under this specific language and then there is a mark occurrences there that has some options. Where it says keep marks when the selection changes, for me this was checked. When I unchecked it the system started highlighting correctly.
For folks who are using a dark background with light font colors, you may want to check out the highlight color in Preferences -> General -> Editors -> Text Editor -> Annotations. Mine was defaulted to black, which does not stand out on a black background.
Glance does not work anymore, but in current Eclipse Versions (Eclipse 2020) you can
highlight any word by selecting the word and pressing CTRL+F. The word is now highlighted. In the small search input, you can toggle 'match whole word' and case sensitivity.
I'd like to complement the other answers - which work in Java editor only or require plugins - with a way to highlight all occurrences of any text (not just a word or identifier) in any editor of text files (e.g. SQL, CSV, HTML, TXT, Java, etc ...).
There is a standard/built in command called Find Text in File (under Window -> Preferences -> Keys)
By default it has no keyboard shortcut assigned. Simply give it a shortcut (e.g. Ctrl+Alt+S) select some text (not necessarily a word) and it will find and highlight all occurrences of that selected text.
It can also be invoked from the menu as Search -> Text -> File.
Enjoy 🙂
Click the word and hold until a popup appears as shown in the figure.
On the popup, there is a little right arrow, after clicking it, a new icon shows up.
Click that link to open preferences.
Once in preferences, select C/C++ Occurrences (it will be language specific) and select Include in next/previous navigation with Text as Highlighted.
This should enable the feature of highlighting all occurences of the selected word in the opened file.

How to disable camel case selection in Eclipse

Is it possible to disable support for camel case in the Eclipse text editor? I want the next word key binding to select the next word, not the next fragment of a word.
I'd given up on eclipse because the editor doesn't work like any other text editor on Mac OS X. But I'd really miss code-completion and am trying to make Eclipse to adapt to my conventions.
Thanks.
Mark
Do you mean this?
Windows > Preferences > Java > Editor: uncheck Smart caret positioning in Java names

Eclipse: I turned on hidden characters now I can't turn off

Somehow I've turned on hidden characters in Eclipse. It's not the "whitespace" characters in the general editor preferences. When turned on, it adds another layer of hidden characters over the existing ones.
Then I have things like
\r\n
Does anyone know what these are and how to remove them?
It is under Preferences > General > Editors > Text Editors. There is a checkbox labeled "Show whitespace characters". If you uncheck this the editor switches back to normal.
If you click on the link (whitespace characters) (<= v3.6) or (configure visibility) (>= v3.7) in this line you will get a popup window, in which you can define which characters eclipse is supposed to consider as whitespace characters.
In this popup window you also get the option to define the transparency in which each whitespace character is displayed in the editor, which you can use to (indirectly) change their foreground colour. I'm just mentioning it here, because it took me about half an hour to find this setting! ;-)
There is a toggle button 'Show Whitespace Chars' on the Eclipse toolbar
A great tip about using 'quick access' from eclipse forum:
CTRL+3 swc
Allows to turn them on and off
The right shortcut is Ctrl + N
UPDATE From Eclipse 3.7 version, something is changed... Now you have to go to:
Window > Preferences > General > Editors > Text Editors
CTRL + . does the job.
For Aptana Users
To toggle hidden characters in Aptana on and off, use the following keyboard shortcut:
Ctrl+Alt+W
I am using Eclipse Oxygen and can see this option to toggle whitespace characters:
It is actually in two places...
Sandkastenliga points out the obvious one, but you can also show white space with a shortcut key combination. The key combination is separate from the text editor preferences and will superimpose additional characters when active (it uses \r and \n for carriage return an line feed respectively instead of the symbols used by the text editor preference.)
Go to preferences > general > keys and look for the binding for the 'Show Whitespace' command.
I have the text editor preference turned on, so I removed the binding for this command altogether (it was set to Ctrl+. in my profile) to prevent accidental activation as it doesn't affect the other preference.
Go to Window > Preferences > General > Editors > Text Editors
Uncheck the "Show whitespace characters" option on the right side of the page, then click "Apply" at the bottom of the page.
Since this is not a standard setting, it could be the result of one of your extra plugin.
Did you try starting your eclipse with the -clean parameter?
Do you reproduce the issue with a fresh Eclipse installation?
Go to Preferences > General > Editors > Text Editors and restore defaults.
I have done this several times by accidentally hitting some keystrokes.
If you go to Windows/Preferences/General/Keys you will see all the keyboard shortcuts you have.
Mine is set to Control + .
I had to place my cursor inside the document and do it a couple of times to make it work because there is also a keyboard shortcut for Control +
Hope that helps.
You can add "Show Whitespace Characters" button in toolbar by customizing your perspective.
It also contains buttons to toggle word wrap, and toggle selection mode.
Go to Window > Perspective > Customize Perspective > Action Set Availability, then select "Editor Presentation" action set:
This works in Eclipse Neon.
You can also add a key binding for this action.
Go to Preferences > General > Keys > "Show Whitespace Characters"
Sorry this is a bit vague but it's a while since i used Eclipse and i do not have it installed. I think this is it ..... in one of the menus you will find the Eclipse settings, there are two set's of settings, current project and overall Eclipse, you mat need to check them both. In there are various menus in tree form that allow you control the actions and look and feel. But some of them are nested so there is an overall control but some packages have their own options in a sub menu set. The menu's will expand when you click them and i'm afraid you need to walk through them all.
Eclipse > Preference > General > Editors > Text Editors > Show WhiteSpace characters.

Turn off tooltips in Eclipse / Aptana

I don't know if anyone has noticed that Eclipse has this annoying feature where it needs to show a useless tool-tip when hovering just about anything.
I was wondering if anyone knows of a way to completely kill all tool-tip behavior in Eclipse / Aptana?
Thanks
I found mine in Window > Preferences > Pydev > Editor > Hovers
It looks like it's a module-level feature (Java, Pydev, C++), not platform-level (Eclipse itself).
Window > Preferences > Java > Editors > Hovers
Disable Combined Hover.
I agree, hints can be really annoying, but there are times when they can be a really useful quick reference - like finding var values during debugging, or required parameter types for a method etc.
So instead of disabling them altogether, or continually enbaling/disabling through the Preferences, I go to Window > Preferences > Java > Editor > Hovers > Combined Hover, and add Alt to the Pressed key modifier while hovering field below.
This way if you want to quickly see hints just hold the Alt key down.
I was completely annoyed with Aptana's tip tool text over my code. I figured out how to disable it:
Window > Preferences > Aptana Studio > Content Assist > Show information on hover > Off
I'm using Aptana 3.
Another thing which really annoys me on Eclipse are the light bulbs in the left part which hide breakpoints, and which are really useless.
To suppress these, go to windows>preference>java>editor and then uncheck "Light bulb for quick assists".
If you dont have this on your eclipse version, try a help search with "light bulb".
This is the answer. Change the Windows regedit.
HKEY_CURRENT_USER ->Control Panel -> Mouse -> mouse -> MouseHoverTime
Change its value to be 400 (4 seconds delay)
http://untamedmind.wordpress.com/2008/11/08/changing-the-mousehovertime-add-delay-on-the-tooltips-pop-up/
Look for TweakUI settings, under Mouse > Hover. Minimize the sensitivity and increase the time and you will, in most cases, be fine.
Note that this is under windows. In any case, search for "hover" and you should be able to find the correct location. Good luck!