mirror of
https://github.com/GeWuYou/GFramework.git
synced 2026-05-07 00:39:00 +08:00
- 创建 RichTextEffectBase 基类提供统一的标签命名和环境参数读取逻辑 - 实现 RichTextJitterEffect 抖动效果类,支持振幅和速度参数调节 - 添加 DefaultRichTextEffectRegistry 默认效果注册表管理内置效果映射 - 创建 GfRichTextLabel 组合式富文本标签宿主,集成效果装配逻辑 - 定义 IRichTextEffectRegistry 接口实现效果注册表抽象 - 开发 RichTextEffectsController 装配控制器负责效果集合管理 - 实现 RichTextMarkup 工具类提供语义化富文本标签构建辅助方法 - 添加相关单元测试验证效果控制器和标记工具的功能正确性
22 lines
709 B
C#
22 lines
709 B
C#
using Array = Godot.Collections.Array;
|
|
|
|
namespace GFramework.Godot.Text;
|
|
|
|
/// <summary>
|
|
/// 抽象可被富文本效果控制器驱动的宿主。
|
|
/// 该接口把装配决策从 Godot 原生 <see cref="RichTextLabel" /> 生命周期中解耦出来,便于在纯托管测试中验证开关、
|
|
/// 配置回退和注册表替换行为。
|
|
/// </summary>
|
|
internal interface IRichTextEffectHost
|
|
{
|
|
/// <summary>
|
|
/// 获取或设置宿主是否启用 BBCode 解析。
|
|
/// </summary>
|
|
bool BbcodeEnabled { get; set; }
|
|
|
|
/// <summary>
|
|
/// 获取或设置当前安装到宿主上的自定义富文本效果集合。
|
|
/// </summary>
|
|
Array CustomEffects { get; set; }
|
|
}
|