diff --git a/CHANGELOG.md b/CHANGELOG.md index 641a299..19a705e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,11 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.0.51] - 2026-06-15 + +### 改进 +- 标签打印字体细化:阈值调回 128,店名改细体,商品名保持粗体 + ## [1.0.50] - 2026-06-15 ### 改进 diff --git a/client/lib/core/utils/print_util_stub.dart b/client/lib/core/utils/print_util_stub.dart index cc309ed..abdd980 100644 --- a/client/lib/core/utils/print_util_stub.dart +++ b/client/lib/core/utils/print_util_stub.dart @@ -240,8 +240,8 @@ Future _renderLabelBitmap({ final codeText = code.isNotEmpty ? '编号:$code' : ''; final rows = <(String, double, bool)>[ - if (shop.isNotEmpty) (shop, kShopSize, true), - if (name.isNotEmpty) (name, nameSize, true), + if (shop.isNotEmpty) (shop, kShopSize, false), // 店名细体,突出商品名 + if (name.isNotEmpty) (name, nameSize, true), // 商品名粗体 if (codeText.isNotEmpty) (codeText, kSmallSize, false), if (degSpec.isNotEmpty) (degSpec, kSmallSize, false), if (date.isNotEmpty) (date, kSmallSize, false), @@ -311,7 +311,7 @@ Future _printFlatLabelThermal({ : 0.299 * rgba[i] + 0.587 * rgba[i + 1] + 0.114 * rgba[i + 2]; } } - if (lum / 4 < 160) row[xx >> 3] &= ~(0x80 >> (xx & 7)); // 黑点 -> bit0 + if (lum / 4 < 128) row[xx >> 3] &= ~(0x80 >> (xx & 7)); // 黑点 -> bit0 } out.add(row); }