Skip to content

Commit

Permalink
Remove redundant calculations of inner_view
Browse files Browse the repository at this point in the history
  • Loading branch information
A-Walrus committed Jul 1, 2022
1 parent 846d392 commit 18f6ebf
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions helix-term/src/ui/editor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -715,11 +715,12 @@ impl EditorView {
let primary_style = theme.get("ui.cursorline.primary");
let secondary_style = theme.get("ui.cursorline.secondary");

let inner_area = view.inner_area();
for line in view.offset.row..(last_line + 1) {
let area = Rect::new(
view.inner_area().x,
view.inner_area().y + (line - view.offset.row) as u16,
view.inner_area().width,
inner_area.x,
inner_area.y + (line - view.offset.row) as u16,
inner_area.width,
1,
);
if primary_line == line {
Expand Down

0 comments on commit 18f6ebf

Please sign in to comment.