module Gtk::AppChooser

Overview

Gtk::AppChooser is an interface for widgets which allow the user to choose an application.

The main objects that implement this interface are Gtk::AppChooserWidget, Gtk::AppChooserDialog and Gtk::AppChooserButton.

Applications are represented by GIO GAppInfo objects here. GIO has a concept of recommended and fallback applications for a given content type. Recommended applications are those that claim to handle the content type itself, while fallback also includes applications that handle a more generic content type. GIO also knows the default and last-used application for a given content type. The Gtk::AppChooserWidget provides detailed control over whether the shown list of applications should include default, recommended or fallback applications.

To obtain the application that has been selected in a Gtk::AppChooser, use Gtk::AppChooser#app_info.

Direct including types

Defined in:

lib/gi-crystal/src/auto/gtk-4.0/app_chooser.cr

Constructors

Class Method Summary

Instance Method Summary

Constructor Detail

def self.cast(obj : GObject::Object) : self #

Cast a GObject::Object to self, throws a TypeCastError if the cast can't be made.


[View source]

Class Method Detail

def self.cast?(obj : GObject::Object) : self | Nil #

[View source]
def self.g_type : UInt64 #

[View source]

Instance Method Detail

def app_info : Gio::AppInfo | Nil #

[View source]
def content_type : String #

[View source]
def content_type=(value : String) : String #

[View source]
def content_type=(value : Nil) : Nil #

Set #content_type property to nil.


[View source]
def content_type? : String | Nil #

Same as #content_type, but can return nil.


[View source]
def refresh : Nil #

[View source]
abstract def to_unsafe #

[View source]