mirror of
https://github.com/bisq-network/bisq.git
synced 2025-02-24 15:10:44 +01:00
Use three zero places max
This commit is contained in:
parent
ab3903d98d
commit
ff7e527ab8
2 changed files with 6 additions and 1 deletions
|
@ -9,7 +9,7 @@ public class ColoredDecimalPlacesWithZerosText extends TextFlow {
|
|||
public ColoredDecimalPlacesWithZerosText(String number) {
|
||||
super();
|
||||
|
||||
String placesBeforeZero = number.split("0*$")[0];
|
||||
String placesBeforeZero = number.split("0{1,3}$")[0];
|
||||
String zeroDecimalPlaces = number.substring(placesBeforeZero.length());
|
||||
Text first = new Text(placesBeforeZero);
|
||||
Text last = new Text(zeroDecimalPlaces);
|
||||
|
|
|
@ -0,0 +1,5 @@
|
|||
package io.bisq.gui.components;
|
||||
|
||||
public class ColoredDecimalPlacesWithZerosTextTest {
|
||||
|
||||
}
|
Loading…
Add table
Reference in a new issue