Skip to content

steventroughtonsmith/CatalystToolbarMenuButton

main
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 

CatalystToolbarMenuButton

This is a simple Mac Catalyst example showcasing how to build a dropdown menu toolbar button using AppKit.

There are ways to build this using NSToolbarItemGroup, but it has peculiarities like the button always being the width of the longest menu item, even when no title is shown. This way, instead, gives you an NSPopUpButton for your toolbar item, and lets you set an NSMenu of your own design to it.

Screenshot

https://hccdata.s3.amazonaws.com/gh_toolbarmenubutton.jpg

About

This is a simple Mac Catalyst example showcasing how to build a dropdown menu toolbar button using AppKit.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published