Eclipse - SPLessons

Eclipse Customizing

Home > Lesson > Chapter 9
SPLessons 5 Steps, 3 Clicks
5 Steps - 3 Clicks

Eclipse Customizing

Eclipse Customizing

shape Introduction

This chapter Eclipse Customizing demonstrate some common ways that a user can customize Eclipse to suit the working style to improve the productivity. There are various ways for customizing the eclipse toolbar. Following are the concepts covered.
  • Perspectives
  • Toolbars and menus
  • Shortcuts-key Bindings

Perspectives

shape Description

A perspective is a set of editors and views and this parts are present with in the perspective, the perspective is similar to a page within a book. Perspective is valuable in organizing different eclipse views around the editor area and are additional useful in dealing with toolbars and menus. User can save perspectives and can be switched to it in future. Eclipse plugin developer can either make a new perspective from scratch or update existing perspective. Updating existing perspective basically intends to suit the view in an existing perspective. There are five major operations that a user can perform on a perspective which are as follows.

Customizing Perspectives

shape Description

When a user customize Eclipse, it’s nothing but really customizing a Perspective, customizing perspectives is quite simple in eclipse, user can modify the current perspective or can create a new one and is not that dangerous to modify the current one because user can always get it back when ever needed. The image below display the default perspective of eclipse. The default perspective can be customized by dragging and dropping method. For example, from the above image initially the Outline and Task List tabs are at right side of the window, now this tabs can be dragged towards left side as shown in the image below. Now, in order to come back to the original perspective i.e. to the default perspective, go to Windows menu -> click Perspective -> click Reset Perspective as shown in the image below. Nevertheless, if user want to switch back and forth or somebody is borrowing the computer and wants to be in a more familiar environment, it's nice not to lose all the customization's by having to reset a perspective, so it’s highly recommend creating a new perspective. So, in order to create new perspective follow the procedure as mentioned. Go to Windows menu -> select Perspective -> Save Perspective As, as shown in the image below. Now, a popup window appears providing a list of Existing Perspectives and option for giving name for the created Perspective, provide preferred name for the perspective and proceed by clicking OK button as shown in the image below. The created perspective can be deleted by few clicks as mentioned below. Go to Windows menu-> select Preference, as shown in the image below. A popup window appears providing some options, in order to see and delete the perspective Click General -> select Perspectives -> select the required Perspective from Available perspectives list -> click Delete button as indicated in the image below. And notice that using plug-ins often adds perspectives, and if they're not uninstalled properly the perspectives won't be deleted. And this is where user can come to manually delete any unwanted perspectives.

Toolbars and menus

shape Description

By customizing Toolbars and Menus user can get rid of items that are seldom or never used and can toggle the toolbar on and off. The toolbar customization is done by dragging and dropping method, the menus and menu items can be changed with a single click and user can also modify a few of the cascading menus in Eclipse and combine various features from different categories. The image below display the default toolbar in Eclipse. In order to customize the tool bar follow the procedure mentioned below. Go to Window menu -> click Perspective -> select Customize Perspective as shown in the image below. Now, a popup window appears Known as Customize Perspective providing some sub section known as Tool Bar Visibility, Menu Visibility, Action Set Availability, Shortcuts. Select Tool Bar Visibility and uncheck the unwanted items on Tool bar and then click OK button as indicated in the image below. Tool bar can be hide entirely from the Eclipse by using Window menu, click on Window menu and select Hide Toolbar option as shown in the image below. Similarly In order to get back Toolbar, click Window menu and select Show Toolbar as shown in the image below.

shape More Info

Previous versions of Eclipse had a functioning Lock Toolbar command, and in fact in Quick Access it still exist. In order to check type Lock and Lock the Toolbars, but it doesn't appear to do anything anymore. This may come back in a future version. If user go to a separator bar and hover, can get a move icon for clicking and dragging a particular toolbar to any position as per the need. The Menus visibility can also be changed similar to the Toolbar using the Customize Perspective. Click Window menu -> select Perspective -> select Customize Perspective as shown in the image below. Now, uncheck the unwanted Menus from Menu Visibility -> Click OK button to save the changes as shown in the image below.

Shortcuts-key Bindings

shape Description

Eclipse supports keyboard shortcuts which is referred to as key bindings, using keys Workspace Preferences user can filter shortcuts by the command name or by the binding. User can also create shortcut keys, various sorting options are available while searching for a particular key binding. Shortcut keys are easy to export and import by which user can easily use those keys in both multiple version of Eclipse and on multiple machines without recreating them from scratch. In order to create new keys or to check the shortcut bindings for the existing commands follow the procedure mentioned. Go to Widows menu -> select Preferences as shown in the image below. Now, a popup window appears Known as Preferences providing some options, click General and select Keys as shown in the image below. User can Unbind the existing command and can bind with the own shortcut for that command using Unbind Command button and space provided for new shortcut Binding, all the existing commands and its bindings can be viewed using a Filter box, once done with all the changes click Apply or OK button.

Summary

shape Key Points

  • Adding, modifying and deleting perspectives are easy in Eclipse.
  • There are multiple ways to customize Toolbars and Menus.
  • User can master the keyboard shortcuts dialog and can import or export the keyboard settings.