<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: ViewInsets not centering map point when left panel is present in .NET Maps SDK Questions</title>
    <link>https://community.esri.com/t5/net-maps-sdk-questions/viewinsets-not-centering-map-point-when-left-panel/m-p/746591#M9329</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I believe you might be hitting a 100.1 bug where calling setviewpointasync immediately after updating the viewinsets has no effect. Try adding a small delay between setting the insets and calling setviewpointasync, and see if that doesn't workaround the problem.&lt;/P&gt;&lt;P&gt;The delay should be about how long it takes for the mapview to complete a render cycle (usually 16-32ms depending on the framerate, so set it a little higher than this to make sure)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 08 Nov 2017 23:46:04 GMT</pubDate>
    <dc:creator>dotMorten_esri</dc:creator>
    <dc:date>2017-11-08T23:46:04Z</dc:date>
    <item>
      <title>ViewInsets not centering map point when left panel is present</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/viewinsets-not-centering-map-point-when-left-panel/m-p/746590#M9328</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="margin: 0in; margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 11.5pt; font-family: 'Helvetica',sans-serif; color: #3d3d3d;"&gt;Using ArcGIS Runtime SDK for .NET -&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 11.5pt; font-family: 'Segoe UI',sans-serif; color: black;"&gt;Version: 100.1.0.0&lt;/SPAN&gt;,&lt;SPAN style="font-size: 11.5pt; font-family: 'Helvetica',sans-serif; color: #3d3d3d;"&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;I am trying to use the GeoView.ViewInsets property to properly center a map point when a panel pulls out from the left. I am doing this by setting&amp;nbsp;mapview.ViewInsets = new Thickness(panelWidth, 0, 0, 0), with mapView being a MapView.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin: 0in; margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 11.5pt; font-family: 'Helvetica',sans-serif; color: #3d3d3d;"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin: 0in; margin-bottom: .0001pt; word-wrap: break-word; font-variant-ligatures: normal; font-variant-caps: normal; orphans: 2; text-align: start; widows: 2; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial; word-spacing: 0px;"&gt;&lt;SPAN style="font-size: 11.5pt; font-family: 'Helvetica',sans-serif; color: #3d3d3d;"&gt;However, when I call&amp;nbsp;await mapView.SetViewpointCenterAsync after setting the ViewInsets, it is still centering the map point on the map as if the panel isn't there. When I put a breakpoint there I can see that the ViewInsets have been set to what I want, and even when I change different parts of the ViewInsets it still centers in the same place.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin: 0in; margin-bottom: .0001pt; word-wrap: break-word; font-variant-ligatures: normal; font-variant-caps: normal; orphans: 2; text-align: start; widows: 2; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial; word-spacing: 0px;"&gt;&lt;SPAN style="font-size: 11.5pt; font-family: 'Helvetica',sans-serif; color: #3d3d3d;"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin: 0in; margin-bottom: .0001pt; word-wrap: break-word; font-variant-ligatures: normal; font-variant-caps: normal; orphans: 2; text-align: start; widows: 2; -webkit-text-stroke-width: 0px; text-decoration-style: initial; text-decoration-color: initial; word-spacing: 0px;"&gt;&lt;SPAN style="font-size: 11.5pt; font-family: 'Helvetica',sans-serif; color: #3d3d3d;"&gt;Is SetViewpointCenterAsync the correct method to call if I want to center a point properly, taking the ViewInsets into account, or is there a different method I should be using? If it is the proper method, what else could be causing this not to center correctly?&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin: 0in; margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 11.5pt; font-family: 'Helvetica',sans-serif; color: #3d3d3d;"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin: 0in; margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 11.5pt; font-family: 'Helvetica',sans-serif; color: #3d3d3d;"&gt;I’ve attached a rough illustration of what’s going on.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin: 0in; margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 11.5pt; font-family: 'Helvetica',sans-serif; color: #3d3d3d;"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin: 0in; margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 11.5pt; font-family: 'Helvetica',sans-serif; color: #3d3d3d;"&gt;The black represents the panel&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin: 0in; margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 11.5pt; font-family: 'Helvetica',sans-serif; color: #3d3d3d;"&gt;The green represents the map&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="margin: 0in; margin-bottom: .0001pt;"&gt;&lt;SPAN style="font-size: 11.5pt; font-family: 'Helvetica',sans-serif; color: #3d3d3d;"&gt;The red dot represents the map point that should be centered in relation to the map area&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Nov 2017 17:33:31 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/viewinsets-not-centering-map-point-when-left-panel/m-p/746590#M9328</guid>
      <dc:creator>WilliamLockwood</dc:creator>
      <dc:date>2017-11-07T17:33:31Z</dc:date>
    </item>
    <item>
      <title>Re: ViewInsets not centering map point when left panel is present</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/viewinsets-not-centering-map-point-when-left-panel/m-p/746591#M9329</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I believe you might be hitting a 100.1 bug where calling setviewpointasync immediately after updating the viewinsets has no effect. Try adding a small delay between setting the insets and calling setviewpointasync, and see if that doesn't workaround the problem.&lt;/P&gt;&lt;P&gt;The delay should be about how long it takes for the mapview to complete a render cycle (usually 16-32ms depending on the framerate, so set it a little higher than this to make sure)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Nov 2017 23:46:04 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/viewinsets-not-centering-map-point-when-left-panel/m-p/746591#M9329</guid>
      <dc:creator>dotMorten_esri</dc:creator>
      <dc:date>2017-11-08T23:46:04Z</dc:date>
    </item>
  </channel>
</rss>

