Java Code Examples for javax.swing.text.DefaultEditorKit#insertBreakAction()

The following examples show how to use javax.swing.text.DefaultEditorKit#insertBreakAction() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: TextRegionManager.java    From netbeans with Apache License 2.0 6 votes vote down vote up
private static String actionType2Name(int actionType) {
    switch (actionType) {
        case TAB:
            return BaseKit.insertTabAction;
        case SHIFT_TAB:
            return BaseKit.removeTabAction;
        case ENTER:
            return DefaultEditorKit.insertBreakAction;
        default:
            throw new IllegalArgumentException();
    }
}