[英]how to create jquery plugin for Speedometer
i have working as web developer and create tiny jquery plugin such as reverse text,slider image. 我已经作为Web开发人员工作,并创建了微小的jquery插件,例如反向文本,滑块图像。 Now i want to create speedometer.
现在我想创建速度计。 I haven't any idea how to start to create speedometer plugin.
我不知道如何开始创建速度计插件。 I have also googling but do not get any fine solution.
我也谷歌搜索,但没有任何好的解决方案。
You will find a usefull tutorial for creating a Dynamic speedometer with jquery and CSS3 here , this is a jQuery plugin helps you create an animated & highly customizable speedometer representing the number you type into an input field. 您将在此处找到有用的教程来创建带有jquery和CSS3的动态速度表,这是一个jQuery插件,可帮助您创建一个动画且高度可定制的速度表,以表示您在输入字段中键入的数字。 Based on jQuery and CSS3 transitions & transforms.
基于jQuery和CSS3过渡和转换。 No image needed.
无需图像。
how to use: 如何使用:
$("#demo").myfunc({
maxVal : 180, // Max value of the meter
divFact : 10, // Division value of the meter
dangerLevel : 120, // more than this leval, color will be red
initDeg : -45, // reading begins angle
maxDeg : 270, // total angle of the meter reading
edgeRadius : 150, // radius of the meter circle
speedNobeH : 4, // speed nobe height
speedoNobeW : 95, // speed nobe width
speedoNobeL : 13, // speed nobe left position
indicatorRadius : 125, // radius of indicators position
indicatorNumbRadius : 90, // radius of numbers position
speedPositionTxtWH : 80, // speedo-meter current value cont
nobW: 20, // indicator nob width
nobH: 4, // indicator nob height
numbW : 30, // indicator number width
numbH : 16, // indicator number height
midNobW : 10, // indicator mid nob width
midNobH : 3, // indicator mid nob height
noOfSmallDiv: 2, // no of small div between main div
eventListenerType : 'change',// no of small div between main div
});
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.