We implement linear gauges with the arrow pointer in our application. I was wondering if there is a way to display an actual label next to the pointer, which would show the value? Please see the attached image.
Also, had a question about scaling the size of the linear gauge. It looks like the background of the gauge is an actual image. If we would like to scale down the size of the entire gauge to adjust to the size of its outer container, what method would you recommend for that?
Thank you for your help.
7 Answers, 1 is accepted
This feature is currently unsupported, and we might consider it for implementation if you log it on uservoice.
Until it gets implemented, you can show the current value of the gauge in a HTML element beside it, like so:
<div id="gauge1">
<div class="gauge"></div>
<div class="gauge-value">0</div>
</div>
<script>
function setGaugeValue(gaugeId, value) {
$(gaugeId)
.find(".gauge-value").text(value).end()
.find(".gauge").data("kendoGauge").value(value);
}
</script>
<style>
.gauge, .gauge-value {
display: inline-block;
*display: inline;
zoom: 1;
vertical-align: middle;
}
</style>
Alex Gyoshev
the Telerik team
I am sorry, for I didn't answer your second question. If I understand it right, you need a scalable container for the gauge? If so, it is advisable to use CSS3 gradients and shadows instead of an image, because they will fit any container you need.
Regards,Alex Gyoshev
the Telerik team

Can you please give me an example on how to position the div with the custom value exactly on top of the selected value?
Just as my awezome picture shows (:P)
Thanks!
We don't have an API for that, but you may look at the source code of the chart and see how the Tooltip class is used -- albeit currently unsupported, this may lead you to a solution in your scenario.
You can also submit a feature request on uservoice so that we consider implementing the feature for a future release.
Regards,
Alex Gyoshev
the Telerik team

I tried to submit a new feature this afternoon (monday) and it was rejected, the page showed me a message saying I was unauthorized, what could I be doing wrong?
I assume that you need to be logged in to post an issue. Or it may be a temporary problem with the uservoice platform...?
Greetings,Alex Gyoshev
the Telerik team

As far as I know I was logged in with my Google Account. I'll maybe try to submit it later!
Thanks for everything!