@@ -8,10 +8,38 @@ Ring provide some basic presets for system info.
88
99``` json
1010{
11- "frame_rate" : 144 ,
12- "type" : " ring" ,
13- "preset" : " disk" ,
14- "prefix" : " Disk "
11+ "index" : [-1 , -1 ],
12+ "widget" : {
13+ "font_family" : " JetBrainsMono Nerd Font" ,
14+ "fg_color" : " #BEAFD9" ,
15+ "bg_color" : " #00000044" ,
16+ "type" : " ring" ,
17+ "prefix" : " " ,
18+ "suffix" : " {float:4,100}%" ,
19+ "suffix_hide" : true ,
20+ "preset" : {
21+ "type" : " custom" ,
22+ "update_interval" : 100 ,
23+ "cmd" : " seq 0 .01 1 | shuf | head -n1"
24+ }
25+ }
26+ }
27+ ```
28+
29+ ``` json
30+ {
31+ "index" : [-1 , -1 ],
32+ "widget" : {
33+ "font_family" : " JetBrainsMono Nerd Font" ,
34+ "bg_color" : " #00000044" ,
35+ "type" : " ring" ,
36+ "prefix" : " " ,
37+ "suffix" : " {preset} {progress:2,100}%" ,
38+ "suffix_hide" : true ,
39+ "preset" : {
40+ "type" : " ram"
41+ }
42+ }
1543}
1644```
1745
@@ -35,14 +63,7 @@ For full info, check [RGBA](https://gtk-rs.org/gtk4-rs/stable/latest/docs/src/gd
3563_ Type: ` string ` _
3664_ Default: ` #FFB847 ` _
3765
38- ## ` frame_rate `
39-
40- Frame rate per second, won't hurt if over screen refresh rate.
41-
42- _ Type: ` int ` _
43- _ Default: ` 60 ` _
44-
45- ## ` transition_duration `
66+ ## ` text_transition_ms `
4667
4768Time cost of showing the widget from the edge.
4869Millisecond.
@@ -113,6 +134,11 @@ Font family of all text within ring widget.
113134_ Type: ` null | string ` _
114135_ Default: ` null ` for default font_
115136
137+ ## ` font_size `
138+
139+ _ Type: ` int ` _
140+ Default: radius \* 2
141+
116142## ` preset `
117143
118144Preset update function of the ring:
@@ -128,6 +154,10 @@ _Type: `string | object`_
128154const `ram`
129155```
130156
157+ #### ` update_interval `
158+
159+ ` u64 `
160+
131161### ` swap `
132162
133163#### ` type* `
@@ -136,6 +166,10 @@ const `ram`
136166const `swap`
137167```
138168
169+ #### ` update_interval `
170+
171+ ` u64 `
172+
139173### ` cpu `
140174
141175#### ` type* `
@@ -144,6 +178,14 @@ const `swap`
144178const `cpu`
145179```
146180
181+ #### ` update_interval `
182+
183+ ` u64 `
184+
185+ #### ` core `
186+
187+ which core to should. leave empty to show global usage.
188+
147189### ` battery `
148190
149191#### ` type* `
@@ -152,6 +194,10 @@ const `cpu`
152194const `battery`
153195```
154196
197+ #### ` update_interval `
198+
199+ ` u64 `
200+
155201### ` disk `
156202
157203#### ` type* `
@@ -167,6 +213,10 @@ Disk partition.
167213_ Type: ` string ` _
168214_ Default: ` / ` _
169215
216+ #### ` update_interval `
217+
218+ ` u64 `
219+
170220### ` custom `
171221
172222#### ` type* `
@@ -175,13 +225,10 @@ _Default: `/`_
175225const `custom`
176226```
177227
178- #### ` update_with_interval_ms `
228+ #### ` update_interval `
179229
180- Update progress with command given milliseconds.
181- Progress must be between 0 and 1.
182- You can disable template by not providing text.
230+ ` u64 `
183231
184- Example: ` [1000, "printf \"0.2333\\n23.33%\""] `
232+ #### ` cmd `
185233
186- _ Type: ` [[int, string]...] ` _
187- _ Default: ` [] ` _
234+ ` string `
0 commit comments