воскресенье, 1 июня 2014 г.

2.2 A Window Is Much More Than a Frame: Navigating Windows

     “And in the beginning, there was the window.” Like with older Mac OSes, most of what you’ll do in OS X occurs within these fancy frames. And, as you might imagine, a number of controls are at your disposal, which you can use to control the size, shape, and appearance of these potent portals. In this section, I — well, to be blunt, I do windows. (No squeegee jokes, if you please.)

Opening and closing windows

     Windows are generally opened automatically by an application when you first run it, or it needs to display a document, or by OS X itself, such as when Finder opens a window to display the contents of your hard drive. Finder, by the way, is the application that OS X runs to display the OS X menus and windows.
     Some programs even let you open new windows on the fly; for example, Figure 2-3 shows a window in its purest form: a new Finder window. To display this window on your own Mac, choose File➪New Finder Window or press ⌘+N. From here, you can reach your files on your Mac or even venture to the Internet.
     The Command (⌘) key usually has both an Apple (•) and a rather strangelooking symbol on it that I often call the Spirograph. (I’m told others have called it rather Celtic, but it’s actually a Scandinavian character.)
     When you’re finished with a document or you no longer need a window open, close it to free that space on your Desktop. To close a window in OS X, move your cursor over the Close button; it’s the red circular button at the top-left corner of the window (refer to Figure 2-3). An X appears on the button when you’re in the zone. When the X appears, just click.
     If you’ve been living the life of a hermit for the last two decades or so, pressing the left mouse button is called clicking the mouse. In the modern Apple universe, a Magic Mouse has no visible buttons, and neither do current MacBook trackpads (and the Magic Trackpad)! (You tap the top of the mouse or the trackpad surface with one finger to click.)
     If your Mac is equipped with a Magic Trackpad, never use any object other than your finger on the trackpad! That means no pencils (no, not even the eraser end), pens, or chopsticks; they can damage your trackpad in no time at all. And no, that doesn’t bode well for ladies with long fingernails.
     Most Mac applications don’t want you closing a window willy-nilly if you’ve changed the contents without saving them. For example, try to close a document window in Word without saving the file first. The program asks you for confirmation before it closes the window containing your Great American Novel. Most programs also have a Close command on their File menu. (Here’s another indicator: Most programs display a black dot in the center of the program’s Close button to indicate that there are unsaved changes.)
     To close all windows displayed by a particular program, hold down the Option key while you click the Close button on one of the windows. Whoosh! They’re all gone.

Scrolling windows

     Often, more stuff is in a document or more files are on your hard drive than you can see in the space available for a window. Guess that means it’s time to delete stuff. No, no, just joking! You don’t have to take such drastic measures to see more in a window.
     Just use the scroll bars that you see in Figure 2-4 to move through the contents of the window. By default, scroll bars don’t appear until you move your pointer close to them. You click the scroll box and drag it. For the uninitiated, that means clicking the darker portion of the bar and holding down the mouse button while you move the mouse in the desired direction. Alternatively, you can click in the empty area above or below the scroll box to scroll pages one at a time.
     Depending on the type of application that you’re using, you might be able to scroll a window with your arrow keys as well — or perhaps use the Page Up and Page Down keys to move through a window.

Minimizing and restoring windows

     The multitalented Figure 2-4 also displays another control that you can use with a window: the Minimize button. When you minimize a window, you eliminate it from your Desktop and store it safely on the Dock — that strip of icons that appears along the bottom (or the side) of your OS X Desktop. A minimized window appears as a miniature icon on the Dock by default, so you can keep an eye on it (so to speak). Figure 2-5 illustrates a minimized window from Safari, which is displaying my website at www.mlcbooks.com. To minimize a window, move your mouse pointer over the yellow Minimize button at the top-left corner of the window — a minus sign appears on the button — and then click.
     You’re gonna love this “Easter egg” hidden in OS X. If you hold down the Shift key whilst you minimize, the window shrinks in cool slow motion. (Who says operating systems have to be totally serious, anyway?)
     When you’re ready to display the window again on your Desktop — restoring the window — simply click the thumbnail icon representing the window on the Dock, and OS X automagically returns it to its former size and location.
     By the way, some — note that I said some — applications continue to run when minimized, whereas others simply stop or pause until you return them to the Desktop. Such is the crazy world we live in.

Zooming windows

     Zooming windows has a kind of Flash Gordon sound to it, don’t you think? It’s nothing quite that exciting — no red tights or laser guns — still, when you’re trying to view a larger portion of a document, zooming is a good thing because it expands the window to the maximum practical size for the application that you’re using (and the content being displayed). In some cases, zooming a window fills almost the entire screen; in others, the extra space would be wasted, so the application zooms the window to the maximum size that shows as much content as possible (without any unnecessary white space). The Zoom button can even be disabled by an application that doesn’t want you to muck about with the window; for example, I own some games that don’t allow zooming.
     To zoom a window, move your mouse pointer over the green Zoom button at the top-left corner of the window. Again, refer to Figure 2-4 (in the preceding section), which struts its stuff and illustrates the position. (Man, that is one versatile figure.) A plus sign appears on the Zoom button. Click to expand your horizons.
     After you finish with a zoomed window, return it to its previous dimensions by clicking the Zoom button again.

Those hard-working toolbars

     If you’re wondering what those tiny icons are at the top of many OS X application windows, I won’t leave you in suspense: They’re called toolbar buttons. A toolbar is a strip of icons in a window (usually across the top) that you click to perform common commands, such as changing the display format or printing the current document. (The toolbar in Figure 2-4, for example, features icons to move Back and Forward, among others.) You’ll encounter more toolbar technology throughout the book.
     Most windows that include a toolbar also include some method of hiding the toolbar (to save screen real estate for your document). For example, you can toggle the display of the toolbar on and off in a Finder window from the View menu, or you can use the convenient ⌘+Option+T key shortcut to toggle the toolbar display on and off.

Moving windows

     In contrast to the rather permanent windows in your home, you can cart a window to another portion of the Desktop. Typically, you do this when you’re using more than one application and you need to see the contents of multiple windows. To grab a window and make off with it, click the window’s title bar — the strip at the top of the window that usually bears a document or application name — and drag the window to the new location. Then release the mouse button to plant the window firmly in the new location.
     By the way, some applications allow you to arrange multiple windows in a graceful swoop with a single click of a menu. Open the Window menu and choose Arrange All to perform this magic.
     I talk about Mission Control and Spaces later, in the section “Switching ’Twixt Programs with Aplomb.” Mission Control helps you organize a large number of open windows on your Desktop. You can use it to display all open application windows so that you can pick the one you want, or display all the windows opened by a specific application. Another Mission Control feature — Spaces — allows you to create custom virtual desktops. (Truly cool.) Each of your Spaces desktops can contain a different set of application windows that you use for different tasks!

Resizing windows

     Next, consider how to change the width or height of your window. To change the dimensions of a window to your exact specifications, move your cursor over any edge of the window and then click and hold down the button to drag until the window is the size that you prefer.

Switching windows

     Before I move on to other graphical wonders of OS X, it’s important that you master how to switch between windows on your Desktop. First, remember this old Norwegian saying (or is it one of Mark’s Maxims?):
Only one can be active at one time.
     What our Oslo friends are communicating is that only one window can be active at any time. The active window appears on top of other windows, and it’s the one that you can edit by typing or by moving your mouse. (It also sports Close, Minimize, and Zoom buttons in color, or it fills the entire screen if you’re working in full-screen mode.) Other windows that you have opened might be minimized, as I describe earlier in the section, “Minimizing and restoring windows,” or they can be inactive (mere ghosts of themselves) and remain on your Desktop. OS X dims the controls for inactive windows so that you can tell they’re hanging around but can’t be used at the moment. (Note that both active and inactive windows can contain Finder Tabs, which I discuss in the upcoming sidebar.) Figure 2-6 illustrates a number of open windows, with the iTunes window active.
     I know you’re going to get tired of hearing me say this, but here I go again: Certain applications, such as iTunes and File Transfer Protocol (FTP) clients, continue to run while their windows are inactive. Some programs, however, stop or pause until you make their window active.
     And how do you switch to — activate — a different window in OS X? Again, Mission Control allows you to activate another window, but if the window is currently visible, you can simply click any part of that window. I generally click the window’s title bar if it’s visible, but any part of the inactive window will do. (You can also right-click the application’s icon on the Dock and choose the desired window from the menu.) The window that you click leaps like a proud stallion to the fore, and the previously active window now skulks in the background.
     You can still use a window’s Close, Minimize, and Zoom buttons even when the window is inactive.

Комментариев нет:

Отправить комментарий