This is a migrated thread and some comments may be shown as answers.

Display ONLY the Pointer for a Linear Gauge

2 Answers 228 Views
Gauges
This is a migrated thread and some comments may be shown as answers.
Chris
Top achievements
Rank 1
Chris asked on 21 Feb 2013, 09:39 AM
I'm trying to create a linear gauge, where ONLY the pointer is shown. The scale and all other furniture needs to be hidden, as we are displaying the pointer over a custom image in our web page.
My code for the gauge so far is as follows:

@(Html.Kendo().LinearGauge().Name("LinGauge" + @Model.ComponentName.Replace(" ",""))
    .Pointer(pointer => pointer.Size(30.0)
                   .Color("Black")
                   .Value(@Model.ComponentScore / 1000.0)
                   .Shape(GaugeLinearPointerShape.Arrow))
    .Scale(scale => scale.Min(0.0)
                 .Max(1.0)
                 .Vertical(false)
                 .MinorTicks(t => t.Visible(false))
                 .MajorTicks(t => t.Visible(false))
                 .Labels(l=>l.Visible(false))))

This is almost there, and displays the pointer with just a single, undecorated line where you would expect the scale to be (see attached image), but I can't seem to find in the API reference how you would switch that line off. Any help would be appreciated.

2 Answers, 1 is accepted

Sort by
0
Accepted
Iliana Dyankova
Telerik team
answered on 21 Feb 2013, 03:11 PM
Hello Chris,

Generally speaking you can achieve this as set visible false to the Gauge's Scale Line. Unfortunately there is a bug in the current version of Kendo UI Linear Gauge for ASP.NET MVC and it is not possible to achieve the desired outcome. The good news is that our developers have managed to address it and the fix will be included in the upcoming Q1 2013 Beta version (which is expected next week). Please accept my apologies for the inconvenience caused.

Regards,
Iliana Nikolova
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
Chris
Top achievements
Rank 1
answered on 21 Feb 2013, 03:48 PM
Thank you, Iliana.
I shall keep my eyes open for the beta update!
Tags
Gauges
Asked by
Chris
Top achievements
Rank 1
Answers by
Iliana Dyankova
Telerik team
Chris
Top achievements
Rank 1
Share this question
or