Questions tagged [texteditingcontroller]
88 questions
2
votes
2 answers
Cursor defaults to start of Textfield when typing, using TextEditingController + onChanged - Flutter
I'm developing an app that will have some single line Textfields that are essentially used to store notes in each, so I am using shared_preferences dependency to set/get these values, but using this with a TextEditingController and onChanged…

James
- 21
- 4
1
vote
1 answer
How to remove hashtags with the word attached to them in Flutter TextFields?
I am trying to capture any words attached to a hashtag symbol to add it to a list and then remove it from the TextFormField. I have searched a lot for a solution but I didn't find a good one also I tried myself. But after a long time of trying to…

Tamrawii C
- 13
- 3
1
vote
2 answers
How can I code a editable textfield in a CustomPainter in Flutter
I have a CustomPainter extending class. Until now, I paint only rectangles with some static text in it. Now I want to improve this a little bit and want that the user of my Flutter-App can edit this text.
I added a TextEditingController to my…

aCas
- 65
- 1
- 6
1
vote
2 answers
Flutter - Make custom text editing controller
I want to make a custom text editing controller which will show the numbers of text in Farsi (Persian), but returns it with English numbers when you call textEditingController.text.
Here's what I have implemented but it seems like the TextField…

Mehrzad Mohammadi
- 404
- 1
- 6
- 18
1
vote
2 answers
How to assign TextEditingController to dynamicaly created textfield in model and retrieve data from TextEditingController in flutter
What I actually want is to create text fields against each index of my list and display this list of text fields in expansion tile with Title 'index' of list and children are Textfields which user will create dynamically on button click so I Created…

Ahmad Raza
- 758
- 7
- 26
1
vote
2 answers
Flutter TextField selection highlighter controls appear too high
Screenshot of the issue and code in use below, the selection controls are above the textfield for some bizarre reason.
var textField = TextField(
selectionHeightStyle: BoxHeightStyle.max,
scrollPadding: EdgeInsets.only(bottom:…

David van Dugteren
- 3,879
- 9
- 33
- 48
1
vote
1 answer
Created 2 text fields with a loop. Now they have same value
Im trying to create a trainings app for myself.
I have created a app that can add more textfields everytime a button is pushed.
The problem im having is all the fields have the same value and i cant enter two diffrent
I have tried a couple of things…

Ko1ind
- 39
- 8
1
vote
1 answer
Flutter : TextEditingController Textspan's recognizer raising error on initializing text
Please check this video.
Here I extend TextEditingController to highlight(also clickable) the keyword "ali". It is working perfectly whenever the user types "ali". But when initializing text to the controller, it is showing a lot of errors. Someone…

Ali Akbar
- 21
- 1
- 4
1
vote
0 answers
Update TextEditingController from a Store (mobx)
I am trying to update a text in TextEditingController when something changes in store.
The flow is: user scans a barcode and I have to show the scanned barcode in a textfield. There is also an option to enter a barcode manually to this field and…

InnaZis
- 79
- 1
- 2
- 14
1
vote
0 answers
Using TextEditingController to pass the item in dropdown, in flutter
I have built a dropdown which has a dropdown list. The item that is selected from the list should be passed to another page, hence, I have used the TextEditingController variable to do that. But the problem is that the dropdown button doesn't allow…

yamini r
- 153
- 1
- 15
1
vote
0 answers
Not able to post http request using TextEditingController variable in JSON body
I am not able to post http request using TextEditingController in JSON body, but same code is working if I directly pass the string to JSON body
class _FormPageState extends State {
late String name1;
late String email1;
…

Abhi Shah
- 11
- 4
1
vote
1 answer
How can I use controller as a string?
I want to pass the controller as a String in an argument but the controller is of TextEditingController type. How can I change the type of controller as a String?

Kapil Kumar
- 23
- 6
1
vote
2 answers
A TextEditingController was used after being disposed. Called a reusable entry field class where i am passing this controller
I have created a reusable field that is called to display different fields in a form in different screen in my app i have also passed a controller however when dispose the controller it shows this error and if i go back to the same form screen it…

Informative Programmer
- 153
- 1
- 2
- 8
1
vote
3 answers
Flutter - Input TextField gets cleared by TextEditingController but the entered message appears to be 'still alive' (not empty)
I have a chat-app that uses a single TextField controlled by a TextEditingController to enter text messages.
Pressing the associated IconButton sends the message if the message is not empty and then clears the TextEditingController. This all works…

CEO tech4lifeapps
- 885
- 1
- 12
- 31
1
vote
2 answers
Flutter Typeahead
I am not getting the desired outcome when using the typeahead package.
Current undesired behaviors:
when I tap on the text field I'm immediately shown the list of all suggestions (over 26,000) before I even begin typing
when I start typing, the…

student
- 11
- 2