Skip to main content

Pragtical v3.12.4 Release

· 3 min read
Jefferson Gonzalez
Contributor of Pragtical

Pragtical v3.12.4 is out with Project Search view controls for plugins, a fix for SDL GPU subpixel text rendering on light backgrounds, better diagnostics for fatal runtime errors, and a native renderer source layout cleanup for developers and builders.

Project Search API

Project Search now exposes projectsearch.show() and projectsearch.hide() helpers for plugins that need to control the global search panel directly. The existing projectsearch.toggle() helper also accepts the same options table.

All three helpers return the shared global ResultsView instance, so plugins can show, hide, toggle, configure, and then keep interacting with the same view. The options table can set the search text, root path, matching flags, replacement text, search type, filters, focus behavior, and optional immediate search execution.

local projectsearch = require "plugins.projectsearch"

local view = projectsearch.show({
text = "ResultsView",
path = core.project_dir,
search_type = "plain",
insensitive = true,
filters = { includes = "*.lua", excludes = "build/" },
run = true,
})

projectsearch.toggle({ path = core.project_dir, has_focus = true })
projectsearch.hide({ path = core.project_dir })

SDL GPU Subpixel Text

The SDL GPU renderer now blends subpixel text correctly on light backgrounds. The previous path collapsed LCD glyph coverage into a single alpha value, which looked fine on dark themes but could produce colored fringes around glyph edges on bright backgrounds.

Subpixel glyph batches now use a two-pass blend that attenuates the destination per channel before adding the foreground color. This keeps destination alpha unchanged and matches the behavior of the surface renderer. Grayscale and color glyphs continue to use the existing single-pass path.

Before

subpixel before

After

subpixel after

Runtime Error Diagnostics

Fatal errors raised from the main core.run_step loop now include a Lua traceback. That makes reports from internal-error dialogs much more useful, because the error now points to the caller stack instead of only the final line where Lua detected the failure.

Those failures are also routed through core.on_error before the fatal dialog is shown, so error.txt is written and dirty documents keep the existing emergency-save handling.

Thanks to 0riginaln0 for raising the issue.

Renderer Source Layout

The native renderer files were reorganized under src/renderer, with concrete backends grouped under src/renderer/backend and generated GPU shader headers under src/renderer/shaders. This keeps the renderer implementation easier to navigate as the modular backend work continues.

Downloads on GitHub.

Changes Log

New Features

  • Add project search view controls (#575)

Enhancements

  • Refactor renderer file locations and names (#574)

Fixes

  • Improve runtime error diagnostics (#572)

  • Fix SDLGPU subpixel text on light backgrounds (#573)