Commit 457e590c authored by Carlos Alves's avatar Carlos Alves Committed by Kurt Hindenburg
Browse files

Correct columns size with highlightScrolledLines

When highlightScrolledLines is set to display the Konsole new window
will open with the display profile terminal size columns  - 1.
Now it will check the options and correct the Konsole size to display
all columns set in profile terminal size.

BUG: 429600
(cherry picked from commit 46d9100f)
parent 3f2b2d9d
......@@ -230,8 +230,12 @@ void SessionManager::applyProfile(Session *session, const Profile::Ptr &profile,
if (apply.shouldApply(Profile::TerminalColumns)
|| apply.shouldApply(Profile::TerminalRows)) {
const auto columns = profile->property<int>(Profile::TerminalColumns);
const auto highlightScrolledLines = profile->property<bool>(Profile::HighlightScrolledLines);
const auto rows = profile->property<int>(Profile::TerminalRows);
auto columns = profile->property<int>(Profile::TerminalColumns);
// highlightScrolledLines takes 1 column to display, correct it
// adding 1 to terminal initial columns profile preference
columns += highlightScrolledLines ? 1 : 0;
session->setPreferredSize(QSize(columns, rows));
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment