From 4ffe45363d9ef964468e63f5c95103583801d558 Mon Sep 17 00:00:00 2001 From: vrubelroman Date: Wed, 28 Oct 2026 01:04:53 +0300 Subject: [PATCH] =?UTF-8?q?Desktop:=20the=20draw=20offer=20button=20is=20?= =?UTF-8?q?=C2=AB=C2=BD=E2=80=93=C2=BD=C2=BB,=20its=20words=20in=20the=20t?= =?UTF-8?q?ooltip?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Opus 5.5 --- CHANGELOG.md | 2 ++ apps/desktop/src/game_view.rs | 8 +++++--- apps/desktop/src/i18n.rs | 18 +++++++++--------- docs/dev/tasks.md | 2 +- 4 files changed, 17 insertions(+), 13 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ca92203..7298422 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,8 @@ All notable changes are listed here. Versions follow [Semantic Versioning](https - The review's mark in the notation stands right after the move, the move in its color (Qg7?? in red), as on Lichess, instead of a colored pill at the edge of the cell; the author's own sign, when there is one, stands instead. +- Desktop, a game against the computer: the draw offer is «½–½» on its button («Offer a + draw» in its tooltip), so that the game's buttons fit in a narrow panel. - Android: the board shows the move's mark in the corner of its square, as on the desktop: the review's ?!, ?, ??, !, !! or the author's own sign. diff --git a/apps/desktop/src/game_view.rs b/apps/desktop/src/game_view.rs index d24a3bd..95cab71 100644 --- a/apps/desktop/src/game_view.rs +++ b/apps/desktop/src/game_view.rs @@ -3516,10 +3516,12 @@ impl GameView { "Rodent accepts when its position is no better and has settled", ), }; + // Short on the button (the row stays one line); the words in the tooltip. + let hint = format!("{}\n{hint}", tr("Offer a draw")); if ui - .add_enabled(may, word(tr("½ Offer a draw"))) - .on_hover_text(hint) - .on_disabled_hover_text(hint) + .add_enabled(may, word("½–½")) + .on_hover_text(&hint) + .on_disabled_hover_text(&hint) .clicked() { let yes = self diff --git a/apps/desktop/src/i18n.rs b/apps/desktop/src/i18n.rs index 199f8a8..7fb9a86 100644 --- a/apps/desktop/src/i18n.rs +++ b/apps/desktop/src/i18n.rs @@ -10947,15 +10947,15 @@ const ROWS: &[[&str; 9]] = &[ "келісім бойынша", ], [ - "½ Offer a draw", - "½ Предложить ничью", - "½ Proposer nulle", - "½ Remis anbieten", - "½ Ofrecer tablas", - "½ Proponi patta", - "½ Propor empate", - "½ Durang taklif qilish", - "½ Тең ойын ұсыну", + "Offer a draw", + "Предложить ничью", + "Proposer nulle", + "Remis anbieten", + "Ofrecer tablas", + "Proponi patta", + "Propor empate", + "Durang taklif qilish", + "Тең ойын ұсыну", ], [ "Maia answers a draw offer with Stockfish's help: none is installed", diff --git a/docs/dev/tasks.md b/docs/dev/tasks.md index 4b5c0ab..246e333 100644 --- a/docs/dev/tasks.md +++ b/docs/dev/tasks.md @@ -132,7 +132,7 @@ Решение — `docs/decisions.md`, «Android: ввод ходов…»; исследование — `docs/research/android-port.md`. Этапы: (1) сессия партии в ядре и ввод ходов на доске, новая партия, свои базы (несколько, во внутренней папке, выгрузка); (2) тренировка дебюта — `train.rs` в общий крейт; (3) Maia 5M без часов, «Играть отсюда», запись в свою базу — логика игры в общий крейт, исправить пик памяти загрузки Maia. Статус: сделано (выпуски 1.5–1.8). ### 18. Короче кнопка «½ Предложить ничью» (2026-10-28) -- **Статус:** на будущее, штрих. +- **Статус:** сделано (2026-10-28): на компьютере кнопка «½–½», «Предложить ничью» — в подсказке; на телефоне кнопка уже короткая («Ничья» со значком). - **Суть:** в партии с компьютером кнопка «½ Предложить ничью» слишком длинная, ряд кнопок под часами переносится. Владелец: переименовать в «½–½» или похоже; полное «Предложить ничью» оставить во всплывающей подсказке (и для экранного чтения). Компьютер; на телефоне проверить ту же кнопку. ## Сделано