Color1, Color2, Color3, GradientFill - SeriesEventMarker

A forum dedicated to WinForms version of LightningChart Ultimate.

Moderator: Queue Moderators

Post Reply
Greg9504
Posts: 38
Joined: Fri Dec 06, 2013 4:51 pm

Color1, Color2, Color3, GradientFill - SeriesEventMarker

Post by Greg9504 » Sat May 10, 2014 1:50 am

Hello,

Could you describe how these parameters: Color1, Color2, Color3, Border, BorderColor, and GradientFill affect the appearance of the event marker?

I eventually got sort of what I wanted but it wasn't intuitive. I wanted to create an event marker that had a transparent body with a black border with no gradient. Setting border width to anything other than 0 resulted in either a solid black marker with no transparency or a marker with a black dot at the center with a black gradient with no transparency. With border width 0, color 1 transparent, color 2 black, color 3 transparent, and gradient fill set to either edge or linear I get a gradient transparent marker.

Attached are some images of one of the samples with the various settings I tried and the resultant marker. Ideally I'm looking to get a transparent marker with a "crisp" black border (no gradient).

With border, gradient (Edge or linear), not transparent:
pointcolor123BorderGradientFill.jpg
pointcolor123BorderGradientFill.jpg (75.05 KiB) Viewed 12032 times
No border, solid gradient, transparent but no border so not particularly useful (note changing border color (and width to 1) to white did not help instead you get a solid while marker):
pointcolor123GradientFillSolidNoBorder.jpg
pointcolor123GradientFillSolidNoBorder.jpg (70.44 KiB) Viewed 12032 times
Border, soild gradient:
pointcolor123GradientFillSolidWithBorder.jpg
pointcolor123GradientFillSolidWithBorder.jpg (72.73 KiB) Viewed 12032 times
continue in next post... as I can only attach 3 images...
Last edited by Greg9504 on Sat May 10, 2014 2:06 am, edited 2 times in total.

Greg9504
Posts: 38
Joined: Fri Dec 06, 2013 4:51 pm

Re: Color1, Color2, Color3, GradientFill - SeriesEventMarker

Post by Greg9504 » Sat May 10, 2014 1:51 am

finally the sort of works:

No border, gradient (edge or linear), color2 black.
pointcolor123GradientFill.jpg
pointcolor123GradientFill.jpg (75.55 KiB) Viewed 12031 times

User avatar
ArctionPasi
Posts: 1367
Joined: Tue Mar 26, 2013 10:57 pm
Location: Finland
Contact:

Re: Color1, Color2, Color3, GradientFill - SeriesEventMarker

Post by ArctionPasi » Sat May 10, 2014 8:20 am

The border is actually rendered as a filled background layer, not a path around the object. Color1 is the 'Primary color', Color2 is 'Secondary' color and Color3 an auxiliary color in lightning symbol in FlagLightning shape.

I agree, it's not very intuitive, but needed to support all shapes with same property set.

To make a transparent or translucent marker, it's easiest to hide the border by setting BorderWidth = 0.

That's great you already found almost an optimal way to produce the appearance you are looking for. By setting Color1=(0,0,0,0) looks better with dark background than Transparent that is (0,255,255,255) color.

The same styles are used also in the series rendering itself, and sets some performance requirements especially when there's millions of points visible.

By setting selecting Shape = Bitmap and creating a transparent PNG image with a bitmap editor, and setting it to symbol.BitmapImage property, you can make symbols of your own.

Of course it would be convenient to have a built-in not-filled 'Ring' shape or something like that.
LightningChart Support Team, PT

Greg9504
Posts: 38
Joined: Fri Dec 06, 2013 4:51 pm

Re: Color1, Color2, Color3, GradientFill - SeriesEventMarker

Post by Greg9504 » Thu May 15, 2014 1:37 pm

Looking like our users expect a black boarder, however adding one means the transparency doesn't work.

FWIW our users are scientists and frequently use the plots from our product in their papers, a symbol with a black boarder with translucent fill is much easier to read, and is better for publishing. This is a key feature of our product, that the plots produced are ready for publishing.
The same styles are used also in the series rendering itself, and sets some performance requirements especially when there's millions of points visible.
I don't think any user of LightningChart would expect the boarder feature to work the way it does (filled background layer). Any way you could make this work "as expected" with the understanding that there are performance trade offs? Set boarder width to 0 for faster rendering when plotting 1000's of points or perhaps allowing SeriesEventMarker's to have proper boarders?
By setting selecting Shape = Bitmap and creating a transparent PNG image with a bitmap editor, and setting it to symbol.BitmapImage property, you can make symbols of your own.
How would I go about this for say a circle shape? Create a circle with black boarder and the rest of the PNG image transparent? When the colour is set wont the complete square get filled with the colour? Or would I create a circle with a white center, black boarder, rest transparent then set the Symbol.BitmapImageTintColor ? Sorry I would have just tried this but my trial ran out.

Thanks
Greg.

User avatar
ArctionPasi
Posts: 1367
Joined: Tue Mar 26, 2013 10:57 pm
Location: Finland
Contact:

Re: Color1, Color2, Color3, GradientFill - SeriesEventMarker

Post by ArctionPasi » Thu May 15, 2014 8:20 pm

I was thinking about bitmap like this:
png file with semi-transparent grey as fill
png file with semi-transparent grey as fill
ring_filled_alpha.png (2.63 KiB) Viewed 12013 times
It's an ugly picture and seems to clip on borders nasty when I exported from CorelDraw.

When that is set as marker symbol, and BitmapTintColor is set, it looks like this:
PNG files as marker symbols
PNG files as marker symbols
bitmaps_as_marker_symbols.jpg (88.54 KiB) Viewed 12013 times
If you don't find this approach suitable, we can add the colored circle with a proper border as built-in feature. It's available in couple of months after purchasing the subscription. Let's not make this a show-stopper ;)
LightningChart Support Team, PT

jrvdboom
Posts: 61
Joined: Thu Apr 10, 2014 1:50 pm

Re: Color1, Color2, Color3, GradientFill - SeriesEventMarker

Post by jrvdboom » Wed Sep 03, 2014 8:11 am

Hi Pasi,

I would also like proper borders for all point shapes. I'm not using this for event markers, but for the series as well. Overlapping points now hide each other.

I tried using bitmaps as a workaround, but they get scaled in the legend which makes them ugly over there. If the LegendBox would not scale its icons, but show them exactly as the points appear on the chart, I would be satisfied as well!

Thanks,
Joost

Post Reply