gnu.jemacs.swing

Class SwingWindow

public class SwingWindow extends EWindow implements FocusListener, KeyListener, ChangeListener

An Emacs window (EWindow) implemented using the Swing toolkits.
Field Summary
Modelinemodeline
Constructor Summary
SwingWindow(Buffer buffer)
SwingWindow(Buffer buffer, boolean wantModeline)
Create new Window.
Method Summary
voidactivateRegion()
protected voiddeleteNoValidate()
voidfocusGained(FocusEvent e)
voidfocusLost(FocusEvent e)
protected voidgetCharSize()
static JTextPanegetContainedWindow(Container cont, boolean last)
intgetHeight()
JPanelgetPanel()
Get the JPanel containing this Window.
intgetPoint()
DimensiongetPreferredScrollableViewportSize()
intgetWidth()
static SwingWindowgetWindow(ActionEvent event)
protected voidhandle(KeyEvent e, int code)
voidkeyPressed(KeyEvent e)
voidkeyReleased(KeyEvent e)
voidkeyTyped(KeyEvent e)
voidrequestFocus()
voidsetBuffer(Buffer buffer)
voidsetDot(int offset)
voidsetSelected()
EWindowsplit(Buffer buffer, int lines, boolean horizontal)
voidstateChanged(ChangeEvent e)
ObjecttooLong(int pendingLength)
voidunselect()
JPanelwrap()
Warp this (and optional modeline) inside a ScrollPane in a new JPanel.

Field Detail

modeline

public Modeline modeline

Constructor Detail

SwingWindow

public SwingWindow(Buffer buffer)

SwingWindow

public SwingWindow(Buffer buffer, boolean wantModeline)
Create new Window.

Parameters: buffer the Buffer containing the data. wantModeline true if we should create a mode line

Method Detail

activateRegion

public void activateRegion()

deleteNoValidate

protected void deleteNoValidate()

focusGained

public void focusGained(FocusEvent e)

focusLost

public void focusLost(FocusEvent e)

getCharSize

protected void getCharSize()

getContainedWindow

public static JTextPane getContainedWindow(Container cont, boolean last)

getHeight

public int getHeight()

getPanel

public JPanel getPanel()
Get the JPanel containing this Window.

getPoint

public int getPoint()

getPreferredScrollableViewportSize

public Dimension getPreferredScrollableViewportSize()

getWidth

public int getWidth()

getWindow

public static SwingWindow getWindow(ActionEvent event)

handle

protected void handle(KeyEvent e, int code)

keyPressed

public void keyPressed(KeyEvent e)

keyReleased

public void keyReleased(KeyEvent e)

keyTyped

public void keyTyped(KeyEvent e)

requestFocus

public void requestFocus()

setBuffer

public void setBuffer(Buffer buffer)

setDot

public void setDot(int offset)

setSelected

public void setSelected()

split

public EWindow split(Buffer buffer, int lines, boolean horizontal)

stateChanged

public void stateChanged(ChangeEvent e)

tooLong

public Object tooLong(int pendingLength)

See Also: EWindow

unselect

public void unselect()

wrap

public JPanel wrap()
Warp this (and optional modeline) inside a ScrollPane in a new JPanel.