zoukankan      html  css  js  c++  java
  • 02-10 flutter hintText和光标不对齐

    Expanded(
                          child: Container(
                            margin: EdgeInsets.fromLTRB(10, 5, 10, 5),
                            padding: EdgeInsets.only(left: 5),
                            decoration: BoxDecoration(
                                color: Colors.white,
                                borderRadius: BorderRadius.circular(4)),
                             double.infinity,
                            child: TextField(
                              controller: shoCodeTextField,
                              toolbarOptions: ToolbarOptions(),
                              maxLines: 1,
    
                              decoration: InputDecoration(
                                fillColor: Colors.red,
                                hintText: "请输入门店号",
                                hintStyle: TextStyle(
                                  fontSize: 12 ,
                                  height: 1.8,
                                  textBaseline: TextBaseline.alphabetic, //用于提示文字对齐
                                ),
                                contentPadding: EdgeInsets.all(0),
                                border: OutlineInputBorder(
                                  borderSide: BorderSide.none
                                )
                              ),
                              style: TextStyle(
                                fontSize: 12 ,
                                textBaseline: TextBaseline.alphabetic, //用于提示文字对齐
                              ),
    
    
                            ),
                          ),
                        ),
    
    child: CupertinoTextField(
        controller: telephoneController,
        keyboardType: TextInputType.number,
        textInputAction: TextInputAction.done,
      style:  TextStyle(
        fontSize: 12,
        height: 1.2,
        textBaseline: TextBaseline.alphabetic,
      ),
    ),
    
  • 相关阅读:
    2021.4.11(每周总结)
    2021.4.9
    2021.4.8
    2021.4.7
    k8s集群安装(一)安装方案介绍
    k8s映射外部服务Endpoints
    Linux服务器配置上网代理squid
    SonarQube学习笔记
    yum安装指定版本mysql
    linux目录没有颜色的处理
  • 原文地址:https://www.cnblogs.com/xiaowuqing/p/14028051.html
Copyright © 2011-2022 走看看