Flutter: How to add bullets points in a TextField?

Issue

How to add bullets points in a TextField widget similar to the Notes app in IOS?

image from iphone x note

Solution

You can use Unicode code to achieve this. Add the following Unicode ( \u25EF ) to your TextField using TextEditingController. You may also need to change the position of the cursor when adding text to your TextEditingController. This depends on your requirement and you will understand when you test this.

TextEditingController _textController = new TextEditingController();



_textController.text = " \u25EF ";

Yes. of course you need a custom button or something to trigger this event like in the note of IOS.
You can create a custom keyboard with an extra button to add bullets or a floating deck with a button like the Note app. Or simply give a button on the screen.

Answered By – SUDESH KUMARA

Answer Checked By – Gilberto Lyons (FlutterFixes Admin)

Leave a Reply

Your email address will not be published.