qt-qml-attachments

Installation
SKILL.md

Qt Qml Attachments

Overview

Fix and tune QML chat attachment layouts so chips/images wrap in rows, align to the correct side, preserve ordering, and keep message bubbles from stretching full width.

Quick Diagnosis

  • If attachments stack vertically, the Flow likely has no usable width. Avoid binding Flow.width to its own implicitWidth.
  • If the row aligns left when it should align right, check layoutDirection, anchors, and model order.
  • If bubbles appear full-width, clamp Layout.preferredWidth and Flow width to a max ratio or fixed pixel cap.

Flow Width & Wrap

  • Give Flow an explicit width based on available space (e.g., chatArea.width - margins).
  • Use Math.max(0, ...) to avoid negative widths during resize.
  • For the container height, prefer implicitHeight over height when it’s driven by a Flow.

Example:

Related skills
Installs
17
First Seen
Jan 28, 2026