A one-instruction bytecode patch that restores text selection in OpenText (NetIQ) Identity Manager Designer 4.10.x on macOS Tahoe 26.1+.
Without this patch, Designer's GCV "Edit XML…" dialog, the DirXML Policy
editor's "XML Source" tab, the standard Java editor, and every other
multi-line text widget across Designer show broken visual selection
highlighting: Cmd-A, drag-select across lines, and shift-arrow appear
to do nothing. The selection state is actually correct (try Cmd-A then
Delete — the whole document goes); only the highlight rendering clips
to one line.
This is not a Designer bug. It's an upstream Eclipse SWT bug.
org.eclipse.swt.graphics.TextLayout.draw() paints the trailing
FULL_SELECTION fill rect with a width of 0x7fffffff (≈ 2.15e9). On
macOS Tahoe 26.1+, NSBezierPath.appendBezierPathWithRect() silently
rejects rect widths that huge, so the trailing fill never paints.
Combined with how StyledText draws multi-line selections, this
manifests as highlights collapsing to single-line visual scope while
selection state remains correct.
Upstream fix:
The upstream fix replaces 0x7fffffff with OS.MAX_TEXT_CONTAINER_SIZE
(5,000,000). Designer ships SWT 3.106.2 (Nov 2017) which contains the
identical buggy line. This project applies the same one-instruction
change to the Designer-bundled jar via ASM.
| Item | Value |
|---|---|
| Jar | /Applications/Designer/plugins/org.eclipse.swt.cocoa.macosx.x86_64_3.106.2.v20171129-0543.jar |
| Class | org/eclipse/swt/graphics/TextLayout |
| Method | draw(GC, int, int, int, int, Color, Color, int)V |
| Instruction | one ldc2_w of double 2.147483647E9 → 5_000_000.0 |
The double constant 2.147483647E9 also appears in
org/eclipse/swt/widgets/Display for an unrelated 32-bit overflow
normalization loop. The patcher targets TextLayout only.
./build.shOutputs dist/swt.cocoa.macosx.x86_64.jar (a drop-in replacement for the
Designer-bundled fragment). Requires JDK 8 (zulu-8 auto-detected from
~/Library/Java or /Library/Java, or override via JAVA_HOME_8).
The vendored pristine jar at lib/swt.cocoa.macosx.x86_64.original.jar
is sha-checked against the live install to catch stale vendors after a
Designer upgrade.
./install.sh- Backs up the original to
<jar>.bak(idempotent — preserved on subsequent runs). - Copies the patched jar into place.
- Wipes the Equinox bundle cache (
configuration/org.eclipse.osgi/*) so the new bytecode is read on next launch. - Refuses to run while Designer is running.
After ./install.sh, launch Designer and:
- Open any Identity Vault project. Right-click a driver → Properties → Global Configuration Values → Edit XML…
- Cmd-A should now highlight the entire XML, not just one line.
- Click-drag across lines should highlight correctly.
- Shift-arrow up/down should extend selection visually.
If the dialog still appears broken, check configuration/*.log for any
Equinox refusal to load the unsigned fragment, and confirm
./uninstall.sh then ./install.sh again with Designer quit.
./uninstall.shRestores the pristine jar from <jar>.bak. Idempotent.
The Eclipse-distributed SWT fragment is signed
(META-INF/ECLIPSE_.SF, ECLIPSE_.RSA, per-entry SHA-256 digests).
Modifying any class invalidates that signature, so the patcher:
- Drops the
.SF/.RSA/.DSA/.ECblocks. - Strips signer-added
*-Digest-*headers from the main manifest. - Drops per-entry sections from
MANIFEST.MF(their only content in a signed Eclipse fragment is the per-entry digest).
Equinox loads unsigned local fragments under plugins/ with at most a
log warning — no enforcement on the Designer plugin path.
- macOS Tahoe 26.1+: fixes the bug.
- macOS Sequoia 15.x and earlier: no behaviour change (the
replacement value
5_000_000is still effectively "wider than any reasonable display", so the trailing fill still extends past the visible viewport). - Apple Silicon: Designer runs x86-64 under Rosetta, so the
cocoa.macosx.x86_64fragment is correct. If a future Designer release ships anaarch64fragment, the same patch needs to be re-applied against that jar.
This is not part of the designer-fast-import LDAP/NDAP bulk-read
cache patch and must not be folded into the fast-import bundle. The
two patches target different jars and address different bugs. Install
or uninstall them independently.