Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Utilities
Konsole
Commits
f4c5adec
Commit
f4c5adec
authored
Mar 28, 2021
by
Luis Javier Merino
Browse files
Support reporting text area size
Add support for CSI 18 t, which reports the text area size in characters.
parent
83bc8b2d
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/Vt102Emulation.cpp
View file @
f4c5adec
...
...
@@ -780,6 +780,7 @@ void Vt102Emulation::processToken(int token, int p, int q)
Q_EMIT
imageResizeRequest
(
QSize
(
q
,
p
));
// Note columns (x), rows (y) in QSize
break
;
case
token_csi_ps
(
't'
,
18
)
:
reportSize
();
break
;
// change tab text color : \e[28;<color>t color: 0-16,777,215
case
token_csi_ps
(
't'
,
28
)
:
/* IGNORED: konsole-specific KDE3-era extension, not implemented */
break
;
...
...
@@ -1113,6 +1114,13 @@ void Vt102Emulation::reportCursorPosition()
sendString
(
tmp
);
}
void
Vt102Emulation
::
reportSize
()
{
char
tmp
[
30
];
snprintf
(
tmp
,
sizeof
(
tmp
),
"
\033
[8;%d;%dt"
,
_currentScreen
->
getLines
(),
_currentScreen
->
getColumns
());
sendString
(
tmp
);
}
void
Vt102Emulation
::
reportTerminalType
()
{
// Primary device attribute response (Request was: ^[[0c or ^[[c (from TT321 Users Guide))
...
...
src/Vt102Emulation.h
View file @
f4c5adec
...
...
@@ -146,6 +146,7 @@ private:
void
reportStatus
();
void
reportAnswerBack
();
void
reportCursorPosition
();
void
reportSize
();
void
reportTerminalParms
(
int
p
);
// clears the screen and resizes it to the specified
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment