Commit bfcdeffd0c415864673da05a9c27f86091ee336c

Authored by weixin_45529955
1 parent eb7e7f6b

微信通知 小程序卡片封面宽度不够换航

Showing 1 changed file with 3 additions and 1 deletions
@@ -3050,6 +3050,8 @@ class Utils { @@ -3050,6 +3050,8 @@ class Utils {
3050 String month = 3050 String month =
3051 '${Utils.addZeroNumber(date.month)}/${Utils.addZeroNumber(date.day)} '; 3051 '${Utils.addZeroNumber(date.month)}/${Utils.addZeroNumber(date.day)} ';
3052 String week = returnWeek(date, context); 3052 String week = returnWeek(date, context);
  3053 + week = week.replaceAll(' ', '');
  3054 +
3053 String hour = subType1 == '1' || subType1 == '3' ? '${ddateHm}' : ''; 3055 String hour = subType1 == '1' || subType1 == '3' ? '${ddateHm}' : '';
3054 String section = subType1 == '1' || subType1 == '4' 3056 String section = subType1 == '1' || subType1 == '4'
3055 ? _getDsoltStrShow(dsolt, mname) 3057 ? _getDsoltStrShow(dsolt, mname)
@@ -3113,7 +3115,7 @@ class Utils { @@ -3113,7 +3115,7 @@ class Utils {
3113 pb3.addText(month + week); 3115 pb3.addText(month + week);
3114 3116
3115 // 设置文本的宽度约束 3117 // 设置文本的宽度约束
3116 - ParagraphConstraints pc3 = ui.ParagraphConstraints(width: 240); 3118 + ParagraphConstraints pc3 = ui.ParagraphConstraints(width:245);
3117 ui.Paragraph paragraph3 = pb3.build()..layout(pc3); 3119 ui.Paragraph paragraph3 = pb3.build()..layout(pc3);
3118 canvas.drawParagraph(paragraph3, 3120 canvas.drawParagraph(paragraph3,
3119 Offset(subType1 == '1' ? 14 * scaleX : 35 * scaleX, 146 * scaleY)); 3121 Offset(subType1 == '1' ? 14 * scaleX : 35 * scaleX, 146 * scaleY));