xamarin - 如何在 xamarin android 中创建/设计自定义底部导航栏并将其连接到 xamarin.forms
问题描述
我想使用带有底部标签的标签页。我想在 android 中制作自定义底栏并在 TabbedPageRenderer 中使用它或对其进行充气。这可能吗?谁能帮我?
我想使用这样的东西。
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<FrameLayout android:id="@+id/bottomtab.navarea" android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_gravity="fill"
android:layout_weight="1" />
<android.support.design.widget.BottomNavigationView android:id="@+id/bottomtab.tabbar" android:theme="@style/Widget.Design.BottomNavigationView" android:layout_width="match_parent"
android:layout_height="wrap_content"/>
</LinearLayout>
然后在我的 TabbedPageRenderer 中,我只想将此布局用于底栏的设计。
就像您可以从 android 访问 Toolbar 和 Tabbar 一样。同样,我想访问或创建底部栏。
解决方案
推荐阅读
- c++ - 来自 QVariantList 的 std::function 的通用调用
- ios - 以不同的时间重复通知
- python - 尽管文件存在,但从 Python 中找不到文件
- javascript - 将结果放入变量中
- firebase - Fabric 不允许我链接我的 Firebase 应用
- c# - 使用 Json.Net 序列化对象列表而不是单个对象时出现类型信息
- node.js - 我们可以在服务器端获取谷歌分析报告,而不重定向到谷歌页面并要求登录吗?
- android - 如何在滚动视图周围显示带有 Imageview 的 Linearlayout?
- sql - SQL 按列 IN listOfColumnNames 分区
- ios - 在 iTunes 连接中添加和使用开发者用户帐户