You can use PreferredSize:
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Example',
home: Scaffold(
appBar: PreferredSize(
preferredSize: Size.fromHeight(50.0), // here the desired height
child: AppBar(
// ...
)
),
body: // ...
)
);
}
}
Related Contents:
- Flutter: RenderBox was not laid out
- How do I bold (or format) a piece of text within a paragraph?
- Flutter position stack widget in center
- Flutter get context in initState method
- Dart Multiple Constructors
- How to remove scroll glow?
- flutter corner radius with transparent background
- Close modal bottom sheet programmatically in flutter
- What are Keys in the Stateless widgets class?
- How do I rotate something 15 degrees in Flutter?
- Flutter BottomNavigationBar not working with more than three items
- Flutter Circle Design
- how to set showModalBottomSheet to full height?
- update dart sdk for flutter
- Textfield validation in Flutter
- Flutter – ‘initialValue == null || controller == null’: is not true. error
- Flutter: Outline input border
- flutter run function every x amount of seconds
- Dart convert int variable to string
- New Flutter Project wizard not showing on Android Studio 3.0.1
- How to get response body with request.send() in dart
- Is there a way to print a console message with Flutter?
- Expanded widgets must be placed inside Flex widgets
- Does using const in the widget tree improve performance?
- Displaying notification badge on BottomNavigationBar’s Icon
- How do I call async property in Widget build method
- How can I get the size of the Text widget in Flutter
- How to spread a list in dart
- Can I use multiple method on a future builder?
- dart:ui:1: Error: Not found: dart:ui. flutter/dart:
- Is it possible “extend” ThemeData in Flutter
- How to write a double back button pressed to exit app using flutter
- how to convert an image to base64 image in flutter?
- How to convert to double
- How to use InputFormatter on Flutter TextField?
- Is there a way to set Height to a Drawer Header?
- How to deploy flutter web on server?
- How to solve Not found: ‘dart:ui’ error while running integration tests on Flutter
- What is the difference between AssetImage and Image.asset – Flutter
- How do I cancel Future.delayed?
- Error: Only static members can be accessed in initializers what does this mean?
- How to use the PI constant in Dart
- Flutter background of unsafe area in SafeArea widget.
- Flutter TextField with currency format
- How do you pass arguments from command line to main in Flutter/Dart?
- using the new keyword in flutter [duplicate]
- What does “context” of “Widget build(BuildContext context)” mean in Flutter?
- Flutter Firestore Server side Timestamp
- What is the difference between streamController.add() and streamController.sink.add()?
- Flutter position fixed equivalent