Skip to content

Commit 043da55

Browse files
Merge pull request #2 from SyncfusionExamples/Update_Blog_Sample
Update on Blog Sample
2 parents 8cab7cd + 13aeda3 commit 043da55

File tree

3 files changed

+19
-8
lines changed

3 files changed

+19
-8
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,4 +45,4 @@ If you are facing a **Path too long** exception when building this project, foll
4545
2. Rename the repository to a shorter name.
4646
3. Reopen the project and build again.
4747

48-
For a step-by-step guide, refer to [Stock Analysis using Syncfusion MAUI Toolkit]()
48+
For a step-by-step guide, refer to [Stock Analysis using Syncfusion MAUI Toolkit](https://www.syncfusion.com/blogs/post/analyze-stocks-in-maui-toolkit-chart)

StockChart/StockChart/MainPage.xaml

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,19 @@
1010
<ContentPage.BindingContext>
1111
<local:StockViewModel x:Name="viewModel"></local:StockViewModel>
1212
</ContentPage.BindingContext>
13-
14-
<Border Margin="15" StrokeThickness="2" Stroke="#79747E">
15-
16-
<Border.StrokeShape>
17-
<RoundRectangle CornerRadius="10"/>
18-
</Border.StrokeShape>
13+
14+
<ContentPage.Resources>
15+
<Style x:Key="PlatformSpecificBorder" TargetType="Border">
16+
<Setter Property="Margin" Value="15" />
17+
<Setter Property="StrokeThickness" Value="2" />
18+
<Setter Property="Stroke" Value="#79747E" />
19+
<Setter Property="StrokeShape">
20+
<RoundRectangle CornerRadius="10"/>
21+
</Setter>
22+
</Style>
23+
</ContentPage.Resources>
24+
25+
<Border x:Name="MyBorder">
1926

2027
<Grid ColumnDefinitions="*,*" Margin="10,-10,20,15" >
2128

@@ -173,7 +180,7 @@
173180
ShowLabels="True"
174181
ShowTicks="True"
175182
LabelsPlacement="OnTicks"
176-
EdgeLabelsPlacement="Inside"
183+
EdgeLabelsPlacement="Default"
177184
DragBehavior="Both"
178185
EnableDeferredUpdate="False">
179186

StockChart/StockChart/MainPage.xaml.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ public partial class MainPage : ContentPage
88
public MainPage()
99
{
1010
InitializeComponent();
11+
if(DeviceInfo.Platform == DevicePlatform.WinUI || DeviceInfo.Platform == DevicePlatform.MacCatalyst)
12+
{
13+
MyBorder.Style = (Style)Resources["PlatformSpecificBorder"];
14+
}
1115
}
1216
private void SfSegmentedControl_SelectionChanged(object sender, Syncfusion.Maui.Toolkit.SegmentedControl.SelectionChangedEventArgs e)
1317
{

0 commit comments

Comments
 (0)