Table of Contents

Class MenuButton

Namespace
Gtk
Assembly
Gtk-4.0.dll
public class MenuButton : Widget, IObject, INotifyPropertyChanged, IDisposable, Accessible, Buildable, ConstraintTarget, IHandle, GTypeProvider
Inheritance
MenuButton
Implements
Inherited Members

Constructors

MenuButton()

public MenuButton()

MenuButton(params ConstructArgument[])

protected MenuButton(params ConstructArgument[] constructArguments)

Parameters

constructArguments ConstructArgument[]

MenuButton(IntPtr, bool)

protected MenuButton(IntPtr ptr, bool ownedRef)

Parameters

ptr IntPtr
ownedRef bool

Fields

ActivateSignal

Signal Descriptor for OnActivate.

public static readonly Signal<MenuButton> ActivateSignal

Field Value

Signal<MenuButton>

ActivePropertyDefinition

public static readonly Property<bool, MenuButton> ActivePropertyDefinition

Field Value

Property<bool, MenuButton>

AlwaysShowArrowPropertyDefinition

public static readonly Property<bool, MenuButton> AlwaysShowArrowPropertyDefinition

Field Value

Property<bool, MenuButton>

CanShrinkPropertyDefinition

public static readonly Property<bool, MenuButton> CanShrinkPropertyDefinition

Field Value

Property<bool, MenuButton>

ChildPropertyDefinition

public static readonly Property<Widget?, MenuButton> ChildPropertyDefinition

Field Value

Property<Widget, MenuButton>

DirectionPropertyDefinition

public static readonly Property<ArrowType, MenuButton> DirectionPropertyDefinition

Field Value

Property<ArrowType, MenuButton>

HasFramePropertyDefinition

public static readonly Property<bool, MenuButton> HasFramePropertyDefinition

Field Value

Property<bool, MenuButton>

IconNamePropertyDefinition

public static readonly Property<string?, MenuButton> IconNamePropertyDefinition

Field Value

Property<string, MenuButton>

LabelPropertyDefinition

public static readonly Property<string?, MenuButton> LabelPropertyDefinition

Field Value

Property<string, MenuButton>

MenuModelPropertyDefinition

public static readonly Property<MenuModel?, MenuButton> MenuModelPropertyDefinition

Field Value

Property<MenuModel, MenuButton>

PopoverPropertyDefinition

public static readonly Property<Popover?, MenuButton> PopoverPropertyDefinition

Field Value

Property<Popover, MenuButton>

PrimaryPropertyDefinition

public static readonly Property<bool, MenuButton> PrimaryPropertyDefinition

Field Value

Property<bool, MenuButton>

UseUnderlinePropertyDefinition

public static readonly Property<bool, MenuButton> UseUnderlinePropertyDefinition

Field Value

Property<bool, MenuButton>

Properties

AccessibleRole

public AccessibleRole AccessibleRole { get; set; }

Property Value

AccessibleRole

Active

public bool Active { get; set; }

Property Value

bool

AlwaysShowArrow

public bool AlwaysShowArrow { get; set; }

Property Value

bool

CanShrink

public bool CanShrink { get; set; }

Property Value

bool

Child

public Widget? Child { get; set; }

Property Value

Widget

Direction

public ArrowType Direction { get; set; }

Property Value

ArrowType

HasFrame

public bool HasFrame { get; set; }

Property Value

bool

IconName

public string? IconName { get; set; }

Property Value

string

Label

public string? Label { get; set; }

Property Value

string

MenuModel

public MenuModel? MenuModel { get; set; }

Property Value

MenuModel

Popover

public Popover? Popover { get; set; }

Property Value

Popover

Primary

public bool Primary { get; set; }

Property Value

bool

UseUnderline

public bool UseUnderline { get; set; }

Property Value

bool

Methods

Announce(string, AccessibleAnnouncementPriority)

[Version("4.14")]
public void Announce(string message, AccessibleAnnouncementPriority priority)

Parameters

message string
priority AccessibleAnnouncementPriority

GetAccessibleParent()

[Version("4.10")]
public Accessible? GetAccessibleParent()

Returns

Accessible

GetAccessibleRole()

public AccessibleRole GetAccessibleRole()

Returns

AccessibleRole

GetActive()

[Version("4.10")]
public bool GetActive()

Returns

bool

GetAlwaysShowArrow()

[Version("4.4")]
public bool GetAlwaysShowArrow()

Returns

bool

GetAtContext()

[Version("4.10")]
public ATContext GetAtContext()

Returns

ATContext

GetBounds(out int, out int, out int, out int)

[Version("4.10")]
public bool GetBounds(out int x, out int y, out int width, out int height)

Parameters

x int
y int
width int
height int

Returns

bool

GetBuildableId()

public string? GetBuildableId()

Returns

string

GetCanShrink()

[Version("4.12")]
public bool GetCanShrink()

Returns

bool

GetChild()

[Version("4.6")]
public Widget? GetChild()

Returns

Widget

GetDirection()

public ArrowType GetDirection()

Returns

ArrowType

GetFirstAccessibleChild()

[Version("4.10")]
public Accessible? GetFirstAccessibleChild()

Returns

Accessible

GetGType()

public static Type GetGType()

Returns

Type

GetHasFrame()

public bool GetHasFrame()

Returns

bool

GetIconName()

public string? GetIconName()

Returns

string

GetLabel()

public string? GetLabel()

Returns

string

GetMenuModel()

public MenuModel? GetMenuModel()

Returns

MenuModel

GetNextAccessibleSibling()

[Version("4.10")]
public Accessible? GetNextAccessibleSibling()

Returns

Accessible

GetPlatformState(AccessiblePlatformState)

[Version("4.10")]
public bool GetPlatformState(AccessiblePlatformState state)

Parameters

state AccessiblePlatformState

Returns

bool

GetPopover()

public Popover? GetPopover()

Returns

Popover

GetPrimary()

[Version("4.4")]
public bool GetPrimary()

Returns

bool

GetUseUnderline()

public bool GetUseUnderline()

Returns

bool

New()

public static MenuButton New()

Returns

MenuButton

Popdown()

public void Popdown()

Popup()

public void Popup()

ResetProperty(AccessibleProperty)

public void ResetProperty(AccessibleProperty property)

Parameters

property AccessibleProperty

ResetRelation(AccessibleRelation)

public void ResetRelation(AccessibleRelation relation)

Parameters

relation AccessibleRelation

ResetState(AccessibleState)

public void ResetState(AccessibleState state)

Parameters

state AccessibleState

SetAccessibleParent(Accessible?, Accessible?)

[Version("4.10")]
public void SetAccessibleParent(Accessible? parent, Accessible? nextSibling)

Parameters

parent Accessible
nextSibling Accessible

SetActive(bool)

[Version("4.10")]
public void SetActive(bool active)

Parameters

active bool

SetAlwaysShowArrow(bool)

[Version("4.4")]
public void SetAlwaysShowArrow(bool alwaysShowArrow)

Parameters

alwaysShowArrow bool

SetCanShrink(bool)

[Version("4.12")]
public void SetCanShrink(bool canShrink)

Parameters

canShrink bool

SetChild(Widget?)

[Version("4.6")]
public void SetChild(Widget? child)

Parameters

child Widget

SetCreatePopupFunc(MenuButtonCreatePopupFunc?)

public void SetCreatePopupFunc(MenuButtonCreatePopupFunc? func)

Parameters

func MenuButtonCreatePopupFunc

SetDirection(ArrowType)

public void SetDirection(ArrowType direction)

Parameters

direction ArrowType

SetHasFrame(bool)

public void SetHasFrame(bool hasFrame)

Parameters

hasFrame bool

SetIconName(string)

public void SetIconName(string iconName)

Parameters

iconName string

SetLabel(string)

public void SetLabel(string label)

Parameters

label string

SetMenuModel(MenuModel?)

public void SetMenuModel(MenuModel? menuModel)

Parameters

menuModel MenuModel

SetPopover(Widget?)

public void SetPopover(Widget? popover)

Parameters

popover Widget

SetPrimary(bool)

[Version("4.4")]
public void SetPrimary(bool primary)

Parameters

primary bool

SetUseUnderline(bool)

public void SetUseUnderline(bool useUnderline)

Parameters

useUnderline bool

UpdateNextAccessibleSibling(Accessible?)

[Version("4.10")]
public void UpdateNextAccessibleSibling(Accessible? newSibling)

Parameters

newSibling Accessible

Events

OnActivate

public event SignalHandler<MenuButton> OnActivate

Event Type

SignalHandler<MenuButton>