Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » ScatterDraw & ScatterCtrl » [solved] ScatterCtrl: program access to the "Measures" ? (Need to set per axis min/max and major unit, no clue how to)
Re: [still wondering] ScatterCtrl: program access to the "Measures" ? [message #52702 is a reply to message #52677] Tue, 12 November 2019 22:58 Go to previous messageGo to previous message
xrysf03 is currently offline  xrysf03
Messages: 43
Registered: November 2018
Location: CZ
Member
Hello Koldo and everybody,

I've moved a little bit further with ScatterCtrl, but it seems like I'm stuck again.
My code contains the following snippet:

Chart1.AddSeries(buffer, buf_size,
		/*x0*/ from_freq_rounded, // Hz
		/*delta x*/ freq_sample_width // HZ
		);
//Chart1.SetMinXmin(from_freq_rounded);
//Chart1.SetMaxXmax(to_freq_rounded);
//Chart1.SetMinYmin(-90);
//Chart1.SetMaxYmax(0);
Chart1.SetLabels("Hz","dBFS");
Chart1.NoMark(0);
Chart1.Stroke(0,1,Blue());
Chart1.ZoomToFit(true,true,0); // X, Y, fill factor (0 = fill the whole control)
//Chart1.Refresh();


This way, it does display a trace, the labels do get modified, and the ZoomToFit works too.
But, if I remove (comment out) the ZoomToFit, and instead use the SetMinXmin/Xmax/Ymin/Ymax, those functions don't seem to work. The range just stays put at 0..100 at both axes. See the attached screenshot.

I'm wondering if I'm missing some other member method or flag to tweak, to "unpeg" those range setting functions. For instance, in the runtime "Properties" tabbed dialog of the ScatterCtrl, there's a check mark called "Attach" per axis (one for X, one for Y) - if that's ticked, the min and max input boxes are grey (deactivated). But I haven't found any access to those "Attach" check marks from my program code... ZoomToFit seems to work regardless of those "Attach" check marks. And if at runtime I first remove the "Attach" check marks manually, and then run the piece of code outlined above, the minXmin(), maxXmax() et al still do not work...

So this is what it behaves like in the 12610 nightly. I've tried upgrading to 13655, but I'm stuck in another problem (problem to include the kissfft plugin - see the thread in newbie corner if interested.) So at the moment I cannot test if the upgrade solves my problem with ScatterCtrl range setting.

So if at this point there are some suggestions, I'd love to hear them Smile
  • Attachment: skyline.png
    (Size: 16.62KB, Downloaded 189 times)
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Compilation of ScatterDraw cause warnings
Next Topic: Remove a Surf from a ScatterDraw
Goto Forum:
  


Current Time: Fri Apr 19 21:52:33 CEST 2024

Total time taken to generate the page: 0.04074 seconds