Skip to content

Maintenance 2026: Text Editor#86

Open
samizdatco wants to merge 54 commits into
mainfrom
maintenance-2026-editor
Open

Maintenance 2026: Text Editor#86
samizdatco wants to merge 54 commits into
mainfrom
maintenance-2026-editor

Conversation

@samizdatco

Copy link
Copy Markdown
Member

Text editor updates

  • Upgrade the embedded Ace editor to version 1.44
  • Fix: Deleting a whole line of text in the editor (via command-backspace) leaves visible artifacts for certain characters
  • Enhanced in-editor documentation:
    • Tooltips show usage when hovering over PlotDevice functions/types
    • Link in tooltip goes to the function's page in the docs (also available via contextual menu)
    • Tab-autocomplete previews syntax while selecting from menu

- all the metadata has been moved to pyproject and setup.py is now only responsible for building the c/objc/swift extension
- CI helpers and app/package building now live in the `build.py` script
- builds & tests now use standard `python3 -m build` and `python3 -m tests`
- pyobjc doesn't ship wheels for 3.8 anyway
- previously they would never interrupt CI, even with a failure
- also fixes local env detection in cli when run from repo
- allows the test suite to run in CI
- it was using map() which started being lazy in python3 and was failing to invoke the callback
- comparing to a tuple was always a non-match
- add missing dunder methods and drop otiose ones from MagicNumber (the base class for Dimension & Unit)
- add unit tests exercising numeric comparison ops
- fixes #67
- previously the vector would be rasterized at the width/height of the PDF or SVG, then that bitmap mask would be scaled
- now the vector image is scaled to the size it will occupy on the canvas *before* being rasterized, so the masking is still pixel-based, but will no longer be super-low res
- partially addresses #83 (though it doesn't provide the vector-based mask the user exptected)
- initial migration uses some runloop trickery in the EditorView.source getter to stay compatible with the synchronous file-saving api
- web inspector is now only enabled by default on dev builds (though it can be added to dist builds with a defaults write to `WebKitDeveloperExtras`)
- removed the need for the runloop trickery by keeping a cached copy of the document in _last_source (updated via the undo-manager callback)
- source file is app/art/PlotDevice-app.icon
- Assets.car can be rebuilt with `make.py icon`
- support for quads was added in macOS 14, deprecating the now-ambiguously named `NSBezierPathElementCurveTo`
- this changes the previous keybinding for adding a new insertion point: it now uses command-opt-click
- when, say, `fill` is used as a kwarg, it won't let you click it (since that would take you to the docs for `fill()` instead)
ace's default command-exec handler replaces falsy args (including a
legitimately empty source, e.g. a brand-new blank document) with {}
before invoking the command, which the refreshdoc command forwarded
straight into session.setValue() -- crashing $detectNewLine since {}
is truthy and has no .match(). Guard against non-string args instead.
@samizdatco samizdatco mentioned this pull request Jul 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant