李卓原

2.3

... ... @@ -49,16 +49,13 @@ Be sure to set the page in the MaterialApp's home/initialRoute(ie the entry file
//fill in the screen size of the device in the design
//default value : width : 1080px , height:1920px , allowFontScaling:false
ScreenUtil.init(context); ~~//flutter_screenuitl < 1.2~~
~~ScreenUtil.init(); //flutter_screenuitl >= 1.2~~
ScreenUtil.init(context);
//If the design is based on the size of the iPhone6 ​​(iPhone6 ​​750*1334)
ScreenUtil.init(context, width: 750, height: 1334); ~~//flutter_screenuitl < 1.2~~
~~ScreenUtil.init(width: 750, height: 1334); //flutter_screenuitl >= 1.2~~
ScreenUtil.init(context, width: 750, height: 1334);
//If you want to set the font size is scaled according to the system's "font size" assist option
ScreenUtil.init(context, width: 750, height: 1334, allowFontScaling: true); ~~//flutter_screenuitl < 1.2~~
~~ScreenUtil.init(width: 750, height: 1334, allowFontScaling: true); //flutter_screenuitl >= 1.2~~
ScreenUtil.init(context, width: 750, height: 1334, allowFontScaling: true);
```
... ...
... ... @@ -53,16 +53,13 @@ import 'package:flutter_screenutil/flutter_screenutil.dart';
//填入设计稿中设备的屏幕尺寸
//默认 width : 1080px , height:1920px , allowFontScaling:false
ScreenUtil.init(context); ~~//flutter_screenuitl < 1.2~~
~~ScreenUtil.init(); //flutter_screenuitl >= 1.2~~
ScreenUtil.init(context);
//假如设计稿是按iPhone6的尺寸设计的(iPhone6 750*1334)
ScreenUtil.init(context, width: 750, height: 1334); ~~//flutter_screenuitl < 1.2~~
~~ScreenUtil.init(width: 750, height: 1334); //flutter_screenuitl >= 1.2~~
ScreenUtil.init(context, width: 750, height: 1334);
//设置字体大小根据系统的“字体大小”辅助选项来进行缩放,默认为false
ScreenUtil.init(context, width: 750, height: 1334, allowFontScaling: true); ~~//flutter_screenuitl < 1.2~~
~~ScreenUtil.init(width: 750, height: 1334, allowFontScaling: true); //flutter_screenuitl >= 1.2~~
ScreenUtil.init(context, width: 750, height: 1334, allowFontScaling: true);
```
... ...
... ... @@ -49,16 +49,13 @@ Certifique-se de definir as dimensões na paginal inicial do MaterialApp (ou sej
//Preencha o tamanho da tela do dispositivo no protótipo de design
//Valor padrão: width : 1080px , height:1920px , allowFontScaling:false
ScreenUtil.init(context); ~~//flutter_screenuitl < 1.2~~
~~ScreenUtil.init(); //flutter_screenuitl >= 1.2~~
ScreenUtil.init(context);
//Se o design é baseado no iPhone6 ​​(iPhone6 ​​750*1334)
ScreenUtil.init(context, width: 750, height: 1334); ~~//flutter_screenuitl < 1.2~~
~~ScreenUtil.init(width: 750, height: 1334); //flutter_screenuitl >= 1.2~~
ScreenUtil.init(context, width: 750, height: 1334);
//Se você quer definir que o tamanho da fonte seja ajustado de acordo com a opção "tamanho da fonte" na acessibilidade do sistema
ScreenUtil.init(context, width: 750, height: 1334, allowFontScaling: true); ~~//flutter_screenuitl < 1.2~~
~~ScreenUtil.init(width: 750, height: 1334, allowFontScaling: true); //flutter_screenuitl >= 1.2~~
ScreenUtil.init(context, width: 750, height: 1334, allowFontScaling: true);
```
... ...