com.aptana.ide.editor.html.formatting
Class HTMLAutoIndentStrategy

java.lang.Object
  extended by com.aptana.ide.editors.unified.UnifiedAutoIndentStrategy
      extended by com.aptana.ide.editor.html.formatting.HTMLAutoIndentStrategy
All Implemented Interfaces:
IPreferenceClient, org.eclipse.jface.text.IAutoEditStrategy

public class HTMLAutoIndentStrategy
extends UnifiedAutoIndentStrategy

Author:
Robin Debreuil

Field Summary
 
Fields inherited from class com.aptana.ide.editors.unified.UnifiedAutoIndentStrategy
configuration, context, sourceViewer
 
Constructor Summary
HTMLAutoIndentStrategy(EditorFileContext context, org.eclipse.jface.text.source.SourceViewerConfiguration configuration, org.eclipse.jface.text.source.ISourceViewer sourceViewer)
          HTMLAutoIndentStrategy
 
Method Summary
static boolean closeTag(org.eclipse.jface.text.DocumentCommand command, LexemeList ll, HTMLParseState parseState)
          closeTag
 void customizeDocumentCommand(org.eclipse.jface.text.IDocument document, org.eclipse.jface.text.DocumentCommand command)
           
protected  char[] getAutoInsertCharacters()
          getAutoInsertCharacters
protected  IFileLanguageService getLanguageService()
          getLanguageService
protected  LexemeList getLexemeList()
          Creates a lexeme list
 org.eclipse.jface.preference.IPreferenceStore getPreferenceStore()
          Returns the current preference store
protected  boolean isValidAutoInsertLocation(org.eclipse.jface.text.IDocument d, org.eclipse.jface.text.DocumentCommand c)
          isValidAutoInsertLocation
 
Methods inherited from class com.aptana.ide.editors.unified.UnifiedAutoIndentStrategy
autoTriggerAssist, canCloseBracket, canOverwriteBracket, closeBracket, findEndOfWhiteSpace, getAutoOverwriteCharacters, getIndentationAtOffset, getIndentationString, getIndentForCurrentLine, getIndentString, hideContentAssistPopup, indentAfterNewLine, indentAfterOpenBrace, isAutoInsertEnabled, overwriteBracket, triggerContentAssistPopup, triggerContextAssistPopup
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HTMLAutoIndentStrategy

public HTMLAutoIndentStrategy(EditorFileContext context,
                              org.eclipse.jface.text.source.SourceViewerConfiguration configuration,
                              org.eclipse.jface.text.source.ISourceViewer sourceViewer)
HTMLAutoIndentStrategy

Parameters:
context -
configuration -
sourceViewer -
Method Detail

isValidAutoInsertLocation

protected boolean isValidAutoInsertLocation(org.eclipse.jface.text.IDocument d,
                                            org.eclipse.jface.text.DocumentCommand c)
Description copied from class: UnifiedAutoIndentStrategy
isValidAutoInsertLocation

Overrides:
isValidAutoInsertLocation in class UnifiedAutoIndentStrategy
Returns:
boolean
See Also:
UnifiedAutoIndentStrategy.isValidAutoInsertLocation(org.eclipse.jface.text.IDocument, org.eclipse.jface.text.DocumentCommand)

getAutoInsertCharacters

protected char[] getAutoInsertCharacters()
Description copied from class: UnifiedAutoIndentStrategy
getAutoInsertCharacters

Overrides:
getAutoInsertCharacters in class UnifiedAutoIndentStrategy
Returns:
char[]
See Also:
UnifiedAutoIndentStrategy.getAutoInsertCharacters()

customizeDocumentCommand

public void customizeDocumentCommand(org.eclipse.jface.text.IDocument document,
                                     org.eclipse.jface.text.DocumentCommand command)
Specified by:
customizeDocumentCommand in interface org.eclipse.jface.text.IAutoEditStrategy
Overrides:
customizeDocumentCommand in class UnifiedAutoIndentStrategy
See Also:
IAutoEditStrategy.customizeDocumentCommand(org.eclipse.jface.text.IDocument, org.eclipse.jface.text.DocumentCommand)

getLexemeList

protected LexemeList getLexemeList()
Description copied from class: UnifiedAutoIndentStrategy
Creates a lexeme list

Specified by:
getLexemeList in class UnifiedAutoIndentStrategy
Returns:
LexemeList
See Also:
UnifiedAutoIndentStrategy.getLexemeList()

closeTag

public static boolean closeTag(org.eclipse.jface.text.DocumentCommand command,
                               LexemeList ll,
                               HTMLParseState parseState)
closeTag

Parameters:
command -
ll -
parseState -
Returns:
boolean

getLanguageService

protected IFileLanguageService getLanguageService()
getLanguageService

Returns:
IFileLanguageService

getPreferenceStore

public org.eclipse.jface.preference.IPreferenceStore getPreferenceStore()
Description copied from class: UnifiedAutoIndentStrategy
Returns the current preference store

Specified by:
getPreferenceStore in interface IPreferenceClient
Specified by:
getPreferenceStore in class UnifiedAutoIndentStrategy
Returns:
The current preference store, or null if not found
See Also:
UnifiedAutoIndentStrategy.getPreferenceStore()