|
Eclipse Platform Release 3.6 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eclipse.jface.bindings.keys.formatting.AbstractKeyFormatter
public abstract class AbstractKeyFormatter
An abstract implementation of a key formatter that provides a lot of common
key formatting functionality. It is recommended that implementations of
IKeyFormatter subclass from here, rather than implementing
IKeyFormatter directly.
| Field Summary | |
|---|---|
protected static java.lang.String |
KEY_DELIMITER_KEY
The key for the delimiter between keys. |
protected static java.lang.String |
KEY_STROKE_DELIMITER_KEY
The key for the delimiter between key strokes. |
protected static int[] |
NO_MODIFIER_KEYS
An empty integer array that can be used in sortModifierKeys(int). |
| Constructor Summary | |
|---|---|
AbstractKeyFormatter()
|
|
| Method Summary | |
|---|---|
java.lang.String |
format(int key)
Formats an individual key into a human readable format. |
java.lang.String |
format(KeySequence keySequence)
Format the given key sequence into a string. |
java.lang.String |
format(KeyStroke keyStroke)
Format the given key strokes into a string. |
protected abstract java.lang.String |
getKeyDelimiter()
An accessor for the delimiter you wish to use between keys. |
protected abstract java.lang.String |
getKeyStrokeDelimiter()
An accessor for the delimiter you wish to use between key strokes. |
protected abstract int[] |
sortModifierKeys(int modifierKeys)
Separates the modifier keys from each other, and then places them in an array in some sorted order. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static final java.lang.String KEY_DELIMITER_KEY
protected static final java.lang.String KEY_STROKE_DELIMITER_KEY
protected static final int[] NO_MODIFIER_KEYS
sortModifierKeys(int).
| Constructor Detail |
|---|
public AbstractKeyFormatter()
| Method Detail |
|---|
public java.lang.String format(int key)
IKeyFormatter
format in interface IKeyFormatterkey - The key to format.
null.public java.lang.String format(KeySequence keySequence)
IKeyFormatter
format in interface IKeyFormatterkeySequence - The key sequence to convert; must not be null.
null.public java.lang.String format(KeyStroke keyStroke)
IKeyFormatter
format in interface IKeyFormatterkeyStroke - The key stroke to convert; must not be null.
nullprotected abstract java.lang.String getKeyDelimiter()
null.protected abstract java.lang.String getKeyStrokeDelimiter()
null.protected abstract int[] sortModifierKeys(int modifierKeys)
modifierKeys - The modifier keys from the key stroke.
KeyStroke.NO_KEY should be ignored.
|
Eclipse Platform Release 3.6 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Guidelines for using Eclipse APIs.
Copyright (c) Eclipse contributors and others 2000, 2010. All rights reserved.