Eclipse CDT spell-check in XML (non-C++) files - eclipse

In Eclipse Oxygen with CDT I can configure spell checking for most file types under
Preferences > General > Editors > Text Editors > Spelling
However for XML files, which are apparently opened in the "Structured Text Editor", I can not find such an option.
Is this hidden somewhere or covered by a good plug-in?
Update
The user guide mentions spell-checking for "Structured Text Editor", but that does not match the actual UI; neither "Window > Preferences > Spell Check" exists as described nor "Edit > Spell Check":

EDIT:
Seems to be a known bug / feature request:
https://bugs.eclipse.org/bugs/show_bug.cgi?id=185695
https://bugs.eclipse.org/bugs/show_bug.cgi?id=521658
Possibly installing Java tooling on top would fix.
NOT HELPING:
The eclipse help has an article on this:
http://help.eclipse.org/kepler/index.jsp?topic=%2Forg.eclipse.wst.sse.doc.user%2Ftopics%2Ftsrcedt010.html
Also Eclipse should have an "Open With" context menu entry by which you could open as a text file, and have spell check.

Related

How do you enable word-wrap by default in Eclipse?

Simple question: how do you enable word-wrap by default in Eclipse? I looked at this plugin but it only goes up to Luna. In addition, this plugin is a separate text editor and does not have syntax highlighting or validation. I'm open to other suggestions.
Word wrap is available in Eclipse Neon IDE: https://www.eclipse.org/neon/noteworthy/#_word_wrap_in_text_editors.
Just consider using the latest version.
Keyboard shortcut: Alt+Shift+Y
Or button:
Or menu Window > Editor > Toggle Word Wrap:
As pointed out by #KrisWebDev in this answer, Eclipse supports soft line/word wrapping as of Eclipse Neon but the GUI to control this setting does not exist yet. There should be a global settings to enable soft word wrapping by default in any text editor in Window > Preferences > General > Editors > Text Editors > Enable Wordwrap and it is not there.
Instead, you have to manually edit the org.eclipse.ui.editors.prefs file (.metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.ui.editors.prefs) in your eclipse workspace. There, you can add the settings wordwrap.enabled=true.
For windows this worked for me(change workspace6 if not works), open settings file
%APPDATA%\DBeaverData\workspace6\.metadata\.plugins\org.eclipse.core.runtime\.settings\org.eclipse.ui.editors.prefs
add
wordwrap.enabled=true

How can I check the spelling in plain text files in eclipse c/c++ edition?

I'm using the Eclipse IDE for C/C++ Developers, Luna Release (4.4.0).
I enabled the spell checking (Preferences: General->Editors->Text Editors->Spelling: Enable Spell Checking) and I'm using a user defined dictionary.
The spell checking works perfect in C/C++ source files but I am puzzled how to do the spell checking of texts in plain text files.
There is no automatical spell check or options like "Do spell check" in the context menu or in the main menu.
What am I missing?
Since this is still open, a workaround:
I am having a similar problem with getting the Eclipse Luna CDT C/C+ spell-checking engine to handle standalone *.dox files (no problem with inline Doxygen comments within source files).
The only workaround I could find (http://thomasplagwitz.com/2015/03/02/getting-eclipse-cdt-to-spell-check-non-source-files/) was renaming my *.dox files to something that the spell checker seems to consider relevant, like *.dox.cpp.
Hth

How can I change Eclipse color scheme for a specific file extension?

I've installed Eclipse Debugger Plugin for v8.
When a Javascript file is brought up from the remote connection, it has a .chromium extension.
Acutal color scheme for *.chromium files is not ideal but I haven't been able to figure out how to change it.
I went into Window > Preferences > General > Editors > File Associations and changed *.chromium file association from "JS Editor" to "JavaScript Editor" (used for .js files edition, and having the color scheme I want.)
However making this change had no effect.
I have the "Eclipse Color Theme" add-on installed and am using Eclipse version 4.2.1.M20120914-1800 running on windows 7.
Once I right clicked on one of the .chromium files and selected "Open With->JavaScript Editor" that file came up with the same editor as the js files. Doing this once must have fixed something in eclipse because now subsequently all .chromium files open up with the other editor.

How do I enable spell checking in Eclipse?

Is there any way to enable code spell checking in Eclipse? I misspell words fairly often.
For example:
void spllmstake() => void spellmistake()
Eclipse has a built-in Spell Checker. Go to Window > Preferences > General > Editors > Text Editors > Spelling to enable it.
I have found a spell checker and proved it (with your example), and it seems to work. Do the following steps:
Download espell checker as zip file
Call Help > Install New Software > Add... > Archive...
Insert the path and file name of the zip file.
Do the normal installation with restart
Go to Window > Preferences > Spelling > AspectJ, Java, ...
Ensure that Check Names is selected.
In your example, the word spllmstake is marked as wrong, as is spellmistake. spellMistake (like two words) works well.
I have founded spell checker from eclipse marketplace. It is JDT spell checker and here is the description
The aim is to provide spelling support for words contained in the
names of Java artifacts: Interfaces, Classes, Methods, ... Splitting
out the names using regular naming patters for Java names.
Eclipse marketplace - http://marketplace.eclipse.org/content/jdt-spelling#.U8drE7E3n34
Git hub - https://github.com/hendrens/jdt.spelling

How to configure eclipse to autosave on run?

I'm looking for a configuration or plugin for eclipse that automatically saves files (so I don't have to use Ctrl+S). It could do it on lost focus or over some period of time. I think I saw something like that (I know IDEA has it), but I cant find it now.
Update seven years later (Eclipse Neon 4.6)
Eclipse now has an Automatic Save of dirty editors
The autosave option is disabled by default.
A new autosave preference page (Preferences > General > Editors > Autosave) is available and allows to enable/disable the autosave and change the interval of autosave.
The countdown is reset on keyboard activity, mouse click, or when a popup is displayed (e.g. content assist, preference page, ...).
Original answer (2009)
The OP IAdapter added in the comments:
I bet plugin like I describe exists.
... and you are right!
Eclipse plugin saveDirtyEditor should do just what you need.
Copy the SaveDirtyEditors_1.0.2.jar in your plugin directory.
You will get a new preference page under
General > Editors > Text Editors > Save Dirty Editors
, allowing you to save dirty files like 'myfile.java' under 'myfile.java.snapshot' every 30 seconds (can be less if you want).
Without additional plugin, though, Eclipse does not support natively that feature.
The closest could be:
Window > Preferences > type "build"
> General > Workspace > [x] Save automatically before build
That way, each time you hit CTRL+B for actually building your sources, they would be saved.
But I realize this is not exactly what you are after.
Beware your option would not be very efficient with the "build automatically" option activated... (that would trigger too much builds)
Again, without achieving exactly what you are looking for, you also have:
Run/Debug > Launching > Save required dirty editors before launching
Run/Debug > Launching > [x] Build (if required) before launching
Note: the difference between IntelliJ IDEA and eclipse is the "compile on save" feature:
As mentioned in the IDEA FAQ:
Q:
Can I enable "compile on save" in IntelliJ IDEA?
IntelliJ IDEA currently doesn't support this feature.
However there is an "Eclipse-mode" plug-in which provides similar functionality, so we suggest you to try this plug-in.
Note that by default IntelliJ IDEA saves the files for you, so you don't have to press the Ctrl+S shortcut frequently like you need to do in other IDEs.
However, with Eclipse, the "build on save" is activated by default, hence the absence of that particular feature.
http://code.google.com/p/eclatosa/
"Saves all open editors in eclipse when deactivating the eclipse window (like in IntelliJ)"
No need to install more plugin.
Window -> Preferences -> General -> Workspace
and there you can check:
Save automatically before build + Build automatically
If that doesn't work try this:
Preferences -> Run/Debug -> Launching -> Save dirty editors before launching
I wrote a plugin a long time ago to do this that still seems to work: http://www.stateofflow.com/projects/71/save-me
It saves the editor when it loses focus. However, if you switch away from eclipse it doesn't notice.
Try this
Goto Eclipse Preferences > General > Editors > Autosave
if it not work then try this
Preferences -> Run/Debug -> Launching -> Save dirty editors before launching