Clarion Assistant 5.6
Documentation search is the headline: PDF text extraction now works on every machine instead of only ones that happened to have a third-party tool installed, the extracted text is more accurate, and it is indexed so that a question is answered by the first result rather than the fifth query. Alongside that, a cycle of fixes across the diagnostics path, completion scoping, and the CA Editor's Monaco overlay — plus a build fix that restores Clarion 10 to the shipped set.
PDF documentation actually imports — and is correct (#167)
Importing a folder of PDFs reported "No documentation files found", naming pdf as supported in the very message saying nothing was there. The files were found. Text extraction shelled out to an external pdftotext.exe that CA never bundled and nothing it requires installs — not Git for Windows, contrary to what the code's own probe paths assumed. So PDF import worked only on machines where a developer happened to have put one, and silently produced nothing everywhere else.
Extraction is now in-process (PdfPig, Apache-2.0), so it works everywhere with no external dependency.
The bigger surprise was accuracy. Where the old path did run, it misaligned multi-column tables: in the Language Reference's date-picture table it paired @D6 (dd/mm/yyyy) with 10/1959 — which is @D14's value, and cannot be a dd/mm/yyyy rendering of any date — while dropping other cells entirely. Every row now reads correctly. Those tables are exactly what a Clarion developer searches the documentation for, so the old path was not merely unavailable; where it ran, it was indexing wrong answers.
Re-import your own PDFs. Anything already in a personal DocGraph was indexed through the old path and keeps the old text. The bundled documentation shipped with this release is already rebuilt.
Documentation search answers the question, not the index (#167)
Extraction being correct is not the same as the answer being findable. Asking which three categories ASCIIFileClass's non-virtual methods divide into took five queries; it now takes one, and the answer is the first result.
Four things were wrong at once. Nothing identified the owning class — every chunk in the ABC Library Reference was labelled with the book's name, and since every ABC class has an identically-named "Occasional Use" subsection, results from five different classes interleaved with nothing to tell them apart. Table-of-contents pages outranked real content: 28.7% of the index was dot-leader lines, which are almost pure keyword, so searching a class name returned page-number lists ahead of prose. Clarion keywords lifted out of example code became headings — 486 chunks titled ACCEPT, PROGRAM or RETURN, including the one holding the ASCIIFileClass text. And subsection labels were splitting sections apart, so the three categories landed in three different chunks and no single result could answer the question.
Chunks now carry their real class, contents pages rank below prose, headings read ASCIIFileClass > GetLastLineNo, and a section stays whole. Property references in the Language Reference (PROP:NumTabs and the rest) get their own headings too, so the definition outranks a passing mention in an example.
Verified against a fixed set of eight retrieval tests, kept with the code at docs/DocGraph-Chunking-Verification.md, including a guard on the date-picture table above so a future chunking change cannot quietly undo the extraction fix.
Index-noise suppression currently covers documentation whose contents pages put the title and page number on one line — SoftVelocity's and CapeSoft's. BoxSoft's manuals wrap them across two lines and are not yet recognised.
Spot which libraries need re-importing
The Documentation Graph panel (Settings → Data → Info) gains a Type column showing each library's source format, and every column header — Library, Type, Vendor, Chunks — is now a sort toggle. Click Type to group the PDFs together, which is the fastest way to see what wants a re-import after this release.
The installer remembers where your Clarion actually is (#142)
Setup derived each Clarion path fresh on every run, registry first, and discarded whatever you corrected in the wizard. If your Clarion isn't where SoftVelocity's installer registered it — a second copy, or one launched with /Configdir= against its own settings folder — you had to re-enter the path on every release, and forget once.
That failure is quiet: the addin lands in a tree you don't launch, the IDE keeps loading the old one, and the symptoms get reported against a build replaced weeks ago. Paths a run actually installs to are now remembered and offered next time, and validated on read so a tree that has since moved falls back to detection.
Diagnostics stop reporting false corruption (#168)
Clarion source is saved as Windows-1252/ANSI with no BOM, but four File.ReadAllText calls on the LSP text-sync path read it with no encoding argument — and .NET only auto-detects via BOM. Every single-byte high-bit character (a copyright symbol, say) silently became U+FFFD before the text reached the language server, which then correctly flagged the replacement character it had been handed. The result was waves of "this character will corrupt the file" warnings — dozens per file — on files that are perfectly valid on disk. All four sites now read through EncodingHelper.DetectFileEncoding, the same helper the diff viewer got in #94.
Squiggles stop vanishing (#170)
The squiggle overlay could render nothing at all for a file that the diagnostics pill correctly reported an error for moments later. Four defects, one symptom, all rooted in treating "no information yet" as "authoritatively zero": a premature empty LSP republish was trusted as final (the server publishes progressively, and a slower cross-file check can land in a later batch); a timed-out round-trip was folded into an empty marker list, which erased every existing squiggle and its gutter mark rather than merely failing to add one; the client's timeout sat below the host's own worst case, discarding slow-but-successful analyses; and the settle loop parked a thread-pool thread per request. Empty results now get a short settle window before being believed, a timeout leaves the rendered markers alone, the diagnostics call gets its own longer budget while completion and hover keep their short interactive one, and the wait is properly async.
Diagnostics window follows the CA Editor's theme — and appears at all (#169)
The LSP status bar and the diagnostics popup rendered in the chat pane's theme, which is a separate setting from the CA Editor's own. They now follow the active editor's theme, tracked per Monaco surface rather than read from a process-wide mirror that only ever recorded whichever page spoke last.
Three correctness bugs surfaced in the same code path and are fixed here too. The status bar pill never appeared when the IDE's own ClarionLsp addin was the active client — the visibility check asked the bundled LspClient, which in that configuration is never started, so the pill was hidden on every tick and the window it opens was unreachable. Both the liveness check and the cache read now go through SharedLspBridge, and the target file is resolved from the active editor instead of "the last file any LSP tool touched". The pill also stopped claiming a green OK for files nothing had ever been published about — unknown now renders as its own muted state rather than being flattened into "clean" during exactly the window when results are still arriving, and the status bar asks for diagnostics when it finds none cached instead of reporting "unknown" indefinitely at a cache nothing else was going to fill. And severity colours now survive a live dark⇆light switch instead of keeping the previous theme's palette until the rows next rebuilt.
Rounding it out: owner-drawn column headers and grid lines that actually follow the theme, a selection highlight that no longer overrides each row's severity colour, a dark-mode-aware native title bar, and no more hover flicker.
Completion stops leaking other procedures' locals (#172)
Follow-up to #159. The CodeGraph backfill in bare-prefix completion matched symbol names across the whole indexed solution with no scope awareness, so a variable declared private to some unrelated procedure in a different file was offered exactly like a genuine global — typing Include at the top of a PROGRAM file could surface an IncludeAddress local from elsewhere entirely. Symbols the indexer already tags as procedure-private are now filtered out of that merge. Locals in the procedure you're actually standing in are unaffected: those come from a live-buffer parse, not the database.
DO completes routines, and only routines
DO takes a ROUTINE label and nothing else, so it is now its own completion context answered from routines alone. Routine names are read from the live buffer, scoped to the enclosing procedure — which is a routine's real visibility in Clarion — so a routine you just typed and haven't saved completes too. Previously DO was answered from the general symbol set: typing DO ref offered methods from an unrelated Reflection class while missing the RefreshWindow routine a few lines up.
Ctrl+X in the CA Editor reaches the clipboard (#173)
Clarion-style Ctrl+X posted the cut text to the host before deleting it from the buffer — and the CA Editor never implemented its half of that contract, so Ctrl+X deleted the line without putting anything on the Windows clipboard. Both stubs left inert since the original overlay spike are now wired: the cut text reaches Clipboard.SetText, and a Data-pad field dropped directly onto the editor surface now returns activation to the editor's own tab instead of leaving focus stranded on the pad.
Show the diagnostics bar again after dismissing it
The LSP status bar — the strip at the bottom of the assistant pane carrying the diagnostics pill — has always had its own ✕, and nothing brought it back: restarting Clarion was the only way. A ◎ button joins the header's title-row actions, beside the theme toggle, and shows or hides it on demand. It repaints from the current state on the way back rather than returning with whatever it was showing when dismissed.
Clarion 10 builds again
DiffService called a FileService method that doesn't exist on Clarion 10's older SharpDevelop fork, so the C10 build had been failing outright since the CA Compare write-back work landed — while 11, 11.1 and 12 compiled clean. It now reaches the same information through an API present on every fork, from one code path.
If you run Clarion 10, this release is the first to include roughly a week of changes that never made it into a working C10 binary. The installer ships a per-Clarion build (bin\Debug-C10 and siblings), so a broken build for one release meant that release shipping stale or not at all.
The deploy script no longer lets one bad target take the others down with it, either: a build failure for a single Clarion version used to abort the run before the deploy step, so nothing was deployed anywhere while the console showed the other three building successfully. Failures are now collected, every version that built is deployed, and the run ends by naming what didn't ship.
Class model preview renders again (#171)
In Create New Class, any model whose declaration put a Clarion keyword and a quoted string on the same line — a standard CLASS,TYPE,MODULE('X.CLW'),LINK('X.CLW') — rendered visibly broken markup instead of coloured code. The keyword pass ran over the HTML the string pass had just produced and matched the literal class and string inside its own attributes. The two passes are now ordered so there is no HTML for the keyword pass to collide with.
Smart formatter keeps comments where they belong (#161)
Two fixes to Ctrl+I, both reported and diagnosed by @geircodes.
A comment sitting among declarations — inside a GROUP/QUEUE/RECORD/FILE, or directly in a procedure's or routine's DATA section — was indented to the CODE-section column rather than the field column it had been aligned to. It visibly jumped left while every declaration around it formatted correctly, which read as arbitrary rather than as a rule; comments inside IF/CASE/LOOP bodies were never affected, which is what made it look inconsistent. Those comments now line up with the fields they sit among — and a long banner comment does not drag the whole structure's field column to the right with it.
"Indent comments" now means what it says. Switching it off used to delete a comment's indentation and dump it at column 1, including comments hand-aligned deep inside nested control structures. Off now means leave the comment exactly where it is.
Thanks
- geircodes — the bulk of this cycle again: the LSP source-encoding fix that ended a wave of false "this character will corrupt the file" warnings (#168), the squiggle overlay going blank on slow or premature results (#170), the diagnostics window's theme plus three correctness bugs found alongside it — including the status bar pill that never appeared at all (#169), the completion scope leak that surfaced other procedures' locals solution-wide (#172), the CA Editor clipboard and drop-focus stubs (#173), and the class-model preview highlighting (#171). Also reported, diagnosed and wrote the patch for the Ctrl+I comment-indenting fixes (#161), filing it as an issue with the semantics question open rather than as a PR — which is why "Indent comments OFF" now means something deliberate.
- Bill Atchison — reporting that PDFs would not import (#167). The bug was invisible to anyone whose machine happened to carry a stray
pdftotext.exe, which is every developer machine here; without the report it would have kept shipping. - BoxSoft — the installer path report (#142) that turned out to be the reason a whole diagnostic round was spent chasing symptoms in a build that had already been replaced.
Supported: Clarion 10, 11, 11.1, and 12 (32-bit IDE). The installer lets you pick which version(s) to install into.
Upgrading: close Clarion before running setup. If you run a Clarion that SoftVelocity's installer did not register — a second copy, or one launched with /Configdir= — check the path in the wizard; from this release onwards it is remembered for next time.