Remove empty space. Semi Circular gauge take full area (StartAngle="270" EndAngle="90")

I'd like to use a semi-circular gauge. Everything is ok, however t,he area used by the control is like a full circular gauge, so half of the control is blank.

How can I remove the black space? It is 50% of the height.

Please use the below example as a reference


Many thanks in advance

Alfonso.

---------

<SfCircularGauge >

       <CircularGaugeBorder Color="#FF00FF"  Width="2" />

    <CircularGaugeAxes >

        <CircularGaugeAxis Maximum="200" StartAngle="270" EndAngle="90" Minimum="0" HideIntersectingLabel="true">

            <CircularGaugeAxisMajorTicks Interval="4"></CircularGaugeAxisMajorTicks>

            <CircularGaugeAxisMinorTicks Interval="2"></CircularGaugeAxisMinorTicks>

        </CircularGaugeAxis>

    </CircularGaugeAxes>

</SfCircularGauge>


3 Replies

IR Indumathi Ravi Syncfusion Team June 9, 2022 12:22 PM UTC

Hi Alfonso,


Thank you for contacting Syncfusion support.


We can remove the extra space around the Circular Gauge by setting the "AllowMargin" property to "false". To occupy the most space, the axis's "Radius" must be set to "100%". The Circular Gauge's radius is determined by the width and height of the component. If the height exceeds the width, the radius will be calculated using the component's width. If the width is greater than the height, the radius will be calculated using the component's height. Please find the code snippet below for the same.


Code Snippet:

<SfCircularGauge AllowMargin="false">

       <CircularGaugeBorder Color="#FF00FF"  Width="2" />

    <CircularGaugeAxes >

        <CircularGaugeAxis Maximum="200" StartAngle="270" EndAngle="90" Minimum="0" HideIntersectingLabel="true" Radius="100%">

            <CircularGaugeAxisMajorTicks Interval="4"></CircularGaugeAxisMajorTicks>

            <CircularGaugeAxisMinorTicks Interval="2"></CircularGaugeAxisMinorTicks>

        </CircularGaugeAxis>

    </CircularGaugeAxes>

</SfCircularGauge>


 Please find the screenshot below for your reference.

In the image above, the spacing above and below the Circular Gauge has been reduced. The spacing between the gauge's right and left sides can be reduced by decreasing the value in the “Width” property of the Circular Gauge component.


Please let us know if you need any further assistance.


Regards,

Indumathi R.



AL Alfonso June 9, 2022 02:28 PM UTC

It works perfectly!


Great support, great team!


Many thanks!



IR Indumathi Ravi Syncfusion Team June 10, 2022 08:00 AM UTC

Hi Alfonso,

Most Welcome.


Please get back to us if you need any further assistance.


Regards,
Indumathi R.


Loader.
Up arrow icon