|
| 1 | +<?xml version="1.0" encoding="utf-8" ?> |
| 2 | +<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui" |
| 3 | + xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" |
| 4 | + x:Class="BarChart.MainPage" |
| 5 | + xmlns:chart="clr-namespace:Syncfusion.Maui.Charts;assembly=Syncfusion.Maui.Charts" |
| 6 | + xmlns:model="clr-namespace:BarChart"> |
| 7 | + |
| 8 | + <ContentPage.BindingContext> |
| 9 | + <model:ViewModel/> |
| 10 | + </ContentPage.BindingContext> |
| 11 | + |
| 12 | + <Border Stroke="Lightgray" StrokeThickness="1" Margin="{OnPlatform Default='5,15,5,5', iOS='25,0,20,25'}"> |
| 13 | + <Border.StrokeShape> |
| 14 | + <RoundRectangle CornerRadius="10"/> |
| 15 | + </Border.StrokeShape> |
| 16 | + |
| 17 | + <Grid BackgroundColor="#011327"> |
| 18 | + <Grid.ColumnDefinitions> |
| 19 | + <ColumnDefinition/> |
| 20 | + <ColumnDefinition/> |
| 21 | + </Grid.ColumnDefinitions> |
| 22 | + |
| 23 | + <Grid.RowDefinitions> |
| 24 | + <RowDefinition Height="1*"></RowDefinition> |
| 25 | + <RowDefinition Height="9*"></RowDefinition> |
| 26 | + </Grid.RowDefinitions> |
| 27 | + |
| 28 | + <HorizontalStackLayout Grid.Row="0" Grid.Column="0" Grid.ColumnSpan="2"> |
| 29 | + <StackLayout Margin="{OnPlatform Default='10,14,10,5',Android='7,12,5,3',MacCatalyst='10,-10,10,5'}" WidthRequest="{OnPlatform Default=16,Android=10,iOS=10}" HeightRequest="{OnPlatform Default=48,Android=33,iOS=31}" BackgroundColor="#a37bf8"/> |
| 30 | + <VerticalStackLayout> |
| 31 | + <Label Margin="{OnPlatform Default='0,14,0,8', Android='0,0,0,4',iOS='0,5,0,2'}" Text="Comparing Generative AI Use for Creating Media vs Obtaining Information" |
| 32 | + TextColor="White" |
| 33 | + FontSize="{OnPlatform Android=15, WinUI=18, iOS=14, MacCatalyst=18}" |
| 34 | + FontFamily="TimeSpan" |
| 35 | + FontAttributes="Bold"/> |
| 36 | + <Label Text="The percentage of respondents who have attempted to use a generative AI tool (e.g. ChatGPT) for the following applications" |
| 37 | + TextColor="White" |
| 38 | + FontSize="{OnPlatform Android=12, WinUI=15, iOS=11, MacCatalyst=15}" |
| 39 | + FontFamily="TimeSpan"/> |
| 40 | + </VerticalStackLayout> |
| 41 | + </HorizontalStackLayout> |
| 42 | + |
| 43 | + <chart:SfCartesianChart Grid.Column="0" Grid.Row="1" Margin="{OnPlatform Default='25,25,25,25',iOS='-15,25,25,25'}" IsTransposed="True" > |
| 44 | + |
| 45 | + <chart:SfCartesianChart.Title> |
| 46 | + <HorizontalStackLayout Margin="{OnPlatform Default='0,0,0,20', iOS ='0,0,0,10', Android='0,0,0,10'}" HorizontalOptions="Center"> |
| 47 | + <Label Text="For getting information" FontFamily="TimeSpan" TextColor="White" FontAttributes="Bold" FontSize="{OnPlatform Android=15, WinUI=18, iOS=15, MacCatalyst=18}" HorizontalOptions="Center" ></Label> |
| 48 | + </HorizontalStackLayout> |
| 49 | + </chart:SfCartesianChart.Title> |
| 50 | + |
| 51 | + <chart:SfCartesianChart.XAxes> |
| 52 | + <chart:CategoryAxis IsInversed="True" ShowMajorGridLines="False"> |
| 53 | + <chart:CategoryAxis.AxisLineStyle> |
| 54 | + <chart:ChartLineStyle Stroke="#011327"/> |
| 55 | + </chart:CategoryAxis.AxisLineStyle> |
| 56 | + <chart:CategoryAxis.MajorTickStyle> |
| 57 | + <chart:ChartAxisTickStyle Stroke="#011327"/> |
| 58 | + </chart:CategoryAxis.MajorTickStyle> |
| 59 | + <chart:CategoryAxis.LabelStyle> |
| 60 | + <chart:ChartAxisLabelStyle FontSize="{OnPlatform Default=17,Android=8,iOS=8}" TextColor="White" ></chart:ChartAxisLabelStyle> |
| 61 | + </chart:CategoryAxis.LabelStyle> |
| 62 | + </chart:CategoryAxis> |
| 63 | + </chart:SfCartesianChart.XAxes> |
| 64 | + |
| 65 | + <chart:SfCartesianChart.YAxes> |
| 66 | + <chart:NumericalAxis ShowMajorGridLines="False" IsVisible="False" > |
| 67 | + <chart:NumericalAxis.AxisLineStyle> |
| 68 | + <chart:ChartLineStyle Stroke="#011327"/> |
| 69 | + </chart:NumericalAxis.AxisLineStyle> |
| 70 | + <chart:NumericalAxis.MajorTickStyle> |
| 71 | + <chart:ChartAxisTickStyle Stroke="#011327"/> |
| 72 | + </chart:NumericalAxis.MajorTickStyle> |
| 73 | + </chart:NumericalAxis> |
| 74 | + </chart:SfCartesianChart.YAxes> |
| 75 | + |
| 76 | + <chart:ColumnSeries ItemsSource="{Binding GettingInformationDetails}" |
| 77 | + ShowDataLabels="True" |
| 78 | + Fill="#a37bf8" |
| 79 | + XBindingPath="Purpose" |
| 80 | + YBindingPath="Percentage"> |
| 81 | + <chart:ColumnSeries.DataLabelSettings> |
| 82 | + <chart:CartesianDataLabelSettings UseSeriesPalette="False" LabelPlacement="Inner"> |
| 83 | + <chart:CartesianDataLabelSettings.LabelStyle> |
| 84 | + <chart:ChartDataLabelStyle FontSize="{OnPlatform Default=15,Android=10,iOS=10}" FontAttributes="Bold" TextColor="Black" ></chart:ChartDataLabelStyle> |
| 85 | + </chart:CartesianDataLabelSettings.LabelStyle> |
| 86 | + </chart:CartesianDataLabelSettings> |
| 87 | + </chart:ColumnSeries.DataLabelSettings> |
| 88 | + </chart:ColumnSeries> |
| 89 | + |
| 90 | + </chart:SfCartesianChart> |
| 91 | + |
| 92 | + <chart:SfCartesianChart Grid.Column="1" Grid.Row="1" Margin="25" IsTransposed="True" > |
| 93 | + |
| 94 | + <chart:SfCartesianChart.Title> |
| 95 | + <HorizontalStackLayout Margin="{OnPlatform Default='0,0,0,20', iOS='0,0,0,10', Android='0,0,0,10'}" HorizontalOptions="Center" > |
| 96 | + <Label Text="For creating media" FontFamily="TimeSpan" TextColor="White" FontAttributes="Bold" FontSize="{OnPlatform Android=15, WinUI=18, iOS=15, MacCatalyst=18}" HorizontalOptions="Center" ></Label> |
| 97 | + </HorizontalStackLayout> |
| 98 | + </chart:SfCartesianChart.Title> |
| 99 | + |
| 100 | + <chart:SfCartesianChart.XAxes> |
| 101 | + <chart:CategoryAxis IsInversed="True" ShowMajorGridLines="False"> |
| 102 | + <chart:CategoryAxis.AxisLineStyle> |
| 103 | + <chart:ChartLineStyle Stroke="#011327"/> |
| 104 | + </chart:CategoryAxis.AxisLineStyle> |
| 105 | + <chart:CategoryAxis.MajorTickStyle> |
| 106 | + <chart:ChartAxisTickStyle Stroke="#011327"/> |
| 107 | + </chart:CategoryAxis.MajorTickStyle> |
| 108 | + <chart:CategoryAxis.LabelStyle> |
| 109 | + <chart:ChartAxisLabelStyle FontSize="{OnPlatform Default=17,Android=8,iOS=8}" TextColor="White"></chart:ChartAxisLabelStyle> |
| 110 | + </chart:CategoryAxis.LabelStyle> |
| 111 | + </chart:CategoryAxis> |
| 112 | + </chart:SfCartesianChart.XAxes> |
| 113 | + |
| 114 | + <chart:SfCartesianChart.YAxes> |
| 115 | + <chart:NumericalAxis ShowMajorGridLines="False" IsVisible="False"/> |
| 116 | + </chart:SfCartesianChart.YAxes> |
| 117 | + |
| 118 | + <chart:ColumnSeries ItemsSource="{Binding CreatingMediaDetails}" |
| 119 | + ShowDataLabels="True" |
| 120 | + Fill="#bbece9" |
| 121 | + XBindingPath="Purpose" |
| 122 | + YBindingPath="Percentage"> |
| 123 | + <chart:ColumnSeries.DataLabelSettings> |
| 124 | + <chart:CartesianDataLabelSettings UseSeriesPalette="False" LabelPlacement="Inner"> |
| 125 | + <chart:CartesianDataLabelSettings.LabelStyle> |
| 126 | + <chart:ChartDataLabelStyle FontSize="{OnPlatform Default=15,Android=10,iOS=10}" FontAttributes="Bold" TextColor="Black" ></chart:ChartDataLabelStyle> |
| 127 | + </chart:CartesianDataLabelSettings.LabelStyle> |
| 128 | + </chart:CartesianDataLabelSettings> |
| 129 | + </chart:ColumnSeries.DataLabelSettings> |
| 130 | + </chart:ColumnSeries> |
| 131 | + |
| 132 | + </chart:SfCartesianChart> |
| 133 | + </Grid> |
| 134 | + </Border> |
| 135 | + |
| 136 | +</ContentPage> |
0 commit comments