laptop and a wrench

Bug

Graphic with TextSymbol does not draw when Polygon Graphic is added to the view twice.

Zuletzt veröffentlicht: December 31, 2020 ArcGIS API for JavaScript
Bug-ID-Nummer BUG-000135688
EingereichtNovember 24, 2020
Zuletzt geändertJune 5, 2024
Gilt fürArcGIS API for JavaScript
Gefunden in Version4.17
BetriebssystemWindows OS
Betriebssystemversion10.0
StatusNon-Reproducible

Zusätzliche Informationen

The code appears to be the issue. If the user zooms in or out after the original test app loads, the text appears to be fine. https://codepen.io/lxie/pen/QWEeroL?editors=1000 If the user adds a delay before adding the second polygon graphic, the text appears fine. https://codepen.io/noash/pen/wvzzByO

Workaround

To add a graphic to the view for the second time, use Graphic.clone() to create a deep clone of the graphic object, and add the clone to the view instead. 

  • Graphic.clone(): https://developers.arcgis.com/javascript/latest/api-reference/esri-Graphic.html#clone

Schritte zur Reproduzierung

Bug-ID: BUG-000135688

Software:

  • ArcGIS API for JavaScript

Benachrichtigung erhalten, wenn sich der Status eines Bugs ändert

Esri Support App herunterladen

Weitere Informationen zu diesem Thema erkunden

Unterstützung durch ArcGIS-Experten anfordern

An den technischen Support wenden

Esri Support App herunterladen

Zu Download-Optionen wechseln