mattcasters opened a new pull request, #7907:
URL: https://github.com/apache/hop/pull/7907

   ## Summary
   
   Implements in-editor search for multi-line SQL/script/text fields (issue 
#7456), and opens the same surface for plugins:
   
   - **Toolbar on `TextComposite`** (same SPI model as `TableView`): undo/redo, 
cut/copy/paste, select all, find, find/replace
   - **Find/replace dialog** with Ctrl+F / Ctrl+H and context menu
   - **`styleType` constructor parameter** so toolbar filters see SQL/JSON/… at 
build time (filters run mid-construction)
   - **Plugin contribution** via `@GuiToolbarElement` + 
`@GuiToolbarElementFilter` on `TextComposite.ID_TOOLBAR`
   - Sample **JSON pretty-print** button in the JSON transform plugin
   - Developer documentation: *GUI plugins and toolbars*
   - Config option to show/hide the text editor toolbar
   
   ## Notes for reviewers
   
   - Prefer `getStyleType()` over `instanceof` specialized subclasses (Hop Web 
stand-ins).
   - `@GuiToolbarElementFilter` runs during host construction: use constructor 
`styleType` only; check `isEditable()` / content in the action method.
   - Runtime: `TextFindSupport` unit tests; compile verified for `ui` and 
affected plugins.
   
   ## Test plan
   
   - [ ] Open Table Input / Exec SQL / SQL Editor: toolbar visible; Ctrl+F 
finds text; Ctrl+H replace works
   - [ ] Mongo/JSON fields (`styleType` JSON): format-JSON toolbar button 
appears; pretty-prints valid JSON; invalid JSON shows error dialog
   - [ ] Read-only log panels: find available; edit actions disabled where 
appropriate
   - [ ] Configuration → show text editor toolbar off: toolbars hidden
   - [ ] Hop Web: SQL fields use `StyledTextComp` with `STYLE_TYPE_SQL`; 
toolbar/find still work
   
   Fixes #7456


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to