Good afternoon. Please tell me how can I change the Z index of the annotations so that the box annotation can overlap the text. Now no matter how I try to do it, the text is always above the rectangles. Does the JS version have some layers with annotations that can be changed by they Z like in this question – https://www.scichart.com/questions/wpf/changing-an-annotations-z-index
Unfortunately, I did not find this functionality in the JS version.
-
I realized that I can position the annotations along the z-axis just by changing their order, but why doesn’t this work with text annotations then? I noticed that the text is always above any other annotations. Here is an example with codepen (https://codepen.io/PodaRocheK/pen/wvRgzEg?editors=0011), where you can see that the BoxAnnotation that was added after the text is not on top. You can swap them around and visually nothing will change. Thanks for the answer.
- You must login to post comments
Hi Yevhenni
The z-Index of annotations in SciChart.js is simply the order they are in the sciChartSurface.annotations
collection.
Just re-order the annotations and the z-index will change. This functionality also exists in WPF (order of annotations in SciChartSurface.Annotations
) as we aim for feature and API parity across platforms. FYI Panel.ZIndex
is a specific WPF API (not a SciChart API) and not available in JavaScript.
Best regards
Andrew
- Andrew Burnett-Thompson answered 8 months ago
- last edited 8 months ago
- You must login to post comments
I realized that I can position the annotations along the z-axis just by changing their order, but why doesn’t this work with text annotations then? I noticed that the text is always above any other annotations. Here is an example with codepen (https://codepen.io/PodaRocheK/pen/wvRgzEg?editors=0011), where you can see that the BoxAnnotation that was added after the text is not on top. You can swap them around and visually nothing will change. Thanks for the answer.
- Yevhenii Krasovskyi answered 7 months ago
- You must login to post comments
Please login first to submit.