Change ENC display settings

View inWPFUWPFormsiOSAndroid
View on GitHub
Sample viewer app

Configure the display of ENC content.

Image of change ENC display settings app

Use case

The S-52 standard defines how Electronic Navigational Chart (ENC) content should be displayed to ensure that data is presented consistently across every charting system. S-52 defines several display options, including variations on symbology to ensure that charts are readable both at night and in direct sunlight.

How to use the sample

The sample displays an electronic navigational chart when it opens. Use the options to choose variations on colors and symbology.

How it works

  1. Load the ENC exchange set.
  2. Configure EncEnvironmentSettings.Default.DisplaySettings as specified by the user. The sample exposes options for color scheme, area symbolization, and point symbolization.
  3. When the view unloads, call ResetToDefaults on the various display settings. Because the settings affect all ENCs displayed by Runtime, failing to reset them would affect other views.

Relevant API

  • EncAreaSymbolizationType
  • EncAreaSymbolizationType.Plain
  • EncAreaSymbolizationType.Symbolized
  • EncColorScheme
  • EncColorScheme.Day
  • EncColorScheme.Dusk
  • EncColorScheme.Night
  • EncDisplaySettings
  • EncDisplaySettings.MarinerSettings
  • EncDisplaySettings.TextGroupVisibilitySettings
  • EncDisplaySettings.ViewingGroupSettings
  • EncEnvironmentSettings
  • EncEnvironmentSettings.Default
  • EncMarinerSettings.ResetToDefaults
  • EncPointSymbolizationType
  • EncPointSymbolizationType.PaperChart
  • EncPointSymbolizationType.Simplified
  • EncTextGroupVisibilitySettings.ResetToDefaults
  • EncViewingGroupSettings.ResetToDefaults

Offline data

This sample downloads the ENC Exchange Set without updates item from ArcGIS Online.

About the data

This sample uses a fictitious ENC exchange set designed for testing.

Tags

display, ENC, hydrographic, hydrography, IHO, layers, maritime, nautical chart, S-52, S-57, settings, symbology

Sample Code

ChangeEncDisplaySettings.xamlChangeEncDisplaySettings.xaml.cs
                                                        
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
<UserControl x:Class="ArcGISRuntime.WPF.Samples.ChangeEncDisplaySettings.ChangeEncDisplaySettings"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
             xmlns:esri="http://schemas.esri.com/arcgis/runtime/2013"
             mc:Ignorable="d">
    <UserControl.Resources>
        <Style TargetType="RadioButton">
            <Setter Property="Margin" Value="0,5,5,10" />
        </Style>
    </UserControl.Resources>
    <Grid>
        <esri:MapView x:Name="MyMapView" />
        <Border Style="{StaticResource BorderStyle}" Width="225">
            <StackPanel>
                <TextBlock Text="Color scheme"
                           FontWeight="Bold" />
                <StackPanel Orientation="Horizontal">
                    <RadioButton x:Name="DayRadioButton"
                                 GroupName="ColorScheme"
                                 Content="Day"
                                 IsChecked="True" />
                    <RadioButton x:Name="DuskRadioButton"
                                 GroupName="ColorScheme"
                                 Content="Dusk" />
                    <RadioButton x:Name="NightRadioButton"
                                 GroupName="ColorScheme"
                                 Content="Night" />
                </StackPanel>
                <TextBlock Text="Area symbolization type"
                           FontWeight="Bold" />
                <StackPanel Orientation="Horizontal">
                    <RadioButton x:Name="PlainAreaRadioButton"
                                 GroupName="Area"
                                 Content="Plain"
                                 IsChecked="True" />
                    <RadioButton x:Name="SymbolizedAreaRadioButton"
                                 GroupName="Area"
                                 Content="Symbolized" />
                </StackPanel>
                <TextBlock Text="Point symbolization type"
                           FontWeight="Bold" />
                <StackPanel Orientation="Horizontal">
                    <RadioButton x:Name="PaperchartRadioButton"
                                 GroupName="Point"
                                 Content="Paper Chart"
                                 IsChecked="True" />
                    <RadioButton x:Name="SimplifiedRadioButton"
                                 GroupName="Point"
                                 Content="Simplified" />
                </StackPanel>
            </StackPanel>
        </Border>
    </Grid>
</UserControl>

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.