Skip to content

TextField cursor height cannot be changed #26870

Closed

Description

@BumsuKimBding

Hi,

I'm making a platform application with Flutter and it's going quite well until now. But since I wanted to make the cursor of Textfield taller(not thicker, I know 'cursorWidth' option already exists), I have no way to do this without any customization of original material class. Anybody has made this before? It would be very cool if anybody has an example/solution.

Activity

  1. added
    a: text inputEntering text in a text field or keyboard related problems
    frameworkflutter/packages/flutter repository. See also f: labels.
    p: material_uimaterial_ui package in flutter/packages
    c: new featureNothing broken; request for a new capability
    on Jan 22, 2019
  2. added this to the milestone on Jan 22, 2019
  3. justinmc commented on Jan 22, 2019

    @justinmc
    Contributor

    As of now you're right, there is only a way to adjust the cursor width, not height. I think this is a reasonable request though. I'm gathering a list of improvements for TextField, so I'll add this.

  4. sgon00 commented on May 6, 2019

    @sgon00

    Currently, the cursor's height is smaller than the Text height and top aligned. Is this expected?

  5. justinmc commented on May 6, 2019

    @justinmc
    Contributor

    @sgon00 I'm not sure, can you post a screenshot? There are some issues that might be similar to what you're seeing.

    #30771 (recently fixed)
    #31661 (open)

  6. GaryQian commented on May 7, 2019

    @GaryQian
    Contributor

    @sgon00 Try dev or master channels, as we have recently landed a fix that centers the caret with the text.

  7. sgon00 commented on May 7, 2019

    @sgon00

    @justinmc @GaryQian Thanks a lot for the quick reply. My previous comment was based on "4 weeks ago" dev build. I just tried the latest dev build. The caret looks much better now. I am ok with the current behavior. Cheers. 😀👍

  8. eliwowlol123 commented on Jun 28, 2019

    @eliwowlol123

    Has there been any progress towards solving this problem?

  9. justinmc commented on Jun 28, 2019

    @justinmc
    Contributor

    No one has worked on a way to set the cursor height yet as far as I know. PRs are welcome though if anyone wants to pick this up!

  10. eliwowlol123 commented on Jun 29, 2019

    @eliwowlol123

    Okay no problemo!

  11. aneeshjose commented on Aug 23, 2019

    @aneeshjose

    #24182 (comment)
    Hope this helps.

  12. rahulsinghk commented on May 16, 2020

    @rahulsinghk

    and one more problem, cursor height decreases when using contentPadding in the input. plz provide a way to change the cursor height

  13. added
    P2Important issues not at the top of the work list
    on May 29, 2020
  14. modified the milestones: , 1.21 - July 2020 on Jul 17, 2020
  15. github-actions commented on Aug 18, 2021

    @github-actions

    This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

  16. locked as resolved and limited conversation to collaborators on Aug 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

P2Important issues not at the top of the work lista: text inputEntering text in a text field or keyboard related problemsc: new featureNothing broken; request for a new capabilityframeworkflutter/packages/flutter repository. See also f: labels.p: material_uimaterial_ui package in flutter/packages

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions