2121 * A terminal session, consisting of a process coupled to a terminal interface.
2222 * <p>
2323 * The subprocess will be executed by the constructor, and when the size is made known by a call to
24- * {@link #updateSize(int, int)} terminal emulation will begin and threads will be spawned to handle the subprocess I/O.
24+ * {@link #updateSize(int, int, int, int )} terminal emulation will begin and threads will be spawned to handle the subprocess I/O.
2525 * All terminal emulation and callback methods will be performed on the main thread.
2626 * <p>
2727 * The child process may be exited forcefully by using the {@link #finishIfRunning()} method.
@@ -61,7 +61,7 @@ public final class TerminalSession extends TerminalOutput {
6161
6262 /**
6363 * The file descriptor referencing the master half of a pseudo-terminal pair, resulting from calling
64- * {@link JNI#createSubprocess(String, String, String[], String[], int[], int, int)}.
64+ * {@link JNI#createSubprocess(String, String, String[], String[], int[], int, int, int, int )}.
6565 */
6666 private int mTerminalFileDescriptor ;
6767
@@ -100,11 +100,11 @@ public void updateTerminalSessionClient(TerminalSessionClient client) {
100100 }
101101
102102 /** Inform the attached pty of the new size and reflow or initialize the emulator. */
103- public void updateSize (int columns , int rows ) {
103+ public void updateSize (int columns , int rows , int fontWidth , int fontHeight ) {
104104 if (mEmulator == null ) {
105- initializeEmulator (columns , rows );
105+ initializeEmulator (columns , rows , fontWidth , fontHeight );
106106 } else {
107- JNI .setPtyWindowSize (mTerminalFileDescriptor , rows , columns );
107+ JNI .setPtyWindowSize (mTerminalFileDescriptor , rows , columns , fontWidth , fontHeight );
108108 mEmulator .resize (columns , rows );
109109 }
110110 }
@@ -120,11 +120,11 @@ public String getTitle() {
120120 * @param columns The number of columns in the terminal window.
121121 * @param rows The number of rows in the terminal window.
122122 */
123- public void initializeEmulator (int columns , int rows ) {
123+ public void initializeEmulator (int columns , int rows , int cellWidth , int cellHeight ) {
124124 mEmulator = new TerminalEmulator (this , columns , rows , mTranscriptRows , mClient );
125125
126126 int [] processId = new int [1 ];
127- mTerminalFileDescriptor = JNI .createSubprocess (mShellPath , mCwd , mArgs , mEnv , processId , rows , columns );
127+ mTerminalFileDescriptor = JNI .createSubprocess (mShellPath , mCwd , mArgs , mEnv , processId , rows , columns , cellWidth , cellHeight );
128128 mShellPid = processId [0 ];
129129
130130 final FileDescriptor terminalFileDescriptorWrapped = wrapFileDescriptor (mTerminalFileDescriptor , mClient );
0 commit comments