mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-07-15 16:26:08 +03:00
fmt
This commit is contained in:
@ -26,7 +26,7 @@ pub inline fn copy(comptime T: type, dest: []T, source: []const T) void {
|
||||
/// and a tmp var for the single rotated item instead of 3 calls to reverse.
|
||||
pub inline fn rotateOnce(comptime T: type, items: []T) void {
|
||||
const tmp = items[0];
|
||||
move(T, items[0..items.len - 1], items[1..items.len]);
|
||||
move(T, items[0 .. items.len - 1], items[1..items.len]);
|
||||
items[items.len - 1] = tmp;
|
||||
}
|
||||
|
||||
|
@ -1331,8 +1331,8 @@ fn rowWillBeShifted(
|
||||
// spacer head will be either moved or cleared, so we also need
|
||||
// to turn the spacer heads in to empty cells in that case.
|
||||
if (self.scrolling_region.right == self.cols - 1 or
|
||||
self.scrolling_region.left < 2
|
||||
) {
|
||||
self.scrolling_region.left < 2)
|
||||
{
|
||||
const end_cell: *Cell = &cells[page.size.cols - 1];
|
||||
if (end_cell.wide == .spacer_head) {
|
||||
end_cell.wide = .narrow;
|
||||
|
@ -184,7 +184,7 @@ pub const Page = struct {
|
||||
pub fn reinit(self: *Page) void {
|
||||
// We zero the page memory as u64 instead of u8 because
|
||||
// we can and it's empirically quite a bit faster.
|
||||
@memset(@as([*]u64, @ptrCast(self.memory))[0..self.memory.len / 8], 0);
|
||||
@memset(@as([*]u64, @ptrCast(self.memory))[0 .. self.memory.len / 8], 0);
|
||||
self.* = initBuf(OffsetBuf.init(self.memory), layout(self.capacity));
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user