Welcome


Object Hierarchy:

Granite.Widgets.Welcome Granite.Widgets.Welcome Granite.Widgets.Welcome Gtk.EventBox Gtk.EventBox Gtk.EventBox->Granite.Widgets.Welcome Gtk.Bin Gtk.Bin Gtk.Bin->Gtk.EventBox Gtk.Container Gtk.Container Gtk.Container->Gtk.Bin Gtk.Widget Gtk.Widget Gtk.Widget->Gtk.Container GLib.InitiallyUnowned GLib.InitiallyUnowned GLib.InitiallyUnowned->Gtk.Widget GLib.Object GLib.Object GLib.Object->GLib.InitiallyUnowned Atk.Implementor Atk.Implementor Atk.Implementor->Gtk.EventBox Atk.Implementor->Gtk.Bin Atk.Implementor->Gtk.Container Atk.Implementor->Gtk.Widget Gtk.Buildable Gtk.Buildable Gtk.Buildable->Gtk.EventBox Gtk.Buildable->Gtk.Bin Gtk.Buildable->Gtk.Container Gtk.Buildable->Gtk.Widget

Description:


public class Welcome : EventBox

This class is for making a first-launch screen easily

It can be used to create a list of one-time action items that need to be executed in order to setup the app.

Granite.Widgets.Welcome will get the style class `welcome`.

Example

public class WelcomeView : Gtk.Grid {
construct {
var welcome = new Granite.Widgets.Welcome ("Granite Demo", "This is a demo of the Granite library.");
welcome.append ("text-x-vala", "Visit Valadoc", "The canonical source for Vala API references.");
welcome.append ("text-x-source", "Get Granite Source", "Granite's source code is hosted on GitHub.");

add (welcome);

welcome.activated.connect ((index) => {
switch (index) {
case 0:
try {
AppInfo.launch_default_for_uri ("https://valadoc.org/granite/Granite.html", null);
} catch (Error e) {
warning (e.message);
}

break;
case 1:
try {
AppInfo.launch_default_for_uri ("https://github.com/elementary/granite", null);
} catch (Error e) {
warning (e.message);
}

break;
}
});
}
}

Namespace: Granite.Widgets
Package: granite

Content:

Properties:

Creation methods:

Methods:

Signals:

Fields:

Inherited Members:

All known members inherited from class Gtk.EventBox
All known members inherited from class Gtk.Bin
All known members inherited from class Gtk.Container
All known members inherited from class Gtk.Widget
All known members inherited from class GLib.Object
All known members inherited from interface Atk.Implementor
All known members inherited from interface Gtk.Buildable



2022 vala-language.org