SteelSeries Gauges: Difference between revisions

From Cumulus Wiki
Jump to navigationJump to search
1,004 bytes added ,  11:06, 18 February 2013
Line 171: Line 171:
   * * * *
   * * * *
  * * * * o
  * * * * o
== Altering the gauge sizes on the page  ==
From version 2.2.0 the sizes of the gauges is controlled via CSS and longer coded in the gauges.js script. By default all the gauge canvas tags are set to pick up their size from the ".gaugeSizeStd" class in gauges-ss.css file. To change the size of all the gauges, simply edit this class and set the width & height to your required size - the width and height should always be the same.
You can easily have different sized gauges on the same page, in the gauges-ss.css I have created two additional classes ".gaugeSizeSml" and ".gaugeSizeLrg", (again you can edit the width/height values of these classes to whatever you want), to assign one of these alternative sizes to a gauge, edit the HTML and change (for example)...
      <canvas id="canvas_baro" class="gaugeSizeStd"></canvas>
      to
      <canvas id="canvas_baro" class="gaugeSizeLrg"></canvas>
This would change the Barometer from a 221 pixel gauge, to 261 pixels (using the default values).


== JavaScript Files ==
== JavaScript Files ==

Navigation menu