79128009

Date: 2024-10-26 07:26:05
Score: 0.5
Natty:
Report link

Your texts do have the same font size:

A digital ruler showing that the text sizes are the same

The issue here is that the individual letters have different sizes - for example a 1 takes less horizontal space than a 0.

What you want to do is use the textAlign-property of the Text()-widget and set it to justify, like so:

Text(
    '24.10.15 16:01',
    style: TextStyle(
        color: Colors.white,
        fontWeight: FontWeight.w600,
        fontSize: 23,
        fontFamily: "Interop",
    ),
    textAlign: TextAlign.justify,
)

For more information, see: How to justify text in a flutter column widget?

See also: https://api.flutter.dev/flutter/dart-ui/TextAlign.html

An alternative approach would be to have each element of your string as a separate Text()-widget with an absolute width.

Reasons:
  • Probably link only (1):
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: Tim Hansen