首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >专栏 >鸿蒙 API18,5.1Release 套件发布,新增穿戴,TV 开发

鸿蒙 API18,5.1Release 套件发布,新增穿戴,TV 开发

作者头像
徐建国
发布于 2025-06-16 04:04:30
发布于 2025-06-16 04:04:30
1300
举报
文章被收录于专栏:个人路线个人路线

OS 新增和增强特性

ArkUI

文本与输入组件能力增强。包括:

  • 文本组件支持通过 NODE_IMMUTABLE_FONT_WEIGHT 属性,设置文字粗细不会跟随系统字体粗细而变化。(API 参考-C API[1]
  • 文本组件支持对选中的文本提供分享服务 (API 参考[2])、支持按音节连字符换行(API 参考[3])。
  • 富文本(RichEditor)组件支持设置最大行数。(API 参考[4]
  • TextInput 组件支持设置文本省略位置。(API 参考[5]
  • TextInput/TextArea/Search/RichEditor 组件支持将文本行间距平分至行的顶部与底部。([6]API 参考-TextInput[7]API 参考-TextArea[8]API 参考-Search[9]API 参考-RichEditor[10]
  • TextInput/TextArea 组件扩展自动填充类型,包含:车牌号、护照号等。(API 参考-ArkTS[11]API 参考-C API[12]
  • 富文本(RichEditor)组件在长按预览菜单时支持振动效果。(API 参考[13]

新增适配圆形屏幕的能力。包括:

  • 新增旋转表冠事件,组件获焦后扭动表冠可获取时间戳、旋转角速度、旋转角度和表冠动作信息。(API 参考[14]、指南[15])
  • 新增弧形列表组件 ArcList 和 ArcListItem,可呈现连续、多行的同类数据。(API 参考-ArcList[16]、API 参考-ArcListItem[17]、指南[18])
  • 新增弧形索引条组件 ArcAlphabetIndexer,可按字母顺排序进行快速定位。(API 参考[19]、指南[20])
  • 新增弧形滚动条组件 ArcScrollBar,可为弧形列表添加外置滚动条。(API 参考[21]、指南[22])
  • 新增弧形按钮组件 ArcButton,可提供强调、普通、警告等样式按钮。(API 参考[23]、指南[24])

Cloud Foundation Kit

云函数云数据库云存储服务支持 Wearable 设备。(指南[25]

NearLink Kit

  • 支持使用星闪传输数据。(指南[26]、API 参考[27])
  • 新增逻辑链路连接状态获取能力。(API 参考[28])
  • 新增数传链路连接状态获取能力。(API 参考[29])

Wear Engine Kit

新增支持 Wearable 设备。(指南[30]

DevEco Studio 5.1.0 Release

IDE 获取:https://developer.huawei.com/consumer/cn/download/

  • DevEco Studio 支持开发 API 18 工程。
  • DevEco Studio 支持使用 MacOS 15 系统版本进行开发。
  • DevEco Studio 支持 TV、Wearable 设备开发。

image-20250612133822418

参考资料

[1]

API参考-C API: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/_ark_u_i___native_module#arkui_nodeattributetype

[2]

API参考: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/ts-text-common#属性

[3]

API参考: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/ts-appendix-enums#wordbreak11

[4]

API参考: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/ts-basic-components-richeditor#maxlength18

[5]

API参考: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/ts-basic-components-textinput#ellipsismode18

[6]

(: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/ts-basic-components-textarea#halfleading18

[7]

API参考-TextInput: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/ts-basic-components-textinput#halfleading18

[8]

API参考-TextArea: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/arkui-ts/ts-basic-components-textarea#halfleading18

[9]

API参考-Search: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/ts-basic-components-search#halfleading18

[10]

API参考-RichEditor: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/ts-basic-components-richeditor#richeditortextstyleresult

[11]

API参考-ArkTS: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/ts-basic-components-textinput#contenttype12枚举说明

[12]

API参考-C API: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/_ark_u_i___native_module#arkui_textinputcontenttype

[13]

API参考: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/ts-basic-components-richeditor#previewmenuoptions18

[14]

API参考: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/ts-universal-events-crown

[15]

指南: https://developer.huawei.com/consumer/cn/doc/harmonyos-guides/arkts-common-events-crown-event

[16]

API参考-ArcList: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/ts-container-arclist

[17]

API参考-ArcListItem: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/ts-container-arclistitem

[18]

指南: https://developer.huawei.com/consumer/cn/doc/harmonyos-guides/arkts-layout-development-create-arclist

[19]

API参考: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/ts-container-arc-alphabet-indexer

[20]

指南: https://developer.huawei.com/consumer/cn/doc/harmonyos-guides/arkts-layout-development-create-arclist#与弧形索引条arcalphabetindexer联动

[21]

API参考: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/ts-basic-components-arcscrollbar

[22]

指南: https://developer.huawei.com/consumer/cn/doc/harmonyos-guides/arkts-layout-development-create-arclist#添加外置滚动条arcscrollbar

[23]

API参考: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/ohos-arkui-advanced-arcbutton

[24]

指南: https://developer.huawei.com/consumer/cn/doc/harmonyos-guides/arkts-advanced-components-arcbutton

[25]

指南: https://developer.huawei.com/consumer/cn/doc/harmonyos-guides/cloudfoundation-introduction#section1874715333414

[26]

指南: https://developer.huawei.com/consumer/cn/doc/harmonyos-guides/nearlink-start-data-transfer

[27]

API参考: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/nearlink-data-transfer-api

[28]

API参考: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/nearlink-remote-device#section945162120309

[29]

API参考: https://developer.huawei.com/consumer/cn/doc/harmonyos-references/nearlink-data-transfer-api#section9446731153818

[30]

指南: https://developer.huawei.com/consumer/cn/doc/harmonyos-guides/we-business_introduction#section1639461742

本文参与 腾讯云自媒体同步曝光计划,分享自微信公众号。
原始发表:2025-06-16,如有侵权请联系 cloudcommunity@tencent.com 删除

本文分享自 大前端之旅 微信公众号,前往查看

如有侵权,请联系 cloudcommunity@tencent.com 删除。

本文参与 腾讯云自媒体同步曝光计划  ,欢迎热爱写作的你一起参与!

评论
登录后参与评论
0 条评论
热度
最新
推荐阅读
领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档