ByteNote LogoByteNote

Navigation

  • Blog
  • 工具

    © 2025 ByteNote. All rights reserved.

    Flutter TextField 组件属性及描述

    Jun 30, 20226 min read
    属性名 类型 说明 默认值 取值
    maxLength int 最大长度
    maxLines int 最大行数
    autocorrect bool 是否自动更正
    autofous bool 是否自动对焦
    obscureText bool 是否是密码
    textAlign TextAlign 文本对齐方式
    style TextStyle 输入文本的样式
    inputFormatters List 允许的输入格式
    onChanged ValueChanded 内容改变的回调
    onSubmitted ValueChanged 内容提交的回调
    enabled bool 是否禁用

    相关文章

    使用 VS Code 中的 REST Client 调试 RESTful 接口

    在 VS Code 中使用 REST Client 插件可以方便地调试 RESTful 接口,支持多种请求类型、自动生成代码、环境切换和权限验证等功能。

    Linux 查看CPU占用最多的前10个进程

    该命令用于在Linux系统中查看并列出CPU占用最高的前10个进程。

    What is the home directory on Windows Subsystem for Linux?

    The Windows Subsystem for Linux home directory is at /home/<username>, with <username> being the current user's name.

    Flutter 点击空白处回收键盘

    Flutter应用中通过GestureDetector的onTap事件检测空白处点击,若当前焦点不是主要焦点,则调用unfocus()方法回收键盘。

    用JavaScript实现函数链式调用,让你的代码更具可读性和灵活性!

    JavaScript中通过链式调用方法增强代码的可读性和灵活性,示例展示了如何创建一个可链式调用的`Calculator`对象。