docs: unify documentation and streamline code comments

- Translated project documentation (LEARNING-JOURNEY, CONTRIBUTORS, AI_DISCLOSURE) to English for better accessibility.
- Standardized internal code documentation by converting XML-doc blocks to standard comment format.
- Cleaned up inline comments and removed redundant versioning metadata across the codebase.
- Refactored non-functional text elements to improve readability and maintain a consistent style.
This commit is contained in:
2026-05-11 00:52:15 +02:00
parent a37882893e
commit c4c85cf4b8
33 changed files with 666 additions and 1364 deletions
+13 -28
View File
@@ -5,18 +5,12 @@ using HellionChat.Util;
namespace HellionChat.Ui;
/// <summary>
/// ImGui style override for Hellion Chat. v1.1.0 ist die Engine
/// theme-getrieben: PushGlobal nimmt eine Theme-Instance + Window-
/// Opacity, die gesamten Color- und Style-Slots werden aus dem Theme
/// gelesen statt aus einer fixen Konstanten-Tabelle.
/// </summary>
// Theme-driven ImGui style override. PushGlobal is pushed once per frame
// in Plugin.Draw and drives every Hellion-rendered window.
internal static class HellionStyle
{
/// <summary>
/// Local color stack auf Basis des aktiven Themes. Cheap. Use inside a
/// `using var _ = HellionStyle.Push(theme);` block.
/// </summary>
// Local color stack for the active theme. Use inside a
// `using var _ = HellionStyle.Push(theme);` block.
internal static IDisposable Push(Theme theme)
{
var a = theme.AbgrCache;
@@ -37,13 +31,8 @@ internal static class HellionStyle
return stack;
}
/// <summary>
/// Global color and style-variable stack pushed once per frame in
/// Plugin.Draw. Drives every Hellion-rendered window from the active
/// theme's palette and layout values.
/// </summary>
/// <param name="theme">Active theme from ThemeRegistry.</param>
/// <param name="windowOpacity">Window background alpha (0.51.0).</param>
// Global color and style stack pushed once per frame.
// windowOpacity: window background alpha (0.5-1.0).
internal static IDisposable PushGlobal(Theme theme, float windowOpacity = 1.0f)
{
var c = theme.Colors;
@@ -54,15 +43,11 @@ internal static class HellionStyle
var alphaByte = (uint)Math.Clamp((int)(windowOpacity * 255f), 0x55, 0xFF);
var windowBgWithAlpha = (c.WindowBg & 0xFFFFFF00u) | alphaByte;
// ChildBg-Alpha: Sub-Bereiche (Tab-Sidebar, Message-Area, Input-Bar)
// werden im ChatLog-Window als BeginChild gezeichnet. Würde der ChildBg
// mit dem gleichen Alpha wie WindowBg gerendert, multiplizieren sich
// die Layer (1 - (1-α)² Deckung), und 50 % WindowOpacity kommt mit
// 75 % Deckung im Child-Bereich an — das Fenster wirkt solider als der
// Slider verspricht. Bei voller Opacity bleibt der Theme-Akzent
// erhalten (Theme-eigene Alpha-Komponente, i.d.R. FF); sobald der User
// Transparenz zieht, wird ChildBg vollständig durchsichtig damit nur
// der WindowBg-Layer die finale Deckung bestimmt.
// ChildBg alpha: child areas rendered inside ChatLogWindow would
// multiply their alpha with WindowBg, making 50% opacity appear
// ~75% solid. At full opacity the theme's alpha is preserved; below
// it ChildBg goes fully transparent so only WindowBg sets the final
// coverage.
var childBgAlpha = windowOpacity >= 0.999f ? (c.ChildBg & 0xFFu) : 0u;
var childBgWithAlpha = (c.ChildBg & 0xFFFFFF00u) | childBgAlpha;
@@ -77,8 +62,8 @@ internal static class HellionStyle
stack.PushStyleVar(ImGuiStyleVar.WindowBorderSize, l.WindowBorderSize);
stack.PushStyleVar(ImGuiStyleVar.FrameBorderSize, l.FrameBorderSize);
// Surfaces — WindowBg/ChildBg use the per-push opacity-modulated value,
// so they go through the RGBA path; everything else reads from cache.
// Surfaces — WindowBg/ChildBg use opacity-modulated values (RGBA path);
// everything else reads from the pre-computed ABGR cache.
stack.PushColor(ImGuiCol.WindowBg, windowBgWithAlpha);
stack.PushColor(ImGuiCol.ChildBg, childBgWithAlpha);
stack.PushColorAbgr(ImGuiCol.PopupBg, a.ChildBg);