Borland C++ Builder to .NET transition help

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
Phil Moseley & Assocs
Newbie
Newbie
Posts: 16
Joined: Fri Jul 27, 2007 12:00 am

Borland C++ Builder to .NET transition help

Post by Phil Moseley & Assocs » Fri Aug 10, 2007 4:36 pm

We are currently porting one of our Borland C++ Builder apps to .NET/WinForms, and I am a little confused about some of the property mappings. Please understand, I am not a Borland programmer, so some things are a bit confusing to me.

First and foremost is the bsClear and bsSolid brush style options provided by Borland. How do I reproduce those effects using the .NET TeeChart? The HatchStyle enumeration provided by System.Drawing doesn't contain Clear or Solid. Should I use the Transparency and Solid properties of the ChartBrush class? If so, what do both of those enums represent in terms of those values? I would think bsSolid = { Solid = true; Transparency = 100; } and bsClear = { Solid = True; Transparency = 0; }, but I am simply not sure.

Any help would be appreciated.

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Mon Aug 13, 2007 8:03 am

Hi MattHolmes,

Yes, you should use Solid and Transparency properties.

bsClear: Any brush style but Transparency=100.
bsSolid: Solid=true and Transparency=0.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Phil Moseley & Assocs
Newbie
Newbie
Posts: 16
Joined: Fri Jul 27, 2007 12:00 am

Post by Phil Moseley & Assocs » Mon Aug 13, 2007 2:57 pm

Great, thanks!

One question. What would considered the "default" HatchStyle? I am using HatchStyle.Max currently, but MS's docs on Drawing2D are a bit lacking.

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Mon Aug 13, 2007 3:07 pm

Hi MattHolmes,

Yes, I've also had this problem with Microsoft's documentation. However I'd say the default value is BackwardDiagonal as looking at some brushes says so, for example:

Code: Select all

			Text = tChart1.Panel.Brush.Style.ToString();
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Post Reply