+ private class OtherScreen extends LogicalScreen {
+
+ /**
+ * The TWindowBackend to notify.
+ */
+ private TWindowBackend window;
+
+ /**
+ * Public constructor.
+ */
+ public OtherScreen(final TWindowBackend window) {
+ this.window = window;
+ }
+
+ /**
+ * Resize the physical screen to match the logical screen dimensions.
+ */
+ @Override
+ public void resizeToScreen() {
+ window.setWidth(getWidth() + 2);
+ window.setHeight(getHeight() + 2);
+ }
+
+ /**
+ * Get the width of a character cell in pixels.
+ *
+ * @return the width in pixels of a character cell
+ */
+ @Override
+ public int getTextWidth() {
+ return window.getScreen().getTextWidth();
+ }
+
+ /**
+ * Get the height of a character cell in pixels.
+ *
+ * @return the height in pixels of a character cell
+ */
+ @Override
+ public int getTextHeight() {
+ return window.getScreen().getTextHeight();
+ }
+
+ }
+