Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 320725 - SourceViewer.java: NPE on Quick Fix after disabling spelling
Summary: SourceViewer.java: NPE on Quick Fix after disabling spelling
Status: RESOLVED FIXED
Alias: None
Product: WTP Source Editing
Classification: WebTools
Component: wst.sse (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 minor (vote)
Target Milestone: 3.3 M1   Edit
Assignee: wst.sse CLA
QA Contact: Nitin Dahyabhai CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-07-23 10:16 EDT by Andrey Vakunov CLA
Modified: 2010-07-23 16:37 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Andrey Vakunov CLA 2010-07-23 10:16:04 EDT
Build Identifier: Version: 3.6.0 Build id: I20100608-0911

After disabling spell checking I've got next NPE:
java.lang.NullPointerException
	at org.eclipse.jface.text.source.SourceViewer.doOperation(SourceViewer.java:920)
	at org.eclipse.jface.text.source.projection.ProjectionViewer.doOperation(ProjectionViewer.java:1534)
	at org.eclipse.wst.sse.ui.internal.StructuredTextViewer.doOperation(StructuredTextViewer.java:597)
	at org.eclipse.ui.texteditor.TextOperationAction$1.run(TextOperationAction.java:131)
	at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70)
....

Reproducible: Always

Steps to Reproduce:
1. Create simple text file in workspace (i.e. 'test.txt') with content (i.e. 'hallo warld')
2. Open created file using 'Standalone Structured Source Editor'
3. Spelling and Quick Fix(by "Ctrl+1") working fine. Doesn't close editor.
4. Goto "Preferences/General/Editors/Text Editors/Spelling"
5. Disable spell checking.
6. Spelling are still in editor.
7. Try call Quick Fix("Ctrl+1"). NPE as a result.
Comment 1 Andrey Vakunov CLA 2010-07-23 10:18:56 EDT
This bug doesn't reproduce in simple 'Text editor'.
Comment 2 Rakesh CLA 2010-07-23 10:57:20 EDT
I think , structured source editor is not meant for txt file .This editor works on StructuredModel which is null in case of text files.
Comment 3 Nitin Dahyabhai CLA 2010-07-23 16:37:48 EDT
Can't reproduce, but that editor shouldn't be there.