Display: add option --fraction-ndigits

to control number of digits to print when formatting ordinary fraction numbers
This commit is contained in:
李通洲
2025-07-16 10:30:45 +08:00
parent 6851e7b082
commit 468d1e0903
5 changed files with 61 additions and 2 deletions
+22
View File
@@ -934,6 +934,28 @@
}
}
},
"fraction": {
"type": "object",
"additionalProperties": false,
"description": "Set how ordinary fraction numbers should be displayed",
"properties": {
"ndigits": {
"oneOf": [
{
"type": "number",
"description": "Set the number of digits to keep after the decimal point when formatting ordinary fraction numbers",
"minimum": 0,
"maximum": 9
},
{
"type": "null",
"description": "The number of digits will be automatically determined based on the value"
}
],
"default": null
}
}
},
"noBuffer": {
"type": "boolean",
"description": "Whether to disable the stdout application buffer",