Identically colored lineseries on mac osx (carbon) forces one to be clBlack lazarus / 55-TAChart ---------------------------------------------------------------------- kcandrews · 2015-09-24 19:33 I am having trouble on my application whenever selecting identical series colors for multiple simple TLineSeries.  Whenever I choose a non-clBlack color (e.g. clBlue) for two line series using the built in list source, one of the two identically colored series is displayed as clBlack with a width of 1.  So for reasons unknown, it seems not possible to have two identically colored non-clBlack series.  (perhaps osx specific!) I confirmed this using the very simple "Getting_Started.lpi" tutorial project displaying three simple line series.  Again if setting two of the series in the designer to the same non-clBlack seriescolor (linepen.color), one of them reverts to black and a width of 1, in spite of the legend, which displays correctly. Notes: If I choose different widths for each of the identically colored series, drawing occurs as expected.  So it would appear some low level code is trying to be overly protective that two series aren't drawn with the same pen.  As info, the "cosmetic" property setting has no effect on my system -- osx. Any thoughts appreciated! ---------------------------------------------------------------------- wp · 2015-09-24 21:43 Unfortunately I don't have access to osx. Strange. TAChart does not contain any widgetset-specific code, therefore, this issue should occur in other widgetsets as well. But at least Windows and Linux/qt and gtk2 are ok. Here are a few ideas what you could test: Can you manually edit the lfm file of the project to set two series colors to the same value? What happens when you run the demo?The getting-started demo uses designtime-created series. What if you create the series at run-time and set the colors?Could you post here the demo project as modified by you? (lpi, lpi, pas and lfm files packed into a single archive which you can upload here). ---------------------------------------------------------------------- kcandrews · 2015-09-24 23:20 wp, Thanks for your prompt reply! Can you manually edit the lfm file of the project to set two series colors to the same value? What happens when you run the demo?    Same problem. The getting-started demo uses designtime-created series. What if you create the series at run-time and set the colors?    My application does runtime creation which is how I found the problem...so that's why I wanted to try the simplest possible test like the tutorial example. Could you post here the demo project as modified by you? (lpi, lpi, pas and lfm files packed into a single archive which you can upload here).    Attached! I have a theory (though Graphics is definitely not my territory) that maybe each lineseries needs to somehow get a unique linepen from osx (and it looks like the "pen handles" suggest otherwise)... but I'm still testing what happens with the handle identifiers as a lineseries is created, and then changed, etc. ---------------------------------------------------------------------- wp · 2015-09-24 23:39 I looked at your demo, nothing wrong with it. Your theory sounds reasonable. As I wrote, I don't have OSX and can't help you much. If you want to debug yourself: all the basic drawing code of TAChart relevant to screen output is in TADrawerCanvas. As you'll see it all boils down to standard TCanvas methods. Therefore, if your theory is correct, the bug must be very fundamental. I am not sure whether the OSX maintainers read this forum. Maybe you'll get better help if you post the issue in the Lazarus mailing list or write a bug report. Please mention that the issue does not seem to be related to TAChart alone but to canvas painting. [EDIT] Oh - I see that you are a new user. Do you need help with the mailing list or the bug tracker? ---------------------------------------------------------------------- derek.john.evans · 2015-09-25 01:09 What version of Lazarus/FreePascal are you using? ---------------------------------------------------------------------- balazsszekely · 2015-09-25 07:03 Confirmed both with Lazarus 1.4.2(FPC 2.6.4) and Lazarus 1.5(FPC 3.0.1)  -->See Chart1 As a quick fix I changed the color of the second series to $00FF0001 which technically is still blue --->See Chart2 ---------------------------------------------------------------------- kcandrews · 2015-09-25 14:35 getmem, tx...I have noticed that changing pretty much any property of the pen including ones that have no effect like  "cosmetic" make the display "correct." Also, I tried various builds using differing LCL widget types gtk2, carbon, qt, fpGUI, and cocoa and had the same problem with all FWIW. I should have posted version stuff at first...sorry: OS X Yosemite 10.10.5 (14F27) MacBook Pro (Retina, 15 inch mid-2014) Graphics NVIDIA GeForce GT 750M 2048 MB Lazarus 1.4.2 FPC 2.6.4 i386-darwin-carbon I have reported this in the bug tracker as issue 0028728 under the Lazarus Widgetset category.