Logo von Qt MCP Plugin

Qt MCP Plugin

Community
davecotter

A plugin for Qt Creator that implements Model Context Protocol, allowing AI to talk to the IDE

Herausgeberdavecotter
RepositoryQt-Creator-MCP-Plugin
SpracheC++
Forks
5
Sterne
16
Verfügbare Tools
0
Transporttypstreamable-http
Kategorien
LizenzMIT
Links
  • Tools mit KI-Workflows verbinden

    Qt MCP Plugin stellt MCP-Funktionen bereit, die kompatible KI-Clients und Agenten nutzen können.

  • 0 verfügbare Tools

    Sehen Sie sich unten die aufrufbaren Aktionen an, einschließlich Namen und Beschreibungen, sofern der Server diese bereitstellt.

  • Konfiguration zum Kopieren

    Nutzen Sie die Installationsbeispiele, um diesen Server in Ihrem bevorzugten MCP-Client zu konfigurieren.

  • Open-Source-Kennzahlen

    16 Sterne und 5 Forks im verlinkten Repository.

Qt MCP Plugin

A Qt Creator plugin that implements the Model Context Protocol (MCP), allowing AI assistants to control Qt Creator for debugging, building, and project management.

AI-First Development

This plugin is designed to be extended by AI assistants. Simply ask your AI to:

Build and install the Qt MCP Plugin
Add new MCP commands for [your specific needs]
Test the plugin and verify MCP server is working

What It Does

The plugin adds a Tools -> MCP Plugin menu (with icon) to Qt Creator and runs an MCP server on port 3001. AI assistants can:

  • Build & Debug: Start builds, debug sessions, run projects
  • Project Management: Load sessions, switch build configs, list projects
  • File Operations: Open files, list open files, manage editor state
  • Issue Tracking: List build errors and warnings; get structured diagnostics (JSON) for Cursor Problems panel
  • Discovery: Use standard MCP protocol to discover available tools

Quick Start

Prerequisites: Qt Creator with Qt Plugin Development components, CMake 3.16+, C++20 compiler

Platform Support: Windows, macOS, Linux

Build & Install:

bash
python3 scripts/build/build_main.py

The build script handles everything:

  • Quits Qt Creator and cleans old versions
  • Auto-detects Qt version from Qt Creator binary (no manual configuration)
  • Verifies matching Qt SDK is installed
  • Builds, installs, and verifies the plugin
  • Registers with Cursor IDE automatically

After a successful build, restart Cursor to enable AI control of Qt Creator.

For AI Assistants: See .cursorrules for detailed build instructions and troubleshooting.

Repository structure

PathContents
src/source/C++ implementation (.cpp, .mm)
src/header/C++ headers
src/resources/mcp.qrc, mcp.png, translations
src/*.inPlugin JSON and version templates
scripts/build/Build and Qt config (build_main.py, qt_config.py)
scripts/test/Test suite and build-diagnostics tests
scripts/installer/macOS installer app and scripts
scripts/git/Git credential helper for pushes
documentation/AGENTS.md, TESTING.md, and other docs
.qt/Qt path config per platform (see .qt/README.md)

Build output and logs go to build/ and logs/ (gitignored).

Build diagnostics (Cursor Problems panel)

The plugin exposes structured build diagnostics so Cursor (or other MCP clients) can show Qt Creator build errors and warnings in the Problems panel:

  • MCP tool: getBuildDiagnostics - Returns a JSON array of { file, line, column, message, severity, code } per issue (pretty-printed). Optional filter: "all", "errors", or "warnings".
  • Menu: Tools -> MCP Plugin -> Get Build Diagnostics (JSON) - Runs the same and shows the JSON in the plugin output pane so you can try it manually.

Use this from a preLaunch script on build failure, or from an extension, to fill the Problems panel with the same issues Qt Creator reports. See documentation/ for build diagnostics and other docs (e.g. documentation/TESTING.md, documentation/AGENTS.md).

Self-test: Run python3 scripts/test/test_build_diagnostics.py --inject (or python3 scripts/test/test_suite.py --build-diagnostics) to inject a syntax error, build via MCP, then assert getBuildDiagnostics returns the error. Requires Qt Creator running with a project open.

Architecture

Cross-Platform Menu Icons

The plugin displays an icon in the Tools -> MCP Plugin menu. Menu icon handling is platform-specific:

  • macOS: Uses native AppKit APIs (macos_menu_icon.mm) to force icon display, as Qt may hide menu icons per Apple HIG
  • Windows/Linux: Uses Qt native icon support via stub implementation (platform_menu_icon.cpp)

Source Files

All plugin source lives under src/: headers in src/header/, implementation in src/source/, resources in src/resources/.

FilePurpose
src/source/qt_mcp_plugin.cppMain plugin entry point, menu setup
src/source/mcpserver.cpp, src/header/mcpserver.hHTTP server on port 3001
src/source/mcpcommands.cpp, src/header/mcpcommands.hMCP tool implementations
src/source/macos_menu_icon.mm, src/header/macos_menu_icon.hmacOS native menu icon support
src/source/platform_menu_icon.cppWindows/Linux menu icon stub
src/source/issuesmanager.cpp, src/header/issuesmanager.hBuild issues tracking (list + structured JSON)
src/source/httpparser.cpp, src/header/httpparser.hHTTP request parsing
src/source/httpresponse.cpp, src/header/httpresponse.hHTTP response generation

Extending the Plugin

Let AI do the work: The plugin is designed for AI-assisted development. Describe what you want to add and let your AI assistant:

  1. Add new MCP commands in src/source/mcpcommands.cpp and src/header/mcpcommands.h
  2. Register tools in src/source/mcpserver.cpp (both tool-list blocks if present)
  3. Expose in the UI (each new MCP tool should be discoverable without reading source):
    • Menu: When it makes sense for a user to trigger the action from Qt Creator, add a Tools → MCP Plugin item in src/source/qt_mcp_plugin.cpp and an action id in src/header/qt_mcp_pluginconstants.h, following existing commands.
    • About dialog: If a menu entry is not appropriate (metadata-only helpers, rarely used plumbing, or anything awkward as a standalone action), document the tool in the About MCP Plugin dialog (MCPServerStatusDialog in qt_mcp_plugin.cpp, opened from Tools → MCP Plugin → About MCP Plugin).
  4. Test using the MCP server or Tools -> MCP Plugin menu

Example AI prompts:

Add an MCP command to open the current file in an external editor
Create a command to export the current project as a standalone executable
Add debugging commands to set breakpoints and inspect variables

MCP Protocol

Standard MCP methods:

  • initialize - Server handshake and capabilities
  • tools/list - Discover available tools with schemas
  • tools/call - Execute tools (build, debug, load sessions, get build diagnostics, etc.)

Server runs on: localhost:3001

Cursor IDE Integration

The build script automatically registers the Qt MCP server with Cursor IDE by adding it to ~/.cursor/mcp.json. After building:

  1. Restart Cursor to activate the MCP connection
  2. Start Qt Creator (plugin loads automatically)
  3. Use AI commands like:
    • "Build the current Qt project"
    • "List build errors and warnings"
    • "Get structured build diagnostics for the Problems panel"
    • "Open file main.cpp in Qt Creator"
    • "Switch to Debug configuration"

Manual registration (if needed):

json
{
  "mcpServers": {
    "qt-creator": {
      "url": "http://localhost:3001",
      "description": "Qt Creator MCP Plugin - AI control of Qt Creator IDE"
    }
  }
}

Troubleshooting

Plugin not loading? Check Help -> About Plugins in Qt Creator

MCP server not responding? Ensure Qt Creator is running with plugin loaded

Need help? Ask your AI assistant - the build system is fully automated and designed for AI-assisted development.

License

This project is licensed under the MIT License - see the included LICENSE file for details.

Qt MCP Plugin MCP mit mehreren KI-Modellen nutzen

TypingMind bindet MCP-Tools auf Arbeitsbereichsebene ein. Sobald Qt MCP Plugin verbunden ist, können Sie die Integration mit verschiedenen KI-Modellen in TypingMind verwenden, statt sie für jedes Modell separat einzurichten. Diese MCP-Integration verbindet sich in TypingMind über die URL eines extern gehosteten MCP-Servers.

Eine MCP-Server-URL hinzufügen

Nutzen Sie diese Option, wenn Qt MCP Plugin bereits auf einem Remote-Server gehostet wird oder Ihr Team einen gemeinsamen Konnektor für mehrere Benutzer benötigt.

1

MCP-Konnektoren öffnen

Gehen Sie in TypingMind zu „Plugins“, öffnen Sie „MCP-Konnektoren“ und wählen Sie dann „URL hinzufügen“.

  1. Öffnen Sie TypingMind in Ihrem Browser.
  2. Gehen Sie zu „Plugins“.
  3. Öffnen Sie „MCP-Konnektoren“.
  4. Klicken Sie auf „Neue URL“.
TypingMind-Formular zum Hinzufügen einer benutzerdefinierten MCP-Server-URL
2

Server-URL einfügen

Geben Sie die MCP-Server-URL des Anbieters in das Feld „Server-URL“ ein. Fügen Sie einen Verbindungsnamen, eine Beschreibung, ein Symbol, benutzerdefinierte HTTP-Header oder OAuth-Client-Einstellungen hinzu, falls der Server diese erfordert.

  1. Fügen Sie die MCP-Server-URL des Anbieters in das Feld „Server-URL“ ein.
  2. Geben Sie einen Verbindungsnamen für Qt MCP Plugin ein.
  3. Fügen Sie bei Bedarf eine Beschreibung und ein Symbol hinzu, um die Verbindung leichter zu erkennen.
  4. Fügen Sie benutzerdefinierte HTTP-Header oder OAuth-Client-Daten hinzu, falls der Server eine Authentifizierung erfordert.
3

Verbindung erstellen

Klicken Sie auf „Verbindung erstellen“, kehren Sie dann zur Plugin-Liste zurück und prüfen Sie, ob die neue MCP-Verbindung aktiv ist.

  1. Klicken Sie auf „Verbindung erstellen“.
  2. Kehren Sie zur Liste der MCP-Konnektoren zurück.
  3. Prüfen Sie, ob die Verbindung zu Qt MCP Plugin als aktiv angezeigt wird.
  4. Aktualisieren Sie die Plugin-Liste, falls die Verbindung nicht sofort angezeigt wird.
4

Modelle ohne erneuten Verbindungsaufbau wechseln

Starten Sie einen Chat mit Ihrem bevorzugten Modell, aktivieren Sie unter „Plugins“ die Tools von Qt MCP Plugin und wechseln Sie bei Bedarf zu einem anderen Modell. Die MCP-Verbindung bleibt im TypingMind-Arbeitsbereich verfügbar.

  1. Starten Sie einen neuen Chat in TypingMind.
  2. Wählen Sie das KI-Modell, das Sie verwenden möchten.
  3. Aktivieren Sie die Tools von Qt MCP Plugin unter „Plugins“.
  4. Bitten Sie das Modell, das Tool bei Bedarf zu verwenden.
  5. Wechseln Sie zu einem anderen KI-Modell und verwenden Sie dieselbe MCP-Verbindung weiter.
TypingMind-Chat mit aktivierten MCP-Tools und einem ausgewählten KI-Modell
Können Sie mir mit Qt MCP Plugin bei dieser Aufgabe helfen?
Qt MCP Plugin
Gerne. Ich habe es gelesen.
Das habe ich mit Qt MCP Plugin gefunden.

Häufig gestellte Fragen

Wofür wird der MCP-Server Qt MCP Plugin verwendet?

Qt MCP Plugin ist ein MCP-Server, über den kompatible KI-Clients auf externe Tools und Kontext zugreifen können. In TypingMind können Sie diesen MCP-Server einmal hinzufügen und seine Tools in Ihrem KI-Arbeitsbereich verfügbar machen.

Kann ich Qt MCP Plugin MCP mit mehreren KI-Modellen in TypingMind verwenden?

Ja. TypingMind bindet MCP-Tools auf Arbeitsbereichsebene ein. So können Sie Qt MCP Plugin mit verschiedenen KI-Modellen wie Claude, ChatGPT, Gemini oder anderen in TypingMind konfigurierten Modellen verwenden, ohne den MCP-Server für jedes Modell separat einzurichten.

Warum Qt MCP Plugin MCP mit TypingMind nutzen?

TypingMind ist eine der besten Oberflächen für LLM-Chats, da es mehrere KI-Modelle, Prompts, Plugins, KI-Agenten, API-Schlüssel und MCP-Tools in einem Arbeitsbereich vereint. Sobald Qt MCP Plugin verbunden ist, können Sie die zugehörigen MCP-Tools mit Ihren bevorzugten Modellen nutzen und Ihre Chat-Abläufe in TypingMind übersichtlich organisieren.

Wie verbinde ich Qt MCP Plugin MCP mit TypingMind?

Sie können Qt MCP Plugin in TypingMind verbinden, indem Sie die URL des gehosteten MCP-Servers hinzufügen. Das ist sinnvoll, wenn Sie eine entfernte MCP-Verbindung benötigen, die in Ihrem TypingMind-Arbeitsbereich verfügbar ist.

Welche Tools stellt Qt MCP Plugin MCP in TypingMind bereit?

Qt MCP Plugin stellt MCP-Funktionen bereit, die Sie auf der Plugins-Seite in TypingMind aktivieren und im Chat verwenden oder KI-Agenten zuweisen können.

Muss ich meine API-Schlüssel mit TypingMind teilen, um Qt MCP Plugin MCP zu verwenden?

Nein. TypingMind arbeitet vorrangig lokal, sodass Sie die Kontrolle über Ihre Modellanbieter, API-Schlüssel, Prompts und MCP-Konfiguration behalten. Falls Qt MCP Plugin eine Authentifizierung erfordert, fügen Sie beim Erstellen der Verbindung die erforderlichen Header, OAuth-Einstellungen oder die lokale Konfiguration für diesen MCP-Server hinzu.

Ähnliche MCP-Server

Alle

Jetzt eigenen KI-Arbeitsbereich einrichten

Abonnieren Sie unseren Newsletter und erfahren Sie mehr über neue Funktionen und kommende Gewinnspiele 👇