如何消除Appbar灰线颤动

时间:2019-08-13 14:18:00

标签: flutter

我正在与Flutter合作,并看到了以下内容:
屏幕上出现一条灰线。
也许是因为应用栏向下移动了5px,背景颜色设置为灰色?

iPhone上的BTW,它运行完美,没有线条 https://imgur.com/jPyr01e

Container(
if I delete width but uncomment height it works but it sets a width of background around 200px I need double.infiniti
If I run the code it sets width to device.width but make the grey line visible
          // height: device.height * 390 / 812,
          width: double.infinity,
          child: BuildSvg('assets/svg/backgroundGradient.svg'),
        ),

buildsvg

import 'package:flutter/material.dart';
import 'package:flutter_svg/flutter_svg.dart';

class BuildSvg extends StatelessWidget {
  final url;
  BuildSvg(this.url);

  @override
  Widget build(BuildContext context) {
    final String assetName = url;
    final Widget svg = new SvgPicture.asset(assetName, semanticsLabel: '');
    return svg
  }
}

我将bgckcolor更改为红色
https://imgur.com/7C4yJ9E

0 个答案:

没有答案