Reword code comments in plain technical language

Comments only, no code changes. Replaces vague or personified phrasing
with explicit statements of what the code does and why, uses bullet
lists for multi-case behavior, and fixes the settings path in
WindowSettings.h (~/.config/sloposk/sloposk.conf).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-03 19:58:59 +01:00
co-authored by Claude Opus 5.5
parent 5e4d4051f3
commit 23e957660f
53 changed files with 232 additions and 226 deletions
+3 -3
View File
@@ -49,7 +49,7 @@ QVariant LayoutModel::data(const QModelIndex &index, int role) const
const QRectF rect = m_rects.value(index.row());
switch (role) {
case LabelRole: return key.text(m_keyLevel);
// A shifted or AltGr key may already show its flick symbol (! on 1): don't repeat it.
// Hide the flick symbol if the main label already shows it (shifted or AltGr: ! on 1).
case FlickLabelRole: return key.flick == key.text(m_keyLevel) ? QString() : key.flick;
case ModifierRole: return key.modifier;
case KeyTypeRole: return keyTypeName(key.type);
@@ -185,7 +185,7 @@ QList<Block> LayoutModel::composeBlocks() const
main.rows += section.rows;
}
if (layer && shown(MainSectionId)) {
// Room for the biggest layer, so switching layers keeps the other blocks still.
// Reserve space for the largest layer, so switching layers doesn't move other blocks.
main.fixedRows = main.rows.size();
for (const Layer &other : m_layout.layers) {
main.minRows = std::max(main.minRows, main.fixedRows + other.rows.size());
@@ -202,7 +202,7 @@ QList<Block> LayoutModel::composeBlocks() const
if (section.placement == Section::Placement::Right && shown(section.id))
blocks.append({section.rows, section.fillHeight});
}
// Never show nothing.
// If no block is shown, fall back to the current layer.
if (blocks.isEmpty() && layer)
blocks.append({layer->rows});
return blocks;