javax.swing.text

Class StyledEditorKit.ForegroundAction

public static class StyledEditorKit.ForegroundAction extends StyledEditorKit.StyledTextAction

Sets the foreground color attribute on the selected text.
Constructor Summary
ForegroundAction(String nm, Color fg)
Creates a new instance of ForegroundAction to set the foreground color to fg.
Method Summary
voidactionPerformed(ActionEvent event)
Performs the action.

Constructor Detail

ForegroundAction

public ForegroundAction(String nm, Color fg)
Creates a new instance of ForegroundAction to set the foreground color to fg.

Parameters: nm the name of the Action fg the foreground color to set

Method Detail

actionPerformed

public void actionPerformed(ActionEvent event)
Performs the action.

Parameters: event the ActionEvent that describes the action