Open mkraska opened 4 months ago
Formatting of the output is tested in TM2 03 T02 V2 Mohr's circle (stress) (Meclib, localized)
Here https://jsfiddle.net/7k0a4jbv/3/ you can find a meclib version with german locale. Infobox and axes tick labels are adjusted.
STACK 4.6 has a question-wide option "decimal separator", which can be set to "." or ",".
If it is set to
,
then the comma becomes the decimal separator and the semicolon;
becomes the argument separator in functions and lists.The required modifications are:
names
input field (unidirectional, JSXGraph to STACK only)Detect the separator setting in the question
The brute force option is to add a constant in the `[[JSXGraph]] block and set it manually to the value of the separator option in the question.
const decsep = ",";
This must be defined manually according to the question setting, unless there is a CAS variable in STACK which reflects that setting.
EDIT 2024-10-19: Actually there is such a variable:
stackfltsep
. It is a string.Format of the
names
input fieldAdjustment of the output format is done in the Meclib function
update()
.This adjustment is required as long as STACK doesn't provide a forgiving mode, where both versions are accepted
Format of the Infobox
The Infobox is customized using the function
The modification could probably be done using JS native localization methods.
Format of the tick labels
The tick labels are also already customized in the [["grid"]] object.
The modification could probably be done using JS native localization methods.