Writing & Consulting Services

Archive for the ‘Software Tips’ Category

For many of us, the Mac’s Mail app is the most often used app in our collection. It has so many features that for most of us, we only touch the surface of what it can do. In this Rocket Yard guide we’ll check out seven features that are often overlooked, most likely left in the default setting, or simply not used.

If you’re a Mac Mail user, take a look at our Mail tips and give them a try.

Set How Often to Check Mail

Has Mail become a distraction? It either rarely or never updates, leaving you wondering if Mail is actually working, or it updates too often, flashing notifications that distract you from your work. In most cases, the problem is the update interval that Mail uses to check for new messages.

You have a few choices in setting the mail check interval, from Automatic to Manual; there are also quite a few preset times, from every minute to every hour and lots of times in-between. The following steps will let you set the interval to use for checking mail:

In the Preferences window that opens, click or tap the General button.

Look for the “Check for new messages:” item. You’ll find the following options in a dropdown menu:

Automatically: (Default) According to Apple, Mail will vary the time frame for checking messages based on whether the Mac is plugged into a power source or using batteries. I’ve found that if someone is using an Exchange mail account or an IMAP account that supports the “Idle” command, Mail will deliver messages as soon as they become available on the server. Otherwise, new mail checking is performed at 5-minute intervals when your Mac is connected to an AC source.

Every minute

Every 5 minutes

Every 15 minutes

Every 30 minutes

Every hour

Manually: Checks for new messages when you click or tap the Get Mail button in the mail toolbar. Additionally, if you’re using IMAP or an Exchange-based mail account, it will check whenever you click or tap an IMAP or Exchange mailbox in the sidebar.

Select the check mail interval you wish to use from the dropdown menu.

Have you found that some websites are using text that is too small or too big, forcing you to either squint to see the text, or perform excessive scrolling to take in the entire site?

Most browsers have methods to allow you some control over how a website appears, including adjusting the size of the web page’s text and images. In this Rocket Yardguide, we’ll look at how to use the Safari browser to adjustfont size and zoom levels for the site you’re currently viewing, and for all sites you view, as well as only for a specific site, whenever you stop by for a look.

Web developers spend a good deal of time designing their websites to appeal to most of their users, but it can be difficult to always get the size right, what with so many different devices and screen sizes viewing the website. If you’re having difficulty viewing text or images on a website, you can try these various tips to get a site looking just the way you like it.

Safari Zoom

Safari has long had the ability to zoom in or out of a web page, letting you see more of the page at one time, or get in close to see details. Safari’s zoom feature normally affects both text and image sizes, but you can also choose to just expand or decrease the text size, leaving the images alone.

Keyboard zoom commands:

Zoom in: Press the command and plus (+) keys at the same time.

Zoom out: Press the command and minus (-) keys at the same time.

If you would like to just increase or decrease the text’s font size while leaving the images at their original size, give the following a go:

Zoom in, text only: Press the option, command, and plus (+) keys at the same time.

Zoom out, text only: Press the option, command, and minus (-) keys at the same time.

Note: If the zoom function isn’t working as expected with the keyboard commands, chances are the keyboard shortcuts are being used by the Accessibility preference pane, to zoom the display in or out. You can change the Accessibility settings, if needed, by following the instructions in the Rocket Yard guide: macOS 101: Using Accessibility’s Vision and VoiceOver Options.

Menu zoom commands:

Zoom in (menu): From the Safari View menu, select Zoom In.

Zoom out (menu): From the Safari View menu, select Zoom Out.

OS X El Capitan and earlier included an option in the View menu to force the Zoom command to only apply to the text on the page, leaving everything else at the original size. To set this option, do the following:

From the Safari View menu, select Zoom Text Only. This will place a checkmark next to the Zoom Text Only menu item, indicating that any subsequent use of the Zoom menu item will affect only the text on the website.

Zoom in, text only: From the Safari View menu, select Zoom In.

Zoom out, text only: From the Safari view menu, select Zoom Out.

macOS Sierra and later did away with the Zoom Text Only item in Safari’s View menu; instead, you can use this trick for increasing or decreasing only the text size in a web page:

Zoom out, text only: Hold down the option key, then open Safari’s View menu and select Make Text Smaller.

Safari Toolbar Zoom Options

Safari’s toolbar does not show any zoom options by default, but you can add the zoom capacities using the toolbar’s customization options.

Open a web page in Safari, and then right-click or control-click on an empty area of the Safari toolbar.

From the popup menu, select Customize Toolbar.

A sheet will drop down, displaying a number of buttons that can be added to the Safari toolbar.

Drag the Zoom buttons to an empty place on the toolbar, and then click the Done button.

The Zoom buttons in the toolbar affect the entire webpage, increasing or decreasing the size of both text and images.

Smart folders and the Dock just seem to be made for each other. You can configure a smart folder to display just the files or folders that meet your specific criteria. Need a folder that just shows the image files you worked on this week? Or perhaps a folder that only shows new music you’ve added to your Mac? Add these smart folders to the Dock, and you’ll have a quick way to view and work with their files without having to browse through the Finder to find them.

If you’ve been following Rocket Yard guides, you may remember that you can use the Terminal app to create Recent Items stacks for the Dock that can show recently used apps, documents, and servers. And while the premade recent items stack is helpful, it doesn’t allow you to use your own search criteria to create the items in the stack.

Smart folders give you all the power of the recent items stack, but with complete control over what the content of the smart folders will be.

Creating Smart Folders
Let’s start the process by exploring how smart folders are created. For an example, we will create a smart folder that displays image files you’ve worked with over the past week.

Start by having the Finder as the active app; you can do this by clicking on the desktop or opening a Finder window. Once the Finder is the front most app, follow these instructions:

The smart folder will be populated with any files or folders that meet the above requirements of being opened in the last week.

To further refine the search, click or tap the plus (+) sign at the far right of the window.

A second search filter will open. Set the first dropdown menu to “Kind,” and the second dropdown menu to “Image.”

A third dropdown menu will appear that you can use to select the type of image (JPEG, TIFF, GIF, PNG); for this example, select the “All” option to display any of the image file types.

At this point, you’ve created a basic smart folder that will show any image file you’ve opened in the last week. And while this may be all you need, there are further refinements to the search filters you can make.

Hold down the option key. You’ll notice that the plus (+) sign has changed to display ellipses. Click or tap the ellipses to add additional restrictions to the current search criteria. You’ll see two filter sets appear.

The first allows you to select Any, All, or None, if the following conditions are true. The second criteria set allows you to set the conditions that are being tested. As an example, if you don’t wish to have any PNG image files included in the smart folder, you would set the menus as follows:

Set the first dropdown menu to None.

Set the second group of menus to Kind, Image, PNG.

You’ve created a smart folder that will display all of the image files you have opened during the last week, except PNG files.

Have you ever wondered what’s stored in your Mac’s Utilities folder? This folder contains apps that are used to perform a number of interesting chores, from providing basic information about your Mac, to displaying complex mathematical formulas as 2D or 3D graphs, to allowing your Mac to speak, not only the text in a window, but how the window’s tools and buttons can be used.

In macOS 101: What’s in the Utility Folder, Part 1 we looked at the first ten apps Apple stores in the Utilities folder. In the second part of this article, we look at the last ten apps. Your version of the Utilities folder may contain more or fewer apps than we list here; the number fluctuates, depending on the Mac OS version you’re using. Other apps may be added by third-party developers.

If you’re ready to continue the exploration of the Utilities folder, open a Finder window and browse to /Applications/Utilities.

Grab
The Mac has been able to take screenshots since it was first introduced, by using keyboard shortcuts, such as Command + Shift + 3, to capture the entire screen, or Command +Shift + 4 to capture a user-selected portion of the screen.

To give the user a bit more control over taking screenshots, Apple includes the Grab app in the utilities folder. Grab can perform the same function as the earlier keyboard shortcuts for screen capture, but it also provides additional capabilities, such as grabbing a selected window, taking timed screenshots, or optionally showing the pointer in the screenshots.

If you’re using macOS High Sierra or earlier, you’ll find that Grab does a great job of handling the screenshot taking needs of most users. If your Mac is running macOS Mojave or later, Grab has been replaced by the newer Screenshot app. You can find out more about the Screenshot app a little further on in this guide.

To give the user a bit more control over taking screenshots, Apple includes the Grab app in the utilities folder. Grab can perform the same function as the earlier keyboard shortcuts for screen capture, but it also provides additional capabilities, such as grabbing a selected window, taking timed screenshots, or optionally showing the pointer in the screenshots.

If you’re using macOS High Sierra or earlier, you’ll find that Grab does a great job of handling the screenshot taking needs of most users. If your Mac is running macOS Mojave or later, Grab has been replaced by the newer Screenshot app. You can find out more about the Screenshot app a little further on in this guide.

Grapher
Grapher is a visualization tool for creating 2D and 3D graphs from mathematical equations. Many users of Grapher consider it an equivalent to the older graphing calculators, but with more ability to store, edit, and refine equations than a hardware-based calculator could ever do. And there’s the added benefit that the graphs you create can be saved in various formats for inclusion in other documents you may be working on.

Grapher supports popular 2D graph types such as classic, polar, linear-logarithmic, log-log and polar log. Three-D graphs can display standard system, cylindrical system, and spherical system. Graphs can include animation, though there’s an issue with exporting animated graphs that can be overcome by using the Screenshot app to capture the animated graph as a video.

Aside from the ability to export an animated graph, Grapher can export data in JPEG, TIFF, EPS, PDF and LaTeX formats.

Safari is the most popular web browser for the Mac, and why not; it’s fast, easy to use, and it comes with every Mac. These eight tricks (sixteen, if you count the tip included with each trick) can make you more productive, make it easier to work with Safari, or just make you scratch your head, wondering why Apple included that feature.

If you’re ready to explore a few new tricks, let’s get started.

Privacy Settings for a Website
Starting with Safari 11 and macOS High Sierra, Safari gained a number of security and privacy protections that can make surfing the web both safer and faster. These settings are normally available on a website-by-website basis, and are stored in Safari preferences, under the Websites button in the toolbar.

Accessing this part of the Safari preferences lets you see and change the privacy settings for each website you’ve visited and altered the privacy settings from the default state.

But it’s not the quickest way to make changes to a site you’re visiting; a much faster method can be found directly in the browser’s menu bar:

Select Safari, Settings for This Website.

A sheet will drop down from the browser’s URL bar, displaying the list of privacy settings for the current page.

You can alter the settings directly within the pane by placing checkmarks on each setting you wish to enable, or use popup menus to select from multiple options for each listed item.

You can choose to:

Use Readers when available

Enable content blockers

Set the page zoom level

Set Auto-Play levels

Adjust popup window settings (macOS Mojave and later)

As well as control the use of:

Camera

Microphone

Location

Tip: You can also access the privacy sheet for the currently loaded website by right-clicking in the URL field and selecting Settings for This Website in the popup menu. Note: The menu item is only available if the URL field hasn’t been previously selected.

Choosing the six best free and almost free Safari extensions is generally a fun task, though this time I had to be a bit more careful, because of the changes made in Safari 12, as well as in macOS Mojave.

Safari 12 prevents the use of some extensions, imposes limits on others, and generally mucks up the ability of the user to decide which Safari extensions they wish to use, all in the name of security and creating a unified user experience.

You don’t have to rush out and pick a different browser to use, though that’s certainly an alternative if your favorite extension is no longer supported in Safari. For the most part, Safari extensions are still supported and available. The changes primarily mean that extension developers must submit their extensions for placement in the Mac App Store, and make use of current Apple extension APIs. The upshot is that many extensions will need to be updated by their developers before they will be available for download and installation from the Mac App Store. Related: Rocket Yard Testing Lab — Which Browser is Fastest?

Two Sources for Safari Extensions
Extensions that will work in Safari 12 and later can be found from two sources: the older Safari Extension Gallery, which is being deprecated in favor of the Mac App Store. It’s still functional for now, and is a good source for many Safari extensions that haven’t yet made the transition to the new Mac App Store platform.

I used both of these sources to assemble our list of the six best Safari Extensions.

Safari Extensions
I liked quite a few of the new Safari extensions; they all have very low impact on Safari and the Mac’s performance, which is one of the design goals of the new extensions format. While I can recommend these six, I want to point out there are plenty of extensions to choose from in the Mac App Store, and more to come.

Ghostery Lite: More than an ad blocker, this privacy extension stops most trackers dead in their tracks, preventing them from sending personal data about your browsing habits back to the advertisers servers. It’s also able to rid web pages of those annoying customer interaction bots that pop up and offer to chat with you about a product or service, dispense with social media feeds that may be integrated into a website, block comments, adult content, audio or video, and, of course, block ads.

Ghostery Lite also allows you to include websites in a trusted sites list, which lets them override the blocking you have in place.

Ghostery Lite is lightweight, and doesn’t place a significant load on CPU or memory when operating.

StopTheMadness: How often have you navigated to a website and discovered that your browser stops working as expected? Many websites suppress normal operations of a browser, preventing such routine operations as using keyboard shortcuts, opening contextual menus, copying, cutting, or pasting of text, AutoFill, and more.

If I end up at just one more website that prevents me from pasting my password into the appropriate field… Well, you get the idea. StopTheMadness does one thing I really like: it lets you take back control of your browser and thumb your nose at websites that want to control you.

The Preview app is a handy tool for viewing and working with PDF (Portable Document Format) files, as outlined in the Rocket Yard guide: macOS 101: Mark It Up with Preview. In Part Two of the guide, we’ll look at how Preview can be used for viewing and editing images.

We’ll be using Preview’s Markup toolbar, which is usually hidden. You can use the instructions from the Mark it Up with Preview guide, linked above, to access the Markup toolbar.

While it’s not a full-featured image-editing app, Preview does have some remarkable capabilities that make it a good choice for working with images, especially when you consider it’s supplied free as part of the macOS.

Destructive Editing, Auto-Save, and Versions
Preview is one of the apps that work with the Mac’s auto-save system. This means that Preview will automatically save a document as you work on it. The practical aspect to this is that Preview will use destructive editing by automatically periodically saving the changes you make to the file you’re working on. In other words, if you want to change an image back to the way it looked earlier, chances are it’s too late. Earlier versions of the image are history.

For this reason, I highly recommend that you work on a duplicate of the image file. This can be done by after opening an image in Preview by selecting Duplicate from the File menu. Give the file a new name, then use Save from the File menu. This will ensure any changes won’t affect the original file.

Optionally, you can make use of the Revert to command in the File menu to return to a previous version of the file that existed before you made any edits. This means you will lose all of the edits you made, even the ones you might want to keep.

Remove Objects from an Image
Preview has a number of tools that allow you to select an object and copy or remove the selected object from the image. One of the problems with selecting an object is the difficulty in performing a precise selection to isolate the object from the background. Preview offers two tools to perform this task: the Selection tool, which allows you to draw a rectangle, an elliptical, a free-form lasso, or a smart lasso around the desired object, and the Instant Alpha tool, which can perform a selection based on colors of objects.

Instant Alpha: This tool has been included with the Preview app for some time. It allows you to remove an object from an image, or remove the background from around an object. Instant Alpha works by making selections based on color matching, making it an ideal tool when there’s distinct difference between the object and the background.

Using Instant Alpha, you can remove the background from around an object, such as these glasses, making it easier to copy them for later use.

The instant alpha tool can be found in the Markup toolbar. It looks like a magic wand, and is usually the second tool from the left in the Markup toolbar.

To use the Instant Alpha tool, make sure the object within the image is visible in the Preview window. You may want to use the Zoom in or Zoom out icons in the standard toolbar to better focus on the object you wish to work with.

Once everything looks right, click or tap the magic wand icon.

Place your cursor near the object above the background you wish to remove.

Click and hold the mouse or touchpad while very slowly dragging the cursor over the background.

As you drag, you’ll notice the background starts to turn pink. The more you drag, the larger the area of the background is turning pink. What is happening is, as you drag the cursor, the Instant Alpha tool adjusts the range of color it will accept as a match. This lets you select more of the background as a wider color match is used. If you select too much area, you can simply drag in the opposite direction to reduce the match range.

Once you have the background selected, stop dragging, and release the mouse or trackpad button.

The pink highlight will be replaced by a dotted selection line.

Click the Delete key on the keyboard, or select Delete from the Edit menu, to remove the selected background.

You’ll likely see a sheet appear asking if it’s OK to convert the image format to PNG. This is done to ensure the deleted areas of the image are replaced with a transparent background.

You may need to repeat the process to remove background areas near the desired object that were a different color.

Once you’ve removed the background around the object, you can use any of the Selection tool types to select the object, and then select Copy from the file menu.

The selected object will be saved to your Mac’s clipboard for use in other apps.

You can save the object to a file by selecting File, New from Clipboard.

Preview will open a new image file with the object you just copied.

You can then select Save from the file menu.

Smart Lasso: The Smart Lasso tool is part of the Selection tool’s options. It allows you to draw a freeform selection line around the object you wish to copy or delete. The smart lasso will attempt to automatically adjust the selection path based on color intensity. This allows it to conform to the object you’re attempting to select.

To use the Smart Lasso, make sure the object of your desire is visible within the image. Adjust the zoom in or zoom out settings as needed.

Click or tap the chevron just to the right of the Selection tool.

In the dropdown menu that appears, make sure that Smart Lasso is chosen.

Place the cursor along one of the edges of the object, then click and hold the mouse or trackpad. Start dragging a line around the object. As you drag, you will notice the freeform line being drawn has a thick border. Make sure the edge of the object you wish to extract is within the thick border of the line you are drawing.

Finish the Smart Lasso by completely surrounding the object, and returning to the starting point.

Release the mouse or trackpad; the thick line will become a dotted selection line hugging the selected object.

Preview, the free PDF viewing app included with the Mac, can do a lot more than view images or open PDF files to view. It includes a number of features and services that can be used for editing PDFs, working with images, even creating electronic signatures to use to sign important documents.

In this Rocket Yard guide, we’re going to explore the Preview app’s ability to fill out PDF forms and mark up files, even files that weren’t designed to be completed electronically.

Using Preview for Markup
PDF (Portable Document Format) is a file format intended to ensure that documents can be exchanged reliably, independent of the type of software or hardware being used to view, print, or edit them. In other words, that PDF file you’re viewing on a Mac will look the same when viewed on a PC, or for that matter, any device that supports PDFs.

Preview supports more than just viewing; you can also mark up a PDF file in order to add additional information. One of the most common uses for a PDF file is as a form intended for an individual to fill out. When a PDF file is created for this purpose, the creator of the file can make the process easier by adding predefined text boxes, check boxes, graphics, links to instructions, just about anything that will make the process of completing the form an easier one. A well-designed PDF form can make the process an easy one.

But even PDFs that weren’t designed as forms can still have information added to them in a process commonly referred to as marking up a document, or simply mark up.

Finding the Markup Tools
Launch Preview, which you’ll find in the /Applications folder.

Preview opens by asking for a document to load. If you don’t have a PDF document to experiment with, I suggest a trip to the IRS.gov website. Download any of the IRS forms, which are available as PDFs ready to be filled in. You can also elect to open a JPG image file, or perhaps one of the OWC manuals you’ve downloaded from the OWC support website.

With the selected PDF file now open, you can access the Markup tools by ensuring that Preview’s toolbar is displayed. Select Show Toolbar from Preview’s View menu.

If the toolbar wasn’t displayed before, you’ll now see a small toolbar across the top of the Preview window. It will include buttons for zooming in or out, sharing, rotating, search, and a few other options.

Just to the left of the search bar is a button that looks like the tip of a pen or pencil within a circle. (Depending on the version of the Mac OS you’re using, the button may look like a little toolbox.) Clicking or tapping this button will display the Markup toolbar just below the standard toolbar.

Using the Markup Toolbar
At the time of this writing, the Markup toolbar contains eleven or twelve tools (depending on the Mac model you’re using) you can use for marking up a PDF file. We will look at each one, and how it is used. The markup tool list below starts with the first tool on the left-hand side of the window and moves to the right:

Text Selection: This tool is used for selecting and copying text. To select text, click the Text Selection button (it turns blue when active), and then drag over the text you wish to choose. In many cases, the Text Selection tool may already be selected, allowing you to simply drag across text to make the selection; in other cases, the Text Selection tool may need to be enabled first.

Once text is selected, you can copy it by selecting Edit, Copy, or by using the keyboard shortcut Command + C, or right-clicking and selecting Copy from the popup menu. Text you have selected can also be subject to other markup tools, as mentioned below.

Rectangular Selection: Use this tool to draw a selection rectangle over an image. The rectangle can be resized using the selection handles as well as moved about the PDF document by dragging from any side. Once in place, you can then copy or remove the area selected.

Sketch: The sketch tool allows you to draw an arbitrary shape using a single stroke. If the shape you draw looks like a standard shape (arc, square, rectangle, circle, oval, star) it will be replaced by the standard shape. A palette will also be displayed, showing the original and the standard shape. Use the palette to pick which of the two shapes you wish to use.

Draw: This tool only appears if your Mac is equipped with a Force Touch trackpad. It works the same as the sketch tool above, but interprets the force being applied to the trackpad to determine the width of the line being drawn.

Backing up your Mac can be a very easy process. Pick a drive to use for your backups, turn on Time Machine, and you have a basic backup system in place with very little effort. Time Machine has a lot going for it, including the ability to recover older versions of a file from the backup device. That can be invaluable when you need to know what was in a document a few versions back, or even a few years back.

But there are a few things Time Machine doesn’t do well, such as restoring all of the data on a failing startup drive. The process of recovering the information from a Time Machine drive can be long and arduous, and having to wait a few hours to get back to work can really throw a monkey wrench into your schedule.

That’s one of the reasons I recommend using a second backup strategy, based around cloning the data on your startup drive. Cloning can let you get back up and running in the time it takes to restart your Mac. It lets you continue to work while you order a replacement storage device for the volume that failed. It can also take some of the tension out of what can be a very stressful time.

Using Time Machine and a cloned startup drive is such a powerful backup system that it’s the basis for all of the backups in our home and office environments.

Which brings us to this week’s Rocket Yard guide: Use Multi-Bay Enclosures for Better Backups.

Using External Enclosures with Two or More Bays
Let me be clear: a multi-drive backup system doesn’t have to be built from multi-bay enclosures. You can successfully make use of multiple single drive enclosures and achieve equivalent results. But using multi-bay enclosures has a few advantages:

Fewer power bricks and cords to clutter up your work area.

A single connection to your Mac leaves more ports available for other uses.

Available with 2, 4, or 6 drive bays, or even more.

Many multi-bay enclosures support various RAID types.

Can be used for multiple tasks, such as backups, media libraries, bulk storage, and media editing.

External Enclosures to Consider
With so many multi-bay drive enclosures available, you may want to look at the following as good examples of enclosures to consider for this backup system.

OWC Mercury Elite Pro Dual Mini: This dual-bay enclosure is designed to accept 2.5-inch drives, the same size used for most laptop drives as well as SATA-based SSDs. It makes use of hardware-based RAID that supports RAID 0, 1, SPAN, and Independent drive modes. The enclosure makes use of USB-C 3.1 Gen 2, providing speeds up to 10 Gb/s. Its small size and use of USB 3.1 Gen 2 connections make it a great choice for backups, as well as image or music libraries.

The Mercury Elite Pro Quad can house up to four drives, and connects using USB 3.1 Gen 2.

OWC ThunderBay 4: A quad-bay enclosure that supports 3.5-inch or 2.5-inch drives with no adapters needed. It makes use of SoftRAID XT Lite, and supports RAID 0, 1, and JBOD. This quad enclosure makes use of Thunderbolt 3 to provide the highest sustained performance of our suggested enclosures for backup.

Launch Services is a core service of the Mac OS that enables an actively running application to open other apps, documents, or URLs (Uniform Resource Locators). Launch Services is also used to prioritize which app is used to open a document or URL.

Launch Services replaced a number of earlier system managers the Mac used to use, such as the Desktop Manager, Internet Config, and File Manager, replacing them with the single Launch Services system, and the database Launch Services maintains to keep track of all things related to how documents and apps relate to each other.

Launch Services allows an app or document to:

Open (launch or activate) another app.

Open a document or URL.

Identify the preferred app to use to open a document or URL.

Register the type of documents or URLs an app is capable of working with.

Keep track of information needed for displaying a file or URL, including its icon, name, and kind (examples: JPEG, PDF, Folder, Volume).

In past versions of the Mac OS, this type of information was maintained by the Finder, as well as by some specific system managers. By consolidating this information to the Launch Services, it allows for greater reliability, easier (actually, automatic) registration of file and document associations, and less need to repair file association information. If you remember having to rebuild the Desktop frequently on older Macs, then you know the file associations tended to get out of whack often.

Launch Services maintains a database aptly known as the Launch Services Database, which is used to record all the needed information about apps, documents, and URLs to determine which items an app is capable of working with.

Application Registration
Launch Services automatically registers an app with the database the first time the app becomes known to the system. This can occur when:

The Finder reports an app has been added to the Applications folder.

An app installer is run.

When a document is opened that has no preferred app, the user is asked to select an app to use, and that app is registered with Launch Services.

When the built-in Launch Services tool is run whenever you boot your Mac or login as a user. This tool scans the Applications folder looking for any new apps that have been placed there.

Opening Documents
When you open a document or URL, Launch Services is used to determine which app to use to open the item. Launch Services uses the following specific order to check for which app to use: