org.eclipse..[.*]- General form of package names The following subprojects are assigned at the time of writing: org.eclipse.jdt.[.*] - Java development tooling org.eclipse.pde.[.*] -
Trang 1o 1.4 Internal Implementation Packages
o 1.5 Test Suite Packages
• 6 Plug-ins and Extension Points
• 7 System Files and Settings
General
Like other open source projects, the code base for the Eclipse project should avoid using names that reference a particular company or their commercial products
Eclipse Workspace Projects
When Eclipse is being used to develop plug-ins for the Eclipse project, the name of the Eclipse workspace project should match the name of the plug-in For example,
org.eclipse.core.runtime plug-in is developed in an Eclipse workspace project named org.eclipse.core.runtime
Java Packages
The Eclipse Platform consists of a collection of Java packages The package namespace
is managed in conformance with Sun's package naming guidelines; subpackages should not be created without prior approval from the owner of the package subtree The
packages for the open-source Eclipse project are all subpackages org.eclipse
The first package name segment after org.eclipse is generally the subproject name, followed by the component name
Trang 2org.eclipse.<subproject>.<component>[.*]- General form of package names
The following subprojects are assigned at the time of writing:
org.eclipse.jdt.<component>[.*] - Java development tooling
org.eclipse.pde.<component>[.*] - Plug-in development environment
The following package name segments are reserved:
internal - indicates an internal implementation package that
org.eclipse.<component>[.*] - Eclipse Platform proper
org.eclipse.<component>.internal[.*] - Eclipse Platform internal package
org.eclipse.<component>.tests[.*] - Eclipse Platform tests
org.eclipse.<component>.examples[.*] - Eclipse Platform examples
The following components of the Eclipse Platform proper are assigned at the time of writing:
org.eclipse.ant[.*] - Ant support
org.eclipse.compare[.*] - Compare support
org.eclipse.core[.*] - Platform core
org.eclipse.debug[.*] - Debug
org.eclipse.help[.*] - Help support
org.eclipse.jdi[.*] - Eclipse implementation of Java Debug Interface (JDI)
org.eclipse.jface[.*] - JFace
org.eclipse.platform[.*] - Documentation
org.eclipse.scripting[.*] - Scripting support
org.eclipse.sdk[.*] - SDK configuration
org.eclipse.search[.*] - Search support
org.eclipse.swt[.*] - Standard Widget Toolkit
org.eclipse.ui[.*] - Workbench
org.eclipse.update[.*] - Plug-in live update
org.eclipse.vcm[.*] - Version and Configuration Management
org.eclipse.webdav[.*] - WebDAV support
Trang 3For example,
org.eclipse.jdt.internal.core.compiler - Correct usage
org.eclipse.jdt.core.internal.compiler - Incorrect internal should immediately follow subproject name
org.eclipse.core.internal.resources - Correct usage
org.eclipse.internal.core.resources - Incorrect internal should never immediately follow org.eclipse
org.eclipse.core.resources.internal - Incorrect internal should immediately follow Eclipse Platform component name
of API packages should not contain internal, tests, or examples to avoid confusion with the scheme for naming non-API packages
Internal Implementation Packages
All packages that are part of the platform implementation but contain no API that should
be exposed to ISVs are considered internal implementation packages All implementation packages should be flagged as internal, with the tag occurring just after the major
package name ISVs will be told that all packages marked internal are out of bounds (A simple text search for ".internal." detects suspicious reference in source files; likewise,
"/internal/" is suspicious in class files)
Test Suite Packages
All packages containing test suites should be flagged as tests, with the tag occurring just after the major package name Fully automated tests are the norm; so, for example, org.eclipse.core.tests.resources would contain automated tests for API in
org.eclipse.core.resources Interactive tests (ones requiring a hands-on tester) should be flagged with interactive as the last package name segment; so, for example,
org.eclipse.core.tests.resources.interactive would contain the corresponding interactive tests
Trang 4• Package names should contain only lowercase ASCII alphanumerics, and avoid underscore _ or dollar sign $ characters
Classes and Interfaces
Sun's naming guidelines states
Class names should be nouns, in mixed case with the first letter of each internal word capitalized Try to keep your class names simple and descriptive Use whole words - avoid acronyms and abbreviations (unless the abbreviation is much more widely used than the long form, such as URL or HTML)
Examples:
• class Raster;
• class ImageSprite;
Interface names should be capitalized like class names
For interface names, we follow the "I"-for-interface convention: all interface names are prefixed with an "I" For example, "IWorkspace" or "IIndex" This convention aids code readability by making interface names more readily recognizable
Additional rules:
The names of exception classes (subclasses of Exception) should follow the common practice of ending in "Exception"
Methods
Sun's naming guidelines states
Methods should be verbs, in mixed case with the first letter lowercase, with the first letter of each internal word capitalized
Trang 5The named of methods should follow common practice for naming getters
(getX()), setters (setX()), and predicates (isX(), hasX())
Variables
Sun's naming guidelines states
Except for variables, all instance, class, and class constants are in mixed case with
a lowercase first letter Internal words start with capital letters Variable names should not start with underscore _ or dollar sign $ characters, even though both are allowed
Variable names should be short yet meaningful The choice of a variable name should be mnemonic - that is, designed to indicate to the casual observer the intent of its use One-character variable names should be avoided except for temporary "throwaway" variables Common names for temporary variables are i,
j, k, m, and n for integers; c, d, and e for characters
Sun's naming guidelines states
The names of variables declared class constants and of ANSI constants should be all uppercase with words separated by underscores ("_")
Examples:
• static final int MIN_WIDTH = 4;
• static final int MAX_WIDTH = 999;
• static final int GET_THE_CPU = 1;
Plug-ins and Extension Points
All plug-ins (and plug-in fragments), including the ones that are part of the Eclipse Platform, like the Resources and Workbench plug-ins, must have unique identifiers following the same style of naming convention as Java packages For example, the workbench plug-in is named org.eclipse.ui
The names of a plug-in and the names of the Java packages declared within the code library of that plug-in commonly align For example, the org.eclipse.ui plug-in declares
Trang 6much of its code in packages named org.eclipse.ui.* While alignment is the
recommended practice, it is not an absolute requirement For instance, the org.eclipse.ui plug-in also declares code in packages named org.eclipse.jface.* The org.eclipse.ant.core plug-in declares code in packages named org.eclipse.ant.core and org.apache.tools.ant.*
The plug-in namespace is managed hierarchically; do not create plug-in without prior approval from the owner of the enclosing namespace
Extension points that expect multiple extensions should have plural names For example,
"builders" rather than "builder"
System Files and Settings
By convention, files or folders that start with a period ('.') are considered "system files" and should not be edited by users or, directly, by other components that do not "own" them
Of special note is the ".settings" folder in a workspace project This folder holds various forms of preference or metadata specific to that workspace project Files in this directory
do not have to start with a period (they are assumed "system files" as they are in a
"system folder") but they must follow the same naming conventions outlined elsewhere
in this guide That is, they must identify themselves with their Eclipse Project's
namespace (e.g org.eclipse.jdt, org.eclipse.jst, etc) and they should be as specific as possible to denote the package they come from, or the function they are serving For example,
Trang 7Eclipse User Interface Guidelines
(Version 2.1 - 3.x Working Draft)
Nick Edgar, Kevin Haaland, Jin Li and Kimberley Peter
Last Updated: February 2004
Note: Please use the discussion page to add comments instead of embedding them in this
document
Note: We have created a section for hosting the drafts of ongoing Eclipse v3.x UI
guidelines (Best Practices) updates
Go to Eclipse UI Best Practices v3.x updates (Last updated in June, 2006) Notice
Your feedback can influence the ideas and guidelines described here If you have
suggestions, please provide us with your feedback on the UI mailing list or on the
discussion page
Introduction
In this document the Eclipse user interface guidelines are defined
Eclipse is a universal tool platform - an open, extensible IDE for anything, but nothing in particular The real value comes from tool plug-ins that "teach" Eclipse how to work with things - Java™ files, Web content, graphics, video - almost anything you can imagine Eclipse allows you to independently develop tools that integrate with other people's tools
so seamlessly, you won't know where one tool ends and another starts The very notion of
a tool, as we know it, disappears completely
The platform is very flexible and extensible, but this flexibility has a serious drawback In particular, there is no way within the program to ensure user interface consistency
between the registered components within the platform This document attempts to reconcile this problem, by defining standard user interface guidelines for the creation of new components If these guidelines are adopted within your own tools, it will lead to greater consistency with the platform and other tools, and an easier learning curve for your customers
These guidelines are intended for use by designers and implementors of an Eclipse user interface extension
Trang 8The Workbench
To start out, let's take a look at the Eclipse workbench user interface, and the various
components within it
The workbench is a collection of windows Each window contains a menu bar, a toolbar,
a shortcut bar and one or more perspectives
A perspective is a visual container for a set of views and content editors The views exist
wholly within the perspective and are not shared, but any opened content editors are
shared across perspectives If two or more perspectives have the same view opened, they
share the same instance of the view although its layout may differ in the perspectives For
perspectives in different Workbench windows, neither editors nor views are shared A
perspective is like a page within a book It exists within a window along with any number
Trang 9of other perspectives and, like a page within a book, only one perspective is visible at any time
The Workbench's main menu bar usually contains the File, Edit, Navigate, Project, Window, Help top-level menus Other top-level menus that are in between the Edit and Project menu are typically context specific, based on the current active perspective, front most editor (whether active or not), and active view
In the File menu you will find a New submenu, which contains menu items for Project, Folder, and File creation The File menu also contains menu items for Import and Export, which are used to import files into the Workbench, and export them out again In the Edit menu, you will find familiar commands like Cut, Copy, Paste, and Delete These
commands are known as global commands, and target the active part In other words, if the Delete command is invoked with the Navigator active, the actual implementation is performed by the Navigator In the Project menu, you will find project related commands such as Open project, Close project and Rebuild project are available In the Run menu, you will find commands related to running and debugging application code, and
launching external tools such Ant scripts In the Window menu, you will find the Open Perspective submenu to open different perspectives to suit to needs of your development tasks You will find perspective layout management menu items You will also find the Show View submenu to add views to the current Workbench window In addition, you will find the Preferences menu item, which is used to modify the functional preferences
of the Workbench
As a plug-in developer, you can contribute new views, editors, wizards, menu, and tool items to the platform These contributions are defined using XML, and once registered, integrate seamlessly with the components which already exist in the platform
Projects, Folders and Files
Eclipse can be used to create many different kinds of content - Java files, Web content, graphics, video - almost anything you can imagine These objects are stored as regular files within the Eclipse workspace The workspace consists of one or more top level projects Each project contains a collection of folders and files These objects are known
as resources
Getting Started
For most developers, an introduction to the platform can be overwhelming, and you may ask "where do I get started?" Here are a few basic guidelines which will help you This document is intended for UI designers and developers With this audience in mind,
we can talk about the two main layers of any application: the model layer and the user interface layer In the model layer of Eclipse, known as the Workspace, is a collection of resources (projects, folders and files) The user interface, or the Workbench, defines the presentation for those resources
Trang 10As a UI developer, you will also have a model and a presentation If we assume that your goal is to make the model visible, through some presentation, most developers will start out by adding a new view or editor to the workbench
In Eclipse, an editor is used to contain the primary content, such as a document or data object, which users interact with In every case, this content is the primary focus of attention and a reflection of the primary task To illustrate this concept, let's look at some common examples
To do Java programming, the primary task is to create, edit, and debug Java code The primary focus is the Java code, so an editor is used to interact with that code The
navigator, outline, and properties view exist to support the primary task, but rarely hold your attention for an extended period of time while you are writing Java code
To read email, the primary task is to create, send, read, and reply to email The primary focus is a particular email message, so an editor is used to view or reply to an email message A view may be used to select an email message to read, and open an editor
To communicate using instant messaging, the primary task is the conversation The primary focus is a particular conversation, so an editor is used to carry on that
conversation A view may be used to list people with whom you can initiate a
contribute commands to the workbench's main menu bar and toolbar
A view may be used to save your favorite links, and reopen them At any time, you may decide to edit the page you are looking at This causes a new editor to open Views are used to support the primary task You use them to navigate a hierarchy of information, open an editor, or view properties for the active part Each view may have its own local toolbar and local menu bar
Once you have added a view or editor, an interesting question arises Where did this model come from? In Eclipse, most data is created using a creation wizard You may want to add a creation wizard too And once an object exists, you may need a way to edit the properties for that object using a properties page, or the properties dialog
All of these ideas will be discussed, in detail, in the following sections
General UI Guidelines
Trang 11the Java dev
pse for guida
pse If so, ado
s
at you already
e basic UI dedback, aesthewledge, plea
y good user igiveness, feed
s, it may be terface Thisvironment, w
st experiencePractices seclipse platfor
orm lead for
uidelines that
r standard U
an Interface ult those gui
y have a basesign principetics, and sim
se read the r
interface desdback, aesth
form for toolhip of teams,
e, the usabil
by user inteappropriate loooling and th
y cases, the form's workfwith the platfo
tempting to
s interface wwhere other to
e, and force yction for exa
rm newsgrou
user interfac
t are unique
UI guidelinesGuidelines, idelines for b
sic understanples: user in mplicity If yrelevant docu
sign principlhetics, and si
l plug-ins Th
or the user mity of an indrface consistook and feel
he Plug-in Deworkflow yoflow and useorm and othe
ignore the wwill almost ceools adopt thyour customamples and mups to share
ce conventio
and specific
s such as Micand Java Lobasic UI des
nding of the control, direyou do not cuumentation f
les: user in cimplicity
hese plug-inmay assembdividual tool,tency
l for a tool, levelopment
ou imagine m
er interface c
er plug-ins,
workflow of ertainly stand
he platform cmers to learn more informinformation
ons
c to the Eclipcrosoft® Usook and Feelign and imp
Eclipse UI aectness, consurrently havefirst
ontrol, direc
ns may be deble a set of pl, and Eclipse
ook to the plEnvironmenmay alreadyconventions
and an easie
Eclipse and
d out like a sconventionsnew ideas
mation
with the com
pse platformser
l Guidelineslementation
architecture sistency,
e the
ctness,
eveloped by lug-ins from
e as a whole
latform first
nt (PDE) in
y exist in This will
er learning
implement sore thumb i You lose
mmunity
m
a
m ,
t,
a
in
Trang 12he focus is, wwindow
mix UI met
n source proity, write a pplatform for pse.org and jo
teresting ide
or all
nventions of instance, theshaded titleswithin that pa
aphors It m
oject If you proposal, andproduct deveoin the Eclip
ea, work with
f Eclipse, be
e active part
s within an eart, but it wi
may blur the o
feel your ide
d work with elopment an
se UI mailin
h the Eclipse
careful not t
in a workbeeditor (see be
cept, and you
rally useful, community customer sati
clipse a
se
d
o
Trang 13r example, "C
yle capitaliza
s, tabs, columouns, pronou
yle capitalizaboxes, radio bfirst word, a
ble on a variedifferent lan
d for the texresources fro
to a new locPractices se
s, tooltip, tababel
should be apChoose an op
ation for men
mn headingsuns, adjective
ation for all cbuttons, grouand any prop
ety of differeguages and n
xt and image
om the sourccale
ction for exa
he resources
the appropri
on for guidel
plug-in leadialog or wind
bs, and push
pplied to all ption for the
h plug-in Thplug-in itsel
, including thtalize the fir
Do not includ
g or window,
xt fields Capord Java
ty of locales
h, a localizatihis involves
ons, and
as a group
hose used forst and last
de ending
, including pitalize the
In ion strategy the
Trang 14o notice, and
ccurs which municate the
g error occur
e occurrence logging faciall the correspuld provide th
name ame (user fri
guidelines wmentation acro
s visual sem
e following
n for guideli
requires eithhould be usedeal with th
duct, an erroThe error shves the user ture, and con
g information
e)
duct, commu
d for Eclipsehese guidelinimplementinamework
ure consistenpse tools andand implem
an opportunntact their sy
n in the deta
unicate the o
e follow a cones you will
ng Eclipse s
ncy of visual
d plug-ins Cmentation con
rrors occur in
t or immediarror to the us
t or immedia
ould be used
e logged usinnity to restarystem adminail area of the
occurrence w
mmon style find basic dstyle icons an
l user interfaConsistency onsiderations
n an editor,
ate attention ser This
ate attention
to
ng the
rt the nistrator
e error
with a dialog
called the design
nd wizard
ace elements
of these These topic
,
s
cs
Trang 15e a consistenize confusionts whenever
ons have alre
ny of the icon
re concepts ispecific mean
ng is mainta
lipse style ic
er interface Tthat many h
cons, a visuaThese concehave come to
erience, und
er, we encou
eated in the cal elementsthe following
e should be t
al language wepts are now
o know throu
derstanding ourage you to
Eclipse visu
s you may ne
g table Eachtaken when u
was formed trepresentedugh using Ec
of concepts are-use Eclip
ual style so theed already e
h of these eleusing them t
to describe a
d by a large clipse tools
across the pse style
here is a exist A ements
to ensure tha
a
at
Trang 16lette for crea
al 256 color p
ow
n the standarpalettes are creating Ecl
ive or selecte
ation and me
different pa
red to as "coective, view
ar, toolbar w
palette that c
rd windows NOT the samlipse style ic
ed state of al
eaning across
alettes used t
olor"— state , toolbar, wizard, and
consists of 2
.aco color
me and cons
Trang 17e icons have specific locawhere they ar
tte
versions of y
of the 8 colo
te for creatinlbar icons
tte
d versions of palette, that
te for creatin
been categoation within
lor icons, yoelow:
ou will need
erspective, v
bled icons, yshown below
r,
d
Trang 18A Product
The Product icon represents the branding of the product, and is always located on the far left of the window title bar before the perspective, document, and product name
B Perspective and Fastview
Perspective and fastview icons are found down the left side of the workbench These icons allow the user to quickly switch between different opened perspectives, or to invoke different views that have been created as fastviews
E View
View icons are found on the left side of the titlebar of each view within the workbench These icons indicate each view’s function
F Local (View) Toolbar
Local toolbar icons are found to the right of the view icon on the titlebar of each view within the workbench These icons invoke an command on objects in that view only
Trang 19o found in tre
s as signifier
e in the locat
e style icons ixel space is
f empty pixe
e location of
c placement
e proper siziallotted scre
View Ico
Maximumcentered
f the empty pshown to en
ing of the seeen space
ons
m 16 pixels wxels must be
uding main, p
ws, and on Ed)
ws They areort of change
igned for wi
d within an a
r the image ifor proper plpixels in the nsure alignmeparate types
s of icons, an
ixels high, al and bottom
ow The ser interface
Trang 20Empty pi
Toolbar Toolbar Local To
Maximumcentered
Empty pi
Model O
Maximumcentered
Model Obhigh
Object O
Object Ovpixel sizeMaximumIcon shouseparate iSee the nkeyline o
ifications for
ive Icons
w Icons
m 16 pixels wxels must be
Icons Wizard Ico oolbar Icons
m 16 pixels wxels should
Object Icons
m 16 pixels wbject icons m
Overlay Icon
verlays are o
e
m 7 pixels wuld have a w
it from the icext section o
ns
one of the ex
wide x 8 pixewhite outside con it is bein
on Icon Positypes of Obje
xceptions to
ls high, alwakeyline arou
ng appendedtioning for uect Overlay
d to
using the icons
d
Trang 21Cut the icons with the specific placement shown to ensure alignment in the user interface.
Icon Positioning
To follow from the specific size and placement of the different types of icons within their allotted screen space, the following positioning guidelines will help with the alignment of these elements relative to one another, and will aid in creating a well organized and aesthetically integrated user interface (All measurements are in pixels.)
Overview
1 Toolbar icons
(Includes Toolbar and Toolbar Wizard Icons)
Trang 22Item Positioning and Spacing
B Between left margin and handle 4 pixels
C Between handle and first icon 7 pixels
C Between icon and top of toolbar 3 pixels
C Between icon and bottom of toolbar 3 pixels
C Between icon and twisty 7 pixels
D Between twisty and hard rule 7 pixels
E Between hard rule and icon 6 pixels
G Between icon and hard rule 10 pixels
H Between hard rule and handle 2 pixels
2 Titlebar icons
(Includes View and Local Toolbar Icons)
Trang 23Item Positioning and Spacing
B Between left margin and view icon 4 pixels
B Between view icon and text label 3 pixels
B Between title bar icons and top of title bar 3 pixels
B Between title bar icons and bottom of title bar 3 pixels
C Between local toolbar icons 7 pixels
D Between last local toolbar icon and closing
Trang 24Perspective Icons Item Positioning and
Spacing
A Perspective bar 27 pixels wide
B Between left margin and
D Vertically between icons 6 pixels
E Between icon and hard
rule
6 pixels
Fastview Icons Item Positioning and
Spacing
D Vertically between icons
(same as perspective icons)
F Between top of fastview
section and first icon
3 pixels
F Between icon and right
margin
6 pixels
4 Tree View icons
(Model Object Icons)
Trang 25Item Positioning and Spacing
A Between “+/-” widget and left of window 4 pixels
A Between “+/-” widget and top of window 4 pixels
B Between top of window and first icon 0 pixels
B Vertically between icons 0 pixels
B Between horizontal treeview branch and icon 0 pixels
B Between icon and text label 3 pixels
C Text is nested within the text label 3 pixels each on left and
top, 2 pixels on right, 4 pixels on bottom (length varies)
Icon Overlays
As stated under Icon Size & Placement, all overlays are consistently the same size: 7 x 8 pixels An additional white border keyline is included on Project Nature and Java Overlay types to visually separate them from the underlying Model Object icon The keyline location varies depending on the overlay's placement on the underlying icon
Project Nature Overlay
The project nature overlays are displayed in the Navigator and the Package views They are completely superimposed on the model object at the top right corner of the 16 x 16 icon space
Only a few project nature overlay icons have been created to prevent crowding in the
interface Project nature overlays quickly identify the various types of projects that can
be contained in the Navigator and mirroring views
Trang 26to the right o
s A maximu
ch an overlagning Java oion of overla
s that alwaylow — of the
applied aroun
splayed in alobject at the
y identifies t
failure, and
yed in the Oumodel objec
of a model ob
um of 3 java
ay appears deoverlays, it isays without c
s display at t
e model obje
nd the image
ll tree viewsbottom left
the status of
success
utline, Hiera
ct icon, so thbject icon, ooverlays canepends on th
s important tcompromisinthe bottom r
ect: synchr
e to enhance
s This type ocorner of the
f an object E
archy, and Pahey extend thoverlapping t
n be put on t
he order in w
to make sure
ng readabilitright corner —
e the base ob
ty Note that
— 'C' positioethod) and
been bject icon can
t there are
on in the
run (class)
n
Trang 27Java overlays identify attributes of an object Examples of Java overlays are static, final,
abstract, and synchronized
Note: In the Hierarchy and Outline views, the Java overlays are appended to the right of
the model object as shown, but in the Package view they are stacked over the model object
Version Control Overlay
Version control overlays are displayed in the Navigator view and in the Structure View of the Merge Editor in CVS When they are displayed in the Navigator view, the overlay is completely superimposed on the model object at the right of the 16 x 16 icon space
When the version control overlays are displayed in the Structure View of the Merge Editor in CVS, they are appended to the model object, so they extend the 16x16 space They are placed to the right of a model object icon, overlapping the 16x16 model object space by 3 pixels In CVS there is a maximum of 2 overlays on the right of the object
Trang 28alette for cre
of an object
deleted, and
pes of icons
e 183 color pgned using a
Trang 29f each wizarould not exce
d banner spaaphic Gener
ifications for
ng guideline
to fit withinright corner o
aphic will va
s wide x 45 p
n, there is noaphic is cent
o firm rule ftered vertica
aphics
g wizard banscreen space
d
ng on the ele
for where to ally, and off-
nner
e that is 75
ements
place the center to thee
Trang 30Cut the wizard graphics with the specific placement shown to ensure alignment in the wizard banner area.
Implementation Conventions
Eclipse provides a set of directory names and structure for storing and accessing user interface graphics easily in any plug-in This section describes the naming conventions and directory path used in Eclipse If followed, the predefined directory names and path allow for the icon and wizard graphic files to be implemented directly into the plug-in structure without any need for modifications
From icon request to delivery, the naming and structure is the same If you use a different user interface directory name or more than one directory to store graphics than that specified at request time, notify your visual design contact of these changes so that they can maintain a parallel system Further, keeping the number of directories in which you store your graphics to a minimum, will reduce unnecessary duplication of graphics and ease resource management issues considerably
Directory Names and Structure
Once your icons have been conceptualized, designed, approved and cut, they are stored using the directory naming convention and structure described below
1 The name of the first level directory refers to the Eclipse platform: Icons used in
an Eclipse plug-in are called org.eclipse.pluginname.ui_0.0.0 Where
pluginname is substituted with the name of the plug-in and _0.0.0 is substituted with the Eclipse version number, for example, org.eclipse.debug.ui_2.1.0
2 Each plug-in that manages user interface elements for a tool set contains a second
level directory called icons
3 Within the icons directory, there are separate folders with names that indicate the
state, type and size of the icons, as follows:
1 The first letter of the folder name indicates the icon state The letter c for color, d for disabled, and e for enabled
2 The next 3 to 6 letters signify the icon type: toolbar (tool), local toolbar (lcl), view
or perspective (view), model object (obj), overlay (ovr), wizard banner (wizban)
3 The last two digits of the folder name indicate the size of the icons within
Usually it will be 16 (to indicate the 16 pixel by 16 pixel size), but there might be others (for example, 32 would indicate the 32 x 32 size) depending on the plug-in
requirements
Trang 31in may not r
he complete here are some
e of icon thatourage you tstructure as
on has multiabled, and diided is impor
a complete d
ide the icons
n type foldernew plug-insectory structuequire all typset of icon tetimes excep
t is not cove
to get to kno shown
iple states, thsabled state rtant, and wi
e stored in th
ory structure
ames provid
phics within ctories
directory stru
s directory, th
rs This full
s The structuure
pes of icons types that yoptions to thisered by this s
ow the differ
he file namefolders Becill prevent y
ou may need
s list of typesstandard set
rent types an
e is the same cause of this
ou from havder
he sample T
d in your plug
s in plug-ins This is rare
nd their respe
across eachorganizationving to renam
s that have a , however, ective states,
Trang 32oses not inte
nce, you wil
or File Nam
useful for m
an be used towing table
ed for icons lowing func ation:
oke a wizardhin a wizardoke executab
in an editor
in a navigat
no fit into anegories
disabled stat
re the icons ancepts they ruplicate file nbeing able t
e readily, esp
me Suffixe
making the di
o denote theshows how
with the ction or
d, or are grap
d ble files view tor view
ny of the oth
tes provided
are designedrepresent, annames If the
to quickly mpecially as th
es
stinction bet
e location or suffixes are
Icon T
phics WizardialogWizarToolband glToolband glToolband glLocal
of theView top, leher Toolband glView
d will help en
nd may preve
e names are make the disti
he volume of
tween types function of being used f
Type and L
rd banner gra
g windows
rd icons: usebar icons: uselobal toolbarbar icons: uselobal toolbarbar icons: uselobal toolbartoolbar icon title area ofand perspeceft corner of bar icons: uselobal toolbarand perspec
nsure appropent misuse owell consideinction betw
f your graph
of user inter
an icon or wfor image fil
rface wizard
le names in
d in wizard
d toolbars ding menus, ding menus, ding menus,
n the far rightfound in the ding menus, found in the
s
t
Trang 33resent mode
model objecect palettes for commandsystem, e.g
el objects
ct icons on
ds that engag build comm
of Local
of theLocal
of the
et Local
of theView top, leModelist viModepalette
ge mand
Toolband glLocal
ay icons: pla
t icon to indition
ct icons: usedand propertiand perspeceft corner of toolbar icon title area oftoolbar icon title area oftoolbar icon title area ofand perspeceft corner of
el object icon
ew, and prop
el object icon
es bar icons: uselobal toolbartoolbar icon title area of
d in the tree ies view
n the far right
n the far right
n the far rightfound in the
he tree view,
object ding menus,
n the far right
Trang 34m label, toolt
eloper, you cividual view
et, a set of ta
a view or ediation of the m
your file nam
can contribu
ws and editorask oriented tor is performmain areas o
mes if possib
ocation or fu
interface icon
to carry out bar In reflec
ge
ute command
rs Contributcommands wmed using in
ds to the winion to the wwhich the usndividual co
ndow menu bindow is perser can showommand
s a character)
newint_wiz
unless the
s, may appeabutes for the
bar and rformed
w or hide
)
ar
Trang 35In this section we'll look at general command guidelines For information on window,
view, or editor specific guidelines, see Windows, Views, and Editors
Appearance
Each command must have a label, tool tip, and image If the command appears in a
toolbar, the command image will be displayed on all platforms If the command appears
in a menu, the image will only be displayed on some platforms, such as Windows® 2000 The label and tool tip should use Headline style capitalization, as defined in General UI
Guidelines
Each command must provide one full color image This image will be displayed if the
mouse is placed over the command It will also be used to generate the enabled, disabled, and pressed images which appear in normal command use Commands which are
contributed in code also have the option to define explicit images for enabled, disabled,
and roll over This option can be used for greater control over image appearance
Trang 36ed on, and th
e version 2.1for the commShow Type H
oltip should
se the text sa
any commanuld adopt the
ws the valid u
label, tool tiptalization
should descrcurrent stateutton For tog
he label shou
1, it is recommand label
Hierarchy bu
describe theame as that f
nd which ha same termin
use of Headl
p, and full co
ribe the beha
For push bggle buttonsuld not changmmended thaFor instanceutton is show
e result of thfor the comm
as a similar bnology
g on the state
p for a commowing snapstool tips tex
, not the curr
existing comm
oolbar
nd tool tip
e command idecribe the ffect when
e of the mand uses theshot the
Trang 37ng an existin
n object insidterm "Add"
ement shouldtimistically anot be comp
for modal inack
rst opens, thquired from ontrol is fou
or requires
e default but
e term "NewProject" and
ng resource
de a resource should be u
ld calculate
d be quick Iand display aleted
nteraction wi
e initial focuthe user Thund where insimple confitton
w" should be
"New Java
e (e.g., a tagused; the use
If command
an appropria
ith the user
us should behis control caformation isfirmation from
used in an cClass" The
enablement ate message
file; a methsomething to
te and Add c
essfully If t
essfully
xpensive to clly enabled
f the dialog pthe initial fo
r wizard Forte" should be
quick, enablemand is
information,
ol where tab order of provides cus may also
Trang 38on
atever is sele
e selected ite(whether the
ave the followelected buck
ected on the ems from the
wing controlkets
l buttons, in
ight
m left to righcontrol butto
tainer If button
m the left to
for moving
ource objectsrder
s
Trang 39o avoid distra
to prompt thrmation is in
a more poliseach wizard
monly used fo
o be used foruld be used ider
nsisting of m
a header, conmage represeale palette foacting the us
he user for invalid The pshed feel, an
or consistencser from the nformation wresence of th
nd greater peext, Finish, a
on of new reion of any tamany steps in
which must b
anner graphiizard task, a
cy with otherimportant fiwhich is abse
he header, werception of and Cancel b
sources, resoask involving
n the task, an
be completed
c and a text and should be
r banners in ields of the went, and dispwith banner gquality to thbutton should
Trang 40ate to display
with a promp
of the wizardNew File wiz
or folder, thname, and poes not poin
y an error m
pt, not an err
d should be dzard, the curr
he wizard wiput cursor foc
nt to a valid pstead, it will ection is on folder or pro
a banner gra
xt, Finish, an
uld be placeader should
message At th
ror message
derived fromrent workbenill pre-populcus in the neparent projecleave the fie
a file, a wizaoject of the f
ct or folder, eld blank andard may alsofile
ext area for uttons in the
t field requirprompt the us
e user hasn't
t where it is
n is examine
nt field with uiring user inthe wizard w
d put the cur
o go through
user footer
ring ser for the
t done
opened For
ed If it pointthe parent nput If the will not pre-rsor focus in
h these
r
ts
n