Compare commits

...

34 Commits

Author SHA1 Message Date
JonKazama-Hellion 4c8b0da3da ci: drop upload-artifact step from build.yml
actions/upload-artifact@v7 fails on Gitea Actions — the GitHub
artifact API has compatibility gaps the Gitea runtime layer does not
fully cover, and v7 specifically tripped exitcode 1 on the Strato
runner. The build itself runs fine; the artefact was never consumed
by anything (release.yml does its own latest.zip lookup), so the
cleanest fix is to make build.yml a pure compile-health check
without artefact upload.
2026-05-08 15:11:46 +02:00
JonKazama-Hellion 9a8a014795 docs: close active upstream cherry-pick pipeline
Chat 2 has entered a major rework that Infi confirmed makes selective
patches no longer portable. The cherry-pick pipeline as a routine
workflow stops with the v1.4.x cycle. Documentation reflects the new
state across all touchpoints.

UPSTREAM_SYNC.md rewritten: replaces the "How I Cherry-Pick" /
"Reviewing What Is New Upstream" / "Conflict Handling" sections with
"Why Cherry-Picking Stopped", "What Closing the Pipeline Means in
Practice", "What Does Not Change", "What Could Re-Open Later".
Existing cherry-pick trails in the git history stay intact, EUPL-1.2
anchor lines and NOTICE.md remain canonical.

README.md, CONTRIBUTING.md, ROADMAP.md, THIRD_PARTY_NOTICES.md and
the PR template updated to match: cherry-pick references reframed as
historical or pointed at UPSTREAM_SYNC.md for the current state.
NOTICE.md keeps the BetterTTV cherry-pick example as a concrete past
case but adds a paragraph that the pipeline is closed and clarifies
the attribution standard is preserved unchanged.

PULL_REQUEST_TEMPLATE.md drops the "Upstream cherry-pick from Chat 2"
checkbox and the cherry-pick-path compatibility prompt. The upstream
git remote was already removed locally on 2026-05-08 (separate change,
not in this commit).

No source-file edits, no manifest version bump, no changelog entry —
this is documentation-only and ships with the next release.
2026-05-08 15:00:30 +02:00
JonKazama-Hellion 9640d336a6 Migrate Actions workflows to Gitea
- codeql.yml removed: GitHub-only (uses github/codeql-action/*).
- build.yml + release.yml: runs-on switched to ubuntu-latest (Gitea Cloud
  has no Windows runner). Dalamud staging is now downloaded via curl/unzip
  into $HOME/.xlcore/dalamud/Hooks/dev/, the path the Dalamud SDK 15 uses
  on Linux. Locate-step uses find instead of Get-ChildItem.
- release.yml: softprops/action-gh-release replaced with the Gitea-native
  https://gitea.com/actions/release-action. Auto-injected GITHUB_TOKEN on
  Gitea Actions has Gitea-API scope and is sufficient.
- forge-announce.yml: environment: Webhook removed (Gitea has no
  environments — DISCORD_FORGE_WEBHOOK is a repo-level Actions secret).
  avatar_url and embed url switched from raw.githubusercontent.com /
  github.com to gitea.com.
- release-footer.md: install URL plus the five doc links (README, PRIVACY,
  THIRD_PARTY_NOTICES, SECURITY, SUPPORT) and LICENSE link switched to
  gitea.com/.../src/branch/main/. ChatTwo upstream link stays on GitHub.
2026-05-08 14:06:44 +02:00
JonKazama-Hellion 12ce015d83 test: add TEST-MIRROR pointer to Build-Suite MigrationLogic 2026-05-08 13:27:39 +02:00
JonKazama-Hellion f455bf4736 chore: drop stale Cycle reference from BrandingLinks comment
The comment on BrandingLinks claimed a follow-up housekeeping sweep was
"out of scope for this Cycle" — that Cycle framing no longer matches how
Plan v4 schedules the work. Trim the trailing clause; the rest of the
comment still documents the housekeeping intent.
2026-05-08 08:51:27 +02:00
JonKazama-Hellion 9bc66c7cf3 chore: optimize image assets and add Florian Eck brand logos
Re-encodes the four existing screenshots and the docs/images forge banner
to 8-bit indexed-color PNGs. Total asset payload drops from ~3.87 MB to
~311 KB (92% smaller) without visible quality loss in the README/forge
post rendering.

Adds the four brand-logo variants designed by Florian Eck and credited
in COPYRIGHT (Visual assets section): the Hellion Online Media wordmark,
the square Hellion crest, the horizontal Hellion Forge color logo and
the Discord-sized hammer mark. All variants live in docs/images/ so the
forge post and README can reference them without polluting the in-game
plugin payload under HellionChat/images/.

Visual assets are NOT covered by the EUPL-1.2 source code licence; their
licensing terms are documented in COPYRIGHT.
2026-05-08 08:51:22 +02:00
JonKazama-Hellion e9022de150 refactor: rename SelfTest/ to SelfTests/ for plan v4 consistency
Renames HellionChat/SelfTest/ to HellionChat/SelfTests/ (plural) to
match the folder convention used throughout the Build Suite Plan v4
Phase 6 file list. The singular name was introduced as a known
discrepancy in cb327b8 and is now resolved.

- git mv preserves full history via rename detection
- Namespace updated: HellionChat.SelfTest → HellionChat.SelfTests
- Plugin.cs qualifier updated: SelfTest. → SelfTests.
- Build: 0 errors, 0 warnings
2026-05-08 08:34:48 +02:00
JonKazama-Hellion cb327b8073 feat: add ThemeSwitchSelfTestStep + ISelfTestRegistry wiring
Registers a single SelfTestStep that exercises Plugin.ThemeRegistry.Switch
through the live theme list. Verified in-game via /xldev SelfTest tab on
2026-05-08; Plugin loads cleanly with the RegisterTestSteps call and the
step runs the theme cycle as expected.

Folder is HellionChat/SelfTest/ (singular). Future steps may rename to
SelfTests/ to match the local Plan v4 convention.
2026-05-08 08:21:21 +02:00
JonKazama-Hellion 1c354d18bb refactor: extract chat-input pure helpers for unit-testable submit + history math
ChatBox.SendMessage reads bytes from ValidateMessage so Encoding.UTF8.GetBytes
runs once per send. ValidateMessage takes an injectable sanitiser so xUnit can
exercise the length-equality gate without ClientStructs game memory.

CompactInputSubmitter and CompactInputHistoryNavigator lift the deterministic
parts of ChatInputBar's pop-out submit and history-up/down callback into POCO
helpers under HellionChat/_Helpers/. The ImGui buffer splice
(DeleteChars/InsertChars) stays at the call site because it needs the live
callback data.

Behavior is identical to the previous inline implementation; tests in the
local Build Suite repo pin the contracts.
2026-05-08 08:21:13 +02:00
JonKazama-Hellion 0ed88691c2 build: add preflight validator family for versions/manifest/changelog drift
Establishes the local pre-push gate. preflight.sh runs four blocks: version
consistency, manifest shape (Icon plus all ImageUrls), changelog sync, plus a
release build as compile-health smoke. setup-hooks.sh wires core.hooksPath to
.githooks. .gitignore opens scripts/ for tracking (setup-dev-env.sh stays
private). Test execution itself lives in a separate local repository and is
not part of this codebase.
2026-05-08 07:23:54 +02:00
JonKazama-Hellion c64fcfd4d1 docs: add v1.4.2 forge-post 2026-05-07 22:47:09 +02:00
JonKazama-Hellion 6689cdb968 chore: bump version to 1.4.2 and document ChatLog Frame-Hot-Path 2026-05-07 22:47:09 +02:00
JonKazama-Hellion 345aa3ea2a perf(ui): gate status-bar aggregation behind the cache check 2026-05-07 22:15:57 +02:00
JonKazama-Hellion 1ffc41f97d perf(ui): cache auto-tell tab tint and icon per tab 2026-05-07 22:06:18 +02:00
JonKazama-Hellion 36b92f0520 perf(ui): hoist invariants out of the chat-log card border loop 2026-05-07 21:34:19 +02:00
JonKazama-Hellion cb612044ea Merge branch 'feature/v1.4.1-theme-engine-performance' 2026-05-07 20:05:14 +02:00
JonKazama-Hellion 71081d8344 docs: add v1.4.1 forge-post 2026-05-07 20:00:29 +02:00
JonKazama-Hellion 54bfeb0f6f chore: bump version to 1.4.1 and document Theme Engine Performance 2026-05-07 19:58:50 +02:00
JonKazama-Hellion 5f83c70292 feat(themes): add Synthwave Sunset built-in, refresh author credits 2026-05-07 19:51:43 +02:00
JonKazama-Hellion 3d7883ee01 fix(themes): refresh abgr cache defensively on theme switch 2026-05-07 19:51:43 +02:00
JonKazama-Hellion e4ee7aaafa fix(themes): keep last-known-good custom theme on transient file-lock 2026-05-07 19:51:43 +02:00
JonKazama-Hellion aff2528a6f perf(themes): read abgr from theme cache in PushGlobal and Push 2026-05-07 19:51:43 +02:00
JonKazama-Hellion 0d2ee63420 perf(themes): add pre-computed ABGR cache on theme records 2026-05-07 19:51:43 +02:00
JonKazama-Hellion de9d1ac60b Merge branch 'feature/v1.4.0-critical-lifecycle-fixes'
Hellion Chat 1.4.0 — Critical Lifecycle Fixes

Seven P0 lifecycle and race bugs eliminated before any performance refactor.
Plus version bump, manifest sync, changelog, forge-post.
2026-05-07 19:06:56 +02:00
JonKazama-Hellion 19f7099af0 docs: add v1.4.0 forge-post 2026-05-07 19:04:24 +02:00
JonKazama-Hellion f8a734d93f chore: bump version to 1.4.0 and document Critical Lifecycle Fixes 2026-05-07 19:04:20 +02:00
JonKazama-Hellion 3f7e86b32e fix(migration): pull HellionThemeWindowOpacity from pre-v13 backup in v13->v14 2026-05-07 08:03:57 +02:00
JonKazama-Hellion e5bf375b42 fix(plugin): flush DeferredSaveFrames in Dispose before service teardown 2026-05-07 07:53:52 +02:00
JonKazama-Hellion 93329087a9 fix(messagemanager): warn loudly when DisposeAsync 10s timeout hits 2026-05-07 07:52:14 +02:00
JonKazama-Hellion 72d568e5b3 fix(emotecache): replace async void Load with async Task tracker 2026-05-07 07:41:50 +02:00
JonKazama-Hellion c9dfd024b2 docs(comments): trim verbose dispose and thread rationale
Match the new HellionChat comment-length convention: 1-3 lines for
standard pitfall notes, 5+ only for non-trivial workarounds. The
previous Dispose comment was 14 lines of textbook prose, which veered
into AI-slop territory and would rot on the next refactor.
2026-05-07 01:10:50 +02:00
JonKazama-Hellion 8c624a0032 fix(threads): mark PendingMessage thread as background, document RetentionSweep rationale 2026-05-07 00:54:43 +02:00
JonKazama-Hellion 079e280226 fix(messagestore): drop GC.Collect from Dispose, rely on Pooling=false 2026-05-07 00:42:26 +02:00
JonKazama-Hellion 3bdf45c29c Datein in falschen ordner verschoben xD 2026-05-06 22:32:01 +02:00
62 changed files with 1388 additions and 508 deletions
+3
View File
@@ -0,0 +1,3 @@
#!/usr/bin/env bash
# .githooks/pre-push — invokes preflight.sh (A/B/C/D=build).
exec scripts/preflight.sh
-2
View File
@@ -23,7 +23,6 @@ https://github.com/JonKazama-Hellion/HellionChat/security/advisories/new
- [ ] Documentation only - [ ] Documentation only
- [ ] Translation update - [ ] Translation update
- [ ] Build, CI or tooling change - [ ] Build, CI or tooling change
- [ ] Upstream cherry-pick from Chat 2
## Linked issue ## Linked issue
@@ -53,7 +52,6 @@ new commands, new translations, removed behaviour. If none, write
bump and is it covered by the existing migration tests? bump and is it covered by the existing migration tests?
- Does this change the schema in MessageStore? - Does this change the schema in MessageStore?
- Does this change the repo.json or HellionChat.yaml manifest fields? - Does this change the repo.json or HellionChat.yaml manifest fields?
- Does this affect the upstream cherry-pick path? See docs/UPSTREAM_SYNC.md.
--> -->
## Checklist ## Checklist
+32
View File
@@ -0,0 +1,32 @@
---
subtitle: Critical Lifecycle Fixes
versionsnatur: Stability-Hotfix
---
**Hellion Chat 1.4.0 — Critical Lifecycle Fixes**
Erster Sub-Patch der v1.4.x Polish-Sweep-Serie. Sieben
bekannte Lifecycle- und Race-Bugs aus den Audit-Pässen
abgearbeitet, bevor Performance- und Architektur-Refactors
draufkommen.
- **SQLite-Dispose** lehnt sich nicht mehr an GC-Druck zur
Datei-Freigabe an, Pooling=false auf der Connection macht
den manuellen GC.Collect überflüssig
- **Worker-Threads** (PendingMessage, RetentionSweep) sind
jetzt explizit IsBackground=true, das Plugin-Domain kann
sauber unloaden bei XIVLauncher-Reload ohne darauf zu warten
- **EmoteCache-Loader** von async-void auf async-Task mit
shared Task-Tracker, drain-on-Dispose. Kein Schreib-Risiko
mehr auf disposed EmoteImages-Einträge nach Plugin-Reload
- **DisposeAsync-Timeout** (10s) warnt jetzt laut statt silent
zu failen
- **Plugin-Dispose** flushed pending DeferredSave bevor Services
abgebaut werden, Settings-Änderungen aus den letzten Frames
vor Disable überleben jetzt zuverlässig
- **v13→v14 Config-Migration** liest pre-v13-Backup und überträgt
HellionThemeWindowOpacity in das neue WindowOpacity-Feld statt
auf 0.85 zurückzufallen
Keine Schema-Bumps, keine User-sichtbaren Funktions-Änderungen
außer dass Reload und Shutdown spürbar sauberer laufen.
+39
View File
@@ -0,0 +1,39 @@
---
subtitle: Theme Engine Performance
versionsnatur: Performance-Patch
---
**Hellion Chat 1.4.1 — Theme Engine Performance**
Zweiter Sub-Patch der v1.4.x Polish-Sweep-Serie. Heap-Pressure
aus dem Theme-Engine-Render-Pfad eliminiert, Custom-Theme-
Hot-Reload überlebt transiente File-Locks beim Editor-Save.
Plus zehnter Built-In und überarbeitete Author-Credits.
- **ABGR-Cache auf den Theme-Records.** Beim Theme-Register
(Built-In oder Custom) werden alle Color-Slots einmalig in
ABGR-Pack-Form vor-konvertiert. HellionStyle.PushGlobal
liest aus dem Cache statt pro Slot pro Frame durch
ColourUtil.RgbaToAbgr zu jagen. Real gemessene
Frame-Time-Recovery: **~13 %** in typischer Render-Szene
(Plan-Erwartung war 2-6 % konservativ, real ~10-15 %)
- **Custom-Theme File-Lock-Härtung.** Wenn der User ein
Theme-JSON gerade speichert während HellionChat reloaden
will, fängt der Loader jetzt explizit Sharing-Violation
und Lock-Violation ab. Last-Known-Good-Snapshot bleibt im
Picker, beim nächsten Tick wird automatisch retry'd —
vorher fiel das Theme aus der Liste bis zum Plugin-Reload
- **Defensive Cache-Refresh beim Theme-Switch.** Falls ein
Theme auf einem alten Pfad ohne Cache-Fill in den Speicher
gekommen ist, holt Switch() das beim Anwenden nach
- **Synthwave Sunset als zehnter Built-In.** Hot Magenta +
Cyan auf Mitternachts-Violett, 80s-Neon-Grid-Vibes für
Late-Night-Raids
- **Author-Credits konsolidiert.** Brand-Themes laufen jetzt
unter „Hellion Forge". Mint Grove und Forge Merchantman
werden Carla Beleandis als Community-Geste zugeschrieben.
Keine Schema-Bumps, keine User-sichtbaren Funktions-
Änderungen außer dass die Frames in Theme-getrieben
rendernden Szenen merklich glatter laufen und ein neues
Theme im Picker steht.
+43
View File
@@ -0,0 +1,43 @@
---
subtitle: ChatLog Frame-Hot-Path
versionsnatur: Performance-Patch
---
**Hellion Chat 1.4.2 — ChatLog Frame-Hot-Path**
Dritter Sub-Patch der v1.4.x Polish-Sweep-Serie. Drei
Per-Frame-Allokations-Quellen aus dem ChatLogWindow-Render-
Pfad und der Settings-StatusBar eliminiert.
- **Card-Mode-Border-Loop entlastet.** DrawMessages hebt
Theme, DrawList, Window-Left, Window-Right und die ABGR-
Border-Color einmalig vor den Per-Message-Loop. Bei 100
sichtbaren Messages sind das gut 500 redundante P/Invokes
und Property-Reads, die der Hoist eliminiert. Pop-Out-
Heavy-Setups (mehrere parallele Chat-Windows) profitieren
proportional, weil der Hoist pro DrawMessages-Call greift,
also pro Window
- **Auto-Tell Tab-Tint und Icon gecached.** Die Hash-Color-
Berechnung für Auto-Tell-Tabs lief pro Tab pro Frame, mit
zwei String-Allokationen pro Tab (eine für Tint-Hash, eine
für Icon-Hash). Der neue TabTintCache liest pre-computed
Werte aus dem Tab und rechnet nur neu wenn das Tell-Target
drifted. Beide Caches haben separate Validation-Keys, also
keine Cross-Invalidation zwischen Tint- und Icon-Pfad.
AutoTellTabTint selbst bleibt pure Hash-Helper, weiterhin
ohne Tab-Awareness
- **StatusBar-Aggregation hinter Cache-Gate.** Die Status-
Leiste am unteren Window-Rand summiert die Tab-Message-
Counts und zählt die Auto-Tell-Tabs pro Frame. Der Cache-
Gate (1 Sekunde) lag bisher hinter den LINQ-Pfaden, also
liefen Sum und Count trotzdem pro Frame. Jetzt vor dem
Gate, plus die LINQ-Pfade durch eine Single-Pass-Foreach
ersetzt. Die Aggregation läuft auf etwa 1 % der Frames
Realistische Frame-Time-Recovery: 2-5 % in typischen Szenen,
Pop-Out-Heavy-Setups potenziell mehr durch die Card-Border-
Multiplikation pro Window.
Keine Schema-Bumps, keine User-sichtbaren Funktions-
Änderungen außer dass die Frames im Chat-Log und in der
Settings-Statusleiste merklich glatter laufen.
+7 -7
View File
@@ -8,19 +8,19 @@ Dalamud main plugin repo. To install:
1. In XIVLauncher: **Settings → Experimental → Custom Plugin Repositories** 1. In XIVLauncher: **Settings → Experimental → Custom Plugin Repositories**
2. Add the URL: 2. Add the URL:
`https://raw.githubusercontent.com/JonKazama-Hellion/HellionChat/main/repo.json` `https://gitea.com/JonKazama-Hellion/HellionChat/raw/branch/main/repo.json`
3. Enable, save, then `/xlplugins` → search **Hellion Chat** → install 3. Enable, save, then `/xlplugins` → search **Hellion Chat** → install
## Project documents ## Project documents
- [README](https://github.com/JonKazama-Hellion/HellionChat/blob/main/README.md) — features, architecture, build - [README](https://gitea.com/JonKazama-Hellion/HellionChat/src/branch/main/README.md) — features, architecture, build
- [Privacy notice](https://github.com/JonKazama-Hellion/HellionChat/blob/main/PRIVACY.md) — what the plugin stores and sends - [Privacy notice](https://gitea.com/JonKazama-Hellion/HellionChat/src/branch/main/PRIVACY.md) — what the plugin stores and sends
- [Third-party notices](https://github.com/JonKazama-Hellion/HellionChat/blob/main/docs/THIRD_PARTY_NOTICES.md) — dependencies and licences - [Third-party notices](https://gitea.com/JonKazama-Hellion/HellionChat/src/branch/main/docs/THIRD_PARTY_NOTICES.md) — dependencies and licences
- [Security policy](https://github.com/JonKazama-Hellion/HellionChat/blob/main/SECURITY.md) — vulnerability reporting - [Security policy](https://gitea.com/JonKazama-Hellion/HellionChat/src/branch/main/SECURITY.md) — vulnerability reporting
- [Support](https://github.com/JonKazama-Hellion/HellionChat/blob/main/SUPPORT.md) — bug reports, questions, contact paths - [Support](https://gitea.com/JonKazama-Hellion/HellionChat/src/branch/main/SUPPORT.md) — bug reports, questions, contact paths
## Licence ## Licence
[EUPL-1.2](https://github.com/JonKazama-Hellion/HellionChat/blob/main/LICENSE). [EUPL-1.2](https://gitea.com/JonKazama-Hellion/HellionChat/src/branch/main/LICENSE).
Based on [Chat 2](https://github.com/Infiziert90/ChatTwo) by Infi and Anna, Based on [Chat 2](https://github.com/Infiziert90/ChatTwo) by Infi and Anna,
also EUPL-1.2. also EUPL-1.2.
+11 -14
View File
@@ -3,6 +3,12 @@ name: Build
# Verifies that every push to main and every PR still builds against the # Verifies that every push to main and every PR still builds against the
# current Dalamud staging branch. Does not produce release artefacts; the # current Dalamud staging branch. Does not produce release artefacts; the
# release workflow handles that on tag. # release workflow handles that on tag.
#
# Linux runner: gitea.com Cloud Actions provides ubuntu-latest. The plugin
# csproj targets net10.0-windows, but `dotnet build` cross-compiles on
# Linux as long as the Dalamud staging assemblies are present at the
# expected lookup path ($(HOME)/.xlcore/dalamud/Hooks/dev/, which the
# Dalamud SDK 15 uses on Linux).
on: on:
push: push:
@@ -21,7 +27,7 @@ permissions:
jobs: jobs:
build: build:
name: Build (Release) name: Build (Release)
runs-on: windows-latest runs-on: ubuntu-latest
timeout-minutes: 15 timeout-minutes: 15
steps: steps:
@@ -34,23 +40,14 @@ jobs:
dotnet-version: 10.0.x dotnet-version: 10.0.x
- name: Download Dalamud staging - name: Download Dalamud staging
shell: pwsh
run: | run: |
$hooks = Join-Path $env:APPDATA "XIVLauncher\addon\Hooks\dev" hooks="$HOME/.xlcore/dalamud/Hooks/dev"
New-Item -ItemType Directory -Force -Path $hooks | Out-Null mkdir -p "$hooks"
Invoke-WebRequest -Uri https://goatcorp.github.io/dalamud-distrib/stg/latest.zip -OutFile dalamud.zip curl -fsSL https://goatcorp.github.io/dalamud-distrib/stg/latest.zip -o dalamud.zip
Expand-Archive -Force -Path dalamud.zip -DestinationPath $hooks unzip -oq dalamud.zip -d "$hooks"
- name: Restore - name: Restore
run: dotnet restore HellionChat/HellionChat.csproj run: dotnet restore HellionChat/HellionChat.csproj
- name: Build (Release) - name: Build (Release)
run: dotnet build HellionChat/HellionChat.csproj --configuration Release --no-restore run: dotnet build HellionChat/HellionChat.csproj --configuration Release --no-restore
- name: Upload build output
uses: actions/upload-artifact@v7
with:
name: HellionChat-build-${{ github.run_number }}
path: HellionChat/bin/Release/**/HellionChat/**
if-no-files-found: warn
retention-days: 14
-93
View File
@@ -1,93 +0,0 @@
name: CodeQL
# Replaces the GitHub default-setup CodeQL scan. The default setup runs
# without resolving the Dalamud assemblies (they live in a user-AppData
# path) and reports "Low C# analysis quality" because call-target
# resolution sits at ~64%. This workflow downloads the Dalamud staging
# distribution before the build, runs a manual dotnet build, and then
# lets CodeQL analyse the fully-resolved compilation. Quality climbs
# back above the 85% thresholds.
#
# This workflow only consumes trusted inputs: the tag/branch ref via
# the standard checkout action, and the Dalamud distribution URL which
# is pinned to a goatcorp-controlled GitHub Pages target. No user-
# controlled event payload (issue title, PR body, commit message) flows
# into a run-step.
#
# Disable the default setup in the repo before this workflow lands:
# Settings -> Code security -> Code scanning -> "CodeQL analysis" tile
# -> Switch to advanced.
on:
push:
branches: [main]
pull_request:
branches: [main]
schedule:
- cron: '17 6 * * 1'
permissions:
actions: read
contents: read
security-events: write
jobs:
analyze-csharp:
name: Analyze (csharp)
runs-on: windows-latest
timeout-minutes: 30
steps:
- name: Checkout
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Setup .NET 10
uses: actions/setup-dotnet@c2fa09f4bde5ebb9d1777cf28262a3eb3db3ced7 # v5.2.0
with:
dotnet-version: 10.0.x
- name: Download Dalamud staging
shell: pwsh
run: |
$hooks = Join-Path $env:APPDATA "XIVLauncher\addon\Hooks\dev"
New-Item -ItemType Directory -Force -Path $hooks | Out-Null
Invoke-WebRequest -Uri https://goatcorp.github.io/dalamud-distrib/stg/latest.zip -OutFile dalamud.zip
Expand-Archive -Force -Path dalamud.zip -DestinationPath $hooks
- name: Initialize CodeQL
uses: github/codeql-action/init@e46ed2cbd01164d986452f91f178727624ae40d7 # v4.35.3
with:
languages: csharp
build-mode: manual
queries: security-extended
- name: Restore
run: dotnet restore HellionChat/HellionChat.csproj
- name: Build (Release)
run: dotnet build HellionChat/HellionChat.csproj --configuration Release --no-restore
- name: Perform CodeQL analysis
uses: github/codeql-action/analyze@e46ed2cbd01164d986452f91f178727624ae40d7 # v4.35.3
with:
category: /language:csharp
analyze-actions:
name: Analyze (actions)
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- name: Checkout
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Initialize CodeQL
uses: github/codeql-action/init@e46ed2cbd01164d986452f91f178727624ae40d7 # v4.35.3
with:
languages: actions
build-mode: none
- name: Perform CodeQL analysis
uses: github/codeql-action/analyze@e46ed2cbd01164d986452f91f178727624ae40d7 # v4.35.3
with:
category: /language:actions
+5 -6
View File
@@ -34,10 +34,9 @@ jobs:
announce: announce:
name: Post changelog to Hellion Forge name: Post changelog to Hellion Forge
runs-on: ubuntu-latest runs-on: ubuntu-latest
# The DISCORD_FORGE_WEBHOOK secret lives under Settings → Environments # The DISCORD_FORGE_WEBHOOK secret is set as a repo-level Actions Secret
# → Webhook (case-sensitive). Without this declaration the secret is # on Gitea (Settings → Actions → Secrets). Repo-level secrets are in
# not in scope for the job. # scope for every job by default, no environment: declaration needed.
environment: Webhook
timeout-minutes: 5 timeout-minutes: 5
steps: steps:
@@ -134,7 +133,7 @@ jobs:
# ---------- Embed-Payload bauen ---------- # ---------- Embed-Payload bauen ----------
$payload = [ordered]@{ $payload = [ordered]@{
username = "Forge Herald" username = "Forge Herald"
avatar_url = "https://raw.githubusercontent.com/JonKazama-Hellion/HellionChat/main/HellionChat/images/icon.png" avatar_url = "https://gitea.com/JonKazama-Hellion/HellionChat/raw/branch/main/HellionChat/images/icon.png"
content = "<@&1500489631555260446>" content = "<@&1500489631555260446>"
allowed_mentions = [ordered]@{ allowed_mentions = [ordered]@{
parse = @() parse = @()
@@ -143,7 +142,7 @@ jobs:
embeds = @( embeds = @(
[ordered]@{ [ordered]@{
title = $title title = $title
url = "https://github.com/JonKazama-Hellion/HellionChat/releases/tag/$tag" url = "https://gitea.com/JonKazama-Hellion/HellionChat/releases/tag/$tag"
color = 12730636 color = 12730636
description = $description description = $description
footer = [ordered]@{ text = $footerText } footer = [ordered]@{ text = $footerText }
+27 -21
View File
@@ -2,15 +2,19 @@ name: Release
# Triggered when a vX.Y.Z tag is pushed. Builds the plugin against the # Triggered when a vX.Y.Z tag is pushed. Builds the plugin against the
# current Dalamud staging branch, locates the latest.zip produced by # current Dalamud staging branch, locates the latest.zip produced by
# DalamudPackager and attaches it to the matching GitHub Release. # DalamudPackager and attaches it to the matching Gitea Release.
# #
# User-controlled inputs touched by this workflow: # User-controlled inputs touched by this workflow:
# - the tag name (filtered by on.tags = v*, validated again at runtime # - the tag name (filtered by on.tags = v*, validated again at runtime
# against ^v\d+\.\d+\.\d+$ before being used in any string) # against ^v\d+\.\d+\.\d+$ before being used in any string)
# All other values are either repo-controlled (paths under # All other values are either repo-controlled (paths under
# HellionChat/bin/Release derived from Get-ChildItem) or pinned URLs to # HellionChat/bin/Release derived from find / Get-ChildItem) or pinned
# goatcorp / GitHub. Nothing from a webhook event payload (issue/PR # URLs to goatcorp / gitea. Nothing from a webhook event payload (issue/PR
# titles, commit messages, etc.) flows into a run-step. # titles, commit messages, etc.) flows into a run-step.
#
# Linux runner: gitea.com Cloud Actions only ships ubuntu-latest. The
# plugin csproj targets net10.0-windows, `dotnet build` cross-compiles on
# Linux when the Dalamud staging assemblies sit under $(HOME)/.xlcore/...
on: on:
push: push:
@@ -33,7 +37,7 @@ permissions:
jobs: jobs:
release: release:
name: Build and attach release ZIP name: Build and attach release ZIP
runs-on: windows-latest runs-on: ubuntu-latest
timeout-minutes: 20 timeout-minutes: 20
steps: steps:
@@ -52,27 +56,25 @@ jobs:
dotnet-version: 10.0.x dotnet-version: 10.0.x
- name: Download Dalamud staging - name: Download Dalamud staging
shell: pwsh
run: | run: |
$hooks = Join-Path $env:APPDATA "XIVLauncher\addon\Hooks\dev" hooks="$HOME/.xlcore/dalamud/Hooks/dev"
New-Item -ItemType Directory -Force -Path $hooks | Out-Null mkdir -p "$hooks"
Invoke-WebRequest -Uri https://goatcorp.github.io/dalamud-distrib/stg/latest.zip -OutFile dalamud.zip curl -fsSL https://goatcorp.github.io/dalamud-distrib/stg/latest.zip -o dalamud.zip
Expand-Archive -Force -Path dalamud.zip -DestinationPath $hooks unzip -oq dalamud.zip -d "$hooks"
- name: Build (Release) - name: Build (Release)
run: dotnet build HellionChat/HellionChat.csproj --configuration Release run: dotnet build HellionChat/HellionChat.csproj --configuration Release
- name: Locate latest.zip - name: Locate latest.zip
id: locate id: locate
shell: pwsh
run: | run: |
$zip = Get-ChildItem -Path HellionChat\bin\Release -Recurse -Filter latest.zip | Select-Object -First 1 zip="$(find HellionChat/bin/Release -name latest.zip -print -quit)"
if (-not $zip) if [ -z "$zip" ]; then
{ echo "latest.zip not found under HellionChat/bin/Release" >&2
throw "latest.zip not found under HellionChat\bin\Release" exit 1
} fi
Write-Host "Found: $($zip.FullName)" echo "Found: $zip"
"path=$($zip.FullName)" | Out-File -FilePath $env:GITHUB_OUTPUT -Append echo "path=$zip" >> "$GITHUB_OUTPUT"
# Build a release body from the matching changelog block in # Build a release body from the matching changelog block in
# HellionChat.yaml plus a static install / docs footer. Fails the # HellionChat.yaml plus a static install / docs footer. Fails the
@@ -150,8 +152,13 @@ jobs:
Write-Host $body Write-Host $body
Write-Host "----------------------------------------" Write-Host "----------------------------------------"
- name: Attach to GitHub release # Gitea-native release action. Creates the release if the tag has no
uses: softprops/action-gh-release@v3 # release yet, or updates the existing one. body_path provides the
# generated release body, files attaches latest.zip. The auto-injected
# GITHUB_TOKEN on Gitea Actions has Gitea-API scope and is sufficient
# for release write.
- name: Attach to Gitea release
uses: https://gitea.com/actions/release-action@main
with: with:
# Explicit tag_name so the action targets the correct release in # Explicit tag_name so the action targets the correct release in
# both push:tags (auto) and workflow_dispatch (manual recovery) # both push:tags (auto) and workflow_dispatch (manual recovery)
@@ -160,5 +167,4 @@ jobs:
tag_name: ${{ github.event.inputs.tag || github.ref_name }} tag_name: ${{ github.event.inputs.tag || github.ref_name }}
files: ${{ steps.locate.outputs.path }} files: ${{ steps.locate.outputs.path }}
body_path: release-body.md body_path: release-body.md
fail_on_unmatched_files: true api_key: ${{ secrets.GITHUB_TOKEN }}
generate_release_notes: false
+1 -1
View File
@@ -9,7 +9,7 @@
.envrc .envrc
!.env.example !.env.example
.vscode/ .vscode/
scripts/ scripts/setup-dev-env.sh
# Local test project (stays out of the published plugin repo; # Local test project (stays out of the published plugin repo;
# pure-function safety net for refactor cycles) # pure-function safety net for refactor cycles)
+35 -9
View File
@@ -15,9 +15,11 @@ to make a contribution land smoothly.
- Read the [README](README.md) so you understand the scope: a - Read the [README](README.md) so you understand the scope: a
privacy-focused, EUPL-1.2-licensed Dalamud plugin that intentionally privacy-focused, EUPL-1.2-licensed Dalamud plugin that intentionally
removes the upstream webinterface and ships privacy-first defaults. removes the upstream webinterface and ships privacy-first defaults.
- Read [`docs/UPSTREAM_SYNC.md`](docs/UPSTREAM_SYNC.md). Cherry-picks - Read [`docs/UPSTREAM_SYNC.md`](docs/UPSTREAM_SYNC.md). Active
from upstream Chat 2 are selective and deliberate; not everything cherry-picking from upstream Chat 2 has ended in the v1.4.x cycle;
that lands there belongs here. HellionChat continues as an independent codebase. Existing
upstream-derived code keeps its attribution. New contributions
stand on their own and do not need to be cherry-pick-compatible.
- Read [`SECURITY.md`](SECURITY.md). Anything security-sensitive goes - Read [`SECURITY.md`](SECURITY.md). Anything security-sensitive goes
through a private advisory, never a public issue or PR. through a private advisory, never a public issue or PR.
- Read the [Code of Conduct](CODE_OF_CONDUCT.md). - Read the [Code of Conduct](CODE_OF_CONDUCT.md).
@@ -43,9 +45,11 @@ to make a contribution land smoothly.
"Was gegenüber Chat 2 fehlt". "Was gegenüber Chat 2 fehlt".
- Features that bypass the privacy filter or weaken the default - Features that bypass the privacy filter or weaken the default
retention behaviour without an explicit, documented opt-in. retention behaviour without an explicit, documented opt-in.
- Sweeping refactors that touch large parts of the codebase. They make - Sweeping refactors that touch large parts of the codebase. The
selective upstream cherry-picks much harder and the maintenance cost maintenance cost outweighs the benefit for a one-person project.
outweighs the benefit for a one-person project. (This used to be doubly important because of the upstream
cherry-pick path; that path is closed now, but the rule still
holds on its own merits.)
- AI-generated code dropped in without disclosure or human review. See - AI-generated code dropped in without disclosure or human review. See
[`docs/AI_DISCLOSURE.md`](docs/AI_DISCLOSURE.md) for how I handle [`docs/AI_DISCLOSURE.md`](docs/AI_DISCLOSURE.md) for how I handle
AI assistance on my side; I expect comparable transparency from AI assistance on my side; I expect comparable transparency from
@@ -117,9 +121,15 @@ Hellion-specific strings live in
direct pull requests. direct pull requests.
The upstream Chat 2 strings in `HellionChat/Resources/Language.*.resx` The upstream Chat 2 strings in `HellionChat/Resources/Language.*.resx`
are **not** translated here. They are owned by the upstream project are **not** translated here. They are kept as-is from the last
and synced in via cherry-pick. Please contribute those to upstream sync and remain the work of the Chat 2 Crowdin community.
[Infiziert90/ChatTwo](https://github.com/Infiziert90/ChatTwo) instead. Active cherry-picking from upstream ended in the v1.4.x cycle (see
[`docs/UPSTREAM_SYNC.md`](docs/UPSTREAM_SYNC.md)), so future
translation improvements to those upstream strings will not flow
into HellionChat automatically anymore. If you have improvements
for the original Chat 2 strings, please contribute them to
[Infiziert90/ChatTwo](https://github.com/Infiziert90/ChatTwo)
directly.
## Licensing ## Licensing
@@ -145,3 +155,19 @@ I respond on weekdays during European business hours and take weekends
and FFXIV patch days off. A pull request that sits for a few days has and FFXIV patch days off. A pull request that sits for a few days has
not been ignored. Pinging once after a week is fine; please do not not been ignored. Pinging once after a week is fine; please do not
ping daily. ping daily.
## First-time setup
After cloning, run once:
```bash
./scripts/setup-hooks.sh
```
This wires `core.hooksPath` to `.githooks/`. The pre-push hook runs preflight
(versions/manifest/changelog/build).
### Test suite
The plugin's test suite lives in a separate local repository and is not part of
this codebase. If you need access for development, contact the maintainer.
+1 -2
View File
@@ -4,8 +4,7 @@ namespace HellionChat.Branding;
// Centralised so a future invite rotation only touches one file. The same // Centralised so a future invite rotation only touches one file. The same
// link is currently hard-coded in repo.json, README.md, SUPPORT.md, // link is currently hard-coded in repo.json, README.md, SUPPORT.md,
// CONTRIBUTORS.md and HellionChat.yaml — those will be migrated to consume // CONTRIBUTORS.md and HellionChat.yaml — those will be migrated to consume
// this constant in a separate housekeeping sweep, but that's out of scope // this constant in a separate housekeeping sweep
// for this Cycle.
internal static class BrandingLinks internal static class BrandingLinks
{ {
public const string HellionForgeDiscordInvite = "https://discord.gg/X9V7Kcv5gR"; public const string HellionForgeDiscordInvite = "https://discord.gg/X9V7Kcv5gR";
+10
View File
@@ -482,6 +482,16 @@ public class Tab
// session. NonSerialized because the temp tab itself is session-only. // session. NonSerialized because the temp tab itself is session-only.
[NonSerialized] public bool IsGreeted; [NonSerialized] public bool IsGreeted;
// v1.4.2 — TabTintCache uses separate validation keys per cache so a
// TellTarget change picked up by GetTint can't strand GetIcon (or vice
// versa) with a stale entry that looks fresh on the shared key.
[NonSerialized] internal string? _cachedTintTellName;
[NonSerialized] internal uint _cachedTintTellWorld;
[NonSerialized] internal uint _cachedTellTint;
[NonSerialized] internal string? _cachedIconTellName;
[NonSerialized] internal uint _cachedIconTellWorld;
[NonSerialized] internal string? _cachedTellIcon;
public bool Matches(Message message) public bool Matches(Message message)
{ {
if (!message.Matches(SelectedChannels, ExtraChatAll, ExtraChatChannels)) if (!message.Matches(SelectedChannels, ExtraChatAll, ExtraChatChannels))
+32 -9
View File
@@ -1,4 +1,5 @@
using System.Numerics; using System.Collections.Concurrent;
using System.Numerics;
using System.Text.Json; using System.Text.Json;
using System.Text.Json.Serialization; using System.Text.Json.Serialization;
using Dalamud.Interface.Textures; using Dalamud.Interface.Textures;
@@ -73,6 +74,19 @@ public static class EmoteCache
private static CancellationTokenSource Cts = new(); private static CancellationTokenSource Cts = new();
internal static CancellationToken Token => Cts.Token; internal static CancellationToken Token => Cts.Token;
// Drain target for in-flight loads on Dispose; without this an orphan
// continuation could still write to a torn-down Texture/Frames field.
private static readonly ConcurrentBag<Task> PendingLoads = new();
internal static void TrackLoad(Task loadTask, string emoteCode)
{
PendingLoads.Add(loadTask.ContinueWith(t =>
{
if (t.IsFaulted)
Plugin.Log.Error(t.Exception!, $"EmoteCache load failed for {emoteCode}");
}, TaskScheduler.Default));
}
public static async Task LoadData() public static async Task LoadData()
{ {
if (State is not LoadingState.Unloaded) if (State is not LoadingState.Unloaded)
@@ -135,10 +149,20 @@ public static class EmoteCache
public static void Dispose() public static void Dispose()
{ {
// Cancel in-flight downloads / texture creates so the async-void
// Load methods bail out before they touch a disposed TextureProvider.
Cts.Cancel(); Cts.Cancel();
// 5s upper bound; anything still running gets abandoned.
try
{
Task.WaitAll(PendingLoads.ToArray(), TimeSpan.FromSeconds(5));
}
catch (AggregateException)
{
// Faults already logged in TrackLoad.
}
while (PendingLoads.TryTake(out _)) { }
foreach (var emote in EmoteImages.Values) foreach (var emote in EmoteImages.Values)
emote.InnerDispose(); emote.InnerDispose();
} }
@@ -233,11 +257,12 @@ public static class EmoteCache
public ImGuiEmote Prepare(Emote emote) public ImGuiEmote Prepare(Emote emote)
{ {
var ct = EmoteCache.Token; var ct = EmoteCache.Token;
Task.Run(() => Load(emote, ct), ct); // Task.Run keeps the sync prefix off the ImGui render thread.
EmoteCache.TrackLoad(Task.Run(() => LoadAsyncTracked(emote, ct), ct), emote.Code);
return this; return this;
} }
private async void Load(Emote emote, CancellationToken ct) private async Task LoadAsyncTracked(Emote emote, CancellationToken ct)
{ {
try try
{ {
@@ -251,8 +276,6 @@ public static class EmoteCache
} }
catch (OperationCanceledException) catch (OperationCanceledException)
{ {
// Plugin disposed mid-load; the EmoteImages entry is also
// being torn down, no extra cleanup needed.
} }
catch (Exception ex) catch (Exception ex)
{ {
@@ -310,11 +333,11 @@ public static class EmoteCache
public ImGuiGif Prepare(Emote emote) public ImGuiGif Prepare(Emote emote)
{ {
var ct = EmoteCache.Token; var ct = EmoteCache.Token;
Task.Run(() => Load(emote, ct), ct); EmoteCache.TrackLoad(Task.Run(() => LoadAsyncTracked(emote, ct), ct), emote.Code);
return this; return this;
} }
private async void Load(Emote emote, CancellationToken ct) private async Task LoadAsyncTracked(Emote emote, CancellationToken ct)
{ {
try try
{ {
+15 -2
View File
@@ -16,6 +16,18 @@ public unsafe class ChatBox
} }
public static void SendMessage(string message) public static void SendMessage(string message)
{
var bytes = ValidateMessage(message);
SendMessageUnsafe(bytes);
}
// Validation split out so the deterministic checks (UTF-8 length, sanitise
// round-trip) can run in xUnit without ClientStructs game memory. The
// sanitiser is injectable so tests can pin throw behaviour without invoking
// Utf8String->SanitizeString, which only resolves in-process. Returns the
// already-encoded bytes so SendMessage doesn't pay GetBytes twice.
// TEST-MIRROR: ../../../Hellion Build test/GameFunctions/ChatBoxTests.cs
internal static byte[] ValidateMessage(string message, Func<string, string>? sanitiserOverride = null)
{ {
var bytes = Encoding.UTF8.GetBytes(message); var bytes = Encoding.UTF8.GetBytes(message);
if (bytes.Length == 0) if (bytes.Length == 0)
@@ -24,10 +36,11 @@ public unsafe class ChatBox
if (bytes.Length > 500) if (bytes.Length > 500)
throw new ArgumentException(Language.ChatBox_Error_Too_Long, nameof(message)); throw new ArgumentException(Language.ChatBox_Error_Too_Long, nameof(message));
if (message.Length != SanitiseText(message).Length) var sanitiser = sanitiserOverride ?? SanitiseText;
if (message.Length != sanitiser(message).Length)
throw new ArgumentException(Language.ChatBox_Error_Invalid, nameof(message)); throw new ArgumentException(Language.ChatBox_Error_Invalid, nameof(message));
SendMessageUnsafe(bytes); return bytes;
} }
private static string SanitiseText(string text) private static string SanitiseText(string text)
+1 -1
View File
@@ -4,7 +4,7 @@
0.1.0 is our bootstrap release; the underlying Chat 2 base is 0.1.0 is our bootstrap release; the underlying Chat 2 base is
called out in the yaml changelog so users can see what it called out in the yaml changelog so users can see what it
derives from. --> derives from. -->
<Version>1.3.0</Version> <Version>1.4.2</Version>
<ImplicitUsings>enable</ImplicitUsings> <ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable> <Nullable>enable</Nullable>
<!-- Honor packages.lock.json on restore so floating version ranges <!-- Honor packages.lock.json on restore so floating version ranges
+117 -36
View File
@@ -31,20 +31,33 @@ description: |-
- Independent plugin state — own config file and database directory, - Independent plugin state — own config file and database directory,
so Hellion Chat does not share state with upstream Chat 2 so Hellion Chat does not share state with upstream Chat 2
v1.1.0 — Theme engine with five built-in themes (Hellion Arctic,
Chat 2 Klassik, Event Horizon, Moonlit Bloom, Mint Grove) plus
JSON-based custom-theme authoring. Settings rebuilt around a card
grid with section detail views. See docs/THEME-AUTHORING.md.
v1.2.3 — Theme catalogue grown to nine built-in themes:
Hellion Arctic, Hellion Spectrum (CVD-safe Deuteran/Protan),
Chat 2 Klassik, Event Horizon, Moonlit Bloom, Mint Grove,
Night Blue, Indigo Violet, Forge Merchantman.
v1.3.0 First plugin integration cycle. Honorific custom titles v1.3.0 First plugin integration cycle. Honorific custom titles
are shown in the chat header above the message log, with auto-detect are shown in the chat header above the message log, with auto-detect
and silent fallback when Honorific is not installed. and silent fallback when Honorific is not installed.
v1.4.0 — Critical Lifecycle Fixes. Plugin reload and shutdown
are cleaner: SQLite no longer leans on GC pressure to release
its file, worker threads are explicitly background, deferred
config saves no longer get lost mid-disable, and pre-v13 config
backups carry the user's custom theme opacity into the v14 schema
instead of falling back to the default.
v1.4.1 — Theme Engine Performance plus a tenth built-in.
HellionStyle.PushGlobal reads pre-computed ABGR values from a
per-theme cache instead of converting RGBA per slot per frame
(~13 % render-time recovery in typical scenes). Custom-theme
hot-reload survives transient file locks (editor mid-save
keeps the last-known-good snapshot). Synthwave Sunset joins
as the tenth built-in theme — Hot Magenta + Cyan on midnight
violet, 80s neon-grid vibes.
v1.4.2 — ChatLog Frame-Hot-Path. Three per-frame allocation
patterns gone from the chat-log render path: card-mode borders
hoist invariants out of the per-message loop, auto-tell tab
tint and icon get a per-tab cache, and the status bar gates
its tab aggregation behind the same one-second cache it uses
for the format strings.
Based on Chat 2 by Infi and Anna, licensed under EUPL-1.2. Based on Chat 2 by Infi and Anna, licensed under EUPL-1.2.
Modding & support: join the Hellion Forge Discord at Modding & support: join the Hellion Forge Discord at
@@ -64,6 +77,100 @@ tags:
- Replacement - Replacement
- Privacy - Privacy
changelog: |- changelog: |-
**Hellion Chat 1.4.2 — ChatLog Frame-Hot-Path**
Third sub-patch of the v1.4.x Polish Sweep series. Per-frame
allocations from the chat-log render path eliminated.
- DrawMessages card-mode hoists theme/drawList/winLeft/winRight/
borderColorAbgr out of the per-message loop. About 500
redundant calls per frame at 100 visible messages, multiplied
by every pop-out window
- Auto-tell tab tint and icon use a per-tab cache. Hash
computation and string allocation only happen when the tell
target name or world drifts. AutoTellTabTint stays a pure
hash helper; cache lives in a thin TabTintCache wrapper
- Status bar gates its tab aggregation behind the same
one-second cache it already used for the format strings.
LINQ Sum and Count replaced with a single foreach pass
that runs on roughly 1% of frames
Realistic frame-time recovery: 2-5% in typical scenes, more
on pop-out-heavy setups because the card-border hoist scales
per window.
Modding & support: join Hellion Forge — https://discord.gg/X9V7Kcv5gR
Based on Chat 2 1.35.3 (upstream Infiziert90/ChatTwo, EUPL-1.2).
**Hellion Chat 1.4.1 — Theme Engine Performance**
Second sub-patch of the v1.4.x Polish Sweep series. Heap
pressure from the theme engine's per-frame render path
removed, plus a tenth built-in theme and hardening for
the custom-theme hot-reload.
- Theme records carry a pre-computed ABGR-packed cache
for every color slot; cache is filled when the theme
is registered and refreshed defensively on every
Switch()
- HellionStyle.PushGlobal reads ABGR values from the
cache instead of calling ColourUtil.RgbaToAbgr per
slot per frame; ~13 % render-time recovery measured
in typical scenes (plan estimate was 26 %, real
~1015 %)
- ThemeRegistry custom-theme reload distinguishes a
recoverable file lock (editor mid-save) from a
permanent IO failure; locked themes keep their
last-known-good snapshot and retry on the next
lookup instead of dropping out of the picker
- New built-in: Synthwave Sunset — Hot Magenta + Cyan
on midnight violet, 80s neon-grid vibes; tenth theme
in the picker
- Author credits refreshed: brand themes are credited
as "Hellion Forge"; Mint Grove and Forge Merchantman
now credited to Carla Beleandis as a community thanks
No schema bump, no user-visible behaviour change other
than smoother frames on GC-sensitive setups and one
additional colour option.
Modding & support: join Hellion Forge — https://discord.gg/X9V7Kcv5gR
Based on Chat 2 1.35.3 (upstream Infiziert90/ChatTwo, EUPL-1.2).
**Hellion Chat 1.4.0 — Critical Lifecycle Fixes**
First sub-patch of the v1.4.x Polish Sweep series. Seven
known lifecycle and race bugs eliminated before any
performance refactor sits on top.
- MessageStore disposal no longer triggers GC.Collect
globally; Pooling=false on the SQLite connection means
there's nothing left to clean up by hand
- PendingMessage and RetentionSweep worker threads are
explicitly marked IsBackground=true so the plugin domain
can unload during XIVLauncher reload without waiting
for them
- EmoteCache image and gif loaders moved from async-void
to async Task with a shared task tracker, draining
on Dispose so an in-flight load can no longer write
to a disposed EmoteImages entry
- DisposeAsync 10s timeout now warns loudly instead of
silently leaving the worker behind
- Plugin.Dispose flushes any pending DeferredSaveFrames
before tearing services down, so settings changes
made in the last few frames before disable are no
longer lost
- The v13→v14 config migration now reads the pre-v13
backup and carries HellionThemeWindowOpacity into the
new WindowOpacity field instead of falling back to
the default 0.85
Modding & support: join Hellion Forge — https://discord.gg/X9V7Kcv5gR
Based on Chat 2 1.35.3 (upstream Infiziert90/ChatTwo, EUPL-1.2).
**Hellion Chat 1.3.0 - Plugin Integrations: Honorific** **Hellion Chat 1.3.0 - Plugin Integrations: Honorific**
First step on the plugin-integration roadmap. HellionChat now First step on the plugin-integration roadmap. HellionChat now
@@ -84,32 +191,6 @@ changelog: |-
Based on Chat 2 1.35.3 (upstream Infiziert90/ChatTwo, EUPL-1.2). Based on Chat 2 1.35.3 (upstream Infiziert90/ChatTwo, EUPL-1.2).
**Hellion Chat 1.2.3 — Theme Expansion**
Four new built-in themes round out the picker. No engine changes,
no settings touched — just more colour options.
- **Night Blue** — Royal Blue on deep marine. Cool tech-dashboard
mood, distinct from the brand themes.
- **Indigo Violet** — Royal Violet on deep indigo with a turquoise-
mint counter for an aurora glitter feel. Sister to Event Horizon
but darker and denser; the turquoise accent keeps the two
distinguishable.
- **Forge Merchantman** — Patina bronze on workshop slate, warm
amber counter. Hellion Forge given a theme of its own — sister
to Hellion Arctic but greener and warmer instead of cold cyan.
- **Hellion Spectrum** — Deuteran/Protan-safe channel colours
using Wong/Okabe-Ito palette tones. Channel identity (Tell pink,
Yell yellow, Shout orange, Party blue, FC green) is preserved;
tones are chosen so each channel stays distinguishable under
red-green colour vision deficiency. Covers the ~99% of CVD cases
that are red-green.
No schema bump, no migration. Default theme is unchanged (Hellion
Arctic). Existing custom themes keep working.
Based on Chat 2 1.35.3 (upstream Infiziert90/ChatTwo, EUPL-1.2).
--- ---
Earlier history: https://github.com/JonKazama-Hellion/HellionChat/releases Earlier history: https://github.com/JonKazama-Hellion/HellionChat/releases
+19 -11
View File
@@ -66,7 +66,12 @@ internal class MessageManager : IAsyncDisposable
Store = new MessageStore(DatabasePath()); Store = new MessageStore(DatabasePath());
PendingMessageThread = new Thread(() => ProcessPendingMessages(PendingThreadCancellationToken.Token)); // IsBackground so a stuck worker never blocks plugin unload.
// Cooperative cancel via PendingThreadCancellationToken first, background flag is the safety net.
PendingMessageThread = new Thread(() => ProcessPendingMessages(PendingThreadCancellationToken.Token))
{
IsBackground = true,
};
PendingMessageThread.Start(); PendingMessageThread.Start();
ContentIdResolverHook = Plugin.GameInteropProvider.HookFromAddress<RaptureLogModule.Delegates.AddMsgSourceEntry>(RaptureLogModule.MemberFunctionPointers.AddMsgSourceEntry, ContentIdResolver); ContentIdResolverHook = Plugin.GameInteropProvider.HookFromAddress<RaptureLogModule.Delegates.AddMsgSourceEntry>(RaptureLogModule.MemberFunctionPointers.AddMsgSourceEntry, ContentIdResolver);
@@ -85,19 +90,22 @@ internal class MessageManager : IAsyncDisposable
Plugin.ChatGui.ChatMessageUnhandled -= ChatMessage; Plugin.ChatGui.ChatMessageUnhandled -= ChatMessage;
await PendingThreadCancellationToken.CancelAsync(); await PendingThreadCancellationToken.CancelAsync();
var timeout = 10_000; // 10s
while (timeout > 0)
{
if (!PendingMessageThread.IsAlive)
break;
timeout -= 100; // 10s cooperative window; Thread.Abort is gone since .NET 5, so a
// stuck worker has to ride out the next AppDomain unload.
var deadline = TimeSpan.FromSeconds(10);
var stopwatch = Stopwatch.StartNew();
while (stopwatch.Elapsed < deadline && PendingMessageThread.IsAlive)
await Task.Delay(100); await Task.Delay(100);
Plugin.Log.Debug("Sleeping because PendingMessageThread thread still alive");
}
// CancellationTokenSource owns an unmanaged WaitHandle; dispose after the if (PendingMessageThread.IsAlive)
// worker thread has drained, otherwise it leaks across plugin reloads. Plugin.Log.Warning(
"PendingMessageThread did not observe cancellation within 10s. " +
"Worker remains on a background thread; next plugin reload releases it. " +
"If this recurs, file a bug with /xllog after the previous reload.");
// CTS owns an unmanaged WaitHandle; dispose even if the worker is
// alive — it checks IsCancellationRequested via the linked token.
PendingThreadCancellationToken.Dispose(); PendingThreadCancellationToken.Dispose();
Store.Dispose(); Store.Dispose();
+4 -3
View File
@@ -131,11 +131,12 @@ internal class MessageStore : IDisposable
public void Dispose() public void Dispose()
{ {
// Pooling=false (set in Connect) avoids ClearAllPools, which is
// provider-wide and would touch other plugins' SQLite connections.
// GC.Collect was here as a defensive flush; removed because explicit
// Close already releases everything we hold.
Connection.Close(); Connection.Close();
Connection.Dispose(); Connection.Dispose();
// Closing the connection doesn't immediately release the file.
GC.Collect();
GC.WaitForPendingFinalizers();
} }
private SqliteConnection Connect() private SqliteConnection Connect()
+71 -2
View File
@@ -41,6 +41,7 @@ public sealed class Plugin : IDalamudPlugin
[PluginService] public static IAddonLifecycle AddonLifecycle { get; private set; } = null!; [PluginService] public static IAddonLifecycle AddonLifecycle { get; private set; } = null!;
[PluginService] public static IPlayerState PlayerState { get; private set; } = null!; [PluginService] public static IPlayerState PlayerState { get; private set; } = null!;
[PluginService] public static ISeStringEvaluator Evaluator { get; private set; } = null!; [PluginService] public static ISeStringEvaluator Evaluator { get; private set; } = null!;
[PluginService] public static ISelfTestRegistry SelfTestRegistry { get; private set; } = null!;
public static Configuration Config = null!; public static Configuration Config = null!;
public static FileDialogManager FileDialogManager { get; private set; } = null!; public static FileDialogManager FileDialogManager { get; private set; } = null!;
@@ -245,11 +246,24 @@ public sealed class Plugin : IDalamudPlugin
// HellionThemeEnabled-Flag wird deprecated und nur noch ein Release // HellionThemeEnabled-Flag wird deprecated und nur noch ein Release
// als Safety-Net im JSON behalten. Window-Opacity wandert von // als Safety-Net im JSON behalten. Window-Opacity wandert von
// HellionThemeWindowOpacity in das neue WindowOpacity-Feld. // HellionThemeWindowOpacity in das neue WindowOpacity-Feld.
//
// v1.4.0 (F5.4): Pre-v13-Backup wird gelesen, HellionThemeWindowOpacity
// ins neue Feld gezogen. Override nur wenn WindowOpacity noch beim
// Default sitzt — sonst hat der User in der Zwischenzeit (z.B. via
// WindowAlpha → WindowOpacity in v15→v16) explizit etwas gesetzt.
if (Config.Version < 14) if (Config.Version < 14)
{ {
Config.Theme = "hellion-arctic"; Config.Theme = "hellion-arctic";
// v1.2.0: alter Opacity-Wert wird nicht mehr migriert (Field entfernt).
// User die direkt v13 → v15 springen bekommen den Default 0.85. var oldThemeOpacity = TryReadPreV13ThemeOpacity();
if (oldThemeOpacity is { } legacy
&& Math.Abs(Config.WindowOpacity - 0.85f) < 0.001f)
{
Config.WindowOpacity = Math.Clamp(legacy, 0.5f, 1.0f);
Log.Information(
$"Migrated pre-v13 HellionThemeWindowOpacity {legacy} to WindowOpacity {Config.WindowOpacity}");
}
Config.ReduceMotion = false; Config.ReduceMotion = false;
Config.UseCompactDensity = false; Config.UseCompactDensity = false;
Config.Version = 14; Config.Version = 14;
@@ -335,6 +349,8 @@ public sealed class Plugin : IDalamudPlugin
} }
} }
// TEST-MIRROR: Hellion Build test/_Helpers/MigrationLogic.cs (local-only repo)
// If you change the formula here, change the mirror — tests assert the contract.
if (oldWindowAlpha != 100f if (oldWindowAlpha != 100f
&& Math.Abs(Config.WindowOpacity - 0.85f) < 0.001f) && Math.Abs(Config.WindowOpacity - 0.85f) < 0.001f)
{ {
@@ -439,6 +455,12 @@ public sealed class Plugin : IDalamudPlugin
ThemeRegistry = new Themes.ThemeRegistry(customThemesDir); ThemeRegistry = new Themes.ThemeRegistry(customThemesDir);
ThemeRegistry.Switch(Config.Theme); ThemeRegistry.Switch(Config.Theme);
// SelfTest hooks live alongside the live registry — the steps
// poll Active per frame and need the registry already wired.
SelfTestRegistry.RegisterTestSteps([
new SelfTests.ThemeSwitchSelfTestStep(this),
]);
// Plugin integrations register their IPC subscribers up-front so // Plugin integrations register their IPC subscribers up-front so
// Ready/Disposing events from the target plugins are caught from // Ready/Disposing events from the target plugins are caught from
// the very first frame, even if the user's Honorific reloads // the very first frame, even if the user's Honorific reloads
@@ -536,6 +558,14 @@ public sealed class Plugin : IDalamudPlugin
Framework.Update -= FrameworkUpdate; Framework.Update -= FrameworkUpdate;
GameFunctions.GameFunctions.SetChatInteractable(true); GameFunctions.GameFunctions.SetChatInteractable(true);
// FrameworkUpdate would have fired the pending save in N frames,
// but we just unsubscribed it. -1 is the idle sentinel.
if (DeferredSaveFrames >= 0)
{
SaveConfig();
DeferredSaveFrames = -1;
}
HonorificService?.Dispose(); HonorificService?.Dispose();
WindowSystem?.RemoveAllWindows(); WindowSystem?.RemoveAllWindows();
@@ -560,6 +590,40 @@ public sealed class Plugin : IDalamudPlugin
EmoteCache.Dispose(); EmoteCache.Dispose();
} }
// Reads HellionThemeWindowOpacity from the pre-v13 backup the v12→v13
// block writes alongside the live config. Null when absent, unreadable,
// or schema-incompatible — all valid steady states (fresh install,
// backup pruned, pre-v12 config). Errors log at Warning so a corrupted
// backup stays visible in /xllog without breaking the migration.
private static float? TryReadPreV13ThemeOpacity()
{
var pluginConfigsDir = Interface.ConfigDirectory.Parent?.FullName;
if (pluginConfigsDir is null)
return null;
var backupPath = Path.Combine(pluginConfigsDir, $"{Interface.InternalName}.json.pre-v13-backup");
if (!File.Exists(backupPath))
return null;
try
{
using var stream = File.OpenRead(backupPath);
using var doc = System.Text.Json.JsonDocument.Parse(stream);
if (doc.RootElement.TryGetProperty("HellionThemeWindowOpacity", out var prop)
&& prop.ValueKind == System.Text.Json.JsonValueKind.Number
&& prop.TryGetSingle(out var value))
{
return value;
}
return null;
}
catch (Exception ex)
{
Log.Warning(ex, "HellionChat: pre-v13 backup lookup failed, defaulting WindowOpacity");
return null;
}
}
private static void MigrateFromChatTwoLayout() private static void MigrateFromChatTwoLayout()
{ {
var pluginConfigsDir = Interface.ConfigDirectory.Parent?.FullName; var pluginConfigsDir = Interface.ConfigDirectory.Parent?.FullName;
@@ -691,6 +755,11 @@ public sealed class Plugin : IDalamudPlugin
policy[(int)(ushort)type] = days; policy[(int)(ushort)type] = days;
var defaultDays = Config.RetentionDefaultDays; var defaultDays = Config.RetentionDefaultDays;
// IsBackground = true for the same reason as PendingMessageThread:
// a stuck sweep must never block plugin unload. RunRetentionSweepIfDue
// guards the run-frequency, and the sweep itself uses the framework's
// cooperative cancellation pattern. The background flag is the safety
// net if the sweep ever takes longer than expected.
new Thread(() => new Thread(() =>
{ {
// Bail out cheaply if a manual sweep is already in flight; the // Bail out cheaply if a manual sweep is already in flight; the
@@ -0,0 +1,85 @@
using Dalamud.Bindings.ImGui;
using Dalamud.Plugin.SelfTest;
using HellionChat.Themes;
namespace HellionChat.SelfTests;
// Validates the runtime theme-switch contract from the user side. The
// caller toggles the active theme via Settings -> Theme & Layout, the
// step polls ThemeRegistry.Active per frame and only passes once the
// slug has moved away from the initial value and back. The ABGR cache
// is sanity-checked on every frame: a freshly switched theme must carry
// a populated cache, otherwise Switch() forgot the recompute and the UI
// would still draw, just with all-transparent slots.
internal sealed class ThemeSwitchSelfTestStep : ISelfTestStep
{
private readonly Plugin plugin;
private string? initialSlug;
private bool switchedAway;
public ThemeSwitchSelfTestStep(Plugin plugin)
{
this.plugin = plugin;
}
public string Name => "Hellion Chat - Theme switch";
public SelfTestStepResult RunStep()
{
var registry = this.plugin.ThemeRegistry;
if (registry is null)
return SelfTestStepResult.Fail;
var active = registry.Active;
if (active is null)
return SelfTestStepResult.Fail;
if (!HasPopulatedCache(active))
return SelfTestStepResult.Fail;
if (this.initialSlug is null)
{
this.initialSlug = active.Slug;
ImGui.Text($"Initial theme: \"{this.initialSlug}\". Open Settings -> Theme & Layout and pick a different theme.");
return SelfTestStepResult.Waiting;
}
if (!this.switchedAway)
{
if (!string.Equals(active.Slug, this.initialSlug, StringComparison.OrdinalIgnoreCase))
{
this.switchedAway = true;
return SelfTestStepResult.Waiting;
}
ImGui.Text($"Switch the active theme away from \"{this.initialSlug}\".");
return SelfTestStepResult.Waiting;
}
if (!string.Equals(active.Slug, this.initialSlug, StringComparison.OrdinalIgnoreCase))
{
ImGui.Text($"Switch back to \"{this.initialSlug}\" to finish the test.");
return SelfTestStepResult.Waiting;
}
return SelfTestStepResult.Pass;
}
public void CleanUp()
{
this.initialSlug = null;
this.switchedAway = false;
}
// Any non-zero slot proves the cache was actually recomputed for the
// current theme. We don't compare against a reference, because custom
// themes can legitimately share slot values with a built-in.
private static bool HasPopulatedCache(Theme theme)
{
var cache = theme.AbgrCache;
return (cache.Primary
| cache.WindowBg
| cache.TextPrimary
| cache.Border) != 0u;
}
}
+1 -1
View File
@@ -9,7 +9,7 @@ internal static class EventHorizon
public static Theme Build() => new( public static Theme Build() => new(
Slug: Slug, Slug: Slug,
Name: "Event Horizon", Name: "Event Horizon",
Author: "Hellion Online Media", Author: "Hellion Forge",
Description: "Cosmic Purple auf Near-Black. Deep-Space-Stimmung.", Description: "Cosmic Purple auf Near-Black. Deep-Space-Stimmung.",
Colors: new ThemeColors( Colors: new ThemeColors(
PrimaryDark: ColourUtil.HexToRgba("#7B3FCF"), PrimaryDark: ColourUtil.HexToRgba("#7B3FCF"),
@@ -9,7 +9,7 @@ internal static class ForgeMerchantman
public static Theme Build() => new( public static Theme Build() => new(
Slug: Slug, Slug: Slug,
Name: "Forge Merchantman", Name: "Forge Merchantman",
Author: "Hellion Online Media", Author: "Carla Beleandis",
Description: "Patina Bronze auf Workshop-Slate — Hellion Forge im Plugin.", Description: "Patina Bronze auf Workshop-Slate — Hellion Forge im Plugin.",
Colors: new ThemeColors( Colors: new ThemeColors(
PrimaryDark: ColourUtil.HexToRgba("#1F8A82"), PrimaryDark: ColourUtil.HexToRgba("#1F8A82"),
+1 -1
View File
@@ -9,7 +9,7 @@ internal static class HellionArctic
public static Theme Build() => new( public static Theme Build() => new(
Slug: Slug, Slug: Slug,
Name: "Hellion Arctic", Name: "Hellion Arctic",
Author: "Hellion Online Media", Author: "Hellion Forge",
Description: "Arctic Cyan + Ember Glow on industrial slate. Plugin default.", Description: "Arctic Cyan + Ember Glow on industrial slate. Plugin default.",
Colors: new ThemeColors( Colors: new ThemeColors(
PrimaryDark: ColourUtil.HexToRgba("#0097A7"), PrimaryDark: ColourUtil.HexToRgba("#0097A7"),
@@ -15,7 +15,7 @@ internal static class HellionSpectrum
public static Theme Build() => new( public static Theme Build() => new(
Slug: Slug, Slug: Slug,
Name: "Hellion Spectrum", Name: "Hellion Spectrum",
Author: "Hellion Online Media", Author: "Hellion Forge",
Description: "Deuteran/Protan-safe channels — Wong palette tones, channel identity preserved.", Description: "Deuteran/Protan-safe channels — Wong palette tones, channel identity preserved.",
Colors: new ThemeColors( Colors: new ThemeColors(
PrimaryDark: ColourUtil.HexToRgba("#005983"), PrimaryDark: ColourUtil.HexToRgba("#005983"),
+1 -1
View File
@@ -9,7 +9,7 @@ internal static class MintGrove
public static Theme Build() => new( public static Theme Build() => new(
Slug: Slug, Slug: Slug,
Name: "Mint Grove", Name: "Mint Grove",
Author: "Hellion Online Media", Author: "Carla Beleandis",
Description: "Mint Green + Honey Amber auf Deep Forest. Naturthemen-tauglich.", Description: "Mint Green + Honey Amber auf Deep Forest. Naturthemen-tauglich.",
Colors: new ThemeColors( Colors: new ThemeColors(
PrimaryDark: ColourUtil.HexToRgba("#3CB371"), PrimaryDark: ColourUtil.HexToRgba("#3CB371"),
+1 -1
View File
@@ -9,7 +9,7 @@ internal static class MoonlitBloom
public static Theme Build() => new( public static Theme Build() => new(
Slug: Slug, Slug: Slug,
Name: "Moonlit Bloom", Name: "Moonlit Bloom",
Author: "Hellion Online Media", Author: "Hellion Forge",
Description: "Bloom Magenta + Soft Sage auf Deep Violet Night.", Description: "Bloom Magenta + Soft Sage auf Deep Violet Night.",
Colors: new ThemeColors( Colors: new ThemeColors(
PrimaryDark: ColourUtil.HexToRgba("#C957D0"), PrimaryDark: ColourUtil.HexToRgba("#C957D0"),
@@ -0,0 +1,76 @@
using HellionChat.Util;
namespace HellionChat.Themes.Builtin;
internal static class SynthwaveSunset
{
public const string Slug = "synthwave-sunset";
public static Theme Build() => new(
Slug: Slug,
Name: "Synthwave Sunset",
Author: "Hellion Forge",
Description: "Hot Magenta + Cyan on midnight violet. 80s neon-grid vibes for late-night raids.",
Colors: new ThemeColors(
PrimaryDark: ColourUtil.HexToRgba("#C71585"),
Primary: ColourUtil.HexToRgba("#FF2D95"),
PrimaryLight: ColourUtil.HexToRgba("#FF6BB6"),
PrimaryGlow: ColourUtil.HexToRgba("#FF2D9599"),
AccentDark: ColourUtil.HexToRgba("#0098B8"),
Accent: ColourUtil.HexToRgba("#00F0FF"),
AccentLight: ColourUtil.HexToRgba("#5CFFFE"),
Identity: ColourUtil.HexToRgba("#FF2D95"),
WindowBg: ColourUtil.HexToRgba("#13041F"),
ChildBg: ColourUtil.HexToRgba("#1E0A35"),
FrameBg: ColourUtil.HexToRgba("#2A1247"),
Surface: ColourUtil.HexToRgba("#3A1860"),
SurfaceHover: ColourUtil.HexToRgba("#4A2475"),
Border: ColourUtil.HexToRgba("#FF2D9566"),
TextPrimary: ColourUtil.HexToRgba("#F0DFFF"),
TextMuted: ColourUtil.HexToRgba("#A88BC4"),
TextDim: ColourUtil.HexToRgba("#6F4D8E"),
StatusSuccess: ColourUtil.HexToRgba("#39FF14"),
StatusDanger: ColourUtil.HexToRgba("#FF3838"),
StatusWarning: ColourUtil.HexToRgba("#FFD700"),
StatusInfo: ColourUtil.HexToRgba("#00F0FF")
),
Layout: new ThemeLayout(
WindowRounding: 5f, ChildRounding: 4f, PopupRounding: 4f,
FrameRounding: 3f, GrabRounding: 3f, TabRounding: 3f,
ScrollbarRounding: 3f, WindowBorderSize: 1f, FrameBorderSize: 1f
),
Typography: new ThemeTypography(),
IsBuiltIn: true,
ChatColors: new ThemeChatColors(new Dictionary<HellionChat.Code.ChatType, uint>
{
// Synthwave Sunset — Magenta dominiert die warmen Channels (Yell/Shout/FC),
// Cyan dominiert die kühlen (Tell/Party). Neon-Akzente für Status-nahe Channels.
[HellionChat.Code.ChatType.Say] = ColourUtil.HexToRgba("#F0DFFF"),
[HellionChat.Code.ChatType.Yell] = ColourUtil.HexToRgba("#FF2D95"),
[HellionChat.Code.ChatType.Shout] = ColourUtil.HexToRgba("#FF6BB6"),
[HellionChat.Code.ChatType.TellIncoming] = ColourUtil.HexToRgba("#00F0FF"),
[HellionChat.Code.ChatType.TellOutgoing] = ColourUtil.HexToRgba("#5CFFFE"),
[HellionChat.Code.ChatType.Party] = ColourUtil.HexToRgba("#5CFFFE"),
[HellionChat.Code.ChatType.Alliance] = ColourUtil.HexToRgba("#FF8C00"),
[HellionChat.Code.ChatType.FreeCompany] = ColourUtil.HexToRgba("#FF2D95"),
[HellionChat.Code.ChatType.NoviceNetwork] = ColourUtil.HexToRgba("#39FF14"),
[HellionChat.Code.ChatType.CrossParty] = ColourUtil.HexToRgba("#5CFFFE"),
[HellionChat.Code.ChatType.Linkshell1] = ColourUtil.HexToRgba("#39FF14"),
[HellionChat.Code.ChatType.Linkshell2] = ColourUtil.HexToRgba("#FF8C00"),
[HellionChat.Code.ChatType.Linkshell3] = ColourUtil.HexToRgba("#FFD700"),
[HellionChat.Code.ChatType.Linkshell4] = ColourUtil.HexToRgba("#00F0FF"),
[HellionChat.Code.ChatType.Linkshell5] = ColourUtil.HexToRgba("#FF6BB6"),
[HellionChat.Code.ChatType.Linkshell6] = ColourUtil.HexToRgba("#FF2D95"),
[HellionChat.Code.ChatType.Linkshell7] = ColourUtil.HexToRgba("#A88BC4"),
[HellionChat.Code.ChatType.Linkshell8] = ColourUtil.HexToRgba("#5CFFFE"),
[HellionChat.Code.ChatType.CustomEmote] = ColourUtil.HexToRgba("#FF6BB6"),
[HellionChat.Code.ChatType.StandardEmote] = ColourUtil.HexToRgba("#A88BC4"),
[HellionChat.Code.ChatType.Echo] = ColourUtil.HexToRgba("#A88BC4"),
})
);
}
+45
View File
@@ -1,3 +1,5 @@
using HellionChat.Util;
namespace HellionChat.Themes; namespace HellionChat.Themes;
public sealed record Theme( public sealed record Theme(
@@ -10,4 +12,47 @@ public sealed record Theme(
ThemeTypography Typography, ThemeTypography Typography,
bool IsBuiltIn, bool IsBuiltIn,
ThemeChatColors? ChatColors = null ThemeChatColors? ChatColors = null
)
{
// Pre-computed ABGR mirror of ThemeColors so PushGlobal can skip the
// RgbaToAbgr conversion per slot per frame.
public ThemeAbgrCache AbgrCache { get; private set; }
public void RecomputeAbgrCache()
{
AbgrCache = new ThemeAbgrCache(
PrimaryDark: ColourUtil.RgbaToAbgr(Colors.PrimaryDark),
Primary: ColourUtil.RgbaToAbgr(Colors.Primary),
PrimaryLight: ColourUtil.RgbaToAbgr(Colors.PrimaryLight),
PrimaryGlow: ColourUtil.RgbaToAbgr(Colors.PrimaryGlow),
AccentDark: ColourUtil.RgbaToAbgr(Colors.AccentDark),
Accent: ColourUtil.RgbaToAbgr(Colors.Accent),
AccentLight: ColourUtil.RgbaToAbgr(Colors.AccentLight),
Identity: ColourUtil.RgbaToAbgr(Colors.Identity),
WindowBg: ColourUtil.RgbaToAbgr(Colors.WindowBg),
ChildBg: ColourUtil.RgbaToAbgr(Colors.ChildBg),
FrameBg: ColourUtil.RgbaToAbgr(Colors.FrameBg),
Surface: ColourUtil.RgbaToAbgr(Colors.Surface),
SurfaceHover: ColourUtil.RgbaToAbgr(Colors.SurfaceHover),
Border: ColourUtil.RgbaToAbgr(Colors.Border),
TextPrimary: ColourUtil.RgbaToAbgr(Colors.TextPrimary),
TextMuted: ColourUtil.RgbaToAbgr(Colors.TextMuted),
TextDim: ColourUtil.RgbaToAbgr(Colors.TextDim),
StatusSuccess: ColourUtil.RgbaToAbgr(Colors.StatusSuccess),
StatusDanger: ColourUtil.RgbaToAbgr(Colors.StatusDanger),
StatusWarning: ColourUtil.RgbaToAbgr(Colors.StatusWarning),
StatusInfo: ColourUtil.RgbaToAbgr(Colors.StatusInfo));
}
}
// Mirrors ThemeColors slot-for-slot. The FillsAll21Slots test pins the
// contract — a new slot without its mirror fails the build.
public readonly record struct ThemeAbgrCache(
uint PrimaryDark, uint Primary, uint PrimaryLight, uint PrimaryGlow,
uint AccentDark, uint Accent, uint AccentLight,
uint Identity,
uint WindowBg, uint ChildBg, uint FrameBg,
uint Surface, uint SurfaceHover, uint Border,
uint TextPrimary, uint TextMuted, uint TextDim,
uint StatusSuccess, uint StatusDanger, uint StatusWarning, uint StatusInfo
); );
+5 -1
View File
@@ -63,7 +63,11 @@ internal static class ThemeJsonLoader
public static Theme LoadFromFile(string path) public static Theme LoadFromFile(string path)
{ {
var json = File.ReadAllText(path); // FileShare.Read lets concurrent readers and well-behaved editors share
// the handle; atomic-replace editors still raise IOException, caught upstream.
using var stream = new FileStream(path, FileMode.Open, FileAccess.Read, FileShare.Read);
using var reader = new StreamReader(stream);
var json = reader.ReadToEnd();
return LoadFromString(json); return LoadFromString(json);
} }
+34 -6
View File
@@ -24,7 +24,13 @@ public sealed class ThemeRegistry
{ IndigoViolet.Slug, IndigoViolet.Build() }, { IndigoViolet.Slug, IndigoViolet.Build() },
{ ForgeMerchantman.Slug, ForgeMerchantman.Build() }, { ForgeMerchantman.Slug, ForgeMerchantman.Build() },
{ MintGrove.Slug, MintGrove.Build() }, { MintGrove.Slug, MintGrove.Build() },
{ SynthwaveSunset.Slug, SynthwaveSunset.Build() },
}; };
// Centralised so the ten .Build() factories stay free of cache plumbing.
foreach (var theme in _builtIns.Values)
theme.RecomputeAbgrCache();
_active = _builtIns[DefaultSlug]; _active = _builtIns[DefaultSlug];
_customThemesDir = customThemesDir; _customThemesDir = customThemesDir;
} }
@@ -45,7 +51,24 @@ public sealed class ThemeRegistry
public IEnumerable<Theme> AllCustom() => RefreshCustomCache(); public IEnumerable<Theme> AllCustom() => RefreshCustomCache();
public void Switch(string slug) => _active = Get(slug); public void Switch(string slug)
{
var theme = Get(slug);
// Defensive — idempotent and cheap, so any future theme source
// that forgets the cache fill still ends up with a populated one.
theme.RecomputeAbgrCache();
_active = theme;
}
// 0x80070020 = SHARING_VIOLATION, 0x80070021 = LOCK_VIOLATION. Other
// IO failures are permanent and get the theme dropped instead of retried.
internal static bool IsRecoverableFileLock(Exception? ex)
{
if (ex is not IOException io)
return false;
var code = (uint)io.HResult;
return code == 0x80070020u || code == 0x80070021u;
}
// Custom-Themes werden lazy aus dem Verzeichnis geladen, Cache mit // Custom-Themes werden lazy aus dem Verzeichnis geladen, Cache mit
// LastWriteTime-Token. Eine geänderte JSON wird beim nächsten Lookup // LastWriteTime-Token. Eine geänderte JSON wird beim nächsten Lookup
@@ -81,14 +104,19 @@ public sealed class ThemeRegistry
try try
{ {
theme = ThemeJsonLoader.LoadFromFile(path); theme = ThemeJsonLoader.LoadFromFile(path);
theme.RecomputeAbgrCache();
_customCache[key] = (theme, stamp); _customCache[key] = (theme, stamp);
} }
catch (Exception ex) catch (Exception ex) when (IsRecoverableFileLock(ex))
{
// Editor mid-save: keep the cached snapshot, leave the stamp
// alone so the next refresh retries automatically.
Plugin.Log.Debug($"Custom theme {Path.GetFileName(path)} is locked, keeping last known good");
if (cached.Theme is not null)
theme = cached.Theme;
}
catch (Exception)
{ {
// Logging passiert in Plugin.cs durch den Aufrufer; hier still
// ignorieren, damit ein einzelnes kaputtes JSON nicht alle
// Custom-Themes blockt.
_ = ex;
continue; continue;
} }
} }
+27 -44
View File
@@ -1,5 +1,6 @@
using System; using System;
using System.Numerics; using System.Numerics;
using HellionChat._Helpers;
using HellionChat.Code; using HellionChat.Code;
using HellionChat.Util; using HellionChat.Util;
using Dalamud.Bindings.ImGui; using Dalamud.Bindings.ImGui;
@@ -89,60 +90,42 @@ public sealed class ChatInputBar
} }
} }
private void SubmitCompact(Tab tab) // TEST-MIRROR: ../_Helpers/CompactInputSubmitter.cs
{ private void SubmitCompact(Tab tab) =>
if (string.IsNullOrWhiteSpace(_state.Buffer)) CompactInputSubmitter.TrySubmit(_state, tab, _host.SendChatBoxFromExternal);
return;
var text = _state.Buffer; // History-navigation callback for the compact input. Cursor math is
_state.Buffer = string.Empty; // delegated to CompactInputHistoryNavigator; only the ImGui buffer
_state.HistoryCursor = -1; // splice stays here because it needs the live callback data.
_host.SendChatBoxFromExternal(tab, text); // TEST-MIRROR: ../_Helpers/CompactInputHistoryNavigator.cs
}
// History-navigation callback for the compact input. Mirrors the main
// window's logic but operates on _state.HistoryCursor and the shared
// InputHistoryService. Index semantics match v0.5.x InputBacklog:
// 0 = oldest, Count-1 = newest.
private int CompactCallback(scoped ref ImGuiInputTextCallbackData data) private int CompactCallback(scoped ref ImGuiInputTextCallbackData data)
{ {
if (data.EventFlag != ImGuiInputTextFlags.CallbackHistory) if (data.EventFlag != ImGuiInputTextFlags.CallbackHistory)
return 0; return 0;
var prev = _state.HistoryCursor; var direction = data.EventKey switch
switch (data.EventKey)
{ {
case ImGuiKey.UpArrow: ImGuiKey.UpArrow => CompactInputHistoryNavigator.Direction.Up,
switch (_state.HistoryCursor) ImGuiKey.DownArrow => CompactInputHistoryNavigator.Direction.Down,
{ _ => (CompactInputHistoryNavigator.Direction?)null,
case -1: };
var offset = 0; if (direction is null)
if (!string.IsNullOrWhiteSpace(_state.Buffer))
{
InputHistoryService.Push(_state.Buffer);
offset = 1;
}
_state.HistoryCursor = InputHistoryService.Count - 1 - offset;
break;
case > 0:
_state.HistoryCursor--;
break;
}
break;
case ImGuiKey.DownArrow:
if (_state.HistoryCursor != -1)
if (++_state.HistoryCursor >= InputHistoryService.Count)
_state.HistoryCursor = -1;
break;
}
if (prev == _state.HistoryCursor)
return 0; return 0;
var historyStr = InputHistoryService.GetByCursor(_state.HistoryCursor) ?? string.Empty; var (cursor, replacement) = CompactInputHistoryNavigator.Navigate(
data.DeleteChars(0, data.BufTextLen); direction.Value,
data.InsertChars(0, historyStr); _state.HistoryCursor,
_state.Buffer,
() => InputHistoryService.Count,
InputHistoryService.Push,
InputHistoryService.GetByCursor);
_state.HistoryCursor = cursor;
if (replacement is null)
return 0;
data.DeleteChars(0, data.BufTextLen);
data.InsertChars(0, replacement);
return 0; return 0;
} }
+12 -8
View File
@@ -1203,6 +1203,15 @@ public sealed class ChatLogWindow : Window
var maxLines = Plugin.Config.MaxLinesToRender; var maxLines = Plugin.Config.MaxLinesToRender;
var startLine = messages.Count > maxLines ? messages.Count - maxLines : 0; var startLine = messages.Count > maxLines ? messages.Count - maxLines : 0;
// Card-mode pre-loop hoist: theme/drawList/winLeft/winRight/border
// are invariant per DrawMessages call; only cursorY moves per row.
var theme = Plugin.ThemeRegistry.Active;
var drawList = ImGui.GetWindowDrawList();
var winLeft = ImGui.GetWindowPos().X;
var winRight = winLeft + ImGui.GetWindowSize().X;
var borderColorAbgr = ColourUtil.RgbaToAbgr((theme.Colors.Border & 0xFFFFFF00u) | 0x33u);
for (var i = startLine; i < messages.Count; i++) for (var i = startLine; i < messages.Count; i++)
{ {
var message = messages[i]; var message = messages[i];
@@ -1344,7 +1353,6 @@ public sealed class ChatLogWindow : Window
{ {
if (message.Sender.Count > 0) if (message.Sender.Count > 0)
{ {
var theme = Plugin.ThemeRegistry.Active;
var senderColor = Plugin.Functions.Chat.GetChannelColor(message.Code.Type) var senderColor = Plugin.Functions.Chat.GetChannelColor(message.Code.Type)
?? theme.Colors.TextPrimary; ?? theme.Colors.TextPrimary;
using (ImRaii.PushColor(ImGuiCol.Text, ColourUtil.RgbaToAbgr(senderColor))) using (ImRaii.PushColor(ImGuiCol.Text, ColourUtil.RgbaToAbgr(senderColor)))
@@ -1363,15 +1371,11 @@ public sealed class ChatLogWindow : Window
// Subtile Border-Bottom als Card-Trenner. Border-Farbe mit // Subtile Border-Bottom als Card-Trenner. Border-Farbe mit
// reduzierter Alpha (RGBA → 0x33) für dezente Trennung. // reduzierter Alpha (RGBA → 0x33) für dezente Trennung.
{ {
var theme = Plugin.ThemeRegistry.Active;
var rowEndY = ImGui.GetCursorScreenPos().Y; var rowEndY = ImGui.GetCursorScreenPos().Y;
var winLeft = ImGui.GetWindowPos().X; drawList.AddLine(
var winRight = winLeft + ImGui.GetWindowSize().X;
var borderRgba = (theme.Colors.Border & 0xFFFFFF00u) | 0x33u;
ImGui.GetWindowDrawList().AddLine(
new Vector2(winLeft + 4, rowEndY - 1), new Vector2(winLeft + 4, rowEndY - 1),
new Vector2(winRight - 4, rowEndY - 1), new Vector2(winRight - 4, rowEndY - 1),
ColourUtil.RgbaToAbgr(borderRgba), borderColorAbgr,
1f); 1f);
ImGui.Dummy(new Vector2(0, 2)); ImGui.Dummy(new Vector2(0, 2));
} }
@@ -1567,7 +1571,7 @@ public sealed class ChatLogWindow : Window
{ {
// v1.2.0 — Hash-Color-Tint differenziert parallele Auto-Tell-Tabs // v1.2.0 — Hash-Color-Tint differenziert parallele Auto-Tell-Tabs
// visuell ohne dass User pro Tab manuell ein Custom-Icon setzen muss. // visuell ohne dass User pro Tab manuell ein Custom-Icon setzen muss.
iconColor = AutoTellTabTint.For(tab.TellTarget.Name, tab.TellTarget.World); iconColor = TabTintCache.GetTint(tab);
} }
else else
{ {
+55 -50
View File
@@ -19,21 +19,21 @@ internal static class HellionStyle
/// </summary> /// </summary>
internal static IDisposable Push(Theme theme) internal static IDisposable Push(Theme theme)
{ {
var c = theme.Colors; var a = theme.AbgrCache;
var stack = new StackHandle(); var stack = new StackHandle();
stack.PushColor(ImGuiCol.Button, c.Primary); stack.PushColorAbgr(ImGuiCol.Button, a.Primary);
stack.PushColor(ImGuiCol.ButtonHovered, c.PrimaryLight); stack.PushColorAbgr(ImGuiCol.ButtonHovered, a.PrimaryLight);
stack.PushColor(ImGuiCol.ButtonActive, c.PrimaryDark); stack.PushColorAbgr(ImGuiCol.ButtonActive, a.PrimaryDark);
stack.PushColor(ImGuiCol.FrameBg, c.FrameBg); stack.PushColorAbgr(ImGuiCol.FrameBg, a.FrameBg);
stack.PushColor(ImGuiCol.FrameBgHovered, c.SurfaceHover); stack.PushColorAbgr(ImGuiCol.FrameBgHovered, a.SurfaceHover);
stack.PushColor(ImGuiCol.FrameBgActive, c.Surface); stack.PushColorAbgr(ImGuiCol.FrameBgActive, a.Surface);
stack.PushColor(ImGuiCol.Border, c.Border); stack.PushColorAbgr(ImGuiCol.Border, a.Border);
stack.PushColor(ImGuiCol.Header, c.Surface); stack.PushColorAbgr(ImGuiCol.Header, a.Surface);
stack.PushColor(ImGuiCol.HeaderHovered, c.SurfaceHover); stack.PushColorAbgr(ImGuiCol.HeaderHovered, a.SurfaceHover);
stack.PushColor(ImGuiCol.HeaderActive, c.Identity); stack.PushColorAbgr(ImGuiCol.HeaderActive, a.Identity);
stack.PushColor(ImGuiCol.CheckMark, c.Primary); stack.PushColorAbgr(ImGuiCol.CheckMark, a.Primary);
stack.PushColor(ImGuiCol.SliderGrab, c.Primary); stack.PushColorAbgr(ImGuiCol.SliderGrab, a.Primary);
stack.PushColor(ImGuiCol.SliderGrabActive, c.PrimaryLight); stack.PushColorAbgr(ImGuiCol.SliderGrabActive, a.PrimaryLight);
return stack; return stack;
} }
@@ -48,6 +48,7 @@ internal static class HellionStyle
{ {
var c = theme.Colors; var c = theme.Colors;
var l = theme.Layout; var l = theme.Layout;
var a = theme.AbgrCache;
var stack = new StackHandle(); var stack = new StackHandle();
var alphaByte = (uint)Math.Clamp((int)(windowOpacity * 255f), 0x55, 0xFF); var alphaByte = (uint)Math.Clamp((int)(windowOpacity * 255f), 0x55, 0xFF);
@@ -76,60 +77,61 @@ internal static class HellionStyle
stack.PushStyleVar(ImGuiStyleVar.WindowBorderSize, l.WindowBorderSize); stack.PushStyleVar(ImGuiStyleVar.WindowBorderSize, l.WindowBorderSize);
stack.PushStyleVar(ImGuiStyleVar.FrameBorderSize, l.FrameBorderSize); stack.PushStyleVar(ImGuiStyleVar.FrameBorderSize, l.FrameBorderSize);
// Surfaces // Surfaces — WindowBg/ChildBg use the per-push opacity-modulated value,
stack.PushColor(ImGuiCol.WindowBg, windowBgWithAlpha); // so they go through the RGBA path; everything else reads from cache.
stack.PushColor(ImGuiCol.ChildBg, childBgWithAlpha); stack.PushColor(ImGuiCol.WindowBg, windowBgWithAlpha);
stack.PushColor(ImGuiCol.PopupBg, c.ChildBg); stack.PushColor(ImGuiCol.ChildBg, childBgWithAlpha);
stack.PushColor(ImGuiCol.Border, c.Border); stack.PushColorAbgr(ImGuiCol.PopupBg, a.ChildBg);
stack.PushColor(ImGuiCol.BorderShadow, 0u); stack.PushColorAbgr(ImGuiCol.Border, a.Border);
stack.PushColorAbgr(ImGuiCol.BorderShadow, 0u);
// Frames // Frames
stack.PushColor(ImGuiCol.FrameBg, c.FrameBg); stack.PushColorAbgr(ImGuiCol.FrameBg, a.FrameBg);
stack.PushColor(ImGuiCol.FrameBgHovered, c.SurfaceHover); stack.PushColorAbgr(ImGuiCol.FrameBgHovered, a.SurfaceHover);
stack.PushColor(ImGuiCol.FrameBgActive, c.Surface); stack.PushColorAbgr(ImGuiCol.FrameBgActive, a.Surface);
// Title bars // Title bars
stack.PushColor(ImGuiCol.TitleBg, c.WindowBg); stack.PushColorAbgr(ImGuiCol.TitleBg, a.WindowBg);
stack.PushColor(ImGuiCol.TitleBgActive, c.Identity); stack.PushColorAbgr(ImGuiCol.TitleBgActive, a.Identity);
stack.PushColor(ImGuiCol.TitleBgCollapsed, c.WindowBg); stack.PushColorAbgr(ImGuiCol.TitleBgCollapsed, a.WindowBg);
// Buttons // Buttons
stack.PushColor(ImGuiCol.Button, c.Primary); stack.PushColorAbgr(ImGuiCol.Button, a.Primary);
stack.PushColor(ImGuiCol.ButtonHovered, c.PrimaryLight); stack.PushColorAbgr(ImGuiCol.ButtonHovered, a.PrimaryLight);
stack.PushColor(ImGuiCol.ButtonActive, c.PrimaryDark); stack.PushColorAbgr(ImGuiCol.ButtonActive, a.PrimaryDark);
// Headers / selectables // Headers / selectables
stack.PushColor(ImGuiCol.Header, c.Surface); stack.PushColorAbgr(ImGuiCol.Header, a.Surface);
stack.PushColor(ImGuiCol.HeaderHovered, c.SurfaceHover); stack.PushColorAbgr(ImGuiCol.HeaderHovered, a.SurfaceHover);
stack.PushColor(ImGuiCol.HeaderActive, c.Identity); stack.PushColorAbgr(ImGuiCol.HeaderActive, a.Identity);
// Tabs // Tabs
stack.PushColor(ImGuiCol.Tab, c.FrameBg); stack.PushColorAbgr(ImGuiCol.Tab, a.FrameBg);
stack.PushColor(ImGuiCol.TabHovered, c.PrimaryLight); stack.PushColorAbgr(ImGuiCol.TabHovered, a.PrimaryLight);
stack.PushColor(ImGuiCol.TabActive, c.Identity); stack.PushColorAbgr(ImGuiCol.TabActive, a.Identity);
stack.PushColor(ImGuiCol.TabUnfocused, c.ChildBg); stack.PushColorAbgr(ImGuiCol.TabUnfocused, a.ChildBg);
stack.PushColor(ImGuiCol.TabUnfocusedActive, c.PrimaryDark); stack.PushColorAbgr(ImGuiCol.TabUnfocusedActive, a.PrimaryDark);
// Scrollbar // Scrollbar
stack.PushColor(ImGuiCol.ScrollbarBg, c.WindowBg); stack.PushColorAbgr(ImGuiCol.ScrollbarBg, a.WindowBg);
stack.PushColor(ImGuiCol.ScrollbarGrab, c.Surface); stack.PushColorAbgr(ImGuiCol.ScrollbarGrab, a.Surface);
stack.PushColor(ImGuiCol.ScrollbarGrabHovered, c.AccentLight); stack.PushColorAbgr(ImGuiCol.ScrollbarGrabHovered, a.AccentLight);
stack.PushColor(ImGuiCol.ScrollbarGrabActive, c.Accent); stack.PushColorAbgr(ImGuiCol.ScrollbarGrabActive, a.Accent);
// Resize grip // Resize grip
stack.PushColor(ImGuiCol.ResizeGrip, c.FrameBg); stack.PushColorAbgr(ImGuiCol.ResizeGrip, a.FrameBg);
stack.PushColor(ImGuiCol.ResizeGripHovered, c.AccentLight); stack.PushColorAbgr(ImGuiCol.ResizeGripHovered, a.AccentLight);
stack.PushColor(ImGuiCol.ResizeGripActive, c.Accent); stack.PushColorAbgr(ImGuiCol.ResizeGripActive, a.Accent);
// Check mark + slider grab // Check mark + slider grab
stack.PushColor(ImGuiCol.CheckMark, c.Primary); stack.PushColorAbgr(ImGuiCol.CheckMark, a.Primary);
stack.PushColor(ImGuiCol.SliderGrab, c.Primary); stack.PushColorAbgr(ImGuiCol.SliderGrab, a.Primary);
stack.PushColor(ImGuiCol.SliderGrabActive, c.PrimaryLight); stack.PushColorAbgr(ImGuiCol.SliderGrabActive, a.PrimaryLight);
// Separator // Separator
stack.PushColor(ImGuiCol.Separator, c.Border); stack.PushColorAbgr(ImGuiCol.Separator, a.Border);
stack.PushColor(ImGuiCol.SeparatorHovered, c.PrimaryLight); stack.PushColorAbgr(ImGuiCol.SeparatorHovered, a.PrimaryLight);
stack.PushColor(ImGuiCol.SeparatorActive, c.Primary); stack.PushColorAbgr(ImGuiCol.SeparatorActive, a.Primary);
return stack; return stack;
} }
@@ -141,6 +143,9 @@ internal static class HellionStyle
internal void PushColor(ImGuiCol slot, uint rgba) internal void PushColor(ImGuiCol slot, uint rgba)
=> _items.Add(ImRaii.PushColor(slot, ColourUtil.RgbaToAbgr(rgba))); => _items.Add(ImRaii.PushColor(slot, ColourUtil.RgbaToAbgr(rgba)));
internal void PushColorAbgr(ImGuiCol slot, uint abgr)
=> _items.Add(ImRaii.PushColor(slot, abgr));
internal void PushStyleVar(ImGuiStyleVar var, float value) internal void PushStyleVar(ImGuiStyleVar var, float value)
=> _items.Add(ImRaii.PushStyle(var, value)); => _items.Add(ImRaii.PushStyle(var, value));
+20 -6
View File
@@ -52,6 +52,19 @@ internal sealed class StatusBar
return $"{count} {(count == 1 ? "tell" : "tells")}"; return $"{count} {(count == 1 ? "tell" : "tells")}";
} }
// Single-pass replacement for the LINQ Sum+Count pair in Draw. Pure
// helper so a future LINQ regression gets pinned by xUnit.
internal static (int messages, int tells) AggregateForStatusBar(IList<Tab> tabs)
{
int messages = 0, tells = 0;
foreach (var t in tabs)
{
messages += t.Messages.Count;
if (t.IsTempTab) tells++;
}
return (messages, tells);
}
/// <summary> /// <summary>
/// Test-Hook: Cache-Logic ohne reale Time-Source verifizieren. /// Test-Hook: Cache-Logic ohne reale Time-Source verifizieren.
/// Nicht für Production-Render. /// Nicht für Production-Render.
@@ -80,12 +93,13 @@ internal sealed class StatusBar
var theme = plugin.ThemeRegistry.Active; var theme = plugin.ThemeRegistry.Active;
var now = Environment.TickCount64; var now = Environment.TickCount64;
// Counts pro Frame berechnen ist günstig (List<>.Count, kleine // Outer gate keeps the foreach out of the hot path 99% of frames.
// Sums); Format-String wird gecached. // UpdateCacheIfDue runs the same check internally — idempotent.
var tabs = Plugin.Config.Tabs.Count; if (now - _lastUpdateMs >= UpdateIntervalMs)
var messages = Plugin.Config.Tabs.Sum(t => t.Messages.Count); {
var tells = Plugin.Config.Tabs.Count(t => t.IsTempTab); var (messages, tells) = AggregateForStatusBar(Plugin.Config.Tabs);
UpdateCacheIfDue(now, tabs, messages, tells); UpdateCacheIfDue(now, Plugin.Config.Tabs.Count, messages, tells);
}
// BorderTop als Trenner — DrawList-Line, ImGui-Separator hat zu viel Padding. // BorderTop als Trenner — DrawList-Line, ImGui-Separator hat zu viel Padding.
var cursorY = ImGui.GetCursorScreenPos().Y; var cursorY = ImGui.GetCursorScreenPos().Y;
+1 -1
View File
@@ -61,7 +61,7 @@ internal static class TabIconMapping
string? autoTellGlyph = null; string? autoTellGlyph = null;
if (tab.IsTempTab && tab.TellTarget != null && tab.TellTarget.IsSet()) if (tab.IsTempTab && tab.TellTarget != null && tab.TellTarget.IsSet())
{ {
autoTellGlyph = AutoTellTabTint.IconFor(tab.TellTarget.Name, tab.TellTarget.World); autoTellGlyph = TabTintCache.GetIcon(tab);
} }
var glyph = TabIconGlyphResolver.ResolveGlyphName(tab, autoTellGlyph); var glyph = TabIconGlyphResolver.ResolveGlyphName(tab, autoTellGlyph);
+36
View File
@@ -0,0 +1,36 @@
namespace HellionChat.Ui;
// Per-Tab cache wrapper around the pure AutoTellTabTint hash helpers.
// Each cache (tint, icon) carries its own name+world validation key so
// neither read path mutates the other's state — refilling one never
// invalidates the other. No string allocation in the steady-state lookup.
internal static class TabTintCache
{
public static uint GetTint(Tab tab)
{
var name = tab.TellTarget.Name;
var world = tab.TellTarget.World;
if (tab._cachedTintTellName != name || tab._cachedTintTellWorld != world)
{
tab._cachedTintTellName = name;
tab._cachedTintTellWorld = world;
tab._cachedTellTint = AutoTellTabTint.For(name, world);
}
return tab._cachedTellTint;
}
public static string GetIcon(Tab tab)
{
var name = tab.TellTarget.Name;
var world = tab.TellTarget.World;
if (tab._cachedTellIcon is null
|| tab._cachedIconTellName != name
|| tab._cachedIconTellWorld != world)
{
tab._cachedIconTellName = name;
tab._cachedIconTellWorld = world;
tab._cachedTellIcon = AutoTellTabTint.IconFor(name, world);
}
return tab._cachedTellIcon;
}
}
@@ -0,0 +1,75 @@
using System;
namespace HellionChat._Helpers;
// Pure-helper mirror of the compact pop-out history-navigation cursor
// math. The original CompactCallback was tangled with ImGuiInputTextCallbackData
// (DeleteChars/InsertChars), which can't be exercised in xUnit. The
// ImGui buffer mutation stays at the call site; only the deterministic
// cursor-and-replacement decision lives here.
//
// Index semantics match InputHistoryService:
// index 0 = oldest entry
// index Count - 1 = newest entry
// cursor == -1 = "not browsing history"
//
// TEST-MIRROR: ../../../Hellion Build test/Ui/CompactInputHistoryNavigatorTests.cs
public static class CompactInputHistoryNavigator
{
public enum Direction { Up, Down }
// replacement == null means: caller must NOT touch the buffer. This
// distinguishes "cursor unchanged, leave the user's typing alone"
// from "cursor moved to an empty slot, clear the buffer".
public static (int cursor, string? replacement) Navigate(
Direction direction,
int currentCursor,
string currentBuffer,
Func<int> getCount,
Action<string> push,
Func<int, string?> getByCursor)
{
ArgumentNullException.ThrowIfNull(getCount);
ArgumentNullException.ThrowIfNull(push);
ArgumentNullException.ThrowIfNull(getByCursor);
var prev = currentCursor;
var next = currentCursor;
switch (direction)
{
case Direction.Up:
if (currentCursor == -1)
{
// First Up press from a fresh buffer: stash whatever
// the user typed so they can recover it after browsing.
var offset = 0;
if (!string.IsNullOrWhiteSpace(currentBuffer))
{
push(currentBuffer);
offset = 1;
}
next = getCount() - 1 - offset;
}
else if (currentCursor > 0)
{
next--;
}
break;
case Direction.Down:
if (currentCursor != -1)
{
next++;
if (next >= getCount())
next = -1;
}
break;
}
if (prev == next)
return (next, null);
var replacement = getByCursor(next) ?? string.Empty;
return (next, replacement);
}
}
@@ -0,0 +1,29 @@
using System;
using HellionChat.Ui;
namespace HellionChat._Helpers;
// Pure-helper mirror of the compact pop-out submit flow. ChatInputBar's
// SubmitCompact used to inline this against a sealed ChatLogWindow, which
// blocks Moq-based isolation. Lifting the deterministic part into a POCO
// keeps the production call site a one-liner while letting xUnit assert
// the buffer/cursor reset and the sender contract directly.
// TEST-MIRROR: ../../../Hellion Build test/Ui/CompactInputSubmitterTests.cs
public static class CompactInputSubmitter
{
public static bool TrySubmit(InputState state, Tab tab, Action<Tab, string> sender)
{
ArgumentNullException.ThrowIfNull(state);
ArgumentNullException.ThrowIfNull(tab);
ArgumentNullException.ThrowIfNull(sender);
if (string.IsNullOrWhiteSpace(state.Buffer))
return false;
var text = state.Buffer;
state.Buffer = string.Empty;
state.HistoryCursor = -1;
sender(tab, text);
return true;
}
}
Binary file not shown.

Before

Width:  |  Height:  |  Size: 166 KiB

After

Width:  |  Height:  |  Size: 68 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 105 KiB

After

Width:  |  Height:  |  Size: 42 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 360 KiB

After

Width:  |  Height:  |  Size: 45 KiB

+20 -7
View File
@@ -35,9 +35,19 @@ edits minimal, isolated to clearly-marked Hellion files, and reversible.
Concrete example: when API 15 hit, I cherry-picked your fix for the Concrete example: when API 15 hit, I cherry-picked your fix for the
BetterTTV emote regression with `git cherry-pick -x` so authorship and BetterTTV emote regression with `git cherry-pick -x` so authorship and
co-author trail stay intact. That is the standard I want to keep using as co-author trail stay intact. That was the standard I held to as long
long as both projects are alive. You should never have to look at this as cherry-picking was viable, and you should never have to look at
fork and wonder if I quietly ate your work. this fork and wonder if I quietly ate your work.
With ChatTwo entering its rework cycle, the active cherry-pick
pipeline is closed since v1.4.x — see [docs/UPSTREAM_SYNC.md](docs/UPSTREAM_SYNC.md)
for the full reasoning. The attribution standard stays exactly the
same: every existing `(cherry picked from commit ...)` line remains
in the git history, the EUPL-1.2 anchor lines in source files are
untouched, and this NOTICE.md remains canonical. If anything from
this point forward originates from Chat 2 it will be a hand-port at
most, called out as such in the commit message and source comments,
not a `git cherry-pick`.
If anything in this fork ever steps on something you would not be okay If anything in this fork ever steps on something you would not be okay
with, please reach out and I will fix it. Genuinely. The list of contacts with, please reach out and I will fix it. Genuinely. The list of contacts
@@ -62,8 +72,10 @@ full-history-by-default position fits a much larger one, including the
roleplaying community where chat archive is part of the play experience. roleplaying community where chat archive is part of the play experience.
Trying to upstream HellionChat's defaults would have meant arguing that Trying to upstream HellionChat's defaults would have meant arguing that
Chat 2's defaults are wrong, and they are not. They are right for the Chat 2's defaults are wrong, and they are not. They are right for the
user base ChatTwo serves. So I keep the fork separate, attribute clearly, user base ChatTwo serves. So I keep the fork separate and attribute
and pull selected upstream patches when they apply. clearly. Active cherry-picking from upstream stopped in the v1.4.x
cycle once Chat 2's rework made selective patches no longer portable;
the existing cherry-pick trail stays in the git history.
## Why HellionChat left the GitHub fork network ## Why HellionChat left the GitHub fork network
@@ -72,8 +84,9 @@ that a fork is either a development branch or a dead mirror. HellionChat
is neither. It is an independently-maintained EUPL-1.2 fork with its own is neither. It is an independently-maintained EUPL-1.2 fork with its own
release cadence, its own custom repo, its own user base. Detaching the release cadence, its own custom repo, its own user base. Detaching the
fork-network relation just makes the situation honest. The git history, fork-network relation just makes the situation honest. The git history,
the cherry-pick trail, and the attribution stay exactly the same. The the existing cherry-pick trail, and the attribution stay exactly the
only thing that changes is the GitHub UI no longer says "forked from". same. The only thing that changes is the GitHub UI no longer says
"forked from".
## Trademarks and naming ## Trademarks and naming
+7 -6
View File
@@ -12,13 +12,13 @@
<img src="docs/images/hellion-forge.png" alt="Hellion Forge" width="180" /> <img src="docs/images/hellion-forge.png" alt="Hellion Forge" width="180" />
</p> </p>
**Version 1.3.0** — Privacy-First-Chat-Plugin für FINAL FANTASY XIV / Dalamud, basierend auf [Chat 2](https://github.com/Infiziert90/ChatTwo) (EUPL-1.2). **Version 1.4.2** — Privacy-First-Chat-Plugin für FINAL FANTASY XIV / Dalamud, basierend auf [Chat 2](https://github.com/Infiziert90/ChatTwo) (EUPL-1.2).
Hellion Chat ist ein Privacy-First-Plugin auf dem Chat-2-Fundament. Der größte Teil der Engine kommt aus Chat 2 (Message-Store, Channel-Logik, Hook-System), die meisten Tastenkürzel funktionieren weiterhin wie gewohnt. Was sich ändert: schärfere Privacy-Defaults von Haus aus, eigene Slash-Commands unter `/hellionchat`, kein Webinterface mehr, und mit v1.1.0 eine Theme-Engine als Schritt in Richtung eigenes UI-Look-and-Feel. Hellion Chat ist ein Privacy-First-Plugin auf dem Chat-2-Fundament. Der größte Teil der Engine kommt aus Chat 2 (Message-Store, Channel-Logik, Hook-System), die meisten Tastenkürzel funktionieren weiterhin wie gewohnt. Was sich ändert: schärfere Privacy-Defaults von Haus aus, eigene Slash-Commands unter `/hellionchat`, kein Webinterface mehr, und mit v1.1.0 eine Theme-Engine als Schritt in Richtung eigenes UI-Look-and-Feel.
Der Daten-Handling-Fokus liegt auf den DSGVO/EU-, US- und JP-Regelungen, soweit für ein Chat-Plugin praktisch umsetzbar: Speicherzeit pro Kanal, granulare Filter, Selbstauskunft per Export. Eine ausführliche Auflistung steht in [`PRIVACY.md`](PRIVACY.md). Der Daten-Handling-Fokus liegt auf den DSGVO/EU-, US- und JP-Regelungen, soweit für ein Chat-Plugin praktisch umsetzbar: Speicherzeit pro Kanal, granulare Filter, Selbstauskunft per Export. Eine ausführliche Auflistung steht in [`PRIVACY.md`](PRIVACY.md).
Eigenständiges Repository, EUPL-1.2-lizenziert. Mit v1.0.0 ist der Standalone-Cut abgeschlossen: eigener Namespace `HellionChat.*`, eigene IPC-Kanäle, eigene Source-Tree-Struktur. Distribution über Custom-Repo. Selektive Cherry-Picks von Upstream-Chat-2 nach Bedarf, dokumentiert in [`docs/UPSTREAM_SYNC.md`](docs/UPSTREAM_SYNC.md). Eigenständiges Repository, EUPL-1.2-lizenziert. Mit v1.0.0 ist der Standalone-Cut abgeschlossen: eigener Namespace `HellionChat.*`, eigene IPC-Kanäle, eigene Source-Tree-Struktur. Distribution über Custom-Repo. Aktiver Upstream-Sync ist mit dem v1.4.x-Cycle beendet: Chat 2 befindet sich in einem grundlegenden Rework und Cherry-Picks sind nicht mehr portierbar. Hellion Chat geht ab da als unabhängige Codebase weiter, Hintergrund und Attribution in [`docs/UPSTREAM_SYNC.md`](docs/UPSTREAM_SYNC.md).
## Acknowledgements ## Acknowledgements
@@ -72,7 +72,7 @@ Hellion Chat wird unter **Hellion Forge** entwickelt, der spezialisierten Moddin
#### Custom Themes (v1.1.0) #### Custom Themes (v1.1.0)
HellionChat bringt eine Theme-Engine mit derzeit neun eingebauten Themes (Hellion Arctic, Hellion Spectrum, Chat 2 Klassik, Event Horizon, Moonlit Bloom, Mint Grove, Night Blue, Indigo Violet, Forge Merchantman) und ein JSON-basiertes Authoring-Format für eigene Themes. Schema und Schritt-für-Schritt-Anleitung in [`docs/THEME-AUTHORING.md`](docs/THEME-AUTHORING.md). Hellion Spectrum ist Deuteran/Protan-safe (rot-grün-Farbenblindheit) auf Basis der Wong/Okabe-Ito-Palette. HellionChat bringt eine Theme-Engine mit derzeit zehn eingebauten Themes (Hellion Arctic, Hellion Spectrum, Chat 2 Klassik, Event Horizon, Moonlit Bloom, Mint Grove, Night Blue, Indigo Violet, Forge Merchantman, Synthwave Sunset) und ein JSON-basiertes Authoring-Format für eigene Themes. Schema und Schritt-für-Schritt-Anleitung in [`docs/THEME-AUTHORING.md`](docs/THEME-AUTHORING.md). Hellion Spectrum ist Deuteran/Protan-safe (rot-grün-Farbenblindheit) auf Basis der Wong/Okabe-Ito-Palette.
#### Plugin-Integrationen (v1.3.0) #### Plugin-Integrationen (v1.3.0)
@@ -225,7 +225,7 @@ Eine optionale Submission ans Dalamud-Main-Plugin-Repo (zusätzlich zum eigenen
## Projektstatus ## Projektstatus
**Version 1.3.0** — Erster Plugin-Integrations-Cycle live (Honorific Custom-Titles im Chat-Header), Theme-Katalog auf neun Built-ins, Settings thematisch re-sortiert, Standalone-Cut abgeschlossen (Stand: 2026-05-06). **Version 1.4.2** — ChatLog Frame-Hot-Path: Per-Frame-Allokationen aus dem ChatLogWindow-Render-Pfad und der Settings-StatusBar eliminiert. Card-Mode-Border-Loop in DrawMessages hebt fünf Invarianten in einen Pre-Loop-Hoist innerhalb des BeginChild-Scopes, AutoTellTabTint bekommt einen Per-Tab-Cache via TabTintCache (separate Validation-Keys pro Cache, kein Cross-Invalidation), StatusBar zieht den Cache-Gate-Check vor die LINQ-Pfade und ersetzt Sum+Count durch eine Single-Pass-Foreach. Realistische Frame-Time-Recovery: 2-5 % in typischen Szenen, mehr bei Pop-Out-Heavy-Setups. Dritter Sub-Patch der v1.4.x Polish-Sweep-Serie (Stand: 2026-05-07).
Hellion Chat ist ein eigenständiges Plugin, kein Fork mehr im Repository-Sinne. Vollständig abgeschlossen: Hellion Chat ist ein eigenständiges Plugin, kein Fork mehr im Repository-Sinne. Vollständig abgeschlossen:
@@ -241,7 +241,8 @@ Hellion Chat ist ein eigenständiges Plugin, kein Fork mehr im Repository-Sinne.
- About-Tab im Hellion-Branding, EN und DE lokalisiert, mit License und Disclaimer - About-Tab im Hellion-Branding, EN und DE lokalisiert, mit License und Disclaimer
- AI-Disclosure dokumentiert (siehe [`docs/AI_DISCLOSURE.md`](docs/AI_DISCLOSURE.md)) - AI-Disclosure dokumentiert (siehe [`docs/AI_DISCLOSURE.md`](docs/AI_DISCLOSURE.md))
- Standalone-Cut: Namespace `HellionChat.*`, IPC-Kanäle `HellionChat.*`, Source-Tree-Restructure, Conflict-Detection gegen Upstream Chat 2, SQLite-CVE-Härtung (3.50.3) - Standalone-Cut: Namespace `HellionChat.*`, IPC-Kanäle `HellionChat.*`, Source-Tree-Restructure, Conflict-Detection gegen Upstream Chat 2, SQLite-CVE-Härtung (3.50.3)
- Theme-Engine mit neun eingebauten Themes plus JSON-Authoring-Format (Engine v1.1.0, Katalog erweitert in v1.2.3, inkl. CVD-safe Hellion Spectrum) - Theme-Engine mit zehn eingebauten Themes plus JSON-Authoring-Format (Engine v1.1.0, Katalog erweitert in v1.2.3, inkl. CVD-safe Hellion Spectrum; Synthwave Sunset in v1.4.1)
- ABGR-Cache auf den Theme-Records: HellionStyle.PushGlobal liest pre-computed ABGR statt RGBA→ABGR pro Slot pro Frame (v1.4.1, ~13 % Render-Time-Recovery)
In Arbeit: schrittweise Modernisierung des UI-Look-and-Feel über die Theme-Engine hinaus. Was als Nächstes geplant ist und welche Themen langfristig auf der Liste stehen, steht in [`docs/ROADMAP.md`](docs/ROADMAP.md). Konkrete eingeplante Items werden zusätzlich im [GitHub-Issue-Tracker](https://github.com/JonKazama-Hellion/HellionChat/issues) mit dem `roadmap`-Label geführt. In Arbeit: schrittweise Modernisierung des UI-Look-and-Feel über die Theme-Engine hinaus. Was als Nächstes geplant ist und welche Themen langfristig auf der Liste stehen, steht in [`docs/ROADMAP.md`](docs/ROADMAP.md). Konkrete eingeplante Items werden zusätzlich im [GitHub-Issue-Tracker](https://github.com/JonKazama-Hellion/HellionChat/issues) mit dem `roadmap`-Label geführt.
@@ -310,7 +311,7 @@ Im Repo-Root liegen die Standard-Repository-Dokumente, vertiefende Dokumentation
| [`docs/LEARNING-JOURNEY.md`](docs/LEARNING-JOURNEY.md) | Entwicklungsgeschichte, vom Web-Stack zu C# / Dalamud, was ich aus dem Fork gelernt habe. | | [`docs/LEARNING-JOURNEY.md`](docs/LEARNING-JOURNEY.md) | Entwicklungsgeschichte, vom Web-Stack zu C# / Dalamud, was ich aus dem Fork gelernt habe. |
| [`docs/IPC.md`](docs/IPC.md) | IPC-Kanal-Reference, Tuple-Payload-Felder, Migrations-Diff für Drittplugins. | | [`docs/IPC.md`](docs/IPC.md) | IPC-Kanal-Reference, Tuple-Payload-Felder, Migrations-Diff für Drittplugins. |
| [`docs/THEME-AUTHORING.md`](docs/THEME-AUTHORING.md) | Theme-Engine-Authoring-Guide (EN): JSON-Schema, Color- und Layout-Slots, Channel-Identity-Regeln, Validierung. | | [`docs/THEME-AUTHORING.md`](docs/THEME-AUTHORING.md) | Theme-Engine-Authoring-Guide (EN): JSON-Schema, Color- und Layout-Slots, Channel-Identity-Regeln, Validierung. |
| [`docs/UPSTREAM_SYNC.md`](docs/UPSTREAM_SYNC.md) | Cherry-Pick-Policy gegenüber Chat 2. | | [`docs/UPSTREAM_SYNC.md`](docs/UPSTREAM_SYNC.md) | Upstream-Sync-Stand: Cherry-Pick-Pipeline seit v1.4.x geschlossen, Attribution intakt. |
| [`docs/THIRD_PARTY_NOTICES.md`](docs/THIRD_PARTY_NOTICES.md) | NuGet-Dependencies mit Lizenzen, Bundled Assets, Network-Status pro Komponente. | | [`docs/THIRD_PARTY_NOTICES.md`](docs/THIRD_PARTY_NOTICES.md) | NuGet-Dependencies mit Lizenzen, Bundled Assets, Network-Status pro Komponente. |
| [`docs/AI_DISCLOSURE.md`](docs/AI_DISCLOSURE.md) | Offenlegung der KI-Unterstützung im Entwicklungsprozess. | | [`docs/AI_DISCLOSURE.md`](docs/AI_DISCLOSURE.md) | Offenlegung der KI-Unterstützung im Entwicklungsprozess. |
+101
View File
@@ -12,6 +12,107 @@ und verlinkt für Details auf die Release-Pages.
--- ---
## Hellion Chat 1.4.2 — ChatLog Frame-Hot-Path
Third sub-patch of the v1.4.x Polish Sweep series. Per-frame
allocations from the chat-log render path eliminated.
- `DrawMessages` card-mode hoists `theme`/`drawList`/`winLeft`/
`winRight`/`borderColorAbgr` out of the per-message loop. About
500 redundant calls per frame at 100 visible messages, multiplied
by every pop-out window
- Auto-tell tab tint and icon use a per-tab cache. Hash
computation and string allocation only happen when the tell
target name or world drifts. `AutoTellTabTint` stays a pure
hash helper; cache lives in a thin `TabTintCache` wrapper
- Status bar gates its tab aggregation behind the same
one-second cache it already used for the format strings.
LINQ `Sum` and `Count` replaced with a single `foreach` pass
that runs on roughly 1 % of frames
Realistic frame-time recovery: 2-5 % in typical scenes, more
on pop-out-heavy setups because the card-border hoist scales
per window.
Modding & support: join Hellion Forge — https://discord.gg/X9V7Kcv5gR
Based on Chat 2 1.35.3 (upstream Infiziert90/ChatTwo, EUPL-1.2).
---
## Hellion Chat 1.4.1 — Theme Engine Performance
Second sub-patch of the v1.4.x Polish Sweep series. Heap
pressure from the theme engine's per-frame render path
removed, plus a tenth built-in theme and hardening for
the custom-theme hot-reload.
- Theme records carry a pre-computed ABGR-packed cache
for every color slot; cache is filled when the theme
is registered and refreshed defensively on every
`Switch()`
- `HellionStyle.PushGlobal` reads ABGR values from the
cache instead of calling `ColourUtil.RgbaToAbgr` per
slot per frame; ~13 % render-time recovery measured
in typical scenes (plan estimate was 26 %, real
~1015 %)
- `ThemeRegistry` custom-theme reload distinguishes a
recoverable file lock (editor mid-save) from a
permanent IO failure; locked themes keep their
last-known-good snapshot and retry on the next
lookup instead of dropping out of the picker
- New built-in: **Synthwave Sunset** — Hot Magenta + Cyan
on midnight violet, 80s neon-grid vibes; tenth theme
in the picker
- Author credits refreshed: brand themes are credited
as "Hellion Forge"; **Mint Grove** and **Forge
Merchantman** now credited to **Carla Beleandis** as
a community thanks
No schema bump, no user-visible behaviour change other
than smoother frames on GC-sensitive setups and one
additional colour option.
Modding & support: join Hellion Forge — https://discord.gg/X9V7Kcv5gR
Based on Chat 2 1.35.3 (upstream Infiziert90/ChatTwo, EUPL-1.2).
---
## Hellion Chat 1.4.0 — Critical Lifecycle Fixes
First sub-patch of the v1.4.x Polish Sweep series. Seven
known lifecycle and race bugs eliminated before any
performance refactor sits on top.
- MessageStore disposal no longer triggers GC.Collect
globally; Pooling=false on the SQLite connection means
there's nothing left to clean up by hand
- PendingMessage and RetentionSweep worker threads are
explicitly marked IsBackground=true so the plugin domain
can unload during XIVLauncher reload without waiting
for them
- EmoteCache image and gif loaders moved from async-void
to async Task with a shared task tracker, draining
on Dispose so an in-flight load can no longer write
to a disposed EmoteImages entry
- DisposeAsync 10s timeout now warns loudly instead of
silently leaving the worker behind
- Plugin.Dispose flushes any pending DeferredSaveFrames
before tearing services down, so settings changes
made in the last few frames before disable are no
longer lost
- The v13→v14 config migration now reads the pre-v13
backup and carries HellionThemeWindowOpacity into the
new WindowOpacity field instead of falling back to
the default 0.85
Modding & support: join Hellion Forge — https://discord.gg/X9V7Kcv5gR
Based on Chat 2 1.35.3 (upstream Infiziert90/ChatTwo, EUPL-1.2).
---
## Hellion Chat 1.3.0 - Plugin Integrations: Honorific ## Hellion Chat 1.3.0 - Plugin Integrations: Honorific
First step on the plugin-integration roadmap. HellionChat now First step on the plugin-integration roadmap. HellionChat now
+43 -10
View File
@@ -12,15 +12,47 @@ Privacy-First-Schnittmenge des Plugins erweisen.
--- ---
## Nächster Cycle (v1.4.0) ## Nächster Cycle (v1.4.3)
**Polish & Motion** - Theme-Crossfade, Header-Quick-Picker, **Plugin-Load Async-Init** — IAsyncDalamudPlugin-Migration
Lerp-Animationen, ggf. Theme-Family-Picker (Carls Grün-Familie und FontManager-async, Plugin-Konstruktor von 3.16 Sek auf
mit Forest/Moss/Mint-Helligkeitsstufen). unter 500 ms perceived load time. Größter und riskantester
Patch der Serie, kommt nach drei stabilen Vorläufer-Patches.
Spec wird im Brainstorming-Cycle vor Beginn der Phase ausgearbeitet. ## v1.4.2 — ChatLog Frame-Hot-Path (released <Datum>)
## v1.3.0 - Plugin Integrations: Honorific (geplant <Datum>) Dritter Sub-Patch der v1.4.x Polish-Sweep-Serie. Per-Frame-
Allokationen aus dem ChatLogWindow-Render-Pfad und der
Settings-StatusBar eliminiert. Card-Mode-Border-Loop in
DrawMessages hebt fünf Invarianten in einen Pre-Loop-Hoist,
AutoTellTabTint bekommt einen Per-Tab-Cache via TabTintCache
(separate Validation-Keys pro Cache, kein Cross-Invalidation),
StatusBar zieht den Cache-Gate-Check vor die Aggregations
und ersetzt LINQ Sum+Count durch eine Single-Pass-Foreach.
## v1.4.1 — Theme Engine Performance (released <Datum>)
Zweiter Sub-Patch der v1.4.x Polish-Sweep-Serie. ABGR-Cache
auf den Theme-Records pre-computed, HellionStyle.PushGlobal
liest aus dem Cache statt pro Slot pro Frame zu konvertieren.
**~13 % Render-Time-Recovery** im Smoke-Test (Plan-Erwartung
2-6 % war konservativ, real ~10-15 %). Custom-Theme-Hot-Reload
überlebt transient File-Locks via Last-Known-Good-Snapshot.
Plus: Synthwave Sunset als zehnter Built-In, Author-Credits
auf Hellion Forge konsolidiert, Mint Grove + Forge Merchantman
auf Carla Beleandis als Community-Thanks.
## v1.4.0 — Critical Lifecycle Fixes (released 2026-05-07)
Erster Sub-Patch der v1.4.x Polish-Sweep-Serie. Sieben P0-
Findings aus Audit-Pass-3 und Pass-4 abgearbeitet:
async-void-Loads, fehlende IsBackground-Flags, GC.Collect
in Dispose, DeferredSave-Race und Pre-v13-Backup-Lookup für
WindowOpacity. Keine Schema-Bumps, keine Funktions-
Änderungen für den User außer dass Reload und Shutdown
spürbar sauberer laufen.
## v1.3.0 - Plugin Integrations: Honorific (released 2026-05-07)
Erster Cycle der Plugin-Integrations-Roadmap. Honorific-Custom- Erster Cycle der Plugin-Integrations-Roadmap. Honorific-Custom-
Titles werden im Chat-Header angezeigt, mit Auto-Detect und Titles werden im Chat-Header angezeigt, mit Auto-Detect und
@@ -60,7 +92,7 @@ Aus dem ursprünglichen v1.1.0-Plan (Ad-Block / Spam-Filter, Receive-
Suppressed-Tells-Toggle) wurden zugunsten der Theme-Engine zurück­ Suppressed-Tells-Toggle) wurden zugunsten der Theme-Engine zurück­
gestellt — beide Items leben weiter im Mittelfrist-Block. gestellt — beide Items leben weiter im Mittelfrist-Block.
## Mittelfristig (v1.3.x v1.4.0) ## Mittelfristig (v1.4.x+)
- **Plugin-Integrations-Roadmap (Cycles 2-6)** - sechs Plugin- - **Plugin-Integrations-Roadmap (Cycles 2-6)** - sechs Plugin-
Integrationen geplant, Honorific (Cycle 1) ist live, danach folgen Integrationen geplant, Honorific (Cycle 1) ist live, danach folgen
@@ -171,6 +203,7 @@ aktuellen Stand getestet.
Hellion Chat ist EUPL-1.2-lizenziert. Konzept-Imports aus AGPL-3.0-Plugins Hellion Chat ist EUPL-1.2-lizenziert. Konzept-Imports aus AGPL-3.0-Plugins
(z.B. XIV Instant Messenger) sind ausschließlich architektonische (z.B. XIV Instant Messenger) sind ausschließlich architektonische
Inspiration, kein Code-Port. Imports aus dem GPL-3.0-kompatiblen Inspiration, kein Code-Port. Code-Imports aus dem Upstream-Bestand
Upstream-Bestand laufen weiter über sind seit v1.4.x abgeschlossen, weil Chat 2 in einem grundlegenden
[`UPSTREAM_SYNC.md`](UPSTREAM_SYNC.md). Rework ist und selektive Patches nicht mehr sauber portierbar sind.
Stand und Begründung in [`UPSTREAM_SYNC.md`](UPSTREAM_SYNC.md).
+3 -2
View File
@@ -51,8 +51,9 @@ HellionChat is a fork of [Chat 2](https://github.com/Infiziert90/ChatTwo)
by Infiziert90 (Infi) and Anna Clemens, also licensed under EUPL-1.2. by Infiziert90 (Infi) and Anna Clemens, also licensed under EUPL-1.2.
The bulk of the code, including the message store architecture, the The bulk of the code, including the message store architecture, the
channel logic, the hook system and the ImGui chat window, originates channel logic, the hook system and the ImGui chat window, originates
from upstream. See `../NOTICE.md` and `UPSTREAM_SYNC.md` for the from upstream. See `../NOTICE.md` for the attribution; `UPSTREAM_SYNC.md`
attribution and the cherry-pick policy. documents the upstream-sync history, including the close of active
cherry-picking in the v1.4.x cycle.
--- ---
+69 -96
View File
@@ -2,12 +2,12 @@
HellionChat is a standalone EUPL-1.2 plugin that originated from HellionChat is a standalone EUPL-1.2 plugin that originated from
[Chat 2](https://github.com/Infiziert90/ChatTwo). Since v1.0.0 it [Chat 2](https://github.com/Infiziert90/ChatTwo). Since v1.0.0 it
lives under its own namespace, IPC channels and source tree. I no lives under its own namespace, IPC channels and source tree. The
longer track upstream as a Git fork, but I do monitor Chat 2 commits active cherry-pick pipeline from upstream Chat 2 is closed since
regularly and cherry-pick selectively where it makes sense. the v1.4.x cycle.
This document covers how that works so anyone (including future-me) This document covers what that means, why I closed it, and what
can do it cleanly. stays in place.
## A Word on Intent ## A Word on Intent
@@ -28,99 +28,77 @@ new UI from scratch and making deliberate architectural decisions that
pull in a different direction. Some upstream patches will simply stop pull in a different direction. Some upstream patches will simply stop
applying cleanly and that is expected. applying cleanly and that is expected.
## One-Time Setup ## Why Cherry-Picking Stopped in v1.4.x
Add the upstream repo as a remote on a fresh clone: Two things converged:
```bash 1. **Chat 2 is in a rework cycle.** Infi mentioned directly that
git remote add upstream https://github.com/Infiziert90/ChatTwo.git parts of ChatTwo are being reworked and "stuff may not be able to
git fetch upstream be cherry picked anymore." Once the upstream code paths I would
``` pull from no longer exist in the same shape, `git cherry-pick`
stops being a meaningful tool — what would land would not be the
change Infi wrote, it would be a hand-port of his concept.
2. **HellionChat has drifted enough that selective patches require
adaptation anyway.** The UI is being rebuilt, the theme engine
sits on top of HellionStyle which has no upstream equivalent, the
privacy filter changes how messages flow through MessageManager.
Even before the rework was announced, more and more upstream
patches needed adaptation rather than a clean apply.
Verify both remotes are wired up: Together those two points mean continuing to call this an "active
cherry-pick pipeline" was no longer honest. So I closed it.
```bash ## What Closing the Pipeline Means in Practice
git remote -v
# origin https://github.com/JonKazama-Hellion/HellionChat.git (fetch)
# origin https://github.com/JonKazama-Hellion/HellionChat.git (push)
# upstream https://github.com/Infiziert90/ChatTwo.git (fetch)
# upstream https://github.com/Infiziert90/ChatTwo.git (push)
```
`upstream` is read-only. Never push to it. - The `upstream` git remote was removed locally on 2026-05-08.
Anyone setting up a fresh clone does **not** add it back.
- New commits will not carry `(cherry picked from commit ...)`
trailers. Anything that originates from Chat 2 from this point
forward will be a hand-port at most, and it gets called out as
such in its own commit message and in the relevant source comments.
- The existing cherry-pick trail stays in the git history exactly as
it is. Every `(cherry picked from commit ...)` line that was added
with `-x` in earlier releases remains intact; that is the
attribution paper trail and removing it would be wrong.
## Reviewing What Is New Upstream ## What Does Not Change
Before any feature cycle I run a quick check: - **EUPL-1.2 anchor lines in source files.** Files that originated
from Chat 2 keep their licence headers and any "based on
Infiziert90/ChatTwo" notice exactly as they are. The licence
obligations under EUPL-1.2 do not lapse because cherry-picking
stopped.
- **NOTICE.md** stays canonical. Attribution to Infi and Anna for the
message store, channel logic, hook system, ImGui chat window and
the localisation infrastructure remains the foundation statement of
this fork.
- **README acknowledgements.** The Acknowledgements section in
`README.md`, the maintainer thanks in the About tab, and the
`Language.*.resx` Crowdin translator credit list all stay as they
are.
- **The original `Language.*.resx` files** remain in the source tree
in their last upstream-sync state. They are the work of the Chat 2
Crowdin community and the existing translations stay valuable. They
will not receive automatic upstream updates anymore — see
CONTRIBUTING.md for what that means for translators.
```bash ## What Could Re-Open Later
git fetch upstream
git log --oneline main..upstream/main | head -30
```
That shows every commit Infi or contributors landed since the last If Chat 2's rework lands and stabilises, and there is a piece of
sync. I read the messages and decide which ones apply to HellionChat. upstream code that I genuinely want in HellionChat, the path forward
is **study and re-implement**, not cherry-pick. That means:
## What I Cherry-Pick - Read the upstream change, understand the design, port the concept
to HellionChat's actual code paths.
- Credit the upstream author in the commit message and, if the
ported code is non-trivial, in a source-file comment.
- Pre-clear with Infi if the port is large enough to warrant a
conversation.
**Always:** security fixes, Dalamud API compatibility patches, This is heavier than `git cherry-pick -x` and that is the point.
BetterTTV and emote-cache fixes, regression fixes for upstream Cherry-picking was light because both codebases shared structure;
behaviour HellionChat still relies on. once they do not, the proper attribution costs a real conversation
rather than a flag on a git command.
**Sometimes:** small bug fixes in `MessageManager.cs`,
`MessageStore.cs`, `ChatLogWindow.cs`, the Tabs system. These come in
when they touch code I have not heavily modified.
**Never:** webinterface changes (the entire webinterface tree is gone
in HellionChat), changes that conflict with the privacy filter, changes
that re-add upstream defaults I deliberately reversed (full-history
logging, Tell Exclusive defaults, etc.).
As HellionChat's UI moves further from the Chat 2 baseline, upstream
patches will increasingly require adaptation rather than a clean
apply. If a patch cannot be ported without breaking HellionChat
behaviour or the privacy model, I skip it rather than force a
compromised version in.
## How I Cherry-Pick
Always with `-x` so authorship and the original commit hash stay
visible:
```bash
git checkout -b sync/upstream-<topic> main
git cherry-pick -x <upstream-commit-sha>
```
`-x` appends a `(cherry picked from commit <sha>)` line to the commit
message. That preserves upstream-author credit and lets anyone reading
`git log` trace the change back to Chat 2. Commit messages stay
identical to the upstream original; I do not rewrite them to match the
HellionChat format.
## Conflict Handling
When a cherry-pick conflicts:
1. Resolve by hand. Do not rewrite upstream code to match HellionChat
conventions; that is what the merge marker showed.
2. If the conflict is fundamental (touches code that no longer exists
in HellionChat), abort the cherry-pick and note why in the
relevant GitHub issue or backlog item. Some upstream patches are
simply not portable and that is fine.
3. After a clean resolve the commit message stays as-is, with the
`-x` footer Git appends automatically.
## Pushing the Sync
Cherry-picked commits go through the same review as any other change.
The sync branch lands in `main` via a no-fast-forward merge, then gets
a release tag if user-visible behaviour changed:
```bash
git checkout main
git merge --no-ff sync/upstream-<topic> -m "merge: upstream sync — <topic>"
```
## Contributing Back ## Contributing Back
@@ -138,17 +116,12 @@ A few things to note about that process:
not push that decision onto his codebase. not push that decision onto his codebase.
- This is not guaranteed for every change, only where it makes sense - This is not guaranteed for every change, only where it makes sense
and where I am confident the fix is clean and self-contained. and where I am confident the fix is clean and self-contained.
- Whether it gets accepted is Infi's call, and a "no" is fine.
## When Upstream Goes Silent
If Chat 2 stops receiving updates the remote stays configured and this
workflow stays documented. The moment maintenance picks back up I am
ready to pull again.
## When Upstream Takes a Direction I Cannot Follow ## When Upstream Takes a Direction I Cannot Follow
If a future Chat 2 release breaks compatibility with the HellionChat If a future Chat 2 release breaks compatibility with the HellionChat
privacy philosophy in a way that cannot be resolved (mandatory cloud privacy philosophy in a way that cannot be resolved (mandatory cloud
sync, removal of the local message store, an incompatible license sync, removal of the local message store, an incompatible licence
change), HellionChat continues from the last compatible cherry-pick. change), HellionChat continues from where it is. The inherited
The inherited history stays under EUPL-1.2 and stays attributed. history stays under EUPL-1.2 and stays attributed.
Binary file not shown.

After

Width:  |  Height:  |  Size: 87 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 160 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 37 KiB

After

Width:  |  Height:  |  Size: 9.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.6 KiB

-20
View File
@@ -1,20 +0,0 @@
**Hellion Chat 1.3.0 - Plugin Integrations: Honorific**
EN - First plugin-integration cycle:
- Honorific titles now show in the chat header above the message log
- Live updates, auto-hide when Honorific is not installed
- New "Integrations" settings tab with status indicator and toggle
- Maintainer attribution buttons for Honorific repo and Caraxi profile
- Coming soon: context menu actions, smart notifications, RP status block, ExtraChat channels, quick DMs
DE - Erste Plugin-Integration:
- Honorific-Titel jetzt im Chat-Header über dem Message-Log
- Live-Update, Auto-Hide wenn nicht installiert
- Neuer "Integrations"-Settings-Tab mit Status-Indikator und Toggle
- Maintainer-Attribution-Buttons für Honorific-Repo und Caraxi-Profil
- Bald: Kontextmenü, Notifications, RP-Block, ExtraChat, schnelle DMs
Got integration ideas? Hop on the Hellion Forge.
Idee für eine Integration? Schreib mir auf der Forge.
Based on Chat 2 1.35.3 (upstream Infiziert90/ChatTwo, EUPL-1.2).
@@ -1,19 +0,0 @@
## Hellion Chat 1.3.0 - Plugin Integrations: Honorific
First step on the plugin-integration roadmap. HellionChat now
listens to Honorific and shows your custom title in the chat
header. The slot auto-hides when Honorific is not installed,
when no custom title is active, or when you are using the
original FFXIV title.
- New "Integrations" settings tab
- Honorific integration with auto-detection and live updates
- "Coming soon" preview of the next five planned integrations:
context menu actions, smart notifications, RP status block,
ExtraChat channels, and quick DM compose
- Maintainer attribution buttons for Honorific repo and Caraxi
- New service-class pattern under HellionChat/Integrations/
Modding and support: join Hellion Forge - https://discord.gg/X9V7Kcv5gR
Based on Chat 2 1.35.3 (upstream Infiziert90/ChatTwo, EUPL-1.2).
+7 -7
View File
@@ -3,8 +3,8 @@
"Author": "JonKazama-Hellion", "Author": "JonKazama-Hellion",
"Name": "Hellion Chat", "Name": "Hellion Chat",
"InternalName": "HellionChat", "InternalName": "HellionChat",
"AssemblyVersion": "1.3.0.0", "AssemblyVersion": "1.4.2.0",
"Description": "Hellion Chat is a privacy-focused chat replacement for FINAL FANTASY XIV based on the Chat 2 codebase (EUPL-1.2). One feature is intentionally removed (the optional webinterface) and a stack of privacy controls is added on top. Tabs, channel filters, RGB colours, emotes, screenshot mode, IPC integration and the chat replacement window itself work the same. The webinterface is intentionally not part of Hellion Chat because it serves a different use case from the smaller default footprint this plugin is built around.\n\nOn top of that, Hellion Chat adds privacy and data-handling controls designed to align with the modern data protection rules that apply across the EU, the United States and Japan. By default only your own conversations are stored; messages from strangers, NPCs and system spam stay out of the database. Retention windows are configurable per channel, history can be wiped retroactively, and stored data can be exported on demand.\n\nKey privacy and data-handling features:\n\n- Channel whitelist with a Privacy-First default\n- Per-channel retention with a daily background sweep\n- Retroactive cleanup with a Ctrl+Shift confirm\n- Export to Markdown, JSON or CSV\n- First-run wizard with three preset profiles (Privacy-First, Casual, Full History)\n- Bilingual UI (English and German) with live language switching\n- Independent plugin state — own config file and database directory, so Hellion Chat does not share state with upstream Chat 2\n\nv1.1.0 — Theme engine with five built-in themes (Hellion Arctic, Chat 2 Klassik, Event Horizon, Moonlit Bloom, Mint Grove) plus JSON-based custom-theme authoring. Settings rebuilt around a card grid with section detail views. See docs/THEME-AUTHORING.md.\n\nv1.2.3 — Theme catalogue grown to nine built-in themes: Hellion Arctic, Hellion Spectrum (CVD-safe Deuteran/Protan), Chat 2 Klassik, Event Horizon, Moonlit Bloom, Mint Grove, Night Blue, Indigo Violet, Forge Merchantman.\n\nv1.3.0 First plugin integration cycle. Honorific custom titles are shown in the chat header above the message log, with auto-detect and silent fallback when Honorific is not installed.\n\nBased on Chat 2 by Infi and Anna, licensed under EUPL-1.2.\n\nModding & support: join the Hellion Forge Discord at https://discord.gg/X9V7Kcv5gR — community for Hellion Chat and other Hellion Online Media plugins/tools.", "Description": "Hellion Chat is a privacy-focused chat replacement for FINAL FANTASY XIV based on the Chat 2 codebase (EUPL-1.2). One feature is intentionally removed (the optional webinterface) and a stack of privacy controls is added on top. Tabs, channel filters, RGB colours, emotes, screenshot mode, IPC integration and the chat replacement window itself work the same. The webinterface is intentionally not part of Hellion Chat because it serves a different use case from the smaller default footprint this plugin is built around.\n\nOn top of that, Hellion Chat adds privacy and data-handling controls designed to align with the modern data protection rules that apply across the EU, the United States and Japan. By default only your own conversations are stored; messages from strangers, NPCs and system spam stay out of the database. Retention windows are configurable per channel, history can be wiped retroactively, and stored data can be exported on demand.\n\nKey privacy and data-handling features:\n\n- Channel whitelist with a Privacy-First default\n- Per-channel retention with a daily background sweep\n- Retroactive cleanup with a Ctrl+Shift confirm\n- Export to Markdown, JSON or CSV\n- First-run wizard with three preset profiles (Privacy-First, Casual, Full History)\n- Bilingual UI (English and German) with live language switching\n- Independent plugin state — own config file and database directory, so Hellion Chat does not share state with upstream Chat 2\n\nv1.3.0 First plugin integration cycle. Honorific custom titles are shown in the chat header above the message log, with auto-detect and silent fallback when Honorific is not installed.\n\nv1.4.0 — Critical Lifecycle Fixes. Plugin reload and shutdown are cleaner: SQLite no longer leans on GC pressure to release its file, worker threads are explicitly background, deferred config saves no longer get lost mid-disable, and pre-v13 config backups carry the user's custom theme opacity into the v14 schema instead of falling back to the default.\n\nv1.4.1 — Theme Engine Performance plus a tenth built-in. HellionStyle.PushGlobal reads pre-computed ABGR values from a per-theme cache instead of converting RGBA per slot per frame (~13 % render-time recovery in typical scenes). Custom-theme hot-reload survives transient file locks (editor mid-save keeps the last-known-good snapshot). Synthwave Sunset joins as the tenth built-in theme — Hot Magenta + Cyan on midnight violet, 80s neon-grid vibes.\n\nv1.4.2 — ChatLog Frame-Hot-Path. Three per-frame allocation patterns gone from the chat-log render path: card-mode borders hoist invariants out of the per-message loop, auto-tell tab tint and icon get a per-tab cache, and the status bar gates its tab aggregation behind the same one-second cache it uses for the format strings.\n\nBased on Chat 2 by Infi and Anna, licensed under EUPL-1.2.\n\nModding & support: join the Hellion Forge Discord at https://discord.gg/X9V7Kcv5gR — community for Hellion Chat and other Hellion Online Media plugins/tools.",
"ApplicableVersion": "any", "ApplicableVersion": "any",
"RepoUrl": "https://github.com/JonKazama-Hellion/HellionChat", "RepoUrl": "https://github.com/JonKazama-Hellion/HellionChat",
"Tags": [ "Tags": [
@@ -20,12 +20,12 @@
"CanUnloadAsync": false, "CanUnloadAsync": false,
"LoadPriority": 0, "LoadPriority": 0,
"Punchline": "Chat replacement with privacy controls aligned to EU, US and JP rules — based on Chat 2 (EUPL-1.2)", "Punchline": "Chat replacement with privacy controls aligned to EU, US and JP rules — based on Chat 2 (EUPL-1.2)",
"Changelog": "**Hellion Chat 1.3.0 - Plugin Integrations: Honorific**\n\nFirst step on the plugin-integration roadmap. HellionChat now listens to Honorific and shows your custom title in the chat header. The slot auto-hides when Honorific is not installed, when no custom title is active, or when you are using the original FFXIV title.\n\n- New \"Integrations\" settings tab\n- Honorific integration with auto-detection and live updates\n- \"Coming soon\" preview of the next five planned integrations: context menu actions, smart notifications, RP status block, ExtraChat channels, and quick DM compose\n- Maintainer attribution buttons for Honorific repo and Caraxi\n- New service-class pattern under HellionChat/Integrations/\n\nModding and support: join Hellion Forge - https://discord.gg/X9V7Kcv5gR\n\nBased on Chat 2 1.35.3 (upstream Infiziert90/ChatTwo, EUPL-1.2).\n\n**Hellion Chat 1.2.3 — Theme Expansion**\n\nFour new built-in themes round out the picker. No engine changes, no settings touched — just more colour options.\n\n- **Night Blue** — Royal Blue on deep marine. Cool tech-dashboard mood, distinct from the brand themes.\n- **Indigo Violet** — Royal Violet on deep indigo with a turquoise-mint counter for an aurora glitter feel. Sister to Event Horizon but darker and denser; the turquoise accent keeps the two distinguishable.\n- **Forge Merchantman** — Patina bronze on workshop slate, warm amber counter. Hellion Forge given a theme of its own — sister to Hellion Arctic but greener and warmer instead of cold cyan.\n- **Hellion Spectrum** — Deuteran/Protan-safe channel colours using Wong/Okabe-Ito palette tones. Channel identity (Tell pink, Yell yellow, Shout orange, Party blue, FC green) is preserved; tones are chosen so each channel stays distinguishable under red-green colour vision deficiency. Covers the ~99% of CVD cases that are red-green.\n\nNo schema bump, no migration. Default theme is unchanged (Hellion Arctic). Existing custom themes keep working.\n\nBased on Chat 2 1.35.3 (upstream Infiziert90/ChatTwo, EUPL-1.2).\n\n---\n\nEarlier history: https://github.com/JonKazama-Hellion/HellionChat/releases", "Changelog": "**Hellion Chat 1.4.2 — ChatLog Frame-Hot-Path**\n\nThird sub-patch of the v1.4.x Polish Sweep series. Per-frame allocations from the chat-log render path eliminated.\n\n- DrawMessages card-mode hoists theme/drawList/winLeft/winRight/borderColorAbgr out of the per-message loop. About 500 redundant calls per frame at 100 visible messages, multiplied by every pop-out window\n- Auto-tell tab tint and icon use a per-tab cache. Hash computation and string allocation only happen when the tell target name or world drifts. AutoTellTabTint stays a pure hash helper; cache lives in a thin TabTintCache wrapper\n- Status bar gates its tab aggregation behind the same one-second cache it already used for the format strings. LINQ Sum and Count replaced with a single foreach pass that runs on roughly 1% of frames\n\nRealistic frame-time recovery: 2-5% in typical scenes, more on pop-out-heavy setups because the card-border hoist scales per window.\n\nModding & support: join Hellion Forge — https://discord.gg/X9V7Kcv5gR\n\nBased on Chat 2 1.35.3 (upstream Infiziert90/ChatTwo, EUPL-1.2).\n\n**Hellion Chat 1.4.1 — Theme Engine Performance**\n\nSecond sub-patch of the v1.4.x Polish Sweep series. Heap pressure from the theme engine's per-frame render path removed, plus a tenth built-in theme and hardening for the custom-theme hot-reload.\n\n- Theme records carry a pre-computed ABGR-packed cache for every color slot; cache is filled when the theme is registered and refreshed defensively on every Switch()\n- HellionStyle.PushGlobal reads ABGR values from the cache instead of calling ColourUtil.RgbaToAbgr per slot per frame; ~13 % render-time recovery measured in typical scenes (plan estimate was 26 %, real ~1015 %)\n- ThemeRegistry custom-theme reload distinguishes a recoverable file lock (editor mid-save) from a permanent IO failure; locked themes keep their last-known-good snapshot and retry on the next lookup instead of dropping out of the picker\n- New built-in: Synthwave Sunset — Hot Magenta + Cyan on midnight violet, 80s neon-grid vibes; tenth theme in the picker\n- Author credits refreshed: brand themes are credited as \"Hellion Forge\"; Mint Grove and Forge Merchantman now credited to Carla Beleandis as a community thanks\n\nNo schema bump, no user-visible behaviour change other than smoother frames on GC-sensitive setups and one additional colour option.\n\nModding & support: join Hellion Forge https://discord.gg/X9V7Kcv5gR\n\nBased on Chat 2 1.35.3 (upstream Infiziert90/ChatTwo, EUPL-1.2).\n\n**Hellion Chat 1.4.0 — Critical Lifecycle Fixes**\n\nFirst sub-patch of the v1.4.x Polish Sweep series. Seven known lifecycle and race bugs eliminated before any performance refactor sits on top.\n\n- MessageStore disposal no longer triggers GC.Collect globally; Pooling=false on the SQLite connection means there's nothing left to clean up by hand\n- PendingMessage and RetentionSweep worker threads are explicitly marked IsBackground=true so the plugin domain can unload during XIVLauncher reload without waiting for them\n- EmoteCache image and gif loaders moved from async-void to async Task with a shared task tracker, draining on Dispose so an in-flight load can no longer write to a disposed EmoteImages entry\n- DisposeAsync 10s timeout now warns loudly instead of silently leaving the worker behind\n- Plugin.Dispose flushes any pending DeferredSaveFrames before tearing services down, so settings changes made in the last few frames before disable are no longer lost\n- The v13→v14 config migration now reads the pre-v13 backup and carries HellionThemeWindowOpacity into the new WindowOpacity field instead of falling back to the default 0.85\n\nModding & support: join Hellion Forge — https://discord.gg/X9V7Kcv5gR\n\nBased on Chat 2 1.35.3 (upstream Infiziert90/ChatTwo, EUPL-1.2).\n\n**Hellion Chat 1.3.0 - Plugin Integrations: Honorific**\n\nFirst step on the plugin-integration roadmap. HellionChat now listens to Honorific and shows your custom title in the chat header. The slot auto-hides when Honorific is not installed, when no custom title is active, or when you are using the original FFXIV title.\n\n- New \"Integrations\" settings tab\n- Honorific integration with auto-detection and live updates\n- \"Coming soon\" preview of the next five planned integrations: context menu actions, smart notifications, RP status block, ExtraChat channels, and quick DM compose\n- Maintainer attribution buttons for Honorific repo and Caraxi\n- New service-class pattern under HellionChat/Integrations/\n\nModding and support: join Hellion Forge - https://discord.gg/X9V7Kcv5gR\n\nBased on Chat 2 1.35.3 (upstream Infiziert90/ChatTwo, EUPL-1.2).\n\n---\n\nEarlier history: https://github.com/JonKazama-Hellion/HellionChat/releases",
"AcceptsFeedback": true, "AcceptsFeedback": true,
"DownloadLinkInstall": "https://github.com/JonKazama-Hellion/HellionChat/releases/download/v1.3.0/latest.zip", "DownloadLinkInstall": "https://github.com/JonKazama-Hellion/HellionChat/releases/download/v1.4.2/latest.zip",
"DownloadLinkUpdate": "https://github.com/JonKazama-Hellion/HellionChat/releases/download/v1.3.0/latest.zip", "DownloadLinkUpdate": "https://github.com/JonKazama-Hellion/HellionChat/releases/download/v1.4.2/latest.zip",
"DownloadLinkTesting": "https://github.com/JonKazama-Hellion/HellionChat/releases/download/v1.3.0/latest.zip", "DownloadLinkTesting": "https://github.com/JonKazama-Hellion/HellionChat/releases/download/v1.4.2/latest.zip",
"TestingAssemblyVersion": "1.3.0.0", "TestingAssemblyVersion": "1.4.2.0",
"IconUrl": "https://raw.githubusercontent.com/JonKazama-Hellion/HellionChat/main/HellionChat/images/icon.png", "IconUrl": "https://raw.githubusercontent.com/JonKazama-Hellion/HellionChat/main/HellionChat/images/icon.png",
"ImageUrls": [ "ImageUrls": [
"https://raw.githubusercontent.com/JonKazama-Hellion/HellionChat/main/HellionChat/images/chatWindow.png", "https://raw.githubusercontent.com/JonKazama-Hellion/HellionChat/main/HellionChat/images/chatWindow.png",
+22
View File
@@ -0,0 +1,22 @@
#!/usr/bin/env bash
# preflight.sh — pre-push gate. Blocks A/B/C verify config drift; Block D is a
# headless `dotnet build` to catch compile-time API drift. Test execution lives
# in the local Build-Suite repo and is NOT part of this preflight.
set -euo pipefail
ROOT="$(cd "$(dirname "$0")/.." && pwd)"
cd "$ROOT"
echo "==> preflight: Block A — version consistency"
./scripts/verify-version-consistency.sh
echo "==> preflight: Block B — manifest shape"
./scripts/verify-manifest-shape.sh
echo "==> preflight: Block C — changelog sync"
./scripts/verify-changelog-sync.sh
echo "==> preflight: Block D — plugin compile health"
dotnet build HellionChat/HellionChat.csproj --configuration Release --nologo --verbosity quiet
echo "==> preflight: ALL GREEN"
+13
View File
@@ -0,0 +1,13 @@
#!/usr/bin/env bash
# setup-hooks.sh — installs pre-push hook via core.hooksPath. Idempotent.
# Note: NO pre-commit hook — test execution is local-only in the Build-Suite repo,
# so the plugin repo's pre-commit cannot run tests. Versions/manifest/changelog
# checks happen on pre-push only.
set -euo pipefail
ROOT="$(cd "$(dirname "$0")/.." && pwd)"
cd "$ROOT"
git config core.hooksPath .githooks
chmod +x .githooks/pre-push
echo "setup-hooks: core.hooksPath set to .githooks. pre-push live."
+45
View File
@@ -0,0 +1,45 @@
#!/usr/bin/env bash
# verify-changelog-sync.sh — Block C.
# Strips .0 suffix from repo.json AssemblyVersion to derive the 3-digit tag/version.
# yaml.changelog is a single multi-line block with **Hellion Chat X.Y.Z** subblocks.
set -euo pipefail
ROOT="$(cd "$(dirname "$0")/.." && pwd)"
YAML="$ROOT/HellionChat/HellionChat.yaml"
REPO_JSON="$ROOT/repo.json"
FORGE_DIR="$ROOT/.github/forge-posts"
fail() { echo "verify-changelog-sync: FAIL — $1" >&2; exit 1; }
ok() { echo "verify-changelog-sync: OK — $1"; }
VER="$(jq -r '.[0].AssemblyVersion' "$REPO_JSON" | sed -E 's/\.0$//')"
TAG="v$VER"
grep -qE "^[[:space:]]*\*\*Hellion Chat ${VER}" "$YAML" \
|| fail "$YAML changelog missing **Hellion Chat ${VER}** subblock. Fix: add the v${VER} block at the top of the changelog field."
jq -r '.[0].Changelog' "$REPO_JSON" | grep -qE "^[[:space:]]*\*\*Hellion Chat ${VER}" \
|| fail "$REPO_JSON Changelog missing **Hellion Chat ${VER}** subblock. Fix: copy the yaml changelog over."
FORGE_FILE="$FORGE_DIR/${TAG}.md"
[ -f "$FORGE_FILE" ] || fail "$FORGE_FILE missing. Fix: create from previous tag's file as template."
SUBTITLE="$(awk '/^---$/{f=!f; next} f && /^subtitle:/' "$FORGE_FILE" | sed -E 's/^subtitle:[[:space:]]*//' | tr -d '\"')"
[ -n "$SUBTITLE" ] || fail "$FORGE_FILE frontmatter missing 'subtitle'."
[ "${#SUBTITLE}" -le 60 ] || fail "$FORGE_FILE subtitle is ${#SUBTITLE} chars (max 60)."
NATUR="$(awk '/^---$/{f=!f; next} f && /^versionsnatur:/' "$FORGE_FILE" | sed -E 's/^versionsnatur:[[:space:]]*//' | tr -d '\"')"
[ -n "$NATUR" ] || fail "$FORGE_FILE frontmatter missing 'versionsnatur'."
[ "${#NATUR}" -le 40 ] || fail "$FORGE_FILE versionsnatur is ${#NATUR} chars (max 40)."
BODY="$(awk '/^---$/{f++; next} f==2' "$FORGE_FILE")"
TITLE_LEN=$((${#VER} + 16 + ${#SUBTITLE}))
FOOTER_LEN=80
TOTAL=$((TITLE_LEN + ${#BODY} + FOOTER_LEN))
[ "$TOTAL" -le 5500 ] || fail "Forge embed total ~${TOTAL} chars > 5500 cap."
YAML_VERSIONS="$(grep -cE '^[[:space:]]*\*\*Hellion Chat' "$YAML" || true)"
[ "$YAML_VERSIONS" -le 4 ] || fail "$YAML changelog has $YAML_VERSIONS version subblocks (max 4). Fix: move oldest to docs/CHANGELOG.md."
ok "yaml/repo.json/forge-post in sync for $TAG, embed-total ~${TOTAL}/5500, $YAML_VERSIONS/4 subblocks"
+43
View File
@@ -0,0 +1,43 @@
#!/usr/bin/env bash
# verify-manifest-shape.sh — Block B. Required fields in lowercase yaml,
# DalamudApiLevel sanity in repo.json, no own DalamudPackager.targets,
# Icon AND every ImageUrl reachable.
set -euo pipefail
ROOT="$(cd "$(dirname "$0")/.." && pwd)"
YAML="$ROOT/HellionChat/HellionChat.yaml"
REPO_JSON="$ROOT/repo.json"
TARGETS_OWN="$ROOT/HellionChat/DalamudPackager.targets"
fail() { echo "verify-manifest-shape: FAIL — $1" >&2; exit 1; }
ok() { echo "verify-manifest-shape: OK — $1"; }
for FIELD in name author punchline description repo_url icon_url image_urls tags changelog; do
grep -qE "^${FIELD}:" "$YAML" || fail "$YAML missing required field: $FIELD"
done
[ -f "$TARGETS_OWN" ] && fail "Own DalamudPackager.targets at $TARGETS_OWN strips Icon/ImageUrls. DELETE it; SDK default works."
API_LEVEL="$(jq -r '.[0].DalamudApiLevel' "$REPO_JSON")"
case "$API_LEVEL" in
''|null) fail "$REPO_JSON missing DalamudApiLevel" ;;
esac
[[ "$API_LEVEL" =~ ^[0-9]+$ ]] || fail "$REPO_JSON DalamudApiLevel must be integer, got: $API_LEVEL"
[ "$API_LEVEL" -ge 12 ] || fail "$REPO_JSON DalamudApiLevel=$API_LEVEL is below SDK 15 floor (12)."
if [ "${HOOKS_OFFLINE:-0}" != "1" ]; then
ICON_URL="$(jq -r '.[0].IconUrl' "$REPO_JSON")"
curl -fsI "$ICON_URL" > /dev/null || fail "IconUrl unreachable: $ICON_URL"
ok "IconUrl reachable: $ICON_URL"
COUNT="$(jq -r '.[0].ImageUrls | length' "$REPO_JSON")"
[ "$COUNT" -ge 1 ] || fail "repo.json ImageUrls is empty"
for i in $(seq 0 $((COUNT - 1))); do
URL="$(jq -r ".[0].ImageUrls[$i]" "$REPO_JSON")"
curl -fsI "$URL" > /dev/null || fail "ImageUrls[$i] unreachable: $URL"
done
ok "$COUNT ImageUrl(s) reachable, DalamudApiLevel=$API_LEVEL"
else
ok "skipped URL reachability (HOOKS_OFFLINE=1), DalamudApiLevel=$API_LEVEL"
fi
+36
View File
@@ -0,0 +1,36 @@
#!/usr/bin/env bash
# verify-version-consistency.sh — Block A of preflight.
# csproj <Version> is 3-digit SemVer; repo.json AssemblyVersion is 4-digit (.0 suffix).
set -euo pipefail
ROOT="$(cd "$(dirname "$0")/.." && pwd)"
CSPROJ="$ROOT/HellionChat/HellionChat.csproj"
REPO_JSON="$ROOT/repo.json"
fail() { echo "verify-version-consistency: FAIL — $1" >&2; exit 1; }
ok() { echo "verify-version-consistency: OK — $1"; }
CSPROJ_VER="$(grep -oE '<Version>[^<]+</Version>' "$CSPROJ" | head -1 | sed -E 's/<[^>]+>//g')"
[ -n "$CSPROJ_VER" ] || fail "$CSPROJ has no <Version> element"
EXPECTED_4DIGIT="${CSPROJ_VER}.0"
REPO_VER="$(jq -r '.[0].AssemblyVersion' "$REPO_JSON")"
[ "$REPO_VER" = "$EXPECTED_4DIGIT" ] \
|| fail "csproj=$CSPROJ_VER expects repo.json AssemblyVersion=$EXPECTED_4DIGIT but got $REPO_VER. Fix: align in $REPO_JSON."
TEST_VER="$(jq -r '.[0].TestingAssemblyVersion' "$REPO_JSON")"
[ "$TEST_VER" = "$EXPECTED_4DIGIT" ] \
|| fail "TestingAssemblyVersion=$TEST_VER must match $EXPECTED_4DIGIT. Fix: align in $REPO_JSON."
TAG="v$CSPROJ_VER"
for KEY in DownloadLinkInstall DownloadLinkUpdate DownloadLinkTesting; do
URL="$(jq -r ".[0].$KEY" "$REPO_JSON")"
case "$URL" in
*"/$TAG/"*) ;;
*) fail "$KEY=$URL does not contain tag $TAG. Fix: update $REPO_JSON $KEY to releases/download/$TAG/latest.zip." ;;
esac
done
ok "csproj=$CSPROJ_VER, repo.json=$EXPECTED_4DIGIT, tag $TAG present in DownloadLinks"