BadgedIcons

Introduction

The Projects, Files and Services tabs in Netbeans Explorer display objects that comprise a Netbeans Project. Each object is represented as a node in a tree hierarchy, with a unique icon representing the type of object. The tree node icon may be badged. Icon badges are miniature icons that are overlaid on, or placed near an object's main icon. Badges provide transient information or status of an object (or objects contained within that node), such as: version control states, executable status, need-to-compile status, or syntax error. When version control is used, in addition to badging, color coding is applied to file names to indicate a file's current status.

Problem

The icon badging scheme reduces the number of unique icons that have to be used to represent each type of object and it's characteristic or condition. However, as new icons and badges are added to the IDE, a user must learn to recognize these composite icons or refer to online documentation for guidance. An example is shown below:

image:BadgedIcons_BadgedIcons.png

The following tables list badges that are shown in the NetBeans Explorer.

System-wide Icon Badges:

Badge Description

image:Error-badge.gif
Error. A file within the project cannot be parsed. A file cannot be found, opened or contains a syntax error. A project cannot be opened.
Can be applied to all objects/icons.

image:B-Warning_BadgedIcons.png
Warning. A dependent library or resource cannot be found.
Can be applied to all objects/icons.

image:B-Compile_BadgedIcons.png
The file needs to be compiled. The file has not been compiled or the source has changed since the last compilation.
Can be applied to files only.

image:B-Running_BadgedIcons.png
Contains main class.
Server or service is running. Server or service started.
Can be applied to Java source files. Can be applied to Servers.

Version Control Badges and Color Coded Filenames:

Badge/
Filename
Description

image:B-Conflict_BadgedIcons.png
The package or folder contains files that are in conflict with those in the repository.
Can be applied to folders and packages.

image:B-Modified_BadgedIcons.png
The package or folder contains files that were modified locally.
Can be applied to folders and packages.

Test.java
The file has been modified locally.
Can be applied to files only.

Test.java
The file has been added locally.
Can be applied to files only.

Test.java
The file contains conflicts that must be resolved.
Can be applied to files only.

Test.java
The file will be ignored by all version control commands.
Can be applied to files only.

Test.java
The file will be excluded from commit operations.
Can be applied to files only.

Proposed Solution

The proposed solution is to show object type and status in a brief tooltip. If multiple badges are used, the tooltip should show the status indicated by each of the badges. Based on the badging scheme in use today, up to three badges can be applied to an object at one time. Files can have three badges and a Version Control status indicated by a color coded file name and label. Tooltips should be displayed using the following format:

Line 1: <Object Name/Description>
Line 2: <Status1> <Status 2> <Status 3>

or, for files with version control information (indicated in a color coded file name/label), using the following format:

Line 1: <File Name> <Version Control Status>
Line 2: <Status1> <Status 2> <Status 3>

If more than one status is shown the most significant status (Error/Warning state) is shown first, followed by any other status information.

Examples of badged icons and their corresponding tooltips:

Badged Icon Tooltip

image:B-WebProjectModified_BadgedIcons.png TestApplication
image:TT-WebProjectModified_BadgedIcons.png

image:B-FileCompile_BadgedIcons.png Test.java
image:TT-FileModifiedCompile_BadgedIcons.png

image:B-FileErrorCompile_BadgedIcons.png Test.java
image:TT-FileConflictErrorCompile_BadgedIcons.png

image:B-FileErrorCompileMain_BadgedIcons.png Main.java
image:TT-FileConflictErrorCompileMain_BadgedIcons.png
image:B-File_BadgedIcons.png Test2.java image:TT-FileAdded_BadgedIcons.png

image:B-PackageErrorConflict_BadgedIcons.png com.sun.ui
image:TT-PackageConflictError_BadgedIcons.png

image:B-ServerRunning_BadgedIcons.png GlassFish V2
image:TT-ServerRunning_BadgedIcons.png

Future Work

  1. Explore the need to suppress tooltips.
  2. Define tooltips for badges shown in the Navigator and Output Windows.
Not logged in. Log in, Register

By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo