AccelLabel


Object Hierarchy:

Granite.AccelLabel Granite.AccelLabel Granite.AccelLabel Gtk.Box Gtk.Box Gtk.Box->Granite.AccelLabel Gtk.Widget Gtk.Widget Gtk.Widget->Gtk.Box GLib.InitiallyUnowned GLib.InitiallyUnowned GLib.InitiallyUnowned->Gtk.Widget GLib.Object GLib.Object GLib.Object->GLib.InitiallyUnowned Gtk.Accessible Gtk.Accessible Gtk.Accessible->Gtk.Box Gtk.Accessible->Gtk.Widget Gtk.Buildable Gtk.Buildable Gtk.Buildable->Gtk.Box Gtk.Buildable->Gtk.Widget Gtk.ConstraintTarget Gtk.ConstraintTarget Gtk.ConstraintTarget->Gtk.Box Gtk.ConstraintTarget->Gtk.Widget Gtk.Orientable Gtk.Orientable Gtk.Orientable->Gtk.Box

Description:


public class AccelLabel : Box

AccelLabel is meant to be used as a Gtk.MenuItem child for displaying a GLib.Action's accelerator alongside the Menu Item label.

The class itself is similar to it's Gtk equivalent Gtk.AccelLabel but follows elementary OS design conventions. Specifically, this class uses Granite.accel_to_string for accelerator string parsing.

Example

  var copy_menuitem = new Gtk.MenuItem ();
copy_menuitem.set_action_name (ACTION_PREFIX + ACTION_COPY);
copy_menuitem.add (new Granite.AccelLabel.from_action_name (_("Copy"), copy_menuitem.action_name));


Namespace: Granite
Package: granite-7

Content:

Properties:

Creation methods:

Inherited Members:

All known members inherited from class Gtk.Widget
All known members inherited from interface Gtk.Orientable