Logo FluentUI

PaneItem QML Type

A navigation destination item. More...

Import Statement: import FluentUI.Controls 1.0

Properties

Signals

Methods

Detailed Description

PaneItem represents a single navigable destination within a NavigationView. It displays a title and optional icon, count badge, and info badge. When tapped, it triggers navigation to the associated URL. PaneItem can also be disabled or hidden as needed.

Usage Example

 import QtQuick
 import FluentUI.Controls

 PaneItem {
     title: "Home"
     icon: "home"
     key: "home"
     url: "qrc:/page/HomePage.qml"
     count: 3
 }

Property Documentation

count : int

An optional numeric count displayed as a badge on the item.

enabled : bool

Whether the item is interactive. Defaults to true. When false, the item cannot be tapped and appears visually disabled.

icon : var

The icon source for the navigation item. Can be a string name or a URL.

iconColor : color

The color of the item's icon.

iconFamily : string

The icon font family used for the item's icon.

iconSpacing : int

The spacing between the icon and the title text.

infoBadge : Component

An optional Component providing a custom badge displayed on the item.

key : string

A unique string identifier for this navigation item. Used for route matching and programmatic navigation.

title : string

The display title of the navigation item.

url : url

The URL associated with this navigation destination, resolved by the PageRouter when navigating.

visible : bool

Whether the item is visible in the navigation. Defaults to true. When false, the item is hidden from the navigation list.

Signal Documentation

void tap()

Emitted when the item is tapped by the user or programmatically.

Note: The corresponding handler is onTap.

Method Documentation

bool canTap()

Returns true if the item can be tapped (is enabled and visible).

void tap()

Programmatically triggers the tap action on this item.