私はXamarin pclを働いています。今Androidのプロジェクトには、ツールバーとタブバーの自動レンダリングレイアウトがあります。私はtoolbar.axmlを中心にアイコンを持つようにカスタマイズしています。すべてのページが戻るボタン(私は推測するナビゲーションページの属性)を終了するまで、それはもはやツールバーの唯一のものではないので、アイコンが右に移動するすべてが終了します。アイコンを固定位置にする簡単な修正はありますか?戻るボタンは、axmlでは宣言されていませんが、Xamarin.Formsの新しいNavigationPage()関数によって生成されます。ツールバーの中央に画像を固定するAndroid
マイAXMLは次のように今見える:私はすでにアンドロイドの使用を検討
<?xml version="1.0" encoding="utf-8"?>
<android.support.v7.widget.Toolbar xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/toolbar"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="#72B1A2"
android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar"
android:popupTheme="@style/ThemeOverlay.AppCompat.Light"
>
<ImageView
android:id="@id/image"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:paddingTop="5dp"
android:paddingBottom="5dp"
android:layout_gravity="center"
android:baselineAlignBottom="true"
android:scaleType="fitCenter"
android:src="@drawable/ictzaak_FC"
/>
</android.support.v7.widget.Toolbar>
:layout_gravity = "センター" とAndroid:layout_gravity = "center_horizontal" とAndroid:center_horizontalか何かが、それはdidnのトン、それがどのように見えるか、それ
を修正: Startup screen without the return button
With return button and out of center
あなたのツールバーに継承されたスタイルは、あなたのxmlでのオーバーライドはあなたにこれを追加することであることを確認してアプリ、ツールバー" – AbuQauod
どこに追加しますか?マニフェストまたはtoolbar.axmlにありますか? – ICTzaakDEV