Search in sources :

Example 6 with BasicCompletion

use of org.fife.ui.autocomplete.BasicCompletion in project knime-core by knime.

the class StringManipulationNodeDialog method createCompletionProvider.

/**
 * Create a simple provider that adds some Java-related completions.
 *
 * @return The completion provider.
 * @since 3.3
 */
protected KnimeCompletionProvider createCompletionProvider() {
    m_completionProvider = new JavaScriptingCompletionProvider();
    Collection<Manipulator> manipulators = StringManipulatorProvider.getDefault().getManipulators(ManipulatorProvider.ALL_CATEGORY);
    for (Manipulator m : manipulators) {
        // A BasicCompletion is just a straightforward word completion.
        m_completionProvider.addCompletion(new BasicCompletion(m_completionProvider, m.getName(), m.getDisplayName(), m.getDescription()));
    }
    return m_completionProvider;
}
Also used : JavaScriptingCompletionProvider(org.knime.base.node.util.JavaScriptingCompletionProvider) BasicCompletion(org.fife.ui.autocomplete.BasicCompletion) Manipulator(org.knime.base.node.preproc.stringmanipulation.manipulator.Manipulator)

Aggregations

BasicCompletion (org.fife.ui.autocomplete.BasicCompletion)6 Completion (org.fife.ui.autocomplete.Completion)3 Manipulator (org.knime.base.node.preproc.stringmanipulation.manipulator.Manipulator)2 AutoCompletion (org.fife.ui.autocomplete.AutoCompletion)1 JavaScriptingCompletionProvider (org.knime.base.node.util.JavaScriptingCompletionProvider)1 DataColumnSpec (org.knime.core.data.DataColumnSpec)1 FlowVariable (org.knime.core.node.workflow.FlowVariable)1