Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
K
Kayak UI
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Microhacks
Bevy Forks
Kayak UI
Commits
8d8a6e92
Commit
8d8a6e92
authored
3 years ago
by
Gino Valente
Browse files
Options
Downloads
Patches
Plain Diff
Fixed some lines not being trimmed
parent
49fa1c26
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
kayak_font/src/font.rs
+2
-1
2 additions, 1 deletion
kayak_font/src/font.rs
with
2 additions
and
1 deletion
kayak_font/src/font.rs
+
2
−
1
View file @
8d8a6e92
...
@@ -147,7 +147,7 @@ impl KayakFont {
...
@@ -147,7 +147,7 @@ impl KayakFont {
for
(
index
,
word
)
in
words
.iter
()
.enumerate
()
{
for
(
index
,
word
)
in
words
.iter
()
.enumerate
()
{
// Check if this is the last word of the line.
// Check if this is the last word of the line.
let
will_break
=
break_index
.map
(|
idx
|
index
+
1
==
idx
)
.unwrap_or_default
();
let
mut
will_break
=
break_index
.map
(|
idx
|
index
+
1
==
idx
)
.unwrap_or_default
();
// === Line Break === //
// === Line Break === //
// If the `break_index` is set, see if it applies.
// If the `break_index` is set, see if it applies.
...
@@ -168,6 +168,7 @@ impl KayakFont {
...
@@ -168,6 +168,7 @@ impl KayakFont {
let
(
next_break
,
next_skip
)
=
self
.find_next_break
(
index
,
line
.width
,
properties
,
&
words
);
let
(
next_break
,
next_skip
)
=
self
.find_next_break
(
index
,
line
.width
,
properties
,
&
words
);
break_index
=
next_break
;
break_index
=
next_break
;
skip_until_index
=
next_skip
;
skip_until_index
=
next_skip
;
will_break
|
=
break_index
.map
(|
idx
|
index
+
1
==
idx
)
.unwrap_or_default
();
}
}
}
}
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment