ASE Home Page Products Download Purchase Support About ASE
ChartDirector Support
Forum HomeForum Home   SearchSearch

Message ListMessage List     Post MessagePost Message

  Pointer is extended to the opposite side in Pointer Angular Meter
Posted by Roopesh on Apr-09-2014 16:44
Attachments:
Hi,
I am using the Anugular Meter type chart with multiple pointers. In the Meter type charts,
the pointer is always extended to the opposite side (like in an analog clock needles).  I
checked the the sample chart available with the library, that too has the same behavior. I
am using the LinePointer type. There is option only to change the total length and width.
Is there anyway to trim the unwanted length at this one end ?

Thanks and regards,
Roopesh
meter_pointers.png

  Re: Pointer is extended to the opposite side in Pointer Angular Meter
Posted by Peter Kwan on Apr-09-2014 18:25
Hi Roopesh,

You can use MeterPointer.setShape2 to use a custom shape as the pointer. A line is just a
thin rectangle, so it should be like (in C#):

private static readonly int[] lineShape = {-5, 0, 5, 0, 5, 1000, -5, 1000};
m.addPointer(myValue).setShape2(lineShape, myLengthRatio, myWidthRatio);

(In the default LinePointer is  {-5, -50, 5, -50, 5, 1000, -5, 1000}, in which the y-
coordinates of the bottom edge is at -50 instead of 0, that's why it goes through the origin
to the other side.)

Hope this can help.

Regards
Peter Kwan