본문으로 건너뛰기
Skillpedia
웹사이트 및 UI (프런트엔드)48k · #5151

makepad-platform

하는 일

이 도구는 Makepad 플랫폼을 사용해 여러 운영체제(Windows, macOS, Linux, Android, iOS, 웹)를 위한 코드를 이해하고 작성하는 데 도움을 줍니다. 지원되는 시스템과 각 시스템에 코드가 어떻게 맞춰지는지 설명합니다.

사용하는 경우

  • ✓Makepad 앱이 어떤 시스템(모바일, 데스크톱, 웹)에서 실행되는지 알고 싶을 때.
  • ✓특정 시스템에서만 작동하는 코드 부분(예: Windows 전용)을 작성해야 할 때.
  • ✓Makepad가 각 시스템에서 Metal, OpenGL 같은 그래픽 기술을 어떻게 사용하는지 이해하고 싶을 때.

스킬 링크

https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/makepad-platform/SKILL.md

복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.

사용 방법

가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.

바로 붙여넣을 수 있는 메시지

Use this skill to help me: https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/makepad-platform/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
AI가 이런 스킬을 알아서 찾아 쓰길 원하시나요?무료 Skillpedia MCP를 설치하세요. 한 줄이면 작업마다 스킬 15,000+개 중에서 검색합니다.1분 만에 설치 →

AI에게 요청하는 예시

“제 Makepad 앱이 Android와 웹 브라우저에서 모두 작동하도록 하려면 어떻게 하나요?”

매주 새 스킬 5개. 읽는 데 1분.

작동 방식

AI는 Makepad가 지원하는 플랫폼에 대한 정보와 코드를 어떻게 맞출 수 있는지 확인합니다. Makepad에 대한 일반 지식과, 가능하다면 문서 파일의 구체적인 정보를 함께 사용합니다.

기술 내용 (원본 SKILL.md)

작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.

Supporting material availability

This catalog copy contains the inline guidance below, but does not include the following supporting paths. They are external prerequisites, not bundled files:

  • ./references/platform-support.md

Ask for the original supporting material or an existing installation before using a step that depends on these paths; this catalog does not identify a verified download source for them. Resolve each path relative to that installation, inspect its contents, and verify any applicable license and execution prerequisites. Do not run a command or claim a referenced procedure was followed until its required file exists. Do not fabricate the missing scripts or treat an unrelated file with the same name as equivalent. Independent steps fully documented here can proceed within the user’s authorized scope; report any dependent step as unavailable.

Makepad Platform Skill

Version: makepad-widgets (dev branch) | Last Updated: 2026-01-19

Check for updates: https://crates.io/crates/makepad-widgets

You are an expert at Makepad cross-platform development. Help users by:

  • Understanding platforms: Explain supported platforms and backends
  • Platform-specific code: Help with conditional compilation and platform APIs

When to Use

  • You need to understand or target specific platforms and graphics backends in Makepad.
  • The task involves platform compatibility, conditional compilation, or OS-specific behavior across desktop, mobile, or web.
  • You need guidance on backend differences such as Metal, D3D11, OpenGL, WebGL, or platform modules.

Documentation

Refer to the local files for detailed documentation:

  • ./references/platform-support.md - Platform details and OsType

IMPORTANT: Documentation Completeness Check

Before answering questions, Claude MUST:

  1. Read the relevant reference file(s) listed above
  2. If file read fails or file is empty:
    • Inform user: "本地文档不完整,建议运行 /sync-crate-skills makepad --force 更新文档"
    • Still answer based on SKILL.md patterns + built-in knowledge
  3. If reference file exists, incorporate its content into the answer

Supported Platforms

Platform Graphics Backend OS Module
macOS Metal apple/metal_*.rs, apple/cocoa_*.rs
iOS Metal apple/metal_*.rs, apple/ios_*.rs
Windows D3D11 mswindows/d3d11_*.rs, mswindows/win32_*.rs
Linux OpenGL linux/opengl_*.rs, linux/x11*.rs, linux/wayland*.rs
Web WebGL2 web/*.rs, web_browser/*.rs
Android OpenGL ES android/*.rs
OpenHarmony OHOS open_harmony/*.rs
OpenXR VR/AR open_xr/*.rs

OsType Enum

pub enum OsType {
    Unknown,
    Windows,
    Macos,
    Linux { custom_window_chrome: bool },
    Ios,
    Android(AndroidParams),
    OpenHarmony,
    Web(WebParams),
    OpenXR,
}

// Check platform in code
fn handle_event(&mut self, cx: &mut Cx, event: &Event) {
    match cx.os_type() {
        OsType::Macos => { /* macOS-specific */ }
        OsType::Windows => { /* Windows-specific */ }
        OsType::Web(_) => { /* Web-specific */ }
        _ => {}
    }
}

Platform Detection

// In Cx
impl Cx {
    pub fn os_type(&self) -> OsType;
    pub fn gpu_info(&self) -> &GpuInfo;
    pub fn xr_capabilities(&self) -> &XrCapabilities;
    pub fn cpu_cores(&self) -> usize;
}

Conditional Compilation

// Compile-time platform detection
#[cfg(target_os = "macos")]
fn macos_only() { }

#[cfg(target_os = "windows")]
fn windows_only() { }

#[cfg(target_os = "linux")]
fn linux_only() { }

#[cfg(target_arch = "wasm32")]
fn web_only() { }

#[cfg(target_os = "android")]
fn android_only() { }

#[cfg(target_os = "ios")]
fn ios_only() { }

Platform-Specific Features

Desktop (macOS/Windows/Linux)

  • Window management (resize, minimize, maximize)
  • File dialogs
  • System menu
  • Drag and drop
  • Multiple monitors

Mobile (iOS/Android)

  • Touch input
  • Virtual keyboard
  • Screen orientation
  • App lifecycle (foreground/background)

Web (WebGL2)

  • DOM integration
  • Browser events
  • Local storage
  • HTTP requests

Entry Point

// App entry macro
app_main!(App);

pub struct App {
    ui: WidgetRef,
}

impl LiveRegister for App {
    fn live_register(cx: &mut Cx) {
        // Register components
        crate::makepad_widgets::live_design(cx);
    }
}

impl AppMain for App {

…
자주 묻는 질문

‘그래픽 백엔드’란 무엇인가요?

Makepad가 각 시스템에서 화면에 그림을 그리기 위해 사용하는 기술입니다. 예를 들어 Metal(Apple), D3D11(Windows), OpenGL(Linux, Android)이 있습니다.

코드는 자신이 어떤 시스템에서 실행되는지 어떻게 아나요?

두 가지 방법이 있습니다. 실행 중(런타임)에 `cx.os_type()`을 사용해 확인하거나, 빌드 전(컴파일 타임)에 `#[cfg(target_os = '...')]`를 사용해 확인합니다.

‘Makepad 크로스 플랫폼’은 무슨 뜻인가요?

여러 운영체제(데스크톱, 모바일, 웹)에서 작동하는 코드를, 각 시스템마다 다시 작성하지 않고 쓸 수 있다는 뜻입니다.

상세 정보

작성자의 원본 설명

CRITICAL: Use for Makepad cross-platform support. Triggers on: makepad platform, makepad os, makepad macos, makepad windows, makepad linux, makepad android, makepad ios, makepad web, makepad wasm, makepad metal, makepad d3d11, makepad opengl, makepad webgl, OsType, CxOs, makepad 跨平台, makepad 平台支持

repo: sickn33/agentic-awesome-skills

인기도

GitHub 스타
48k
순위
#5151
라이선스
MIT
업데이트
2026. 10. 15.

이 스킬이 유용한가요?

0

로그인 투표하려면 로그인하세요.

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬