在我的项目顶部插入徽标 xamarin 表单 ios,android



我有一个项目,这个没有标志只写了公司的名称,如下图所示

在此处输入图像描述

现在我想把公司标志放在我的项目顶部,以保持完美的设计师,如下图所示

在此处输入图像描述

我正在使用 xamarin 表单并为 android 和 iOS 开发应用程序,如何在我的项目中执行此操作? 有人有任何例子吗?

编辑

<?xml version="1.0" encoding="UTF-8"?>
<ContentPage
xmlns="http://xamarin.com/schemas/2014/forms"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="projeto.Views.home"
x:Name="Name"
Title="Name" Icon="">

以下是页面外观的粗略布局:

<ContentPage
xmlns="http://xamarin.com/schemas/2014/forms"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="projeto.Views.home"
x:Name="Name"
Title="Name" Icon="">
<!--Content page may only have one child element-->
<StackLayout HorizontalOptions="FillAndExpand" VerticalOptions="FillAndExpand" Orientation="Vertical">
<Image Source="CompanyLogo.png" AspectRatio="AspectFit"/>
<StackLayout>
<!--Other content--->
</StackLayout>
</StackLayout>
</ContentPage>

请注意,这种非常基本的方法只是几种方法之一。您需要熟悉 xaml 以及可用于实现某些目标的不同组件。

最新更新