Logo de Godot Ui

Godot Ui

Comunidade
jame581
godot-ui

Use ao criar interfaces de usuário — nós Control, temas, âncoras, contêineres e padrões de layout

Add to TypingMind

Visão geral

Publicado porjame581
RepositórioGodotPrompter
Nome da habilidadegodot-ui
Estrelas
808
Forks
47
Arquivos incluídos
6
LicençaMIT
Links
  • Instruções em Markdown

    Um arquivo SKILL.md que o modelo carrega sob demanda, consumindo tokens apenas quando uma solicitação é realmente relevante para a habilidade.

  • Funciona com qualquer LLM

    As habilidades de IA são escritas em Markdown simples, não em código específico de um provedor. Por isso, funcionam com GPT, Claude, Gemini, Grok ou um modelo local.

  • Arquivos incluídos: 6

    Scripts, templates e referências que o modelo pode ler enquanto trabalha. Os arquivos são somente para leitura e nunca são executados.

  • Código aberto

    Publicada por jame581 no GitHub. Leia os arquivos da habilidade antes de instalá-la.

Instalação

Instale a habilidade de IA Godot Ui no TypingMind para usá-la com qualquer LLM ou adicione-a a outro agente que leia SKILL.md.

1

Instalar no TypingMind

O TypingMind instala uma habilidade diretamente da pasta dela no GitHub — lê o arquivo SKILL.md, reúne os arquivos de recursos em um pacote e armazena o resultado localmente.

  1. Abra o app e vá para Plugins → Habilidades.
  2. Escolha "Instalar do GitHub".
  3. Cole a URL abaixo, que aponta para a pasta da habilidade, e confirme.
    https://github.com/jame581/GodotPrompter/tree/master/skills/godot-ui
  4. Ative a habilidade em cada chat em que quiser disponibilizá-la.
Plugins → Habilidades → Adicionar habilidade → Via URL do GitHub. Depois, cole a URL da pasta e pressione Continuar.
2

Instalar em outro agente

Qualquer agente que leia o formato Agent Skills pode usar esta habilidade — copie a pasta para o diretório de habilidades desse agente.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/jame581/GodotPrompter.git /tmp/GodotPrompter
mkdir -p .claude/skills
cp -r /tmp/GodotPrompter/skills/godot-ui .claude/skills/godot-ui
Reinicie Claude Code após copiar para que a nova habilidade seja reconhecida.

Use no TypingMind

Ative Godot Ui em qualquer chat do TypingMind e o modelo cuida do resto. O nome e a descrição da habilidade ficam no prompt do sistema e, assim que uma solicitação relevante aparece, o modelo carrega as instruções completas automaticamente — sem precisar de acionamento manual e sem consumir tokens até que ela seja realmente usada.

O modelo carrega Godot Ui automaticamente assim que uma solicitação é relevante para essa habilidade.

Funciona com qualquer modelo de IA

Habilidades de IA são instruções em Markdown simples, não código específico de um provedor. Por isso, Godot Ui não fica vinculada ao modelo para o qual foi criada. Instale-a uma vez no TypingMind e use-a com GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama ou um modelo local executado por conta própria — tudo com suas próprias chaves de API.

  • Carregada apenas quando necessário

    O prompt do sistema contém apenas o nome e a descrição. As instruções são buscadas na primeira solicitação relevante, então uma habilidade sem uso não gera custo.

  • Troque de modelo durante a conversa

    Como a habilidade é composta de instruções, não de código, trocar de modelo não afeta seu funcionamento — o próximo modelo lê o mesmo arquivo SKILL.md.

Instruções da habilidade

Este é o conteúdo de SKILL.md que o modelo carrega. Leia antes de instalar — uma habilidade é um conjunto de instruções que seu modelo seguirá.

Godot UI — Control Nodes, Themes & Layout

All examples target Godot 4.3+ with no deprecated APIs; GDScript first, then C#.

Related skills: responsive-ui for multi-resolution scaling, hud-system for in-game HUD patterns, dialogue-system for dialogue UI presentation, tween-animation for UI transition and animation effects.


1. Control Node Hierarchy

How Control Differs from Node2D

Control is the base class for all UI nodes — it lives in a separate scene-tree branch from Node2D/Node3D with a fundamentally different layout model.

FeatureNode2DControl
Position modelWorld-space position (pixels from parent)Anchor + offset relative to parent rect
SizeNo intrinsic sizeHas size, minimum_size, custom_minimum_size
ThemeNoneInherits and overrides Theme resources
FocusNot applicableBuilt-in focus system (focus_mode, grab_focus())
Mouse eventsManual via _inputgui_input, mouse_entered, mouse_exited
Layout helpersNoneContainer subclasses auto-arrange children

Control as Base Class

Every UI widget (Button, Label, LineEdit, etc.) extends Control. Key properties defined on Control itself:

  • anchor_left, anchor_top, anchor_right, anchor_bottom — fractional values (0.0–1.0) relative to the parent rect
  • offset_left, offset_top, offset_right, offset_bottom — pixel offsets applied after the anchor resolves
  • size_flags_horizontal, size_flags_vertical — how the node participates in Container layout
  • theme — a Theme resource; if null, walks up the tree to the nearest ancestor with one
  • focus_mode — whether the node can receive keyboard/gamepad focus

Place UI nodes inside a CanvasLayer (or directly under the scene root's built-in canvas) so they render on top of the 3D/2D world, unaffected by Camera transforms.

⚠️ Changed in Godot 4.7: Control.accessibility_live changed type from DisplayServer.AccessibilityLiveMode to AccessibilityServer.AccessibilityLiveMode (LIVE_OFF = 0 default, LIVE_POLITE, LIVE_ASSERTIVE) — accessibility enums/APIs moved to the new AccessibilityServer singleton. GDScript-compatible; breaks C# binary/source compatibility (rebuild against the new enum). See the 4.7 migration guide.


2. Common Container Nodes

ContainerPurposeWhen to Use
VBoxContainerStacks children verticallyLists, option rows, vertical menus
HBoxContainerStacks children horizontallyToolbars, stat rows, horizontal nav
GridContainerArranges children in a fixed-column gridInventory grids, key-binding tables
MarginContainerAdds padding around a single childWrapping any node to give it breathing room
PanelContainerDraws a StyleBox background, then lays out childrenCard UI, dialog boxes, HUD panels
ScrollContainerMakes its single child scrollable; clips overflowLong lists, logs, scrollable settings
TabContainerStacks children as named tabs; shows one at a timeSettings screens, multi-section panels

Sizing tips:

  • Set size_flags_horizontal = SIZE_EXPAND_FILL on children that should fill available space.
  • Use custom_minimum_size to prevent a child from collapsing to zero.
  • MarginContainer reads margin from the theme property margin_*; override at runtime with add_theme_constant_override("margin_left", 16).

Godot 4.7+: custom_maximum_size (Vector2(-1, -1)) caps size per axis, prioritized over custom_minimum_size; propagate_maximum_size (default false) makes a parent's maximum constrain its Control children; _get_maximum_size() computes maximums from code.

⚠️ Changed in Godot 4.7: TabContainer.all_tabs_in_front is deprecated — it does nothing now, since tabs are always in front. Remove code that sets it. See GH-118623.


3. Anchors & Margins

How Anchor Presets Work

An anchor is a point on the parent rect expressed as a fraction (0 = top/left edge, 1 = bottom/right edge). Godot resolves the final pixel position of each edge as:

final_left   = parent_width  * anchor_left   + offset_left
final_top    = parent_height * anchor_top    + offset_top
final_right  = parent_width  * anchor_right  + offset_right
final_bottom = parent_height * anchor_bottom + offset_bottom

The editor exposes built-in presets:

PresetAnchor valuesUse case
Full RectL=0, T=0, R=1, B=1Overlay / fill parent — most common for root UI
CenterL=0.5, T=0.5, R=0.5, B=0.5Fixed-size widget centred in parent
Top LeftL=0, T=0, R=0, B=0Fixed-size widget pinned to top-left corner
Top RightL=1, T=0, R=1, B=0Fixed-size widget pinned to top-right corner
Bottom CenterL=0.5, T=1, R=0.5, B=1HUD element anchored to bottom centre

Setting Anchors in Code

Anchors resolve as parent_size * anchor + offset per edge, so setting them by hand means setting eight properties. set_anchors_and_offsets_preset(Control.PRESET_*) does it in one call — use that, then adjust offset_* for margins (negative on right/bottom).

The anchor-vs-offset rule (keep offsets at 0 and let anchors do the work) plus full GDScript + C# examples — full-rect fill, top-right HUD with 16 px margins, and a custom half-screen side panel: references/anchors-in-code.md


4. Theme System

A Theme resource centralizes fonts, colors, and StyleBoxes. Apply at the root and let inheritance do the work; use theme_override_* only for one-off tweaks. StyleBoxFlat covers most flat-design needs (bg_color, border_color, corner_radius, border_width); StyleBoxTexture for textures.

See references/theme-system.md for the full Theme resource creation walk-through, StyleBoxFlat properties, font overrides, theme inheritance rules, and per-node theme_override_* methods.

Godot 4.7+: GradientTexture2D's Fill enum gains FILL_CONIC — colors interpolated in a cone (angular) pattern; radial progress/cooldown indicators without a shader (C#: FillEnum.Conic).


5. Focus & Navigation

Focus modes (FOCUS_NONE, FOCUS_CLICK, FOCUS_ALL) gate keyboard/gamepad navigation. Wire chains with focus_neighbor_top / _bottom / _left / _right, or rely on automatic spatial detection. Call grab_focus() on the first interactive element when a menu opens.

See references/focus-and-navigation.md for focus mode details, focus_neighbor chain examples, gamepad/keyboard input handling, and grab_focus patterns.


6. Common UI Patterns

Three canonical scenes: a main menu (centered VBoxContainer with title + button list), a settings screen with tabs (TabContainer + child panels per category), and a pause menu overlay (full-rect ColorRect background + centered options panel, paused via get_tree().paused = true).

See references/ui-patterns.md for the full scene-tree fragments and GDScript wiring for each pattern.

Godot 4.7+: offset_transform_* — visual-only UI-juice transform (shake/pulse) that never re-triggers container layout; _get_cursor_shape(at_position) — per-position cursor shapes; PopupMenu search bar (search_bar_enabled, fuzzy by default) plus set_item_index() for reordering; TextureRect STRETCH_TILE now tiles AtlasTextures (only non-zero margin unsupported). Code: references/ui-patterns.md.

⚠️ Changed in Godot 4.7: RichTextLabel.add_image() / update_image() sizing was reworked — width/height are now float; width_in_percent/height_in_percent bools become width_unit/height_unit, taking the new ImageUnit enum (IMAGE_UNIT_PIXEL, IMAGE_UNIT_PERCENT, IMAGE_UNIT_EM — em scales with font size). ImageUpdateMask.UPDATE_WIDTH_IN_PERCENT is renamed UPDATE_WIDTH_UNIT, breaking GDScript using the old name. See the 4.7 migration guide.


7. Signals

Button.pressed for clicks, Control.gui_input for raw events on a node, Control.mouse_entered / mouse_exited for hover. Connect in _ready() or via the Inspector's Node panel.

See references/signals.md for the complete signal catalog and signal-driven UI update patterns.


8. FoldableContainer (Godot 4.5+)

FoldableContainer is a built-in accordion Container added in Godot 4.5 — a toggle header plus collapsible children, replacing the old boilerplate of wiring a Button to show/hide a VBoxContainer. Set title, set folded for the initial state, add children normally, and listen to folding_changed(is_folded).

Full GDScript + C# construction, the key-properties table, and the toggle signal: references/foldable-container.md


9. Stacked Label Effects (Godot 4.5+)

Godot 4.5 lets Label and RichTextLabel layer multiple text effects simultaneously — e.g., stacking two outline effects at different widths/colors, or combining a shadow with a glow. Previously, multiple outline layers required duplicating and manually layering Label nodes.

gdscript
# Configure via Theme Overrides → Constants in the inspector, or add_theme_* overrides at runtime.
func apply_stacked_outlines(label: Label) -> void:
    # Outer outline — wide, dark
    label.add_theme_constant_override("outline_size", 6)
    label.add_theme_color_override("font_outline_color", Color(0.0, 0.0, 0.0, 0.9))

    # Shadow (second layered effect)
    label.add_theme_constant_override("shadow_offset_x", 2)
    label.add_theme_constant_override("shadow_offset_y", 2)
    label.add_theme_color_override("font_shadow_color", Color(0.0, 0.0, 0.0, 0.5))
csharp
public void ApplyStackedOutlines(Label label)
{
    // Outer outline — wide, dark
    label.AddThemeConstantOverride("outline_size", 6);
    label.AddThemeColorOverride("font_outline_color", new Color(0f, 0f, 0f, 0.9f));

    // Shadow (second layered effect)
    label.AddThemeConstantOverride("shadow_offset_x", 2);
    label.AddThemeConstantOverride("shadow_offset_y", 2);
    label.AddThemeColorOverride("font_shadow_color", new Color(0f, 0f, 0f, 0.5f));
}

For RichTextLabel, stacked effects can also be applied via BBCode combined with theme overrides:

gdscript
# Multiple outline-style effects via BBCode + theme
$RichTextLabel.text = "[outline size=4 color=#000000]Level Up![/outline]"
# Additional layers via theme overrides, as above.

Editor workflow: Configure stacked effects via Theme Editor → Label → Constants, or add multiple FontFile-style outline passes in the Font resource. The runtime API (add_theme_*_override) above covers dynamic scenarios.


10. Checklist

  • Root UI Control has anchor preset Full Rect (or appropriate preset for the layout)
  • All interactive widgets (Button, LineEdit, Slider) have focus_mode = FOCUS_ALL
  • Decorative nodes (Label, TextureRect) have focus_mode = FOCUS_NONE
  • Focus neighbours wired for non-linear layouts so gamepad navigation wraps correctly
  • grab_focus() called on the first interactive widget in _ready() for each screen
  • Pause menu root Control has process_mode = PROCESS_MODE_ALWAYS
  • One Theme resource assigned at the screen root — not duplicated on every child
  • StyleBoxFlat used instead of image assets for simple solid-colour panels
  • add_theme_*_override() used for per-node overrides rather than assigning a whole new Theme
  • Containers (VBoxContainer, HBoxContainer, etc.) used for layout instead of manual position values
  • custom_minimum_size set on widgets that must not collapse to zero
  • Slider and volume code uses linear_to_db / db_to_linear — not raw linear values mapped to audio bus
  • Signals connected in _ready() (or via the editor); no polling of UI state in _process
  • Tab order in TabContainer matches logical reading / navigation order
  • Accordion-style collapsible panels use FoldableContainer instead of manual Button + VBoxContainer wiring (Godot 4.5+)
  • Multiple outline/shadow layers on Label/RichTextLabel use stacked theme overrides instead of duplicated nodes (Godot 4.5+)

Arquivos incluídos

O modelo lê esses arquivos sob demanda enquanto a habilidade está carregada. Eles são disponibilizados para leitura e nunca são executados.

Perguntas frequentes

O que a habilidade de IA Godot Ui faz?

Use ao criar interfaces de usuário — nós Control, temas, âncoras, contêineres e padrões de layout

Por que usar Godot Ui no TypingMind?

Porque basta instalar uma vez para usar com qualquer modelo. A habilidade Godot Ui é escrita em Markdown simples, e não em código específico de um provedor, então a mesma habilidade funciona com GPT-5, Claude, Gemini, Grok ou um modelo local — e é possível trocar de modelo no meio do chat sem que ela deixe de funcionar. No TypingMind, você usa suas próprias chaves de API e paga diretamente aos provedores, em vez de pagar uma assinatura por licença de usuário. Suas habilidades e chats permanecem no seu próprio armazenamento.

Como instalar Godot Ui no TypingMind?

Abra Plugins → Habilidades → Instalar do GitHub no TypingMind e cole https://github.com/jame581/GodotPrompter/tree/master/skills/godot-ui. O TypingMind lê o arquivo SKILL.md, reúne os arquivos da habilidade e a instala para que possa ser ativada em cada chat.

Quais modelos de IA podem usar Godot Ui?

Qualquer modelo conectado no TypingMind. As habilidades de IA são instruções em Markdown simples, e não código específico de um provedor. Assim, GPT, Claude, Gemini, Grok e modelos locais podem carregar esta habilidade quando uma solicitação corresponder a ela.

Quantos modelos de IA posso usar com Godot Ui?

Quantos quiser. Desde que o modelo ofereça suporte a habilidades, é possível usar Godot Ui com ele — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama e outros — tudo no TypingMind com suas próprias chaves de API.

A habilidade de IA Godot Ui é gratuita?

Sim. A habilidade é publicada no GitHub por jame581 sob a licença MIT. O pagamento é feito apenas ao seu provedor de IA pelos tokens usados.

O que são habilidades de IA?

Uma habilidade de IA é um conjunto reutilizável de instruções que ensina um modelo de IA a realizar uma tarefa específica. Ela segue o formato aberto Agent Skills: um arquivo SKILL.md com nome e descrição, além de scripts, templates ou arquivos de referência de que o modelo possa precisar. O modelo lê as instruções apenas quando sua solicitação corresponde à habilidade, então uma habilidade instalada não gera custos até ser usada.

Qual é a diferença entre habilidades de IA e plugins ou servidores MCP?

Um plugin ou servidor MCP oferece ao modelo novas ferramentas que ele pode acionar — código que é executado em algum lugar e retorna um resultado. Já uma habilidade de IA dá ao modelo o conhecimento e as orientações de que ele precisa: como abordar uma tarefa, quais etapas seguir e como deve ser um bom resultado. As habilidades são escritas em Markdown simples, por isso não precisam de servidor, chave de API nem ambiente de execução, e funcionam com qualquer modelo.

Ver lista completa

Crie seu próprio espaço de trabalho com IA agora

Inscreva-se na nossa newsletter para receber avisos sobre novos recursos e futuros sorteios 👇