LinkButton


Object Hierarchy:

Object hierarchy for LinkButton

Description:

[ CCode ( type_id = "gtk_link_button_get_type ()" ) ]
public class LinkButton : Button, Accessible, Actionable, Buildable, ConstraintTarget

A GtkLinkButton is a Button with a hyperlink, similar to the one used by web browsers, which triggers an action when clicked.

It is useful to show quick links to resources.

A link button is created by calling either LinkButton or LinkButton.with_label. If using the former, the URI you pass to the constructor is used as a label for the widget.

The URI bound to a GtkLinkButton can be set specifically using set_uri, and retrieved using get_uri.

By default, GtkLinkButton calls show_uri when the button is clicked. This behaviour can be overridden by connecting to the activate_link signal and returning true from the signal handler.

CSS nodes

GtkLinkButton has a single CSS node with name button. To differentiate it from a plain Button , it gets the .link style class.

Accessibility

GtkLinkButton uses the BUTTON role.


Namespace: Gtk
Package: gtk4

Content:

Properties:

Creation methods:

Methods:

Signals:

Inherited Members:

All known members inherited from class Gtk.Widget