diff options
| author | Danilo M. <danix@danix.xyz> | 2026-08-24 11:02:08 +0200 |
|---|---|---|
| committer | Danilo M. <danix@danix.xyz> | 2026-08-24 11:02:08 +0200 |
| commit | dd6f35b8f35f231ebf1511daef3dd707eaa9839d (patch) | |
| tree | 2013df8d9541164bef2339aeee2ab507d976a615 /src/config.cpp | |
| parent | f814bb57c03e01c96ec97c2bfb2d314210a95f28 (diff) | |
| download | qtmaildir-dd6f35b8f35f231ebf1511daef3dd707eaa9839d.tar.gz qtmaildir-dd6f35b8f35f231ebf1511daef3dd707eaa9839d.zip | |
fix(compose): default to quoting below, and focus the body on a reply
The previous commit fixed the cursor within each quote_position branch and
the user still saw the old layout, because the branches were already right:
what was wrong was the DEFAULT. quote_position shipped as `above`, and the
layout asked for is exactly what `below` already produced, a blank line at
the top with the quote underneath.
So the default flips, along with the fallback for a malformed value and the
warning naming it. Nothing needs an Upgrading note: compose has not been
released, so no config in the wild sets this.
Focus goes to the body whenever To: is already filled, which a Reply and a
Forward always are. The form's first widget took it otherwise, so the user
had to click into the editor before typing. A New message keeps the default,
since an empty To: is genuinely the first thing to fill in.
The focus test asserts on the window's focusWidget() rather than on
QWidget::hasFocus(): an unshown window is never active, so hasFocus() reads
false whatever the code does and would fail against a correct fix. Both
directions are mutation-checked, since focusing unconditionally passes the
reply case while breaking the new-message one.
Diffstat (limited to 'src/config.cpp')
| -rw-r--r-- | src/config.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/config.cpp b/src/config.cpp index c6bedd2..b148102 100644 --- a/src/config.cpp +++ b/src/config.cpp @@ -531,7 +531,7 @@ void Config::load(const QString &path) // other enum-ish key in this file (sync_on_exit, language, date_format) // rather than being the one silent exception. const QString quotePosition = - settings.value(QStringLiteral("quote_position"), QStringLiteral("above")) + settings.value(QStringLiteral("quote_position"), QStringLiteral("below")) .toString().trimmed(); if (quotePosition.compare(QStringLiteral("above"), Qt::CaseInsensitive) == 0) { m_compose.quotePosition = ComposeSettings::QuotePosition::Above; @@ -539,7 +539,7 @@ void Config::load(const QString &path) m_compose.quotePosition = ComposeSettings::QuotePosition::Below; } else { addProblem(tr("[compose] quote_position '%1' is not recognised; " - "expected above or below. Using above.") + "expected above or below. Using below.") .arg(quotePosition)); } |
