如何把导航默认在最底下显示?
<?xml version="1.0" encoding="utf-8"?>
<DirectionalLayout
xmlns:ohos="http://schemas.huawei.com/res/ohos"
ohos:height="match_parent"
ohos:width="match_parent"
ohos:orientation="vertical"
ohos:background_element="#FFE0E3E3">
<Text
ohos:id="$+id:text_helloworld"
ohos:height="match_content"
ohos:width="match_content"
ohos:layout_alignment="horizontal_center"
ohos:text="$string:mainability_HelloWorld"
ohos:text_size="40vp"
/>
<DirectionalLayout
xmlns:ohos="http://schemas.huawei.com/res/ohos"
ohos:height="match_content"
ohos:width="match_parent"
ohos:orientation="horizontal"
ohos:background_element="#FFFFFF"
>
<Button
ohos:id="$+id:dynamic"
ohos:height="match_content"
ohos:width="match_parent"
ohos:text="动态"
ohos:text_size="10vp"
ohos:element_top="$media:dt"
ohos:weight="1"/>
<Button
ohos:id="$+id:friend"
ohos:height="match_content"
ohos:width="match_parent"
ohos:text="好友"
ohos:text_size="10vp"
ohos:element_top="$media:hy"
ohos:weight="1"/>
<Button
ohos:id="$+id:function"
ohos:height="match_content"
ohos:width="match_parent"
ohos:text="功能"
ohos:text_size="10vp"
ohos:element_top="$media:gn"
ohos:weight="1"/>
<Button
ohos:id="$+id:set"
ohos:height="match_content"
ohos:width="match_parent"
ohos:text="我的"
ohos:text_size="10vp"
ohos:element_top="$media:yh"
ohos:weight="1"/>
</DirectionalLayout>
</DirectionalLayout>
鸿蒙
导航
显示
赞
收藏 0
回答 1
待解决
相关问题
Tabs的导航栏如何居顶部显示,不居中显示?
1891浏览 • 1回复 待解决
实现左边显示导航,右边显示显示具体页面效果的方案
801浏览 • 1回复 待解决
在鸿蒙4.0版本中有没有最简单的音频wav播放设置,最简单的代码?
930浏览 • 1回复 待解决
Tab导航栏tabbar子组件突出上沿显示
868浏览 • 1回复 待解决
何如把默认的左右动画换成上下动画?
3126浏览 • 1回复 待解决
tabs默认居中,我顶部的导航栏需要居左,要咋整?
1406浏览 • 1回复 待解决
Navigation如何隐藏导航栏
1077浏览 • 1回复 待解决
mage组件在Preview上可以显示,但是在真机上无法显示该图片
759浏览 • 1回复 待解决
如何将容器定位到屏幕的最底部
995浏览 • 1回复 待解决
组件在沉浸式的情况下在页面最底端不响应滚动手势
859浏览 • 1回复 待解决
太难了,能从最基础讲起吗?
5023浏览 • 1回复 待解决
Image组件如何设置默认图?
562浏览 • 1回复 待解决
TextInput如何取消默认聚焦效果
1160浏览 • 1回复 待解决
鸿蒙开发如何默认启动ability
7276浏览 • 3回复 待解决
priviewer为什么只能文字Text标签显示正常,图片Image标签都显示不出来,设置了默认图片的
6957浏览 • 2回复 待解决
Button如何设置state-container背景,目前button只能设置默认背景,无法显示点击动态效果?
5665浏览 • 1回复 待解决
如何设置Swiper导航点的样式?
29浏览 • 1回复 待解决
webview导航无法正常导航,怎么处理?
4574浏览 • 1回复 待解决
ArkTS如何把string转为byte数组
1521浏览 • 1回复 待解决
写文件的时候怎么设置把之前的内容清空之后在写
601浏览 • 1回复 待解决
使用navigation在折叠屏上展示双栏,右栏如何展示默认的page页面呢?
674浏览 • 1回复 待解决
鸿蒙WebView 层级 总是处于最外层
6286浏览 • 3回复 待解决
鸿蒙竖屏可以在底部显示的布局,在横屏显示不了是出了什么问题
5527浏览 • 1回复 待解决
导航栏如何适配,有人知道吗?
823浏览 • 0回复 待解决
Swiper组件如何设置导航点位置
810浏览 • 1回复 待解决
DirectionalLayout默认从上往下,楼主可以参考DependentLayout