Search found 73 matches

by TLC
Fri Nov 22, 2024 3:37 pm
Forum: .NET
Topic: Annotations are broken. Can't draw on the canvas.
Replies: 17
Views: 15427

Re: Annotations are broken. Can't draw on the canvas.

Found the problem-- I added the following and it fixed it as i'm initiating the draw from another place.

Code: Select all

    protected override void ChartEvent( EventArgs e ) { } // => base.ChartEvent( e );
by TLC
Wed Nov 20, 2024 4:15 pm
Forum: .NET
Topic: Annotations are broken. Can't draw on the canvas.
Replies: 17
Views: 15427

Re: Annotations are broken. Can't draw on the canvas.

Hello, which code are you using to draw the annotation? Drawing the annotation inside the OnAfterDraw event should do the trick. If you send me code that you're using I can check it here. Thanks Unfortunately, I can't send the source code as its private. it is possible the AfterDraw event is gettin...
by TLC
Tue Nov 19, 2024 8:07 pm
Forum: .NET
Topic: Annotations are broken. Can't draw on the canvas.
Replies: 17
Views: 15427

Re: Annotations are broken. Can't draw on the canvas.

Somehow, the annotation popup hangs around after it is redrawn/invalidated. Only the most recent previous popup is visible aside from the current one. In otherwords, once you click again, it will remove the 2nd oldest, keeping the previous and draws the new one. The arrow from is the current one, th...
by TLC
Thu Nov 14, 2024 10:27 pm
Forum: .NET
Topic: Steema.TeeChart.Tools.NearestPoint Change event doesn't trigger
Replies: 6
Views: 6002

Re: Steema.TeeChart.Tools.NearestPoint Change event doesn't trigger

So i found the cause... and it's a few issues from the source code: Most of it is instead of leaving the value as a double, you are converting it to an int. This is a loss of precision and can greatly affect the developer when trying to figure out which point the end users has pressed. This happens ...
by TLC
Wed Nov 13, 2024 9:24 pm
Forum: .NET
Topic: Steema.TeeChart.Tools.NearestPoint Change event doesn't trigger
Replies: 6
Views: 6002

Re: Steema.TeeChart.Tools.NearestPoint Change event doesn't trigger

the work around doesn't really work afterall-- it's always at the first point. doesn't change no matter where i click or drag.
by TLC
Wed Nov 13, 2024 9:23 pm
Forum: .NET
Topic: Annotations are broken. Can't draw on the canvas.
Replies: 17
Views: 15427

Re: Annotations are broken. Can't draw on the canvas.

Not sure how, but got the arrow to show up. but as related to the issue Steema.TeeChart.Tools.NearestPoint Change event doesn't trigger http://support.steema.com/viewtopic.php?f=4&t=18263&sid=f489335f5e76f1f1342280e7a75ee146 , it's always at the first point. doesn't change no matter where i click or...
by TLC
Mon Nov 11, 2024 5:13 pm
Forum: .NET
Topic: Annotations are broken. Can't draw on the canvas.
Replies: 17
Views: 15427

Re: Annotations are broken. Can't draw on the canvas.

I'm on android. Could you post the code for your demo?
by TLC
Fri Nov 08, 2024 5:33 pm
Forum: .NET
Topic: Annotations are broken. Can't draw on the canvas.
Replies: 17
Views: 15427

Re: Annotations are broken. Can't draw on the canvas.

Hello, does the following code works for you ? it should draw an Arrow from left bottom corner to the third point in Chart. private void TChart1_AfterDraw(object sender, Steema.TeeChart.Drawing.IGraphics3D g) { var series = tChart1.Chart.Series[0]; int pointIndex = 2; // Index 3 double xValue = ser...
by TLC
Tue Nov 05, 2024 5:29 pm
Forum: .NET
Topic: Annotations are broken. Can't draw on the canvas.
Replies: 17
Views: 15427

Re: Annotations are broken. Can't draw on the canvas.

Here is a screenshot of so you can see it. The toast on the image is to help debug it. In this case, the arrow should be from the bottom left corner of the popup to the 3rd point. #if DEBUG _ = Dialogs.Toast( $"{nameof(AnnotationTool)}.{nameof(Draw)}.{Active}.{currentPointIndex}.{line.Count}" ); #en...
by TLC
Tue Nov 05, 2024 5:20 pm
Forum: .NET
Topic: Annotations are broken. Can't draw on the canvas.
Replies: 17
Views: 15427

Re: Annotations are broken. Can't draw on the canvas.

If i try to draw the popup first, it still crashes. The native RectangleTool.DrawText method also crashes. See the previous stack traces. The arrow is never drawn. Oddly though, the popup still is displayed but nothing else, regardless of the call order(text or arrow first) private void DrawText( re...
by TLC
Tue Nov 05, 2024 4:16 pm
Forum: .NET
Topic: Annotations are broken. Can't draw on the canvas.
Replies: 17
Views: 15427

Re: Annotations are broken. Can't draw on the canvas.

As a part of the Annotation, I need to draw an arrow from the corner of the popup to the point in question. A lot of math is done prior to this, but the following is crashing due the stack trace bellow. I tried the native method and doing a custom arrow. Both crash. private void DrawArrow( ref reado...
by TLC
Tue Nov 05, 2024 3:19 pm
Forum: .NET
Topic: Steema.TeeChart.Tools.NearestPoint Change event doesn't trigger
Replies: 6
Views: 6002

Re: Steema.TeeChart.Tools.NearestPoint Change event doesn't trigger

Yes its on MAUI. THe workaround if found was to do the following: protected override void MouseEvent( MouseEventKinds kind, MouseEventArgs e, ref Cursor c ) { if ( _iSeries is null ) { return; } Point point = new(e.X, e.Y); int index = GetNearestPoint( point ); _viewModel.SetCurrentPointIndex( index...
by TLC
Tue Oct 29, 2024 6:59 pm
Forum: .NET
Topic: Steema.TeeChart.Tools.NearestPoint Change event doesn't trigger
Replies: 6
Views: 6002

Steema.TeeChart.Tools.NearestPoint Change event doesn't trigger

Steema.TeeChart.Tools.NearestPoint Change event doesn't trigger because the kind parameter is never MouseEventKinds.Move . I clicked and dragged on the chart but it never triggered. Only the down and up events fired. protected internal override void MouseEvent( MouseEventKinds kind, MouseEventArgs e...
by TLC
Tue Oct 29, 2024 5:36 pm
Forum: .NET
Topic: Annotations are broken. Can't draw on the canvas.
Replies: 17
Views: 15427

Annotations are broken. Can't draw on the canvas.

Steema.TeeChart.NET.MAUI v6.2024.8.29 Seems that the following is the culprit: Microsoft.Maui.Graphics.Platform.PlatformCanvas Seems like the CurrentState is null. It should be an instance of PlatformCanvasState . public override void FillRectangle(float x, float y, float width, float height) { var ...
by TLC
Thu Oct 05, 2023 12:39 am
Forum: .NET
Topic: Steema.TeeChart.NET.Xamarin.Forms v4.2022.12.20 breaks in iOS v17.0.3
Replies: 2
Views: 25803

Re: Steema.TeeChart.NET.Xamarin.Forms v4.2022.12.20 breaks in iOS v17.0.3

Found a workaround and it works on both platforms...

change Line.Add( point.Date, point.Value, point.Label, color ); to Line.Add( Utils.DateTime( point.Date ), point.Value, point.Label, color );