Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
F
Front-End
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abdullh.alsoleman
Front-End
Commits
19a83549
Unverified
Commit
19a83549
authored
Dec 25, 2020
by
creativecreatorormaybenot
Committed by
GitHub
Dec 25, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Correct typos in RenderParagraph (#72930)
parent
6e5f55fb
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
8 deletions
+7
-8
paragraph.dart
packages/flutter/lib/src/rendering/paragraph.dart
+7
-8
No files found.
packages/flutter/lib/src/rendering/paragraph.dart
View file @
19a83549
...
...
@@ -266,11 +266,10 @@ class RenderParagraph extends RenderBox
/// Used by this paragraph's internal [TextPainter] to select a
/// locale-specific font.
///
/// In some cases the same Unicode character may be rendered differently
/// depending
/// on the locale. For example the '骨' character is rendered differently in
/// the Chinese and Japanese locales. In these cases the [locale] may be used
/// to select a locale-specific font.
/// In some cases, the same Unicode character may be rendered differently
/// depending on the locale. For example, the '骨' character is rendered
/// differently in the Chinese and Japanese locales. In these cases, the
/// [locale] may be used to select a locale-specific font.
Locale
?
get
locale
=>
_textPainter
.
locale
;
/// The value may be null.
set
locale
(
Locale
?
value
)
{
...
...
@@ -378,7 +377,7 @@ class RenderParagraph extends RenderBox
case
ui
.
PlaceholderAlignment
.
belowBaseline
:
{
assert
(
RenderObject
.
debugCheckingIntrinsics
,
'Intrinsics are not available for PlaceholderAlignment.baseline, '
'PlaceholderAlignment.aboveBaseline, or PlaceholderAlignment.belowBaseline
,
'
);
'PlaceholderAlignment.aboveBaseline, or PlaceholderAlignment.belowBaseline
.
'
);
return
false
;
}
case
ui
.
PlaceholderAlignment
.
top
:
...
...
@@ -432,7 +431,7 @@ class RenderParagraph extends RenderBox
final
List
<
PlaceholderDimensions
>
placeholderDimensions
=
List
<
PlaceholderDimensions
>.
filled
(
childCount
,
PlaceholderDimensions
.
empty
,
growable:
false
);
int
childIndex
=
0
;
// Takes textScaleFactor into account because the content of the placeholder
// span will be scale up when it paints.
// span will be scale
d
up when it paints.
width
=
width
/
textScaleFactor
;
while
(
child
!=
null
)
{
final
Size
size
=
child
.
getDryLayout
(
BoxConstraints
(
maxWidth:
width
));
...
...
@@ -556,7 +555,7 @@ class RenderParagraph extends RenderBox
// Leave height unconstrained, which will overflow if expanded past.
BoxConstraints
boxConstraints
=
BoxConstraints
(
maxWidth:
constraints
.
maxWidth
);
// The content will be enlarged by textScaleFactor during painting phase.
// We reduce constraint
by textScaleFactor
so that the content will fit
// We reduce constraint
s by textScaleFactor,
so that the content will fit
// into the box once it is enlarged.
boxConstraints
=
boxConstraints
/
textScaleFactor
;
while
(
child
!=
null
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment