我需要创建一个带有装饰的 TextFormField - counterText 和 labelText。我是这样做的:
new TextFormField(
decoration: new InputDecoration(
counterText: "some text",
labelText: header),
);
一切都很好,除了我需要将计数器文本移到左侧,但默认情况下,它位于右侧。如何改变呢?我知道有 counterStyle
参数,但我不知道如何使用它来实现将文本向左移动。
最佳答案
这是helperText
属性您正在寻找的东西。
关于dart - flutter 文本字段对齐,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/48821717/