What does the windows taskbar do

How to use the taskbar in Windows 10

Use the taskbar for more than seeing your apps and checking the time. You can personalize it in many ways—change the color and size, pin your favorite apps to it, move it around on your screen, and rearrange or resize taskbar buttons. You can also lock the taskbar to keep your options, check your battery status, and minimize all open programs momentarily so that you can take a look at your desktop.

Pin an app to the taskbar

Pin an app directly to the taskbar for quick access when you’re on the desktop. (Or unpin it, if you want.) You can do it from Start or the Jump List, which is a list of shortcuts to recently opened files, folders, and websites.

In the search box on the taskbar, type the name of the app you want to pin to the taskbar. Select More > Pin to taskbar . If you’re unpinning, follow the same steps and select Unpin from taskbar .

If the app is already open, locate the app’s icon button on the taskbar, press and hold the button, and then swipe up until the App list appears. If you’re using a mouse, locate the app icon button on the taskbar, right-click the button, and then select Pin to taskbar . If you’re unpinning, follow the same steps and select Unpin from taskbar .

Change your taskbar settings

Customize the taskbar from the taskbar itself. If you want to change multiple aspects of the taskbar at one time, use Taskbar settings. Press and hold or right-click any empty space on the taskbar, and then select Taskbar s ettings .

In the Taskbar settings, scroll to see the options for customizing, sizing, choosing icons, battery information and much more.

Select any of the following to see more info.

To change the color of your taskbar, select Start > Settings > Personalization > Colors > Show accent color on the following surfaces. Select Start, taskbar, and action center. This will change the color of your taskbar to the color of your overall theme.

Locking the taskbar is handy to make sure it remains how you set it up. Unlock the taskbar later when you want to make changes or change its location on the desktop. Press and hold or right-click any empty space on the taskbar, select Taskbar settings , and turn on Lock the taskbar.

If Lock the taskbar has a check mark next to it, you know it’s already locked. To turn it off, select Lock the taskbar or go to Taskbar settings and turn it Off.

If you have multiple monitors that display the taskbar, you’ll see Lock all taskbars.

Typically, the taskbar is at the bottom of the desktop, but you can also move it to either side or the top of the desktop. When the taskbar is unlocked, you can change its location. See Lock and unlock the taskbar to find out if yours is locked. When you’ve confirmed that your taskbar is unlocked, press and hold or right-click any empty space on the taskbar. Select Taskbar settings > Taskbar location on screen, and then select Left, Top, Right, or Bottom.

Like many other changes in the taskbar, you’ll need to first unlock the taskbar. Then, move the pointer over the border of the taskbar until the pointer turns into a double arrow. Drag the border to the size you want and release.

To add the battery icon to the taskbar, select Start > Settings > Personalization > Taskbar, and then take a look at the notification area. Choose Select which icons appear on the taskbar, and switch Power to On.

You can check battery status by selecting the battery icon in the taskbar.

Note: You might need to select show hidden icons Up arrow icon on the taskbar before selecting the battery icon. Power is not an option on systems without a battery.

Whenever you want to change the order of app buttons on the taskbar, just drag a button from its current position to a different one.

You might want to choose how taskbar buttons are grouped, especially if you have multiple windows open. By default, all open files from the same app are always grouped together, even if you didn’t open them in succession.

If you want to change how taskbar buttons group together, press and hold or right-click any empty space on the taskbar, select Taskbar settings > Combine taskbar buttons and then select from the list:

Always, hide labels. This is the default setting. Each app appears as a single, unlabeled button, even when multiple windows for that app are open.

When taskbar is full. This setting shows each window as an individual, labeled button. When the taskbar becomes crowded, apps with multiple open windows collapse into a single app button. Select the button to see a list of the windows that are open.

Never. This setting shows each window as an individual, labeled button and never combines them, no matter how many windows are open. As more apps and windows open, buttons get smaller, and eventually the buttons will scroll.

If you use multiple displays, you can make a different choice for your extra displays. Select Taskbar settings > Multiple Displays > Combine taskbar buttons on other taskbars. For these displays, select from Always, hide labels, When taskbar is full, and Never.

Читайте также:  Слетела активация windows sp3

If you want to show more of your apps on the taskbar, you can show smaller versions of the buttons. Press and hold or right-click any empty space on the taskbar, select Taskbar settings , and then select On for Use small taskbar buttons. Select Off to return to the larger taskbar buttons.

Note: Badges aren’t displayed on small taskbar buttons.

A badge on a taskbar button is an alert to let you know that some activity is happening or needs to happen with that app.

For example, a bell badge on the Alarms & Clocks app alerts you to an active alarm that will notify you at the time you set. This feature is turned on by default, but if you want to make sure it’s on (or to turn it off), press and hold or right-click any empty space on the taskbar, select Taskbar settings , and go to Show badges on taskbar buttons.

Use the Peek feature to take a quick look at what’s on your desktop behind all the open windows.

Press and hold or right-click any empty space on the taskbar, select Taskbar settings , and then turn on Use Peek to preview the desktop when you move your mouse to the Show desktop button at the end of the taskbar.
Open Taskbar settings

Move the mouse pointer over (or press and hold) the far-right edge of the taskbar to see the desktop.

To restore the view of all your open windows, move the pointer away or press and hold the edge one more time.

You can hide the taskbar based on whether you’re in desktop mode or tablet mode. Press and hold or right-click any empty space on the taskbar, select Taskbar settings , and then turn on either Automatically hide the taskbar in desktop mode or Automatically hide the taskbar in tablet mode (or both).

The Taskbar

The Windows interface includes a special application desktop toolbar called the taskbar. You can use the taskbar for such tasks as switching between open windows and starting new applications.

For information on changes made to the taskbar as of WindowsВ 7, see Taskbar Extensions.

This topic contains the following sections.

About the Taskbar

The taskbar includes the following:

  • Start menu
  • Quick Launch bar (WindowsВ Vista and earlier only)
  • Taskbar buttons
  • Toolbars (optional)
  • Notification area

The Start menu contains commands that can access programs, documents, and settings. These commands include All Programs, Documents, Control Panel, Games, Help and Support, Shut down, and Search programs and files.

The Start in earlier versions of Windows contained items such as Find and Run, the functionality of which was included in Search programs and files in WindowsВ Vista and later.

The Quick Launch bar, available in versions of Windows earlier than WindowsВ 7, contains shortcuts to applications. Windows provides default entries, such as Windows Internet Explorer, and the user can add any further shortcuts that they choose. Icons in this area respond to a single click. In WindowsВ 7 and later, this functionality is included in the taskbar buttons.

The Shell places a button on the taskbar whenever an application creates an unowned window—that is, a window that does not have a parent and that has the appropriate extended style bits (see Managing Taskbar Buttons, below). To switch to a window, the user clicks its window button. This functionality has been greatly expanded as of Windows 7. For more information, see Taskbar Extensions.

Applications can put icons in the notification area to indicate the status of an operation or to notify the user about an event. For example, an application might put a printer icon in the notification area to show that a print job is under way. However, in WindowsВ 7 and later, some of the information previously provided by the notification area should be provided through an application’s taskbar button. The notification area is located at the right edge of the taskbar (if the taskbar is horizontal) or at the bottom (if the taskbar is vertical). For more information, see Notifications and the Notification Area.

The notification area also displays the current time if that option is selected. The option is found as:

  • WindowsВ 7 and later: The Clock drop-down list in the Turn system icons on or off page of the Notification Area Icons Control Panel application (also accessible through the notification area properties).
  • WindowsВ Vista: The Clock check box in the Notification Area page of the Taskbar and Start Menu properties window.
  • WindowsВ XP: The Show the clock check box in the Taskbar and Start Menu properties window.

The user can right-click the taskbar to display the shortcut menu. The shortcut menu includes commands to cascade windows, stack windows, show windows side-by-side, show the desktop, start Task Manager, and set taskbar properties. The shortcut menu also provides the option to add or remove a set of toolbars from the taskbar. You can add new toolbars to this menu by registering them under the CATID_DeskBand category. For more information, see Implementing Band Objects. Note that as of WindowsВ 7, the taskbar and the notification area have separate shortcut menus. These shortcut menus share some options, such as window arrangement, and add others.

Taskbar Display Options

The taskbar supports two display options: Auto-Hide and, in WindowsВ Vista and earlier only, Always On Top (the taskbar is always in this mode in WindowsВ 7 and later). To set these options, the user must open the taskbar shortcut menu, click Properties, and select or clear the Auto-hide the taskbar check box or the Keep the taskbar on top of other windows check box. To retrieve the state of these display options, use the ABM_GETSTATE message. If you would like to be notified when the state of these display options changes, process the ABN_STATECHANGE notification message in your window procedure. To change the state of these display options, use the ABM_SETSTATE message.

Читайте также:  Windows server ip alias

The work area is the portion of the screen not obscured by the taskbar. To retrieve the size of the work area, call the SystemParametersInfo function with the SPI_GETWORKAREA value set. To retrieve the rectangle coordinates that describe the location of the taskbar, use the ABM_GETTASKBARPOS message.

It is possible to cover the taskbar by explicitly setting the size of the window rectangle equal to the size of the screen with SetWindowPos. For WindowsВ 2000 systems or later, the window must lack either WS_CAPTION or WS_THICKFRAME, or else the window must be sized so that the client area covers the entire screen. Also particular to those systems, if the taskbar is set to Always On Top, it will remain hidden only while the application is the foreground application.

Adding Shortcuts to the Start Menu

To add an item to the Programs submenu on Microsoft WindowsВ NTВ 4.0, WindowsВ 2000 and later, or WindowsВ 95 or later, follow these steps.

  1. Create a shell link by using the IShellLink interface.
  2. Obtain the PIDL of the Programs folder by using SHGetSpecialFolderLocation, passing CSIDL_PROGRAMS.
  3. Add the Shell link to the Programs folder. You can also create a folder in the Programs folder and add the link to that folder.

Managing Taskbar Buttons

The Shell creates a button on the taskbar whenever an application creates a window that isn’t owned. To ensure that the window button is placed on the taskbar, create an unowned window with the WS_EX_APPWINDOW extended style. To prevent the window button from being placed on the taskbar, create the unowned window with the WS_EX_TOOLWINDOW extended style. As an alternative, you can create a hidden window and make this hidden window the owner of your visible window.

The Shell will remove a window’s button from the taskbar only if the window’s style supports visible taskbar buttons. If you want to dynamically change a window’s style to one that does not support visible taskbar buttons, you must hide the window first (by calling ShowWindow with SW_HIDE), change the window style, and then show the window.

The window button typically contains the application icon and title. However, if the application does not contain a system menu, the window button is created without the icon.

If you want your application to get the user’s attention when the window is not active, use the FlashWindow function to let the user know that a message is waiting. This function flashes the window button. Once the user clicks the window button to activate the window, your application can display the message.

Modifying the Contents of the Taskbar

Version 4.71 and later of Shell32.dll adds the capability to modify the contents of the taskbar. From an application, you can now add, remove, and activate taskbar buttons. Activating the item does not activate the window; it shows the item as pressed on the taskbar.

The taskbar modification capabilities are implemented in a Component Object Model (COM) object (CLSID_TaskbarList ) that exposes the ITaskbarList interface (IID_ITaskbarList). You must call the ITaskbarList::HrInit method to initialize the object. You can then use the methods of the ITaskbarList interface to modify the contents of the taskbar.

Adding, Modifying, and Deleting Icons in the Notification Area

Use the Shell_NotifyIcon function to add, modify, or delete icons from the notification area. The dwMessage parameter of Shell_NotifyIcon is a message to the taskbar that specifies the action to be taken. The pnid parameter is a pointer to a NOTIFYICONDATA structure that is used to identify the icon and pass any additional information that is needed for the system to process the message.

You can perform the following actions with notification area icons.

  • To add an icon to the taskbar’s notification area, call Shell_NotifyIcon with the dwMessage parameter set to NIM_ADD. The NOTIFYICONDATA structure is used to specify the icon’s handle and identifier, and any tooltip text. If the user has selected the Show Clock check box in the taskbar properties, the system places the icon to the immediate left of the clock. Otherwise, the icon appears on the right side or at the bottom of the taskbar. Any existing icons are shifted to the left to make room for the new icon.
  • To modify an icon’s information, including its icon handle, tooltip text, and callback message identifier, call Shell_NotifyIcon with dwMessage set to NIM_MODIFY.
  • To delete an icon from the notification area, call Shell_NotifyIcon with the dwMessage parameter set to NIM_DELETE.

When you have completed a user interface operation, return focus to the notification area by calling Shell_NotifyIcon with dwMessage set to NIM_SETFOCUS. For example, you could do this when a taskbar icon displays a shortcut menu, but the user cancels it by pressing the ESCAPE key.

Receiving Notification Area Callback Messages

Applications commonly put icons in the notification area of the taskbar to serve as status indicators. You can provide additional information when the user performs mouse actions, such as moving the mouse pointer over the icon or clicking the icon.

The system notifies you of mouse and keyboard events by sending an application-defined callback message that is associated with a particular icon. In this way, the system can notify an application when the user, for instance, clicks the icon or selects it by pressing a key.

Читайте также:  Как запустить восстановление системы windows 10 если система не загружается

You define an icon’s callback message when you add the icon to the taskbar. The callback message identifier is specified in the uCallbackMessage member of the NOTIFYICONDATA structure passed with NIM_ADD. When an event occurs, the system sends the callback message to the window procedure of the window specified by the hWnd member. The wParam parameter of the message contains the identifier of the taskbar icon in which the event occurred. The lParam parameter holds the mouse or keyboard message associated with the event. For example, when the mouse pointer moves onto a taskbar icon, lParam contains WM_MOUSEMOVE.

The results of various mouse events can be summarized as follows:

  • When the user moves the mouse pointer over the icon, the system displays the tooltip text that was specified in NOTIFYICONDATA.
  • When the user clicks the icon, your application receives a WM_LBUTTONDOWN notification.
  • When the user right-clicks the icon, your application receives a WM_RBUTTONDOWN notification.
  • When the user double-clicks the icon, your application receives a WM_LBUTTONDBLCLK notification.

Typically, clicking the icon causes the application to display a window with additional information, right-clicking displays a shortcut menu, and double-clicking executes the default shortcut menu command.

For an example of how to change the tooltip text associated with a notification area icon, see Balloon Tooltips for Status Bar Icons.

Versions 5.0 and later of the Shell handle Shell_NotifyIcon mouse and keyboard events in different ways than earlier Shell versions found on Windows NT 4.0, Windows 95, and Windows 98. The differences are as follows:

  • If a user requests a notify icon’s shortcut menu with the keyboard, the version 5.0 Shell sends the associated application a WM_CONTEXTMENU message. Earlier versions send WM_RBUTTONDOWN and WM_RBUTTONUP messages.
  • If a user selects a notify icon with the keyboard and activates it with the space bar or ENTER key, the version 5.0 Shell sends the associated application an NIN_KEYSELECT notification. Earlier versions send WM_RBUTTONDOWN and WM_RBUTTONUP messages.
  • If a user selects a notify icon with the mouse and activates it with the ENTER key, the version 5.0 Shell sends the associated application an NIN_SELECT notification. Earlier versions send WM_RBUTTONDOWN and WM_RBUTTONUP messages.
  • If a user passes the mouse pointer over an icon with which a balloon tooltip is associated, the version 6.0 Shell (WindowsВ XP)sends the following messages.
      • NIN_BALLOONSHOW — Sent when the balloon is shown (balloons are queued).
      • NIN_BALLOONHIDE — Sent when the balloon disappears—for example, when the icon is deleted. This message is not sent if the balloon is dismissed because of a timeout or a mouse click.
      • NIN_BALLOONTIMEOUT — Sent when the balloon is dismissed because of a timeout.
      • NIN_BALLOONUSERCLICK — Sent when the balloon is dismissed because of a mouse click.

You can select which way the Shell should behave by calling Shell_NotifyIcon with dwMessage set to NIM_SETVERSION. Set the uVersion member of the NOTIFYICONDATA structure to indicate whether you want version 5.0 or pre-version 5.0 behavior.

Taskbar Creation Notification

With Microsoft Internet ExplorerВ 4.0 and later, the Shell notifies applications that the taskbar has been created. When the taskbar is created, it registers a message with the TaskbarCreated string and then broadcasts this message to all top-level windows. When your taskbar application receives this message, it should assume that any taskbar icons it added have been removed and add them again. This feature generally applies only to services that are already running when the Shell launches. The following example shows a very simplified method for handling this case.

On Windows 10, the taskbar also broadcasts this message when the DPI of the primary display changes.

Using the Taskbar

This section includes examples that demonstrate how to add icons to the taskbar notification area and how to process callback messages for taskbar icons.

Adding and Deleting Taskbar Icons in the Notification Area

You add an icon to the taskbar notification area by filling in a NOTIFYICONDATA structure and then passing the structure to Shell_NotifyIcon with dwMessage set to NIM_ADD. The structure members must specify the handle to the window that is adding the icon, as well as the icon identifier and icon handle. You can also specify tooltip text for the icon. If you need to receive mouse messages for the icon, specify the identifier of the callback message that the system should use to send the message to the window procedure.

The function in the following example demonstrates how to add an icon to the taskbar.

To delete an icon from the taskbar notification area, fill a NOTIFYICONDATA structure and call Shell_NotifyIcon with dwMessage set to NIM_DELETE. When deleting a taskbar icon, specify only the cbSize, hWnd, and uID members of the structure. For example:

Receiving Mouse Events

If you specify a callback message for a taskbar icon, the system sends the message to your application whenever a mouse event occurs in the icon’s bounding rectangle. The wParam parameter of the message specifies the identifier of the taskbar icon, and the lParam parameter of the message specifies the message that the system generated as a result of the mouse event.

The function in the following example is from an application that adds both battery and printer icons to the taskbar. The application calls the function when it receives a callback message. The function determines whether the user has clicked one of the icons and, if a click has occurred, calls an application-defined function to display status information.

Оцените статью