<?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: Webmap legend in ArcGIS API for Python Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-python-questions/webmap-legend/m-p/846753#M3678</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks David, that works like a charm &lt;IMG src="https://community.esri.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 29 Nov 2018 21:58:04 GMT</pubDate>
    <dc:creator>simoxu</dc:creator>
    <dc:date>2018-11-29T21:58:04Z</dc:date>
    <item>
      <title>Webmap legend</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/webmap-legend/m-p/846747#M3672</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi folks:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A&amp;nbsp;very basic question:&amp;nbsp;&lt;STRONG&gt;How&amp;nbsp;to display map legend in the webmap widget? &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am really stuck&amp;nbsp;despite I've been trying and using ArcGIS Python API for a little while.&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is it even possible?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 11 Sep 2018 02:05:43 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/webmap-legend/m-p/846747#M3672</guid>
      <dc:creator>simoxu</dc:creator>
      <dc:date>2018-09-11T02:05:43Z</dc:date>
    </item>
    <item>
      <title>Re: Webmap legend</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/webmap-legend/m-p/846748#M3673</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If the charts from python matplotlib can have legend, I am sure maps should have legend too.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;After all what's the benefit of using sophisticated ArcGIS map rendering technology when the audience can not understand what the symbols and colors represent?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope&amp;nbsp;one of the group&amp;nbsp;admins can shed some light on this&amp;nbsp;&lt;IMG src="https://community.esri.com/legacyfs/online/emoticons/happy.png" /&gt;&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.esri.com/migrated-users/45514"&gt;Atma Mani&lt;/A&gt;&amp;nbsp;&lt;A href="https://community.esri.com/migrated-users/157558"&gt;Rohit Singh&lt;/A&gt;‌ &lt;A href="https://community.esri.com/migrated-users/2049"&gt;John Yaist&lt;/A&gt;‌&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 17 Sep 2018 00:05:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/webmap-legend/m-p/846748#M3673</guid>
      <dc:creator>simoxu</dc:creator>
      <dc:date>2018-09-17T00:05:34Z</dc:date>
    </item>
    <item>
      <title>Re: Webmap legend</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/webmap-legend/m-p/846749#M3674</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &lt;A href="https://community.esri.com/migrated-users/50987"&gt;Simo Xu&lt;/A&gt;‌ , thanks for the comments and suggestions. You are right that the audience could get confused by what the colors and symbols represent on the map widget without having a pictographic legend visible. While this functionality doesn't exist in our current 1.5 release, we will research the technical plausibility of adding in a legend for the widget, and will attempt to keep you updated. Thanks again for chiming in &lt;IMG src="https://community.esri.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 17 Sep 2018 20:38:45 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/webmap-legend/m-p/846749#M3674</guid>
      <dc:creator>Anonymous User</dc:creator>
      <dc:date>2018-09-17T20:38:45Z</dc:date>
    </item>
    <item>
      <title>Re: Webmap legend</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/webmap-legend/m-p/846750#M3675</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi David,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for the clarification.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Legend is so essential when mapping data in data science field. It's not like street map which&amp;nbsp;people can understand without a key / legend, because&amp;nbsp;of its ubiquity.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Since this function does not exist, I created a ArcGIS Idea, and&amp;nbsp;hope this could become a priority in the future development.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.esri.com/ideas/15551" target="_blank"&gt;https://community.esri.com/ideas/15551&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Jun 2021 08:50:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/webmap-legend/m-p/846750#M3675</guid>
      <dc:creator>simoxu</dc:creator>
      <dc:date>2021-06-22T08:50:02Z</dc:date>
    </item>
    <item>
      <title>Re: Webmap legend</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/webmap-legend/m-p/846751#M3676</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Update:&lt;/P&gt;&lt;P&gt;This is fixed in the version 1.5.1 release, see the #1 in the New list:&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://developers.arcgis.com/python/guide/release-notes/" title="https://developers.arcgis.com/python/guide/release-notes/"&gt;What's new in version 1.5.1 | ArcGIS for Developers&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But there is a catch: the legend is only available for the &lt;STRONG&gt;map widget (arcgis.widgets._mapview.MapView)&lt;/STRONG&gt; , but not for the&lt;STRONG&gt; webmap (arcgis.mapping._types.WebMap)&lt;/STRONG&gt;, and only by coding which is a one-liner, not that too bad although a button on the UI will be easier for end users. Hope all these issues will be addressed in coming versions.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A nice step towards the right direction. Thank you ESRI for listening and acting on our request. &lt;A href="https://community.esri.com/migrated-users/305084"&gt;David Vitale&lt;/A&gt;‌&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 29 Nov 2018 05:14:15 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/webmap-legend/m-p/846751#M3676</guid>
      <dc:creator>simoxu</dc:creator>
      <dc:date>2018-11-29T05:14:15Z</dc:date>
    </item>
    <item>
      <title>Re: Webmap legend</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/webmap-legend/m-p/846752#M3677</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &lt;A href="https://community.esri.com/migrated-users/10807"&gt;simo xu&lt;/A&gt;, glad to have helped out!! As to your points, yes the legend is only available for the &lt;STRONG&gt;MapView&lt;/STRONG&gt; widget class. However, if you instantiate a &lt;STRONG&gt;MapView&lt;/STRONG&gt; class directly, there is an &lt;STRONG&gt;item&lt;/STRONG&gt; argument which allows you to pass in an &lt;STRONG&gt;Item&lt;/STRONG&gt; instance of a WebMap or WebScene for visualization (See &lt;A href="https://esri.github.io/arcgis-python-api/apidoc/html/arcgis.widgets.html#mapview"&gt;here&lt;/A&gt;).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here's some sample code that might better explain this: Run these 2 blocks as 2 seperate code cells in a notebook:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;from arcgis.gis import GIS&lt;BR /&gt;gis = GIS()&lt;BR /&gt;wm_item = gis.content.get('8a567ebac15748d39a747649a2e86cf4')&lt;BR /&gt;wm_item&lt;/BLOCKQUOTE&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;from arcgis.mapping import WebMap&lt;BR /&gt;webmap = WebMap(wm_item)&lt;BR /&gt;webmap&lt;/BLOCKQUOTE&gt;&lt;P&gt;You will notice no option to specify a legend. However, if you then run this code cell, you will see the same WebMap visualized with the legend property callable (notice the arguments passed in on &lt;STRONG&gt;MapView &lt;/STRONG&gt;instantiation)&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;from arcgis.widgets import MapView&lt;BR /&gt;mapview = MapView(gis=gis, item=wm_item)&lt;BR /&gt;mapview.legend = True&lt;BR /&gt;mapview&lt;/BLOCKQUOTE&gt;&lt;P&gt;As for making the legend visible via a UI button, we decided to do this programmatically to keep the user interface simple (There isn't much space in a jupyter notebook widget to add buttons without things looking cluttered). We'll reconsider adding a UI button for future releases.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hopefully this fits your use case, let us know of any future concerns about the legend or anything else.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 29 Nov 2018 17:54:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/webmap-legend/m-p/846752#M3677</guid>
      <dc:creator>Anonymous User</dc:creator>
      <dc:date>2018-11-29T17:54:42Z</dc:date>
    </item>
    <item>
      <title>Re: Webmap legend</title>
      <link>https://community.esri.com/t5/arcgis-api-for-python-questions/webmap-legend/m-p/846753#M3678</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks David, that works like a charm &lt;IMG src="https://community.esri.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 29 Nov 2018 21:58:04 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-python-questions/webmap-legend/m-p/846753#M3678</guid>
      <dc:creator>simoxu</dc:creator>
      <dc:date>2018-11-29T21:58:04Z</dc:date>
    </item>
  </channel>
</rss>

