X-Git-Url: http://git.nikiroo.be/?a=blobdiff_plain;f=src%2Fjexer%2Fbackend%2FSwingBackend.java;h=797caa821fbe9f14e1e8259fef86f1abc2368182;hb=a2855f1dd3ca42b61ac4c47a18e2253ea32dd56e;hp=a98627ec3f860d79df7bd71c55be2fab50b63f29;hpb=be72cb5ccbd42fe304c0acafc380c5636f0d03a2;p=fanfix.git diff --git a/src/jexer/backend/SwingBackend.java b/src/jexer/backend/SwingBackend.java index a98627e..797caa8 100644 --- a/src/jexer/backend/SwingBackend.java +++ b/src/jexer/backend/SwingBackend.java @@ -35,7 +35,11 @@ import javax.swing.JComponent; * This class uses standard Swing calls to handle screen, keyboard, and mouse * I/O. */ -public final class SwingBackend extends GenericBackend { +public class SwingBackend extends GenericBackend { + + // ------------------------------------------------------------------------ + // Constructors ----------------------------------------------------------- + // ------------------------------------------------------------------------ /** * Public constructor. The window will be 80x25 with font size 20 pts. @@ -127,6 +131,10 @@ public final class SwingBackend extends GenericBackend { screen = (SwingTerminal) terminal; } + // ------------------------------------------------------------------------ + // SwingBackend ----------------------------------------------------------- + // ------------------------------------------------------------------------ + /** * Set to a new font, and resize the screen to match its dimensions. * @@ -147,4 +155,13 @@ public final class SwingBackend extends GenericBackend { return ((SwingTerminal) terminal).getBlinkMillis(); } + /** + * Getter for the underlying Swing component. + * + * @return the SwingComponent + */ + public SwingComponent getSwingComponent() { + return ((SwingTerminal) terminal).getSwingComponent(); + } + }