Package com._1c.g5.v8.dt.bsl.ui.autoedit
Class BslCommentNewLineEditStrategy
java.lang.Object
org.eclipse.xtext.ui.editor.autoedit.AbstractEditStrategy
com._1c.g5.v8.dt.bsl.ui.autoedit.BslCommentNewLineEditStrategy
- All Implemented Interfaces:
EventListener,org.eclipse.jface.text.IAutoEditStrategy,org.eclipse.swt.custom.VerifyKeyListener,org.eclipse.swt.internal.SWTEventListener
public class BslCommentNewLineEditStrategy
extends org.eclipse.xtext.ui.editor.autoedit.AbstractEditStrategy
This strategy adds '//' after inserting new line if shift+enter was pressed and before comment line was detected:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classSpecial factory for creatingBslCommentNewLineEditStrategy -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected com.google.inject.Provider<org.eclipse.jface.text.DefaultIndentLineAutoEditStrategy>Fields inherited from class org.eclipse.xtext.ui.editor.autoedit.AbstractEditStrategy
debug, DEBUG -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidinternalCustomizeDocumentCommand(org.eclipse.jface.text.IDocument document, org.eclipse.jface.text.DocumentCommand command) voidverifyKey(org.eclipse.swt.events.VerifyEvent event) Methods inherited from class org.eclipse.xtext.ui.editor.autoedit.AbstractEditStrategy
count, customizeDocumentCommand, getDocumentContent, handleBadLocationException, isIdentifierPart
-
Field Details
-
defaultIndentLineAutoEditStrategy
@Inject protected com.google.inject.Provider<org.eclipse.jface.text.DefaultIndentLineAutoEditStrategy> defaultIndentLineAutoEditStrategy
-
-
Constructor Details
-
BslCommentNewLineEditStrategy
public BslCommentNewLineEditStrategy()
-
-
Method Details
-
verifyKey
public void verifyKey(org.eclipse.swt.events.VerifyEvent event) - Specified by:
verifyKeyin interfaceorg.eclipse.swt.custom.VerifyKeyListener- Overrides:
verifyKeyin classorg.eclipse.xtext.ui.editor.autoedit.AbstractEditStrategy
-
internalCustomizeDocumentCommand
protected void internalCustomizeDocumentCommand(org.eclipse.jface.text.IDocument document, org.eclipse.jface.text.DocumentCommand command) throws org.eclipse.jface.text.BadLocationException - Specified by:
internalCustomizeDocumentCommandin classorg.eclipse.xtext.ui.editor.autoedit.AbstractEditStrategy- Throws:
org.eclipse.jface.text.BadLocationException
-