Comma being always replaced by decimal point inside text input boxes

Javier Cayetano Rodríguez shared this problem 1 month ago
In Progress

Recently, I have noticed that if I use a comma to separate the decimal part inside a number input box (online, files in Spanish language), it is automatically replaced by a decimal point. This is most of the times a good idea.


But it also happens when the input box is associated to a text variable. And it is inconvenient in some cases. Any comma inside the text is replaced by a decimal point!


For other types of variables it works fine (points and lists).


(Try it for example, here https://www.geogebra.org/m/ex2yunrx )


Is there any way I can prevent this from happening?

Thank you.


f335cd51996a999e792db9f9f1b255dff47b9fb2733c1fabe20444be035ba9ed

Comments (8)

photo
1

I can't see an immediate solution, unless substituting the input box with a dropdown list, containing a suitable choice of answers.

photo
1

Or provide a note text, telling users to enter names separated by "and".

Like "Teo and Francesca and Fabrizio"

photo
1

But it is a general problem. In may case, I have used input text boxes to collect different answers from students.

For example, a list of divisors (without making them write the "{" and "}" ).

In many of them, I think there is a workaround, but if think it would be an unnecessary limitation for GeoGebra to have input text boxes where no commas are allowed!!

Maybe a solution would be as simple as not make the substitution in those types of inputboxes. For example, for lists or points it is not made either.


Thank you for your answer.

photo
1

Seems like the comma is always treated special, just differently in different languages. In some languages it is replaced by a dot. In others (incl. English) it's even worse, the comma is simply removed (so if someone doesn't leave a space after the comma, everything is smushed together).

As far as I can tell, most other special characters are fine and properly appear in the text variable. Only other exception I found was the quotation mark, but that's not really a problem.

photo
1

You'll be able to use the new Symbolic Input Boxes for text objects soon where this is OK

photo
1

So, should I change the applets where I need the users to introduce a comma?

Or will you consider fixing the behaviour of the input text boxes we are using now, and we have used in our former applets?


Thank you.

photo
1

You'll need to wait a couple of weeks until it's released

photo
1

Ok. Thank you.

photo
© 2021 International GeoGebra Institute