Toggle navigation
Toggle navigation
This project
Loading...
Sign in
flutter_package
/
flutter_screenutil
Go to a project
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
李卓原
2020-12-30 17:26:37 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
c7829b270e7e2c5ab37254abb56c0dfbde215a0a
c7829b27
1 parent
66262a0b
5.0.0-nullsafety.2
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
8 deletions
CHANGELOG.md
example/lib/main.dart
example/lib/main_zh.dart
CHANGELOG.md
View file @
c7829b2
# 5.0.0-nullsafety.
1
# 5.0.0-nullsafety.
2
-
merge 4.0.2+2 #186
# 5.0.0-nullsafety.1
...
...
example/lib/main.dart
View file @
c7829b2
...
...
@@ -65,7 +65,7 @@ class _HomePageState extends State<HomePage> {
// Without using Extensions
Container
(
padding:
EdgeInsets
.
all
(
ScreenUtil
().
setWidth
(
10
)),
width:
180
.
w
,
width:
ScreenUtil
().
setWidth
(
180
)
,
height:
ScreenUtil
().
setHeight
(
200
),
color:
Colors
.
blue
,
child:
Text
(
...
...
example/lib/main_zh.dart
View file @
c7829b2
...
...
@@ -47,8 +47,8 @@ class _HomePageState extends State<HomePage> {
children:
<
Widget
>[
Container
(
padding:
EdgeInsets
.
all
(
ScreenUtil
().
setWidth
(
10
)),
width:
ScreenUtil
().
setWidth
(
375
),
height:
ScreenUtil
().
setHeight
(
200
),
width:
180
.
w
,
height:
200
.
h
,
color:
Colors
.
red
,
child:
Text
(
'我的实际宽度:
${0.5.sw}
dp
\n
'
...
...
@@ -58,15 +58,14 @@ class _HomePageState extends State<HomePage> {
),
Container
(
padding:
EdgeInsets
.
all
(
ScreenUtil
().
setWidth
(
10
)),
width:
180
.
w
,
height:
200
.
h
,
width:
ScreenUtil
().
setWidth
(
180
),
height:
ScreenUtil
().
setHeight
(
200
),
color:
Colors
.
blue
,
child:
Text
(
'我的设计稿宽度: 180dp
\n
'
'我的设计稿高度: 200dp'
,
style:
TextStyle
(
color:
Colors
.
white
,
fontSize:
ScreenUtil
().
setSp
(
12
))),
),
],
),
Container
(
...
...
@@ -74,7 +73,8 @@ class _HomePageState extends State<HomePage> {
width:
100
.
r
,
height:
100
.
r
,
color:
Colors
.
green
,
child:
Text
(
'我是正方形,边长是100'
,
child:
Text
(
'我是正方形,边长是100'
,
style:
TextStyle
(
color:
Colors
.
white
,
fontSize:
ScreenUtil
().
setSp
(
12
),
...
...
Please
register
or
login
to post a comment