Search code examples
flutterflutter-layout

How To make this TextBox in Flutter


I want to acchive the textbox which will look like this and this is disable user can't change content in it.

enter image description here

How can I achive this?


Solution

  • TextField(
      readOnly: true,
      controller: TextEditingController()..text = "Lorem Ipsum is simply dummy text of the \nprinting and typesetting industry",
      minLines: 3,
      maxLines: 3,
      decoration: InputDecoration(
           labelText: "Explaination",
           labelStyle: TextStyle(fontWeight: FontWeight.w500), 
           border: OutlineInputBorder()
      ),
    ),