editor: Represent scroll offset with more precision (#39367)
Closes #5355 Release Notes: - Fixed rendering glitches with files with more than 16 million lines (that occured due to floating number rounding errors). --------- Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
This commit is contained in:
co-authored by
Smit Barmase
parent
4c35274b6e
commit
d359a814f8
@@ -585,7 +585,7 @@ fn aligned_origin_x(
|
||||
|
||||
match align {
|
||||
TextAlign::Left => origin.x,
|
||||
TextAlign::Center => (2.0 * origin.x + align_width - line_width) / 2.0,
|
||||
TextAlign::Center => (origin.x * 2.0 + align_width - line_width) / 2.0,
|
||||
TextAlign::Right => origin.x + align_width - line_width,
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user