MACRO: Float Specified Apple Notes, v2.3

PURPOSE

This macro will open the Apple Notes app and float one or more notes (i.e., open each note in a separate window). Thus it provides a convenient method to access frequently used notes.


SETTINGS

Note settings for this macro are entered in variable local_Favorite_Folders_Titles. For the required syntax, see the macro Comment Syntax Description—SETTINGS (Notes).

Window position settings are entered in variable local_WindowPositions_x_y_w_h. For the syntax, see the macro Comment Syntax Description—SETTINGS (Windows).


HOT KEY TRIGGERS

⌥⇧N : primary Hot Key trigger. This macro processes the SETTINGS (Notes) normally (same as if it was triggered from the KM Editor, a palette, etc.). This Hot Key can be freely changed.

(any modifier combination)+n, where n is any single character, except N (e.g., ⇧⌘W, ⌥⇧⌘3, ⌃⌥⌘Q) : These optional secondary Hot Keys will normally be matched (in the three examples W, 3, Q) to prefixes in the SETTINGS (Notes) variable. If no match is found, this macro functions as if it was triggered from the Keyboard Maestro Editor.


TRIGGERING

If this macro is triggered directly it will use the SETTINGS (Notes). If it is triggered by another macro* (a.k.a. a caller), it will use the SETTINGS (Notes) provided by that macro.

*To ensure that a calling macro is structured properly, duplicate macro Float Specified Apple Notes CALLER TEMPLATE and customize the duplicate as needed.


ACKNOWLEDGEMENTS

This macro includes an AppleScript handler derived from a template created and shared by @JMichaelTX: What is Best Practice for Handling Script Errors in Execute Script Action? - Questions & Suggestions


TESTED WITH

• Keyboard Maestro v10.1.1
• Monterey, v12.4/MacBookPro16,1
• Mojave 10.14.16/Macmini6,2
• High Sierra 10.13.6/iMac11,1445


VERSION HISTORY

expand

1.0 - This was based off Float Selected Apple Note with the following enhancements:
a) open one or more notes directly (with $> prefix)
b) open a specific note with a Hot Key Trigger
c) trigger this macro from a calling macro

2.0
a) Added SETTINGS for window positions.
b) Accommodates n: prefixes in the SETTINGS (Notes) from a calling macro.

2.1
a) Set icon to the Apple Notes app.
b) Updated parsing of text lists.
c) Bug fix: n: was not properly detected unless the line also included $>, i.e., n:$>

2.2
a) Changed primary hot key trigger from ⌥⌘N to ⌥⇧N.
b) Changed secondary hot key triggers from ⌥⇧⌘1 to ⌃⌥⇧1 and from ⌥⇧⌘2 to ⌃⌥⇧2.
c) Included minor performance improvements.
d) Included minor adjustments to window position and size.
e) Fixed a few typographical errors in the comments.
f) Updated TESTED WITH.

2.3 - Modified to accommodate macOS Ventura (v13.x). In this version the Notes app menu item Window>Float Selected Note was changed to Window>Open Note in New Window.


DOWNLOAD Macro File:
Float Specified Apple Notes.kmmacros (195 KB)
Note: This macro was uploaded in a DISABLED state. It must be ENABLED before it can be run. If it does not trigger, the macro group might also need to be ENABLED.

Macro-image


Float Specified Apple Notes can be triggered (a.k.a called) for another macro. The following is a template that can be duplicated and modified as required.

DOWNLOAD Macro File:
Float Specified Apple Notes CALLER TEMPLATE.kmmacros (21 KB)
Note: This macro was uploaded in a DISABLED state. It must be ENABLED before it can be run. If it does not trigger, the macro group might also need to be ENABLED.

Macro-Image

6 Likes

I've updated the OP with Version 2.0 of Float Specified Apple Notes.

  • Added SETTINGS for window positions.
  • Accommodates <hk>n: prefixes in the SETTINGS (Notes) from a calling macro.
1 Like

I've updated the OP with Version 2.1 of Float Specified Apple Notes.

  • Set icon the the Apple Notes app
  • Updated parsing of text lists.

Bug fix:

  • <hk>n: was not properly detected unless the line also incuded $>, i.e., <hk>n:$>
1 Like

Nice, thanks for sharing the update. Ever since you posted your original macro I have been using it quite extensively both as a stand-alone as well as embedded in other macros. It’s a very well put together macro!

Hi @cdthomer, glad you are finding it useful. Thanks for the feedback. Your early comments (with Float Selected Apple Note, the predecessor) inspired some of the current features—so extensive I had to even change the macro name. :grinning:

1 Like

I've updated the OP with Version 2.2 of Float Specified Apple Notes.

  • Changed primary hot key trigger from ⌥⌘N to ⌥⇧N.
  • Changed secondary hot key triggers from ⌥⇧⌘1 to ⌃⌥⇧1 and from ⌥⇧⌘2 to ⌃⌥⇧2.
  • Included minor performance improvements.
  • Included minor adjustments to window position and size.
  • Fixed a few typographical errors in the comments.
  • Updated TESTED WITH.

Users of Apple Notes might find this macro also useful: New Apple Note

I've updated the OP with Version 2.3 of Float Specified Apple Notes.

Modified to accommodate macOS Ventura (v13.x). In this version the Notes app menu item Window>Float Selected Note was changed to Window>Open Note in New Window.

1 Like

Hey Jim, glad to see you're continuously updating and posting your macro. I've modified my personal copy so much now that I'm afraid to download your updated ones because I would have to tinker with it to get back to how mine currently works. :sweat_smile:

But one of these days when I am able to again spend more time with my macros like before I'm going to download the latest version and check out all the cool updates!

1 Like