显示效果:

图片1.png (39.37 KB, 下载次数: 0)

2021-4-29 17:05 上传

点击已关闭右边的按钮可以开启

图片2.png (42.47 KB, 下载次数: 0)

2021-4-29 17:05 上传

可以调节亮度

图片3.png (42.92 KB, 下载次数: 0)

2021-4-29 17:05 上传

hml中的代码

{{ deviceName }}

{{ errorMessage }}

{{ message }}

{{ spreadText }}

@submit-server-click="dialogSubmitServer"

@cancel-click="dialogCancel()">

{{ $t('strings.prompt') }}

{{ $t('strings.useHiLink') }}

{{ $t('strings.hiLinkUrl') }}

显示效果:

图片4.png (124.13 KB, 下载次数: 0)

2021-4-29 17:06 上传

布局中的代码

xmlns:ohos="http://schemas.huawei.com/res/ohos"

ohos:id="$+id:root_layout"

ohos:height="match_parent"

ohos:width="match_parent"

ohos:orientation="vertical">

xmlns:ohos="http://schemas.huawei.com/res/ohos"

ohos:id="$+id:app_bar"

ohos:height="match_content"

ohos:width="match_parent"

ohos:layout="$layout:app_bar_layout"/>

ohos:id="$+id:app_content"

ohos:height="match_parent"

ohos:width="match_parent"

ohos:bottom_margin="$float:default_layout_margin"

ohos:end_margin="$float:default_layout_margin"

ohos:orientation="vertical"

ohos:start_margin="$float:default_layout_margin"

>

ohos:id="$+id:grid_layout"

ohos:height="match_parent"

ohos:width="match_parent"

ohos:align_parent_top="true"

ohos:background_element="$graphic:background_table_layout_up"

ohos:bottom_margin="$float:grid_layout_bottom_margin">

ohos:height="match_content"

ohos:width="match_parent"

ohos:alignment="center"

ohos:orientation="vertical">

ohos:id="$+id:table_layout_up"

ohos:height="match_content"

ohos:width="match_parent"

ohos:orientation="vertical">

ohos:id="$+id:grid_view_up"

ohos:height="match_content"

ohos:width="match_parent"

ohos:bottom_margin="4vp"

ohos:column_count="$integer:column_count"

ohos:end_margin="$float:default_layout_margin"

ohos:start_margin="$float:default_layout_margin"

ohos:top_margin="24vp">

ohos:id="$+id:table_layout_down"

ohos:height="match_content"

ohos:width="match_parent"

ohos:background_element="$graphic:background_table_layout_down"

ohos:orientation="vertical">

ohos:id="$+id:table_layout_down_desc"

ohos:height="match_content"

ohos:width="match_parent"

ohos:bottom_margin="$float:grid_layout_desc_bottom_margin"

ohos:end_margin="$float:default_layout_margin"

ohos:max_text_lines="2"

ohos:multiple_lines="true"

ohos:start_margin="$float:default_layout_margin"

ohos:text="$string:grid_layout_desc_text"

ohos:text_size="$float:grid_layout_desc_size"

ohos:top_margin="$float:grid_layout_desc_top_margin"/>

ohos:id="$+id:grid_view_down"

ohos:height="match_content"

ohos:width="match_content"

ohos:column_count="$integer:column_count"

ohos:end_margin="$float:default_layout_margin"

ohos:start_margin="$float:default_layout_margin">

ohos:height="match_content"

ohos:width="match_parent"

ohos:align_parent_bottom="true"

ohos:background_element="$graphic:background_bottom_layout"

ohos:layout_direction="locale"

ohos:orientation="horizontal">

ohos:id="$+id:bottom_left_button"

ohos:height="$float:bottom_button_height"

ohos:width="$float:bottom_button_width"

ohos:background_element="$graphic:background_bottom_button"

ohos:bottom_margin="$float:bottom_button_bottom_margin"

ohos:start_margin="$float:bottom_button_left_right_margin"

ohos:text="$string:bottom_button_text"

ohos:text_color="$color:bottom_button_text_color"

ohos:text_size="$float:grid_layout_desc_size"

ohos:top_margin="$float:bottom_button_top_margin">

ohos:id="$+id:bottom_right_button"

ohos:height="$float:bottom_button_height"

ohos:width="$float:bottom_button_width"

ohos:background_element="$graphic:background_bottom_button"

ohos:bottom_margin="$float:bottom_button_bottom_margin"

ohos:end_margin="$float:bottom_button_left_right_margin"

ohos:start_margin="$float:bottom_left_button_margin"

ohos:text="$string:bottom_button_text"

ohos:text_color="$color:bottom_button_text_color"

ohos:text_size="$float:grid_layout_desc_size"

ohos:top_margin="$float:bottom_button_top_margin">

TV版

图片5.png (29.53 KB, 下载次数: 0)

2021-4-29 17:06 上传

显示效果:

图片6.png (32.16 KB, 下载次数: 0)

2021-4-29 17:06 上传

可进行操作 裁剪不一样的

图片7.png (31.62 KB, 下载次数: 0)

2021-4-29 17:07 上传

布局中的代码

xmlns:ohos="http://schemas.huawei.com/res/ohos"

ohos:id="$+id:image_editor_main"

ohos:height="match_parent"

ohos:width="match_parent"

ohos:background_element="$color:background"

ohos:orientation="vertical">

ohos:id="$+id:appBar"

ohos:height="$float:height_appBar"

ohos:width="match_parent"

ohos:end_margin="$float:maxPadding"

ohos:orientation="horizontal"

ohos:start_margin="$float:maxPadding">

ohos:id="$+id:appBar_leftPart"

ohos:height="match_parent"

ohos:width="match_parent"

ohos:alignment="center"

ohos:orientation="horizontal"

ohos:weight="1">

ohos:id="$+id:appBar_backButton_touchTarget"

ohos:height="match_parent"

ohos:width="$float:size_touchTarget"

ohos:alignment="center">

ohos:id="$+id:appBar_backButton"

ohos:height="$float:size_appBar_buttons"

ohos:width="$float:size_appBar_buttons"

ohos:image_src="$graphic:ic_back"/>

ohos:id="$+id:appBar_userName"

ohos:height="match_parent"

ohos:width="match_parent"

ohos:start_margin="$float:leftMargin_appBar_text"

ohos:text="$string:title_appBar"

ohos:text_color="$color:appBar_Text"

ohos:text_size="$float:textSize_appBar"/>

ohos:id="$+id:appBar_rightPart"

ohos:height="match_parent"

ohos:width="match_parent"

ohos:alignment="vertical_center|right"

ohos:orientation="horizontal"

ohos:weight="1">

ohos:id="$+id:appBar_undoButton_touchTarget"

ohos:height="$float:size_touchTarget"

ohos:width="$float:size_touchTarget"

ohos:alignment="center">

ohos:id="$+id:appBar_undoButton"

ohos:height="$float:size_appBar_buttons"

ohos:width="$float:size_appBar_buttons"

ohos:image_src="$graphic:ic_undo"/>

ohos:id="$+id:appBar_redoButton_touchTarget"

ohos:height="$float:size_touchTarget"

ohos:width="$float:size_touchTarget"

ohos:alignment="center">

ohos:id="$+id:appBar_redoButton"

ohos:height="$float:size_appBar_buttons"

ohos:width="$float:size_appBar_buttons"

ohos:image_src="$graphic:ic_redo"/>

ohos:id="$+id:appBar_saveButton_touchTarget"

ohos:height="$float:size_touchTarget"

ohos:width="$float:size_touchTarget"

ohos:alignment="center">

ohos:id="$+id:appBar_saveButton"

ohos:height="$float:size_appBar_buttons"

ohos:width="$float:size_appBar_buttons"

ohos:image_src="$graphic:ic_save"/>

ohos:height="match_parent"

ohos:width="match_parent"

ohos:orientation="vertical"

ohos:weight="1">

ohos:id="$+id:edit_fraction_container"

ohos:height="match_parent"

ohos:width="match_parent"

ohos:weight="1">

ohos:id="$+id:edit_fraction"

ohos:height="match_parent"

ohos:width="match_parent"/>

ohos:id="$+id:adjust_toast"

ohos:height="match_parent"

ohos:width="match_parent"

ohos:text_alignment="center"

ohos:text_color="$color:adjust_text_normal"

ohos:text_size="$float:size_adjust_tips"/>

ohos:id="$+id:slideBar_container"

ohos:height="$float:height_slideBar"

ohos:width="match_parent"

ohos:alignment="center"

ohos:left_padding="$float:padding_slideBar"

ohos:right_padding="$float:padding_slideBar"/>

ohos:id="$+id:paraBar_container"

ohos:height="$float:height_paraBar"

ohos:width="match_parent"

ohos:alignment="center">

ohos:id="$+id:paraBar"

ohos:height="match_content"

ohos:width="match_parent"

ohos:fixed_mode="true"

ohos:orientation="horizontal"/>

ohos:id="$+id:toolBar_container"

ohos:height="$float:height_toolBar"

ohos:width="match_parent"

ohos:alignment="center"

ohos:bottom_margin="$float:margin_interval">

ohos:id="$+id:toolBar"

ohos:height="match_content"

ohos:width="match_parent"

ohos:fixed_mode="true"

ohos:orientation="horizontal"/>

完整代码地址:

鸿蒙应用开发在线体验,鸿蒙应用开发-DevEco Studio 模板体验(二)相关推荐

  1. Android高德地图基本开发/在线高德离线地图开发/断网使用离线地图(Assets文件夹的使用)

    文章目录 高德SDK基本使用 前置操作 需求一:显示地图,并以当前所在位置为中心 权限申请 布局功能代码 活动功能代码 效果展示 需求二:离线地图(直接添加到应用端项目内) 需求三 :点击数据后以数据 ...

  2. 【鸿蒙 HarmonyOS】创建 Java 语言 HarmonyOS 手机应用 ( 首次进入 DevEco Studio 配置环境 | 创建 Java 手机工程 | 鸿蒙工程代码目录简介 )

    文章目录 一.首次进入 DevEco Studio 配置环境 二.创建 Java 手机工程 三.鸿蒙工程代码目录简介 鸿蒙 HarmonyOS 开发环境 DevEco Studio 安装 , 参考博客 ...

  3. 华为DevEco Studio v1.0 亲自体验,有什么惊喜?

    最近什么最火? 自从9.10号开发者大会以来,鸿蒙系统一直是热中之火热. 那我们来看看华为消费者业务为开发者提供的集成开发环境吧. HUAWEI DevEco Studio初介绍 地址 https:/ ...

  4. 鸿蒙应用开发在线体验官网,华为鸿蒙 HarmonyOS 应用开发在线体验网站上线

    原标题:华为鸿蒙 HarmonyOS 应用开发在线体验网站上线 IT之家 4 月 22 日消息 华为 HarmonyOS 应用开发在线体验网站现已上线. 开发者可以通过在线体验"To-Do ...

  5. js动态创建两个div 把其中一个添加到另一个的里面_我开发了一个鸿蒙在线教育APP!...

    鸿蒙 2.0 已经发布了有段时间了,目前网上也有些小 demo 了,但是缺乏稍微大点的项目代码. 我准备计划开发一个稍微正式点的项目,我写了个初略的项目需求清单,来体验鸿蒙应用开发. 目前我已经着手实 ...

  6. 鸿蒙开发入门 | 开发第一个鸿蒙应用+页面跳转

    CSDN话题挑战赛第2期 参赛话题:学习笔记 准备好鸿蒙开发环境后,接下来就需要创建鸿蒙项目,掌握项目的创建过程以及配置.项目创建好后,需要把项目运行在模拟器上,鸿蒙的模拟和安卓模拟器有些不同,鸿蒙提 ...

  7. 华为鸿蒙2048小游戏,《从零开发鸿蒙小游戏App》直播答疑(包含新版2048游戏代码)...

    请到附件中下载新版2048游戏代码.最好能对该代码再做一些优化(见下述问题8),欢迎感兴趣的朋友随时跟我探讨,^_^ 问题1:如何将开发的Lite Wearable项目部署在鸿蒙手表Watch GT2 ...

  8. HarmonyOS开发语言,华为鸿蒙操作系统 HarmonyOS

    华为鸿蒙OS 下载地址:https://www.chtml.cn/product/show/10945 教程目录:https://www.chtml.cn/topic/show/10945 Harmo ...

  9. 鸿蒙so系统,鸿蒙手机版JNI实战(JNI开发、SO库生成、SO库使用)

    鸿蒙JNI开发现状 现阶段,不仅鸿蒙JNI相关的开发资料较少,而且Phone相关的JNI开发资料几乎没有,这对于新入行的鸿蒙开发者们来说,非常不友好. 也可能会给Android工程(使用了SO库的工程 ...

  10. 三、华为鸿蒙HarmonyOS应用开发HUAWEI DevEco Studio实现页面跳转

    在上一节二.华为鸿蒙开发DevEco Studio运行第一个Hello Word工程 基础上进行下面步骤. 在Java UI框架中,提供了两种编写布局的方式:在XML中声明UI布局和在代码中创建布局. ...

最新文章

  1. ubuntu下载安装MaskRCNN-benchmark
  2. BZOJ2331:[SCOI2011]地板——题解
  3. 全国计算机二级qq闪退,电脑上QQ闪退怎么回事?各个系统版本电脑QQ闪退现象的解决方法介绍...
  4. Eclipse Memory Analyzer 安装(Update Site: http://download.eclipse.org/mat/1.3.1/update-site/ )
  5. 记一次详细的的SQL查询经历,group by慢查询优化
  6. 「1s」即可!用 VS Code 一键玩转 GitHub 代码!
  7. winFrom窗体样式
  8. python编译安装没有c扩展_python – 为什么我在安装simplejson时得到“C扩展无法编译”?...
  9. Linux主流架构运维工作简单剖
  10. [文档]CSS中文字体对照表
  11. 思维导图案例之VeritasDCG
  12. 奇怪的技能又增加了,我学会了用ETS5配置KNX
  13. 惠普z800工作站bios设置_HP工作站 BIOS说明 适用Z228 Z440 Z230 Z640 Z840 Z800 Z620 Z420 Z820主板设置 -...
  14. PS 模块BAPI新建修改项目、WBS、网络、作业 (二)
  15. Windows10系统把JDK安装到D盘上的步骤及安装
  16. 【原创】高精度好题 Heaven Cow与God Bull
  17. CDPSE-数据隐私解决方案工程师
  18. 很酷的瞄准镜样式光标效果
  19. 前端使用Echart实现动态图表
  20. 益智拼图APP隐私政策

热门文章

  1. 190511每日一句
  2. 黑马程序员 Python学习笔记之 算数运算符
  3. 扇贝有道180913每日一句
  4. Atitit 高级人员要看哪些源码 目录 1. Ati看过的源码 1 1.1. Ui类 1 1.2. Mvc类 1 1.3. 数据库类 1 1.4. 算法类 1 2. 看源码的意义 2 2.1. 一
  5. Atitit 锁的不同层级 app锁 vm锁 os锁 硬件锁 目录 1. 在硬件层面,CPU提供了原子操作、关中断、锁内存总线的机制 1 1.1. test and set指令 1 1.2. 锁内
  6. Atitit 减少财政支出----获取商家商业机构的补贴措施 attilax大总结.docx
  7. atitit.提升备份文件复制速度(3) ----建立同步删除脚本
  8. paip.获取文件名从路径uapi java python php总结...
  9. paip.注册java程序为LINUX系统服务的总结。
  10. Rust: 如何在windows环境中用Atom中玩转它?--new