Token导航 LogoToken导航TokenDH.com
前端设计需要联网github未标认证来源可访问许可证需确认审计提醒

godot-ui-theminggodot UI 主题

Agent Skill

用于辅助界面设计、视觉规范、排版、配色、布局和交互体验优化。它适合让 Agent 根据产品场景整理页面结构、生成 UI 方案、检查视觉一致性或改进组件层级。使用时需要结合现有品牌、设计系统和用户任务,不应只堆装饰元素;涉及真实页面改动时,应通过截图或浏览器预览检查文本溢出、对齐和响应式表现。

总安装

3,608

周安装

155

GitHub Stars

138

下载量

1,265
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:godot-ui-theming(godot UI 主题)
来源仓库:https://github.com/thedivergentai/gd-agentic-skills
仓库路径:skills/godot-ui-theming
安装命令:
npx skills add https://github.com/thedivergentai/gd-agentic-skills --skill godot-ui-theming
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/thedivergentai/gd-agentic-skills --skill godot-ui-theming

简介

用于辅助界面设计、视觉规范、排版、配色和布局优化。

  • 适合整理页面结构、生成 UI 方案或检查组件层级一致性。
  • 通过 npx skills add 命令从指定 GitHub 仓库安装并使用。
  • 使用时需结合品牌与设计系统,并通过预览检查文本溢出与对齐。
  • godot-ui-theming 属于前端设计类 Skill,可作为该场景下的辅助能力补充。

SKILL.md

UI Theming

Theme resources, StyleBox styling, font management, and override system define consistent UI visual identity.

Available Scripts

global_theme_manager.gd

Expert theme manager with dynamic switching, theme variants, and fallback handling.

ui_scale_manager.gd

Runtime theme switching and DPI/Resolution scale management.

theme_swapper.gd

Dynamic Dark/Light mode implementation using cascading theme root propagation.

danger_button_assignment.gd

Expert use of theme_type_variation for semantic UI styling without scene duplication.

dynamic_stylebox_color.gd

Safe runtime StyleBox modification. Demonstrates the critical duplicate() pattern for isolated overrides.

procedural_theme_safe.gd

Reliable theming for generated UI elements using NOTIFICATION_THEME_CHANGED.

custom_chart_drawing.gd

Pattern for reading active Theme properties (colors, fonts) in custom _draw() logic.

theme_isolation.gd

Ensuring HUD consistency by isolating nodes from parent themes and referencing Project Defaults.

pulsating_ui_theme.gd

Animating UI styles via Tweens. Targets StyleBox properties directly after duplication.

crisp_ui_scaler.gd

High-quality resolution-independent scaling using content_scale_factor to maintain font crispness.

memory_safe_custom_drawing.gd

Fixing the "disappearing stylebox" bug by caching resources at the class level for the RenderingServer.

rtl_theme_mirroring.gd

Bi-directional (RTL/LTR) UI support. Swaps theme variants dynamically based on layout direction.

NEVER Do in UI Theming

  • NEVER create StyleBox in _ready() for many nodes — Instantiating StyleBoxFlat.new() 100 times creates 100 unique objects. Use a Theme resource for shared heritage.
  • NEVER forget theme inheritance — Parent themes are ignored if a child has its own theme. Apply themes at the root and use theme_type_variation for specific overrides.
  • NEVER hardcode colors in StyleBox — Use theme.get_color() to maintain a single source of truth for your palette.
  • NEVER use add_theme_override for global styles — This is brittle. Define styles in a Theme resource for automatic propagation across the project.
  • NEVER modify theme resources during _draw() OR _process() — Frequent layout recalculations will severely degrade performance.
  • NEVER assign StyleBoxEmpty to focus styles without a fallback — This invisibly breaks controller/keyboard navigation [1]. Always provide a visible alternative (e.g. scale change).
  • NEVER use standard set() for theme properties — Calling node.set("font_color", red) fails. You MUST use the dedicated add_theme_color_override() API [3].
  • **NEVER use expand_margin_* to increase clickable area** — It only expands the VISUAL bounds. Use content_margin_* on the StyleBox or adjust the Control's size to ensure input works [5].
  • NEVER define StyleBoxes as local variables inside _draw() — They will be garbage collected before the RenderingServer can finish drawing them [7]. Store at class level.
  • NEVER duplicate scenes/themes just to change one color — Use theme_type_variation to create lightweight derived styles (e.g. "DangerButton") within the same Theme [8].
  • NEVER skip corner_radius_all shortcut — It's a useful shorthand for uniform rounding in StyleBoxFlat.

  1. Project Settings → GUI → Theme
  2. Create new Theme resource
  3. Assign to root Control node
  4. All children inherit theme

StyleBox Pattern

# Create StyleBoxFlat for buttons
var style := StyleBoxFlat.new()
style.bg_color = Color.DARK_BLUE
style.corner_radius_top_left = 5
style.corner_radius_top_right = 5
style.corner_radius_bottom_left = 5
style.corner_radius_bottom_right = 5

# Apply to button
$Button.add_theme_stylebox_override("normal", style)

Font Loading

# Load custom font
var font := load("res://fonts/my_font.ttf")
$Label.add_theme_font_override("font", font)
$Label.add_theme_font_size_override("font_size", 24)

Reference

Related

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

39.11%
按下载量换算495

Claude

29.15%
按下载量换算369

Cursor

19.49%
按下载量换算247

Gemini CLI

9.64%
按下载量换算122

安全审计

Gen Agent Trust Hub

可疑

Socket

通过

Snyk

通过

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在 warning/failed 结果,不能写成本站确认安全。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills