Skip to content

DatePicker dialog overflows on large screen #21383

@Ch4rl3B

Description

@Ch4rl3B

Hi, i have an issue with the datepicker dialog on a BLU STUDIO G2 with a large screen, the dialog bottom is overflowed by 39 pixels, so the "Accept" and "Cancel" button are inaccessible.

Steps to Reproduce

On my code:

My theme:

final ThemeData mainTheme = new ThemeData(
  brightness: Brightness.dark,
  primaryColor: Colors.white,
  accentColor: Colors.lightBlue,
  splashColor: Colors.lightBlue,
  textTheme: TextTheme(
    headline: TextStyle(color: Colors.black),
    subhead: TextStyle(color: Colors.white70),
    body1: TextStyle(color: Colors.white),
    caption: TextStyle(color: Colors.blue),
  ),
  primaryTextTheme: TextTheme(
    headline: TextStyle(color: Colors.black, fontWeight: FontWeight.bold),
    subhead: TextStyle(color: Colors.black54, fontStyle: FontStyle.italic),
    body1: TextStyle(color: Colors.black),
    body2: TextStyle(color: Colors.white),
    display2: TextStyle(color: Colors.black54),
    display3: TextStyle(color: Colors.black),
  ),
);

The DatePicker:

final DateTime picked = await showDatePicker(
        context: context,
        initialDate: selectedDate,
        firstDate: selectedDate,
        lastDate: new DateTime(2101)
    );

Logs

I/flutter (22738): ══╡ EXCEPTION CAUGHT BY RENDERING LIBRARY ╞═════════════════════════════════════════════════════════
I/flutter (22738): The following message was thrown during layout:
I/flutter (22738): A RenderFlex overflowed by 39 pixels on the bottom.
I/flutter (22738): The overflowing RenderFlex has an orientation of Axis.vertical.
I/flutter (22738): The edge of the RenderFlex that is overflowing has been marked in the rendering with a yellow and
I/flutter (22738): black striped pattern. This is usually caused by the contents being too big for the RenderFlex.
I/flutter (22738): Consider applying a flex factor (e.g. using an Expanded widget) to force the children of the
I/flutter (22738): RenderFlex to fit within the available space instead of being sized to their natural size.
I/flutter (22738): This is considered an error condition because it indicates that there is content that cannot be
I/flutter (22738): seen. If the content is legitimately bigger than the available space, consider clipping it with a
I/flutter (22738): ClipRect widget before putting it in the flex, or using a scrollable container rather than a Flex,
I/flutter (22738): like a ListView.
I/flutter (22738): The specific RenderFlex in question is:
I/flutter (22738):   RenderFlex#e5936 relayoutBoundary=up7 OVERFLOWING
I/flutter (22738):   creator: Column ← SizedBox ← LayoutBuilder ← OrientationBuilder ← DefaultTextStyle ←
I/flutter (22738):   AnimatedDefaultTextStyle ← _InkFeatures-[GlobalKey#65434 ink renderer] ←
I/flutter (22738):   NotificationListener<LayoutChangedNotification> ← CustomPaint ← _ShapeBorderPaint ← PhysicalShape
I/flutter (22738):   ← _MaterialInterior ← ⋯
I/flutter (22738):   parentData: <none> (can use size)
I/flutter (22738):   constraints: BoxConstraints(w=240.0, 0.0<=h<=449.3)
I/flutter (22738):   size: Size(240.0, 449.3)
I/flutter (22738):   direction: vertical
I/flutter (22738):   mainAxisAlignment: start
I/flutter (22738):   mainAxisSize: min
I/flutter (22738):   crossAxisAlignment: stretch
I/flutter (22738):   verticalDirection: down
I/flutter (22738): ◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤
I/flutter (22738): ════════════════════════════════════════════════════════════════════════════════════════════════════

Flutter Doctor

[√] Flutter (Channel beta, v0.5.1, on Microsoft Windows [Version 10.0.15063], locale en-US)
   • Flutter version 0.5.1 at C:\flutter
   • Framework revision c7ea3ca377 (3 months ago), 2018-05-29 21:07:33 +0200
   • Engine revision 1ed25ca7b7
   • Dart version 2.0.0-dev.58.0.flutter-f981f09760
                                                                                                                                                                            [
!] Android toolchain - develop for Android devices (Android SDK 27.0.3)
   • Android SDK at F:\sdk
   • Android NDK location not configured (optional; useful for native profiling support)
   • Platform android-27, build-tools 27.0.3
   • ANDROID_HOME = F:\sdk
   • Java binary at: C:\Program Files\JetBrains\Android Studio 3.0\jre\bin\java
   • Java version OpenJDK Runtime Environment (build 1.8.0_112-release-736)                                                                                                 
   X Android license status unknown.
                                                                                                                                                                            [
√] Android Studio (version 3.0)
  • Android Studio at C:\Program Files\Android\Android Studio
  • Flutter plugin version 22.2.1
  • Dart plugin version 171.4424
  • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-915-b01)
                                                                                                                                                                           [√
[√] Android Studio (version 3.0)
   • Android Studio at C:\Program Files\JetBrains\Android Studio 3.0
   • Flutter plugin version 22.2.1
   • Dart plugin version 171.4424
   • Java version OpenJDK Runtime Environment (build 1.8.0_112-release-736)
                                                                                                                                                                            [
!] IntelliJ IDEA Ultimate Edition (version 2017.2)
   • IntelliJ at C:\Program Files\JetBrains\IntelliJ IDEA 2017.2                                                                                                            
   X Flutter plugin not installed; this adds Flutter specific functionality.                                                                                                
    X Dart plugin not installed; this adds Dart specific functionality.
    • For information about installing plugins, see
      https://flutter.io/intellij-setup/#installing-the-plugins

[!] Connected devices
    ! No devices available

! Doctor found issues in 3 categories.

Pictures:

blu studio g2 version de android 6 0
device-2018-09-03-214820

Metadata

Metadata

Assignees

Labels

f: date/time pickerDate or time picker widgetsf: material designflutter/packages/flutter/material repository.frameworkflutter/packages/flutter repository. See also f: labels.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions