Notation: moves in Ubuntu Bold (desktop) and bold (Android); Medium dropped
Some checks are pending
CI / check (push) Waiting to run
CI / windows-build (push) Waiting to run
CI / macos-build (push) Waiting to run

The designer compared JetBrains Mono: in a monospace face !! and ?? fall apart
and O-O-O reads as 0-0-0; the Ubuntu family stays.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
vrubelroman 2026-10-28 03:04:55 +03:00
parent 1f27c2ae57
commit df59ff1b32
6 changed files with 25 additions and 37 deletions

View file

@ -4,9 +4,8 @@ All notable changes are listed here. Versions follow [Semantic Versioning](https
## [Unreleased]
- The moves of the notation and the signs after them are bolder (Ubuntu Medium on the
desktop, a heavier weight on Android), and so are the marks in the circles on the board
(Ubuntu Bold). In Russian the report's rows read «Блестящий» and «Замечательный».
- The moves of the notation and the signs after them are bold (Ubuntu Bold on the desktop,
the bold system font on Android), and so are the marks in the circles on the board. In Russian the report's rows read «Блестящий» and «Замечательный».
- Android: the dark theme by default (it was the system's); a theme chosen before stays.
Android is told the app's own theme, so the window and the splash screen before the

View file

@ -170,8 +170,8 @@ Three evaluation signs (⩲ ⩱ ⌓) come from Noto Sans Math (Copyright 2022 Go
cut down to those glyphs: `apps/desktop/assets/fonts/NotoSansMath-nag.ttf`, licence beside it.
The figurines of the move notation (♔♕♖♗♘) are the five chess glyphs of egui's
emoji-icon-font (MIT), cut out to `apps/desktop/assets/fonts/figurines.ttf`.
The moves of the notation and the move marks on the board are in Ubuntu Medium and Ubuntu
Bold (Ubuntu Font Family 0.83, © 2010–2011 Canonical Ltd., Ubuntu Font Licence 1.0), from
The moves of the notation and the move marks on the board are in Ubuntu Bold (Ubuntu Font
Family 0.83, © 2010–2011 Canonical Ltd., Ubuntu Font Licence 1.0), from
the official release `https://assets.ubuntu.com/v1/fad7939b-ubuntu-font-family-0.83.zip`
(SHA-256 456d7d42…05b42, as in Arch Linux's `ttf-ubuntu-font-family`):
`apps/desktop/assets/fonts/Ubuntu-M.ttf`, `Ubuntu-B.ttf`, licence `UFL.txt` beside them.
`apps/desktop/assets/fonts/Ubuntu-B.ttf`, licence `UFL.txt` beside it.

View file

@ -412,7 +412,7 @@ private fun MoveCell(
horizontalArrangement = Arrangement.spacedBy(1.dp),
) {
val markColor = mark?.takeIf { !selected }?.let { judgementColor(it, chess.dark) }
Text(san(n.san), fontSize = 17.sp, fontWeight = FontWeight.SemiBold, color = markColor ?: MaterialTheme.colorScheme.onSurface)
Text(san(n.san), fontSize = 17.sp, fontWeight = FontWeight.Bold, color = markColor ?: MaterialTheme.colorScheme.onSurface)
if (mark != null) {
Text(judgementSymbol(mark), fontSize = 17.sp, fontWeight = FontWeight.Bold, color = markColor ?: MaterialTheme.colorScheme.onSurface)
}

View file

@ -156,16 +156,10 @@ pub fn install(ctx: &egui::Context) {
ctx.set_fonts(font_definitions());
}
/// The font families of the heavier faces.
pub const MEDIUM: &str = "ubuntu-medium";
/// The font family of the bold face.
pub const BOLD: &str = "ubuntu-bold";
/// A font of the medium face (the moves of the notation).
pub fn medium(size: f32) -> egui::FontId {
egui::FontId::new(size, egui::FontFamily::Name(MEDIUM.into()))
}
/// A font of the bold face (the marks on the board).
/// A font of the bold face (the moves of the notation, the marks on the board).
pub fn bold(size: f32) -> egui::FontId {
egui::FontId::new(size, egui::FontFamily::Name(BOLD.into()))
}
@ -195,32 +189,28 @@ pub fn font_definitions() -> egui::FontDefinitions {
),
),
);
// The heavier faces of the same family (egui's text is Ubuntu Light): the moves of the
// The bold face of the same family (egui's text is Ubuntu Light): the moves of the
// notation and the marks on the board.
for (name, bytes) in [
(MEDIUM, &include_bytes!("../assets/fonts/Ubuntu-M.ttf")[..]),
(BOLD, &include_bytes!("../assets/fonts/Ubuntu-B.ttf")[..]),
] {
fonts.font_data.insert(
name.into(),
std::sync::Arc::new(egui::FontData::from_static(bytes)),
);
let mut list = vec![name.to_string()];
list.extend(
fonts
.families
.get(&egui::FontFamily::Proportional)
.cloned()
.unwrap_or_default(),
);
fonts.font_data.insert(
BOLD.into(),
std::sync::Arc::new(egui::FontData::from_static(include_bytes!(
"../assets/fonts/Ubuntu-B.ttf"
))),
);
let mut bold = vec![BOLD.to_string()];
bold.extend(
fonts
.families
.insert(egui::FontFamily::Name(name.into()), list);
}
.get(&egui::FontFamily::Proportional)
.cloned()
.unwrap_or_default(),
);
fonts
.families
.insert(egui::FontFamily::Name(BOLD.into()), bold);
for family in [
egui::FontFamily::Proportional,
egui::FontFamily::Monospace,
egui::FontFamily::Name(MEDIUM.into()),
egui::FontFamily::Name(BOLD.into()),
] {
if let Some(list) = fonts.families.get_mut(&family) {
@ -235,7 +225,6 @@ pub fn font_definitions() -> egui::FontDefinitions {
for family in [
egui::FontFamily::Proportional,
egui::FontFamily::Monospace,
egui::FontFamily::Name(MEDIUM.into()),
egui::FontFamily::Name(BOLD.into()),
] {
if let Some(list) = fonts.families.get_mut(&family) {

View file

@ -602,7 +602,7 @@ fn paint_move_cell(
cell.left_center() + vec2(10.0, 0.0),
Align2::LEFT_CENTER,
format!("{san}{sym}"),
crate::assets::medium(16.0),
crate::assets::bold(16.0),
text_color,
)
.right()