Skip to main content

Introducing the Qt Widget to Qt Quick Skill: Automating 80% of Porting

Comments

Moving an existing Qt Widgets user interface to Qt Quick is a big investment. Every screen, dialog, menu and toolbar has to be rebuilt. Every custom-drawn element has to be redesigned. The application logic that sits tangled up with the screens has to be separated out, the project setup has to be reworked, and the result has to be compared with the original screen by screen to make sure nothing was lost. For applications that want a modern, fluid, touch-friendly interface, this adds up to weeks and months of repetitive work that few teams have room for.

The new qt-widgets-to-quick skill brings agentic development to this problem. It guides an AI coding agent through the whole conversion, from taking stock of the existing application to delivering a Qt Quick version that builds, runs and has been checked against the original. As the code should be built with Qt 6.12, you are one step closer to EU CRA compliance.

QtWidget to Quick Conversion Skill

What the Skill Gives You

The skill automates around 80% of the work of porting a Qt Widgets UI to Qt Quick. It might do 95% of the port but how much depends finally on the source widget UI. Screens, layouts, dialogs, menus, shortcuts, data handling and custom-drawn elements are converted by the agent and verified by building and running the result. What it will not port for you are the parts that have no direct equivalent in Qt Quick or that need a product or design decision: native system dialogs, window-docking experiences, and heavily customized graphical editors. The agent lists these explicitly instead of silently leaving them out.

The skill is optimized to write best-practice Qt Quick code. The result follows the way Qt recommends building modern interfaces, keeps the application logic cleanly separated from the user interface, adapts to the system's light and dark themes, and is checked with Qt's own quality tools. Your team receives a codebase that is a sound basis for future development, not a one-off translation.

If you need pixel-perfection, ask the agent for an additional round of visual comparison between the original and the port. The agent then compares screenshots of both applications and fine-tunes spacing, margins and alignment until the differences are gone.

How long the conversion takes depends on the size of the application. A small project can be converted in about an hour, while bigger projects take several hours and are done in several steps.

How the Skill Ports Your Application

The skill works through eight steps and builds the project after each stage, so problems are caught early.

  1. Take stock. The agent surveys the existing application: its screens, custom elements, user actions and shortcuts, data handling and settings. This makes sure no feature is forgotten.
  2. Plan the new structure. Each part of the application is assigned to its place in the new design: interface parts are rebuilt in Qt Quick, while data and business logic are kept and reused.
  3. Convert the application shell. The main window, menus and toolbars are rebuilt in Qt Quick.
  4. Convert the screens. Standard interface elements and layouts are replaced with their Qt Quick counterparts. Texts, tab order, default values and initial states are kept exactly as they were.
  5. Connect the logic. Existing business logic is kept and linked to the new interface. Logic that was mixed into the old main window is separated out so it can be reused.
  6. Convert custom-drawn elements. Elements that were drawn by hand are rebuilt to use the graphics hardware for smooth rendering. Custom QWidgets (using QPainter) are ported to QCanvasPainterItems (using QCanvasPainter). Among other things, this also makes the custom widgets hardware-accelerated with GPU.
  7. Convert looks and resources. Styling, icons, images and translations are carried over.
  8. Verify. The agent builds both the original and the new application, fixes warnings, starts the app and treats every error as a defect. It then compares screenshots of the two, checks light and dark mode, and tries out every action, shortcut and dialog of the original.

WidgetQuickConverted Qwen4Max

The Rules the Skill Follows

Beside the workflow, the skill carries a set of rules that keep the output consistent from one project to the next:

  • The old technology is fully removed from the result, unless you explicitly choose a step-by-step hybrid approach.
  • The visual style is set in one central place, mirroring the look of the original, instead of being scattered through the code.
  • Colors follow the system theme instead of being fixed in the code.
  • Behavior stays identical first. Improvements come afterwards and are reported. Quirks of the original are mentioned, not silently fixed.
  • Large applications are converted in stages, with the build and tests working at each step.
  • The agent checks the Qt documentation instead of relying on memory.

Limitations of the Skill

The skill automates around 80% of the conversion, not all of it. It might be able to do more but that depends on your UI. What typically remains for your team are native system dialogs, window-docking experiences that have to be rebuilt, and graphical editors that need design decisions. The agent lists each of these in its final report.

The visual comparison depends on a multi-modal AI model that can interpret screenshots.

Tested With

The skill has been tested with Claude Sonnet 5.5 and Opus 5.5 in Claude Code CLI, with GPT 6.2 Terra and Gemini 4 Hydrogen in GitHub Copilot in VS Code, and with Qwen 4 Max and DeepSeek 4.1 Flash in Qwen Code CLI.

Getting the Skill

The qt-widgets-to-quick skill is available in the Qt agent-skills repository on the GitHub repo (TheQtCompanyRnD/agent-skills) and as part of the “qt-development” plugin on the Claude marketplace.

 

Comments

Subscribe to our blog

Try Qt 6.12 Now!

Download the latest release here: www.qt.io/download

Qt 6.12 LTS is now available, with new features and improvements for application developers and device creators.

We're Hiring

Check out all our open positions here and follow us on Instagram to see what it's like to be #QtPeople.