alpha
Login
or
Join now
ptr.pet
/
ghostty
Star
0
Fork
0
Atom
Configure Feed
Issues
Pull Requests
Commits
Tags
Feed URL
Select the types of activity you want to include in your feed.
This repository has no description
Star
0
Fork
0
Atom
Configure Feed
Issues
Pull Requests
Commits
Tags
Feed URL
Select the types of activity you want to include in your feed.
Overview
Issues
Pulls
Pipelines
ghostty
/
src
/
renderer
/
at
main
3 folders
17 files
Mike Bommarito
renderer: skip updateFrame when surface is not visible
2mo ago
14d9e600
metal
renderer/metal: clamp texture sizes to the maximum allowed by the device This prevents a crash in our renderer when it is larger. I will pair this with apprt changes so that our mac app won't ever allow a default window larger than the screen but we should be resilient at the renderer level as well.
7 months ago
opengl
Remove unused imports
8 months ago
shaders
renderer: added cursor style and visibility uniforms Specifically: iCurrentCursorStyle iPreviousCursorStyle iCurrentCursorVisible iPreviousCursorVisible Visibility calculated and updated independently from the typical cursor unifrom updates to preserve cursor style even when not in the viewport or set to be hidden
8 months ago
Metal.zig
fix(iOS): fix iOS app startup failure Fixes #7643 This commit address the issue with 3 minor fixes: 1. Initialize ghostty lib before app start, or global allocator will be null. 2. `addSublayer` should be called on CALayer object, which is the property 'layer' of UIView 3. According to apple's [document](https://developer.apple.com/documentation/metal/mtlstoragemode/managed?language=objc), managed storage mode is not supported by iOS. So always use shared mode. FYI, another [fix](https://github.com/mitchellh/libxev/pull/204) in libxev is also required to make iOS app work.
7 months ago
OpenGL.zig
gtk/opengl: print an error when OpenGL version is too old #1123 added a warning when the OpenGL version is too old, but it is never used because GTK enforces the version set with gl_area.setRequiredVersion() before prepareContext() is called: we end up with a generic "failed to make GL context" error: warning(gtk_ghostty_surface): failed to make GL context current: Unable to create a GL context warning(gtk_ghostty_surface): this error is almost always due to a library, driver, or GTK issue warning(gtk_ghostty_surface): this is a common cause of this issue: https://ghostty.org/docs/help/gtk-opengl-context This patch removes the requirement at the GTK level and lets the ghostty renderer check, now failing as follow: info(opengl): loaded OpenGL 4.2 error(opengl): OpenGL version is too old. Ghostty requires OpenGL 4.3 warning(gtk_ghostty_surface): failed to initialize surface err=error.OpenGLOutdated warning(gtk_ghostty_surface): surface failed to initialize err=error.SurfaceError (Note that this does not render a ghostty window, unlike the previous error which rendered the "Unable to acquire an OpenGL context for rendering." view, so while the error itself is easier to understand it might be harder to view)
9 months ago
Options.zig
Remove unused imports
8 months ago
Overlay.zig
renderer: semantic prompt overlay
6 months ago
State.zig
renderer: fix preedit range width
3 months ago
Thread.zig
renderer: skip updateFrame when surface is not visible renderCallback early-returns while !flags.visible to avoid the cell rebuild for hidden surfaces (tab switch, minimize, etc.). The .visible → true mailbox handler now runs updateFrame before drawFrame so the first frame after re-show isn't stale. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2 months ago
WebGL.zig
can specify a wasm target in build
3 years ago
backend.zig
build: move apprt, font, renderer enums to dedicated files This reduces the surface area of files we depend on for builds.
10 months ago
cell.zig
terminal: make stream processing infallible The terminal.Stream next/nextSlice functions can now no longer fail. All prior failure modes were fully isolated in the handler `vt` callbacks. As such, vt callbacks are now required to not return an error and handle their own errors somehow. Allowing streams to be fallible before was an incorrect design. It caused problematic scenarios like in `nextSlice` early terminating processing due to handler errors. This should not be possible. There is no safe way to bubble up vt errors through the stream because if nextSlice is called and multiple errors are returned, we can't coalesce them. We could modify that to return a partial result but its just more work for stream that is unnecessary. The handler can do all of this. This work was discovered due to cleanups to prepare for more C APIs. Less errors make C APIs easier to implement! And, it helps clean up our Zig, too.
5 months ago
cursor.zig
renderer: added cursor style and visibility uniforms Specifically: iCurrentCursorStyle iPreviousCursorStyle iCurrentCursorVisible iPreviousCursorVisible Visibility calculated and updated independently from the typical cursor unifrom updates to preserve cursor style even when not in the viewport or set to be hidden
8 months ago
generic.zig
libghostty: add resolved bg_color and fg_color to cells API Fixes #11705 Add bg_color and fg_color options to GhosttyRenderStateRowCellsData that resolve the final RGB color for a cell, flattening the multiple possible sources. For background, this handles content-tag bg_color_rgb, content-tag bg_color_palette (looked up in the palette), and the style bg_color. For foreground, this resolves palette indices through the palette; bold color handling is not applied and is left to the caller. Both return GHOSTTY_INVALID_VALUE when no explicit color is set, in which case the caller should fall back to whatever default color it wants (e.g. the terminal background/foreground).
4 months ago
image.zig
libghostty: add placement pixel_size and grid_size, rename calculatedSize Expose Placement.pixelSize() and Placement.gridSize() as new C API functions ghostty_kitty_graphics_placement_pixel_size() and ghostty_kitty_graphics_placement_grid_size(). Both take the placement iterator, image handle, and terminal, returning their results via out params. Rename the internal Zig method from calculatedSize to pixelSize to pair naturally with gridSize — one returns pixels, the other grid cells. Updated all callers including the renderer.
4 months ago
link.zig
terminal: make stream processing infallible The terminal.Stream next/nextSlice functions can now no longer fail. All prior failure modes were fully isolated in the handler `vt` callbacks. As such, vt callbacks are now required to not return an error and handle their own errors somehow. Allowing streams to be fallible before was an incorrect design. It caused problematic scenarios like in `nextSlice` early terminating processing due to handler errors. This should not be possible. There is no safe way to bubble up vt errors through the stream because if nextSlice is called and multiple errors are returned, we can't coalesce them. We could modify that to return a partial result but its just more work for stream that is unnecessary. The handler can do all of this. This work was discovered due to cleanups to prepare for more C APIs. Less errors make C APIs easier to implement! And, it helps clean up our Zig, too.
5 months ago
message.zig
Remove unused imports
8 months ago
row.zig
PR review
6 months ago
shadertoy.zig
renderer: added cursor style and visibility uniforms Specifically: iCurrentCursorStyle iPreviousCursorStyle iCurrentCursorVisible iPreviousCursorVisible Visibility calculated and updated independently from the typical cursor unifrom updates to preserve cursor style even when not in the viewport or set to be hidden
8 months ago
size.zig
renderer/size: move PaddingBalance enum out of Config Previously WindowPaddingBalance was defined inside Config.zig, which meant tests for renderer sizing had to pull in the full config dependency. Move the enum into renderer/size.zig as PaddingBalance and re-export it from Config so the public API is unchanged. This lets size.zig tests run without depending on Config.
4 months ago