point size lazarus / 55-TAChart ---------------------------------------------------------------------- fleabit · 2015-09-27 16:49 I would like to plot a line series using a single pixel for each point rather than a symbol.  Is there a way to do this? ---------------------------------------------------------------------- derek.john.evans · 2015-09-27 17:01 Have you tried changing Pointer.HorizSize and Pointer.VertSize? If you set Pointer.Visible to False, you can draw whatever you want in OnDrawPointer. *EDIT* Scratch that. Doesn't work Setting Pointer.Style to psNone and using OnDrawPointer seems to work. ---------------------------------------------------------------------- fleabit · 2015-09-27 17:59 Yes.  Smallest you can set is vertical and horizontal size of 1 which still gives a larger than pixel size symbol ---------------------------------------------------------------------- wp · 2015-09-27 18:27 Geepster means that you need an event handler for the line series' OnDrawPointer such as Code: [Select]procedure TForm1.Chart1LineSeries1DrawPointer(ASender: TChartSeries;   ACanvas: TCanvas; AIndex: Integer; ACenter: TPoint); begin   ACanvas.Pixels[ACenter.X, ACenter.Y] := TLineSeries(ASender).SeriesColor; end; For this to work you have to set the series' Pointer.Style to psNone, and the ShowPoints to true. And you have to "use" TACustomSeries. ---------------------------------------------------------------------- wp · 2015-09-27 19:40 I just added a new pointer style psPoint to TAChart trunk (r49881). The point color is defined by the LinePen.Color of the Pointer. HorizSize and VertSize, as well as Brush properties are ignored. The new pointer style should work with all drawers, but feedback would be welcome since I did not do too much testing. ---------------------------------------------------------------------- fleabit · 2015-09-29 14:52 Thanks for that but I can't find that that revision number.  How do I get it into my copy of Lazarus? ---------------------------------------------------------------------- wp · 2015-09-29 15:30 The changes are in the development version of Lazarus ("trunk") which you can access by means of svn. But I think you did not work with svn before? Then it might be easier to patch TAChart by yourself. At first, make a backup-copy of your TAChart installation, i.e. copy the folder "components/tachart" of your Lazarus installation to a safe place.Then go to http://svn.freepascal.org/cgi- bin/viewvc.cgi/trunk/components/tachart/?root=lazarus, here you can access the "trunk" files by means of html.Download the files "tatypes.pas", "tadrawutils.pas", "tadrawerfpcanvas.pas" and "tadrawercanvas.pas" into the (original) TAChart folder.Run Lazarus, execute the menu command "Tools" / "Build Lazarus with profile..." to recompile the IDE with the changed TAChart. After a while Lazarus will close and restart with the new TAChart version.Please be aware that you'll have to repeat this procedure whenever you update your Lazarus version unless you'll decice to go the trunk altogether, or Lazarus v1.6 is released (since the points symbol style is a new feature it will not be backported) - but this may still take some time. The more convenient solution to your issue would be to apply the method that was proposed by Geepster some posts above. ---------------------------------------------------------------------- fleabit · 2015-09-29 15:51 Thanks.  The OnDrawPointer override worked well.