DevExtreme v26.1 is now available.

Explore our newest features/capabilities and share your thoughts with us.

Your search did not match any results.

Angular Gauges - Angles Customization

This demo illustrates how to change the geometry of the CircularGauge. The shape of the gauge arc is defined by the values assigned to the startAngle and endAngle properties of the geometry configuration object.

Backend API
<div class="long-title"> <h3>Humidity in Rooms (%)</h3> </div> <div id="gauge-demo"> <dx-circular-gauge class="gauge" [value]="80"> <dxo-circular-gauge-scale [startValue]="0" [endValue]="100" [tickInterval]="10" > </dxo-circular-gauge-scale> <dxo-circular-gauge-geometry [startAngle]="180" [endAngle]="90"> </dxo-circular-gauge-geometry> </dx-circular-gauge> <dx-circular-gauge class="gauge" [value]="75"> <dxo-circular-gauge-scale [startValue]="100" [endValue]="0" [tickInterval]="10" > </dxo-circular-gauge-scale> <dxo-circular-gauge-geometry [startAngle]="90" [endAngle]="0"> </dxo-circular-gauge-geometry> </dx-circular-gauge> <dx-circular-gauge class="gauge" [value]="70"> <dxo-circular-gauge-scale [startValue]="100" [endValue]="0" [tickInterval]="10" > </dxo-circular-gauge-scale> <dxo-circular-gauge-geometry [startAngle]="-90" [endAngle]="-180"> </dxo-circular-gauge-geometry> </dx-circular-gauge> <dx-circular-gauge class="gauge" [value]="68"> <dxo-circular-gauge-scale [startValue]="0" [endValue]="100" [tickInterval]="10" > </dxo-circular-gauge-scale> <dxo-circular-gauge-geometry [startAngle]="0" [endAngle]="-90"> </dxo-circular-gauge-geometry> </dx-circular-gauge> </div>
import { bootstrapApplication } from '@angular/platform-browser'; import { Component, enableProdMode, provideZoneChangeDetection } from '@angular/core'; import { DxCircularGaugeModule } from 'devextreme-angular'; if (!/localhost/.test(document.location.host)) { enableProdMode(); } @Component({ selector: 'demo-app', templateUrl: './app.component.html', styleUrls: ['./app.component.css'], imports: [ DxCircularGaugeModule, ], }) export class AppComponent { } bootstrapApplication(AppComponent, { providers: [ provideZoneChangeDetection({ eventCoalescing: true, runCoalescing: true }), ], });
::ng-deep #gauge-demo { height: 440px; width: 100%; } ::ng-deep .gauge { width: 50%; height: 50%; float: left; } ::ng-deep .long-title h3 { font-family: 'Segoe UI Light', 'Helvetica Neue Light', 'Segoe UI', 'Helvetica Neue', 'Trebuchet MS', Verdana; font-weight: 200; font-size: 28px; text-align: center; margin-bottom: 20px; }
<!DOCTYPE html> <html lang="en"> <head> <title>DevExtreme Demo</title> <meta http-equiv="X-UA-Compatible" content="IE=edge" /> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=5.0" /> <link rel="stylesheet" type="text/css" href="https://cdn3.devexpress.com/jslib/26.1.5/css/dx.light.css" /> </head> <body class="dx-viewport"> <div class="demo-container"> <demo-app>Loading...</demo-app> </div> <script src="https://cdn.jsdelivr.net/npm/zone.js@0.16.2/bundles/zone.umd.js"></script> <script src="./bundle.js" type="module"></script> </body> </html>