Recent

Author Topic: (Solved) LiveView, problem with ViewPort > 1 and x-axis.  (Read 889 times)

arneolav

  • Full Member
  • ***
  • Posts: 145
    • ElTranslador
(Solved) LiveView, problem with ViewPort > 1 and x-axis.
« on: September 17, 2021, 02:50:05 pm »
First of all, thanks for the LiveView component, nice work.
As LiveView function is asked for I'm implementing the component (on Lazarus 2.2.0RC1).

I'v run into a problem:
-ViewPort = Active
-ViewportSize > 1
Then the scrolling does not work, the scrollbar is "solid". (See screendump below).
Seems LogicalExtent not is activated?

Bottom Axis, Marks, Source is set to DateTimeIntervalChartSource1.
Chart Series is as default 0. Dynamic created in code.

I've looked into the demo and read thru the documentation and mostly all I can find of discussion but can't find a solution.
« Last Edit: September 17, 2021, 06:06:29 pm by arneolav »
Win XP, Win7, Win 10 win64 , Lazarus 2.0.12
Delphi/DevExpress

wp

  • Hero Member
  • *****
  • Posts: 8880
Re: LiveView, problem with ViewPort > 1 and x-axis.
« Reply #1 on: September 17, 2021, 02:59:54 pm »
-ViewportSize > 1
The ViewportSize is measured in units of the x axis. Since you have a date/time variable on the x axis, the x axis is scaled in days. Thus, Viewportsize > 1 means that you must collect values during a full until the scrolling becomes active. If you want to see the values arriving during the last, say, hour, then ViewportSize should be 1 hour = 1day / 24 = 1/24, or for during the last minute, it should be 1/(24*60).
Mainly Lazarus trunk / fpc 3.2.0 / all 32-bit on Win-10, but many more...

arneolav

  • Full Member
  • ***
  • Posts: 145
    • ElTranslador
Re: LiveView, problem with ViewPort > 1 and x-axis.
« Reply #2 on: September 17, 2021, 06:05:28 pm »
Thanks, then it works.

It was my suspicion that the problem had something to do with the timeline.

Got a minor problem with the ColorBelow;
On select active the colorbelow is shown incorrect, just at the end of the line.
On scroll from left to right, the ColorBelow is shown correct in the beginning but replaced by the default series color "pixel by pixel" as the scroll go on.
This not very important!   
Thanks again!

Win XP, Win7, Win 10 win64 , Lazarus 2.0.12
Delphi/DevExpress

wp

  • Hero Member
  • *****
  • Posts: 8880
Re: (Solved) LiveView, problem with ViewPort > 1 and x-axis.
« Reply #3 on: September 17, 2021, 06:46:43 pm »
Sorry, I am completely lost for the moment: What do you mean with ColorBelow?
Mainly Lazarus trunk / fpc 3.2.0 / all 32-bit on Win-10, but many more...

arneolav

  • Full Member
  • ***
  • Posts: 145
    • ElTranslador
Re: (Solved) LiveView, problem with ViewPort > 1 and x-axis.
« Reply #4 on: September 17, 2021, 08:37:17 pm »
Sorry for my bad explanation,

If a point value is below a given value ( a SplitValue)  I call its color "ColorBelow".

Colors are set this way:
LineSeries.AddXY(x,y,name,color);

Look at the picture in the first post, you will see the SeriesLine has changed to blue under a value, in this example  10 degrees.

In a "quick look" a user may see if a critical value has occurred, may be too high or too low, depending on setting of the split value.
Win XP, Win7, Win 10 win64 , Lazarus 2.0.12
Delphi/DevExpress

wp

  • Hero Member
  • *****
  • Posts: 8880
Re: (Solved) LiveView, problem with ViewPort > 1 and x-axis.
« Reply #5 on: September 17, 2021, 09:31:14 pm »
Found an incorrect a point index used for determination of the point color in relation with ColorEach of TLineSeries. Fixed in main (trunk). Please test if this fixes your issue.
Mainly Lazarus trunk / fpc 3.2.0 / all 32-bit on Win-10, but many more...

arneolav

  • Full Member
  • ***
  • Posts: 145
    • ElTranslador
Re: (Solved) LiveView, problem with ViewPort > 1 and x-axis.
« Reply #6 on: September 17, 2021, 10:27:50 pm »
Yes, it did the trick!
Again, thanks a lot!!
Win XP, Win7, Win 10 win64 , Lazarus 2.0.12
Delphi/DevExpress

wp

  • Hero Member
  • *****
  • Posts: 8880
Re: (Solved) LiveView, problem with ViewPort > 1 and x-axis.
« Reply #7 on: September 17, 2021, 10:54:07 pm »
OK, merged it to fixes_2_2.
Mainly Lazarus trunk / fpc 3.2.0 / all 32-bit on Win-10, but many more...

 

TinyPortal © 2005-2018