Toggle navigation
Toggle navigation
This project
Loading...
Sign in
developOne
/
harmonyPool
Go to a project
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
张善主
2024-05-28 17:28:48 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
4cd51ed4e3338be3af5d51c2dee6a28b3ffe8310
4cd51ed4
1 parent
201bd132
fix(版面):读报纸弹窗字号调整
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
6 deletions
sight_harmony/features/wdComponent/src/main/ets/dialog/ENewspaperListDialog.ets
sight_harmony/features/wdComponent/src/main/ets/dialog/ENewspaperListDialog.ets
View file @
4cd51ed
...
...
@@ -3,7 +3,7 @@ import { ExtraDTO } from 'wdBean/src/main/ets/bean/component/extra/ExtraDTO'
import { WDRouterRule } from 'wdRouter/Index'
import { ENewspaperPageDialog } from '../dialog/ENewspaperPageDialog'
import { Logger } from 'wdKit';
import { window } from '@kit.ArkUI';
import {
font,
window } from '@kit.ArkUI';
/**
* 读报纸半屏弹窗
...
...
@@ -56,6 +56,11 @@ export struct ENewspaperListDialog {
}
async aboutToAppear() {
//注册字体
font.registerFont({
familyName: 'BebasNeueBold',
familySrc: $rawfile('font/BebasNeueBold.otf')
})
// 屏幕高度 - 滑动高度计算
let windowClass: window.Window = await window.getLastWindow(getContext(this));
let changeHeight = 85 + 44 + px2vp(windowClass.getWindowAvoidArea(window.AvoidAreaType.TYPE_SYSTEM).topRect.height)
...
...
@@ -151,7 +156,7 @@ export struct ENewspaperListDialog {
Column() {
if (itemIndex == 0) {
Text(item.pageNum + '版:' + item.pageName)
.fontSize($r('app.float.font_size_1
4
'))
.fontSize($r('app.float.font_size_1
3
'))
.fontColor($r('app.color.color_ED2800'))
.fontWeight(600)
.width('100%')
...
...
@@ -165,7 +170,7 @@ export struct ENewspaperListDialog {
Column() {
if (positionItem.shortTitle) {
Text(positionItem.shortTitle)
.fontSize($r('app.float.font_size_1
4
'))
.fontSize($r('app.float.font_size_1
3
'))
.fontColor($r('app.color.color_222222'))
.fontWeight(600)
// .maxLines(2)
...
...
@@ -176,7 +181,7 @@ export struct ENewspaperListDialog {
if (positionItem.title) {
Text(positionItem.title)
.fontSize($r('app.float.font_size_1
7
'))
.fontSize($r('app.float.font_size_1
6
'))
.fontColor($r('app.color.color_222222'))
.fontWeight(600)
.margin({
...
...
@@ -187,7 +192,7 @@ export struct ENewspaperListDialog {
if (positionItem.downTitle) {
Text(positionItem.downTitle)
.fontSize($r('app.float.font_size_1
4
'))
.fontSize($r('app.float.font_size_1
3
'))
.fontColor($r('app.color.color_222222'))
.fontWeight(600)
.margin({
...
...
@@ -197,7 +202,7 @@ export struct ENewspaperListDialog {
}
if (positionItem.newsTxt) {
Text(positionItem.newsTxt)
.fontSize($r('app.float.font_size_1
4
'))
.fontSize($r('app.float.font_size_1
3
'))
.fontColor($r('app.color.color_999999'))
.lineHeight(25)
.margin({
...
...
Please
register
or
login
to post a comment