Similar to the "Spectrogram cross-section" demo, I implemented a wrapper for my application. But in addition, I'd like to be able to move both lines simultaneously if the mouse pointer started dragging near the intersection of the lines:
At the moment, I am doing this with a transparent AnnotationXY (Style = AnnotationStyle.Rectangle). Unfortunately, the annotation is always right and below the Location (with LocationCoordinateSystem = CoordinateSystem.AxisValues). If I switch to CoordinateSystem.RelativeCoordinatesToTarget, I can center the rectangle with LocationRelativeOffset, but then I run into problems with the moved event.
While LocationAxisValuesChangedByMouse delivers the correct value, LocationRelativeOffsetChangedByMouse seems to deliver ScreenCoordinates.
At this point, I cannot figure out a solution to fix this. Do you have any advice?
Thanks, Andreas
LCU 7.0.2
Another user with the same problem: http://www.arction.com/forum/viewtopic. ... shair#p773
Crosshair cursor for IntensityGridSeries
Moderator: Queue Moderators
Crosshair cursor for IntensityGridSeries
- Attachments
-
- AL_CursorCrosshair.zip
- Sample Code
- (7.73 KiB) Downloaded 652 times
- ArctionPasi
- Posts: 1367
- Joined: Tue Mar 26, 2013 10:57 pm
- Location: Finland
- Contact:
Re: Crosshair cursor for IntensityGridSeries
Hi,
how about adding another LineSeriesCursor and ConstantLine with LineStyle.Width = 20 etc, transparent? In the position changed event handler, update the visible cursors position?
how about adding another LineSeriesCursor and ConstantLine with LineStyle.Width = 20 etc, transparent? In the position changed event handler, update the visible cursors position?
LightningChart Support Team, PT
Re: Crosshair cursor for IntensityGridSeries
I'm sorry, I do not understand what you're proposing.
The problem is, that I cannot move the crosshair in both directions at the same time. ConstantLine and LineSeriesCursor do not include the coordinate for the other axis in their respective MovedByMouse events. Thus the workaround with the transparent annotation which can be moved freely. I just cannot get it to align properly on the crosshair, i.e. centered.
Please try my sample code to see the problem. I tried to recreate the image, the first one probably was too confusing.
The problem is, that I cannot move the crosshair in both directions at the same time. ConstantLine and LineSeriesCursor do not include the coordinate for the other axis in their respective MovedByMouse events. Thus the workaround with the transparent annotation which can be moved freely. I just cannot get it to align properly on the crosshair, i.e. centered.
Please try my sample code to see the problem. I tried to recreate the image, the first one probably was too confusing.