JBoss.comEnterprise Documentation
Version: 1.1.0.CR1
Copyright © 2007, 2008 JBoss, a division of Red Hat Inc.
April 2008
This guide covers the usage of Visual Web Tools in JBoss Developer Studio and JBoss Tools. The difference between these products is that JBoss Tools are just a set of Eclipse plugins where JBoss Developer Studio adds the following functionality:
an installer
Eclipse and Web Tools preconfigured
JBoss EAP with JBoss AS and Seam preconfigured
3rd party plugins bundled and configured
access to RHEL and Red Hat Network
access to the JBoss/Red Hat supported software
For additional information, please visit the JBoss Developer Studio home page at: http://www.jboss.com/products/devstudio.
In JBoss Tools there is an extensive collection of specialized wizards, editors and views that can be used in various scenarios while developing Web applications. The following chapters walk through these features.
Here is the table of the main features of Visual Web Tools:
Table 1.1. Key Functionality for Visual Web Tools
Feature | Benefit | Chapter |
---|---|---|
Visual Page Editor | Powerful and customizable visual page editor. Possibility to develop an application using any web technology: jsf, seam, struts, jsp, html and others. Developing using four tabs: visual/source, visual, source and preview. Fast and easy switching between these tabs. Split screen design of visual and source views. Full and instant synchronization between source and visual views. Integration with properties and outline views. Graphical toolbar to add inline styling to any tag. | visual page editor |
JBoss Tools Palette | Organizing various tags by groups, inserting tags into a jsp or xhtml page with one click, adding custom or 3rd party tag libraries into the palette, easy controling the number of tag groups shown on the palette. | jboss tools palette |
Web Projects View | Visualizing and displaying projects by function. Easy selecting of different kinds of items and dropping them into jsp pages. Using context menus to develop the application. Using icon shortcuts to create and import JSF and Struts projects. Expanding and inspecting tag library files. Selecting custom and third-party tag libraries to drag and drop onto the JBoss Tools Palette. | web projects view |
OpenOn | Easy navigation between views and other parts of your projects. | openOn |
Content Assist | Code completion proposals while working in java, xml, jsp, xhtml, xhtml, seam project and jsf configuration files. Content assist based on project data (dynamic code assist); with graphical editor. Code completion for values from property files, beans attributes and methods, navigation rule outcomes and jsf variables. | content assist |
Drag-and-Drop | Possibility of inserting any tag onto the page you are editing by just drag-and-droping it from the palette to this page. Adding any properties, managed bean attributes, navigation rules, tag library file declarations, jsp files from web projects view by clicking them and draging to source code. | visual page editor drag-and-drop |
Rich Faces Support | Tight integration between JBDS and RichFaces frameworks. Easy managing RichFaces components in any web application. Support for RichFaces and Ajax4jsf libraries in JBoss Tools Palette. Rendering RichFaces components in Visual Page Editor. | rich faces support |
JBoss Developer Studio is bundled with Spring IDE for Eclipse. Visit Spring IDE site for the latest versions and documentation.
Spring IDE is a graphical user interface for the configuration files used by the Spring Framework. It's built as a set of plugins for the Eclipse platform.
In the JSF Tools Reference Guide and Struts Tools Reference Guide you had possibility to read about Graphical Editor for JSF and Struts configuration files, Graphical Editor for Tiles Files, Graphical Editor for Struts Validation Files. All these editors have OpenOn and Content Assist features, which are described in more details in this document. In addition you get to know a Visual Page Editor for combined visual and source editing of Web pages and many other editors for different types of files.
JBoss Developer Studio has powerful editor features that help you easily navigate within your application and make use of content and code assist no matter what project file (jsp, xhtml, xml, css, etc...) you are working on.
OpenOn lets you easily link directly from one resource to another in your project without using the Package Explorer view (project tree). With OpenOn, you can simply click on a reference to another file and the file will be opened.
OpenOn is available for the following files:
Java files
Press and hold down the Ctrl key. As you move the mouse cursor over different file references in the file, they display an underline. When you hover the name of the file you want to open, click and the file will open in its own editor. In this example the managed bean NameBean will open.
This is the result of using OpenOn.
You can also use OpenOn with defined attributes.
You can also open any JSP pages.
OpenOn is also very useful in JSP pages. It will allow you to quickly jump to the reference instead of having to hunt around in the project structure.
You can easily open the imported property files.
Use OpenOn to open a CSS file used with a JSP page:
Open managed beans:
For JSP files in a JSF project, you can also easily open the navigation rules by applying OpenOn to the JSF tag for the navigation outcome:
Content assist is available when working with
When working with JSF project in JBoss Developer Studio, you can use various Content Assist features while developing:
Content Assist for XML, JSP and JSF configuration files
Content Assist based on project data
Content Assist with graphical JSF editor
At any point when working with any XML, JSP and JSF configuration files Content Assist is available to help you. Simply type Ctrl-Space to see what is available.
Content Assist for JSF configuration file:
Content Assist for JSF JSP file:
Content Assist for other JSF XML project files (web.xml shown):
JBoss Developer Studio takes Content Assist to the next level. Studio will constantly scan your project and you will be able to insert code into the JSP page from your project that includes:
Values from Property files
"Managed beans" attributes and methods
Navigation Rule Outcomes
JSF variables (context, request etc...)
The figure below shows how to insert message from a Properties files. You simply put the cursor inside the "value" attribute and press Ctrl-Space. JBoss Developer Studio will scan your project and show a list of possible values to insert.
In the following screenshot we are inserting a "Managed bean" attribute value. Again, by simply clicking Ctrl-Space, JBoss Developer Studio will show a list of all possible values that you can insert.
Once you select a Managed bean, it will show you a list of all available attributes for the selected Managed bean (userBean).
Code Assist based on project data will also prompt you for navigation rules that exist in your JSF configuration file.
Content Assist features are available when you work with Struts projects.
Content Assist helps you in Struts Configuration file.
JBDS provides full code completion for JSF tags:
When the tag is selected the required attributes, if there any, are already inserted and the cursor is located to the first attribute. At this point you can ask for attribute proposals.
Content assist for HTML tags has the same mechanism as for JSF tags:
You can use as well attributes proposals for HTML tags:
JBDS indeed provides code completion for Rich Faces framework components. All you have to do is to install Rich Faces libraries into your project. See here how to install it.
To insert a Rich Faces component on a page expand JBoss Rich Faces group on the palette
Click on some component
Put the needed attributes in the Insert Tag dialog and click Finish button
The Rich Faces tag will be inserted on your page displayed in source and visual modes:
Here is what you need to do to add project based code assist to a custom component added in JBoss Developer Studio:
Create a new xml file in <JBDS_home>studio/eclipse/plugins/org.jboss.tools.common.kb_***/schemas/tld/. For example call it JeniaFaces.xml. The file should be written according to <JBDS_home>/studio/eclipse/plugins/org.jboss.tools.common.kb/kb.jar/org/jboss/tools/common/kb/kb-schema_1.0.dtd
Follow these steps to set what is available for code assist:
Adds code assist for JSF pre-defined objects, such as value= "#{param}" :
<AttributeType ...>
<proposal type="jsfVariables"/>
</AttributeType>
Add bundle resource (property file) code assist:
<AttributeType ...>
<proposal type="bundleProperty"/>
</AttributeType>
Add managed bean property code assist:
<AttributeType ...>
<proposal type="beanProperty"/>
</AttributeType>
Add managed bean property but of a specified type:
<AttributeType ...>
<proposal type="beanProperty">
<param name="type" value="java.lang.Boolean"/>
</proposal>
</AttributeType>
Add managed bean method with a signature:
<AttributeType ...>
<proposal type="beanMethodBySignature">
<param name="paramType" value="javax.faces.context.FacesContext"/>
<param name="paramType" value="javax.faces.component.UIComponent"/>
<param name="paramType" value="java.lang.Object"/>
<param name="returnType" value="void"/>
</proposal>
</AttributeType>
Add information on your xml file in <JBDS_home>/studio/eclipse/plugins/org.jboss.common.kb_***/plugin.xml
<tld
jsf="true"
name="Jenia Faces"
schema-location="schemas/tld/myJSF.xml"
uri="http://www.jenia.org/jsf/dataTools"/>
Restart Eclipse. You should now have code assist for the component.
JBoss Developer Studio offers the flexibility to edit any files in either source or extra visual modes at the same time.
The project is yours and so is the source. JBoss Developer Studio provides you many different graphical editors to speed your application development. At the same time, you always have a full control over all project source files. Any changes you make in the source view immediately appear in the graphical view.
The JSF configuration file editor has three views: Diagram, Tree and Source. All views are synchronized, you can edit the file in any view.
The same is relevant to all other JBoss Developer Studio editors.
Web XML editor is shown. Web XML editor has a graphical view (Tree) and source (Source).
JBoss Developer Studio TLD file editor is shown in Tree view. At any point you can edit the source by switching to Source view.
JBoss Developer Studio comes with a powerful and customizable Visual Page Editor (VPE). You can use the Visual Page Editor to develop an application using any technology: JSF, Struts, JSP, HTML and others.
Current VPE version has two tabs: Visual/Source and Preview.
Here is shown a split screen design with instant synchronization between Source and Visual views:
Preview view is read-only, it shows how the page will look like in a browser.
The Visual Page Editor has a split pane with toggle buttons for quickly moving between source, visual or source/visual modes instead of multiple tabs.
You can use Shift + F6 and Alt + Shift + F6 as shortcuts to toggle between the various states of the split pane.
When editing large documents hiding the visual part will speed up the editing.
No matter what view you select, you get a full integration with Properties and Outline views:
The VPE allows you to insert any tags from the palette to the page you are editing with just a click or drag-and-drop.
In the visual part of VPE there is a graphical toolbar, use it to add inline styling to any tag. The toolbar can be hidden by clicking on arrow sign in the upper left corner.
In the left vertical pane there are three buttons: Preferences, Refresh, Page Design Options.
Preferences button provides a quick access to Visual Page Editor preferences.
Clicking on Refresh button you refresh the displaying information.
Page Design Options button leads to page design options.
This dialog let's you set resources which are usually only resolved in runtime. To set a stylesheet, click Add (for CSS File Path section) and add your stylesheet. It works when CSS is defined on your page in the following way:
Code:
<link rel="stylesheet" type="text/css"
href="#{facesContext.externalContext.requestContextPath}/style.css"/>
This will work fine in runtime, but the Visual Page Editor doesn't know what requestContextPath in design time is.
The next section (URI), let's you add URI taglibs if you are using includes so that the editor knows where to find the tag libraries.
The first two sections let you define actual runtime folders. Here is an example.
Let's say you have the following project structure:
WebContent/
pages/
img/
a.gif
header.jsp
main.jsp
header.jsp content:
My Header
<img src="img/a.gif"/>
main.jsp:
<jsp:include page="pages/header.jsp" />
When you open main.jsp in Visual Page Editor, it will not be able to resolve the image from the header, however, it will work fine in runtime. To fix this in design time, click the Page Design Options button and set Actual Run-Time Relative Folder to <project>WebContent > pages and you will see the image appear.
At the bottom of VPE there is a Selection bar.
By clicking on the component in Visual view or selecting a code snippet in Source mode you see the tags tree. If you want to hide the selection bar, use the "Hide Selection Bar" button on the lower right side.
Linux users may need to do the following to get the Visual Editor to work correctly on their machines.
The Visual Page Editor requires the library libstdc++.so.5. This library is contained in the compat-libstdc++-33.i386 package.
To install this package on Fedora Core or Red Hat Enterprise Linux run the following command:
yum install compat-libstdc++-33.i386
On any other rpm based distributions download libstdc++.so.5 and run the following command:
rpm -Uvh compat-libstdc++-33.i386
On Debian based distributives run the following command:
apt-get install compat-libstdc++-33.i386
In case you have the library installed and you still have issue with starting the visual page editor then close all browser views/editors and leave one visual page editor open and restart eclipse. This should force a load of the right XULRunner viewer.
When working in JBoss Tools JSP editor you are constantly provided with feedback and contextual error checking as you type.
JBoss Developer Studio comes with JSP design-time preview features. When designing JSP pages you can easily preview how they will look during runtime. You can even attach your stylesheet to the preview.
JSP preview is available for:
Struts Pages
JSF Pages
The preview features are available with Visual Page Editor.
Besides Visual Page Editor JBDS is supplied with a huge range of various editors for different file types: properties, TLD, web.xml, tiles, and so on.
The Properties editor allows you to work in two different modes and also supports unicode characters.
To create a new properties file, in the Package Explorer view, select New > Properties File from the right-click context menu on the folder where you want to create the file.
You can edit the file using a table-oriented "Properties" viewer:
You can also use a Source viewer for editing the file:
The TLD editor comes with same features you will find in all other JBoss Developer Studio editors:
Graphical and source edit modes
Validation and error checking
You can easily switch from Tree to Source by selecting the Source tab at the bottom of the editor.
You can easily add a new tag:
You can also easily add a new attribute to an existing tag:
Content assist is available when editing the file using the Source viewer:
In the Source viewer, if at any point a tag is incorrect or incomplete, an error will be indicated next to the line and also in the Problems view below.
The Web Application File editor comes with the same features you will find in all other JBoss Developer Studio editors:
Graphical and source edit modes
Validation and error checking
You can add any new elements right in the Tree viewer:
Switch to the Source viewer to edit the web.xml file by hand at any time:
Content assist is available in the Source viewer. Simply click CTRL-Space anywhere in the file.
The CSS editor comes with the same features you will find in all other JBoss Developer Studio editors.
Content assist
Validation and error checking
With the CSS (Cascading Style Sheet) editor, you can take advantage of code prompting:
And you can also use the Properties view next to the editor to edit existing stylesheet declaration properties:
The JavaScript editor includes a Preview viewer and a Source viewer. In the Source viewer, you can use code assist:
You can also use the Source viewer with the Outline view to navigate around the file:
JBoss Developer Studio comes with an XSD Editor for XML Schema files. This editor comes from the Web Tools Project (WTP) (see WTP Getting Started).
To create a new XSD file, right-click a folder in the Package Explorer view, select New > Other... from the context menu and then select XML > XML Schema in the dialog box.
The XSD Editor includes two viewers for working on the file, a Design viewer and a Source viewer:
In the Design viewer, you can drill down on an element by double-clicking on it:
Various edit options are available when you right-click an element in the diagram:
You can also use the Properties view to edit a selected element:
You can also use a Source viewer for the file. In this viewer, along with direct editing of the source code, you can also edit the file by using the Properties view on the right:
This chapter will introduce you to the functionality provided by JBoss Tools Palette. The Palette allows you to quickly and easily create your JSP or JSF pages. Now you can do it more faster without additional knowledge.
The JBoss Tools Palette allows you to:
Insert tags into a JSP or JSF page with one click
Add custom and 3rd party tags
The JBoss Tools Palette contains a developer's project tag libraries and provides possibility to add any tag libraries to it. Also you can choose a necessary one from the list of already existed tag libraries:
HTML
JBoss
JSF
JSTL
MyFaces
Oracle ADF Faces
Struts
XHTML
By default the Palette is represented in Web Development Perspective with four groups. If you can't see it, select Window > Show View Other... > JBoss Tools Web > JBoss Tools Palette from the menu bar.
To facilitate your work, you can configure the Palette in your own way, by selecting the corresponding icon on the Palette toolbar.
There is a possibility to configure the JBoss Tools Palette:
to edit the palette content by adding, removing or changing the palette elements
to show/hide groups, subgroups
to import groups, subgroups
JBoss Tools Palette contains existing libraries of tags, thus the Palette editor is intended to work with them or create your new one, as well.
To open the editor, click on the Palette Editor icon:
The window has two parts. There is a reflected grouped list of components on the left side of the palette editor. Each group is divided into multiple groups, every of which is a tag library. The right side of the palette editor is an editing window where it's possible to change values of group or tag library attributes that you've chosen on the left part of the window.
It can also be done by right click and using Edit… option.
For example, JSF group consists of Core, Facelets, HTML tag libraries and the attributes as name, description and hidden which are available for editing:
The Palette Editor provides the following possibilities when working with existing tags or icons:
to work with a set of icons
Icons is the root folder for the icon sets. The first step is creating the icon set. Right click on the Icons folder and select Create > Create Set...
Set the value of the name in the Add Icons window and click Finish button. A new element will appear in the list.
Also you can delete the set. Right click on the set of icons that you wish to remove and chose the Delete Set option from the pop-up menu or click the Delete keyboard button.
to edit icons in the chosen set
When the set of icons is created, new icons can be imported to it. Choose the required set and select the option Create > Import Icon... from the pop-up menu that appears after you right-click on a folder.
Set the name of the icon and the path and click Finish button.
to work with a group of tag libraries
The first step in work with the editor is creating a group of libraries. It's very easy to do, right mouse button click on the Palette folder and select Create > Create Group…
Set a name of a group in the Create Group window and click OK button. A new element will appear at the end of the list.
You are allowed to edit or delete a group, as well. If you'd like to change attributes of a group, use the right editing window of the palette editor or the Edit... option, like it was mentioned before. In order to remove the group, right click on the group that you wish to remove and chose the Delete option or click the Delete keyboard button.
The removal option is enabled only for custom folders.
to work with a tag library
The group maintains a list of tag libraries. If you'd like to create your own library, click right mouse button on the group and choose Create Group… option.
After setting the attribute name and the path of the icon, click Ok button.
If you do not choose an icon the default one will be assigned.
You are allowed to edit or delete the tag library, as well. If you'd like to change attributes of the library or choose another icon, use the right editing window of the palette editor or the Edit... option. In order to remove the tag library, right click on the library that you wish to remove and chose the Delete option or click the Delete keyboard button.
The removal option is enabled only for custom tag libraries.
to work with a tag element
When the library folder is created, new tags can be added to it. Choose the required library and select the option Create > Create Macro… from the pop-up menu that appears after you right-click on a folder.
In the Add Palette Macro window, you can configure the tag element. Attribute Name is mandatory to fill and it will be the name of the tag element. Other settings are optional. You can choose the icon and set the Start Text and the End Text for your tag element. If your tag text is too long, use the Change... button to see it all. For start text and end text there is a possibility to control the cursor position by using "|" symbol.
After all the attributes are set, click Finish button.
If you do not choose an icon the default one will be assigned.
You are also allowed to edit or delete the tag. If you'd like to change the attributes of the tag or choose another icon for it, use the right editing window of the palette editor or the Edit... option from the pop-up menu. In order to remove the tag, right click on the tag that you wish to remove and chose the Delete option or click the Delete keyboard button.
The removal option is enabled only for custom tags. JBoss Palette tags can not be removed but can be modified.
Show/Hide is a very useful feature that allows you to control the number of tag groups that are shown on the palette.
Click Show/Hide button, at the top right side of the JBoss Tools Palette.
In the dialog Show/Hide Drawers check the groups the libraries of which you want to be shown on the palette:
If libraries are not displayed in the palette, check whether they are selected. Click the plus sign to expand the libraries of the group and make sure that a tick is put next to the wanted libraries.
Click OK. The new groups will now be shown on the palette:
The names of the elements are compound. The first part is the group name and the second is the library name.
The Import button lets you add a custom or 3rd party tag library to JBoss Tools Palette. Find out more information on how to add particular tags see the Adding Custom JSF Tags section.
A new tag can be added into any text file including jsp, htm, html and xhtml.
Let's do it. Open your JSP file and place the cursor in a place where you'd like to add a tag and then click that tag in the palette. In the Insert Tag window, that appears, you can set the value of general and advanced attributes of the tag that you chose.
In the example below, the commandButton tag has been inserted.
if you place the cursor over any tag, a balloon hint is shown with all the "tag" attributes.
The cursor position after adding a tag into a file is specified by "|" symbol in the tag template on the right in the Palette Editor window.
Above you can see where the cursor position for HTML > Form > input is set. Thus, after adding this tag into your file the cursor will be in the attribute "type". Then, you can straight use the combination of buttons Ctrl + Space to inquire about a prompting.
There are two ways to add any custom or 3rd party tag library to the JBoss Tools Palette:
Drag-and-drop from the Web Projects view
The Import button on the JBoss Tools Palette
Before you can add your custom component library, you need to make sure it is included in your project. Either place the ".tld" file or the ".jar" that includes your tag library under the lib folder in your project.
Switch to the Web Projects view and expand the Tag Libraries folder. If the view is not active, select Window > Show View > Web Projects from the menu bar.
Also make sure that the JBoss Tools Palette is open. Select the tag library that you want to add and simply drag-and-drop it on to the JBoss Tools Palette.
You will see the following dialog window. As you can see JBoss Developer Studio takes care of all the details. Chosen TLD file , name and prefix of the library and Library URL are detected, thus just need to set the Group name to which you wish to place this tag library. You can either add this tag library to an existing Group or just create a new one.
Once you are finished, you will see the new tag library added to the JBoss Tools Palette.
The same you can do with Import button. You can see this button at the top right side of the JBoss Tools Palette.
By clicking on the Import button you will see the Import Tag window a similar like in the Drag-and-Drop method. Set the name and prefix of the library and Library URL. Also you need to set the Group name to which you'd like to add your tag library. And like in the previous method you can add it to an existing Group or create a new one. On this Import Tag form you can use Browse... button to locate the tag library that you want to add:
JBoss Developer Studio comes with a tight integration with Rich Faces component framework. Rich Faces and Ajax4jsf in JBoss Tools Palette always exist, this palette is not dynamic and is not changed from file to file. JBoss Tools Palette supports only the last version of the Rich Faces components.
If you'd like to know the last version of Rich Faces component framework see JBoss RichFaces site.
Rich Faces components, as well, as Ajax4jsf ones are already on the JBoss Tools Palette:
Web Projects is a special view that comes with JBoss Developer Studio.
If the Web Projects view's tab is not visible next to the Package Explorer tab, select Window > Show View > Other > JBoss Tools Web > Web Projects from the menu bar.
With the Web Projects view, you can:
Visualize the project better because the project artifacts for JSF and Struts projects are organized and displayed by function.
Select these kinds of items to drag and drop into JSP pages:
JSF managed bean attributes
JSF navigation rules outcomes
Property file values
Tag library files
Tags from tag libraries
JSP page links
Use context menus to develop the application (all create and edit functions are available)
Use icon shortcuts to create and import JSF and Struts projects
Expand and inspect tag library files
Select custom and third-party tag libraries to drag and drop onto the JBoss Tools Palette
The Web Projects view organizes your project in a different way. The physical structure of course stays the same. The new organization combines common project artifacts together which makes it simpler to locate what you are looking for and develop.
The screen shot below shows a JSF project and a Struts project in Web Projects view.
Web Projects View has a drag and drop option that can be used for property, managed bean attributes, navigation rules, tag library file declaration and JSP Pages.
Expand the Resources Bundles folder that holds all the Property files in your project. Select the file from which you want to add the property and then select the property.
We will be dragging and dropping a property file value inside the outputText tag for the "value" attribute.
Select the property:
Drag the property and drop it between the quotes for the value attribute in the JSP file. Notice that JBoss Developer Studio added the correctly formatted expression for referring to the property value #{Message.header} automatically.
You can actually place the tag anywhere in the page, not just inside an existing tag. In this case, JBoss Developer Studio will place the complete tag <h:outputText value="#{Message.header}"/> in the page.
Select a "managed bean" attribute and then drag and drop it onto the JSP page. We are going to place it inside the "value" attribute of the inputText tag.
Once again, JBoss Developer Studio adds the correct expression, #{user.name}.
Select the navigation rule under Configuration > faces-config.xml > Navigation Rules:
Drag and drop it inside the commandButton tag:
You could do the same if the navigation rule was defined inside an action method:
Here is how it would look after drag and drop:
Select a TLD file:
Then drag and drop it onto the JSP page to add a declaration at the top of the page:
It is also possible to develop your application right from the Web Projects view. Simply right-click any node in the tree and select an appropriate action from the context menu. For instance, this screen capture shows creating a new navigation rule.
You can easily expand any TLD file in the project. Browse to the Tag Libraries folder. Right-click a TLD file and select Expand. The TLD file will now be expanded.
You can then select any tag and drag it onto a JSP page.
Read Adding Tag Libraries to learn about this.
Configuring the various JBoss Developer Studio features is done via the Preferences screen by selecting Window > Preferences > JBoss Tools from the menu bar.
From this screen, you can select these more specific sets of JBoss Tools preferences:
Select JBoss Tools > XDoclet > Code Assist to see Code Assist preference page.
Here is what the Code Assist preference page looks like:
You can set various preferences for the editors that JBoss Developer Studio adds to the Eclipse environment by selectind JBoss Tools > Web > Editors.
In the initial Editors screen, you can decide on some global settings for JBoss Tools editors. You can select whether an available JBoss Tools editor should always be the default editor for a type of file, whether the user should be warned that making a project an Red Hat project will make an JBoss Tools editor fully available for a particular type of file, and whether, for JBoss Tools editors, the Source mode should be the default instead of a visual mode.
The following preferences can be changed on the JBoss Tools > JBoss Servers preference page.
Here is what the JBoss Servers preference page looks like:
Select JBoss Tools > Web > JSF to get to the JSF Project specific preferences.
Selecting JBoss Tools > Web > Editors > JSF Flow Diagram allows you to specify some aspects of the Diagram mode of the JSF configuration file editor.
The first two items control the background grid for the diagram. The next two items allow you to control the appearance of the labels for views (pages) and the transitions between views. For these two items, clicking the Change... button allows you to assign a font with a dialog box.
The first check box determines whether a view in the diagram that doesn't have a transition connecting it to another view yet should be written to the source code as a partial navigation rule. The next check box determines whether the diagram cursor reverts immediately to the standard selection mode after it's used in the transition-drawing mode to draw a transition. Finally, the last two check boxes concern shortcuts. A shortcut is a transition that is there but isn't actually displayed in the diagram as going all the way to the target view it's connected to, in order to make the diagram clearer. With the check boxes, you can decide whether to display a small shortcut icon as part of the shortcut and also whether to display the target view as a label or not.
Selecting the Add Page tab in the JSF Flow Diagram screen allows you to determine the default template and file extension for views (pages) you add directly into the diagram using a context menu or the view-adding mode of the diagram cursor.
By selecting JBoss Tools > Web > JSF > > JSF Pages you can add jsf pages or remove existing ones.
Select JBoss Tools > Web > JSF > Project to see JSF Project preference page.
On Project panel you define a template for a new created project: servlet version, page template and so on.
Selecting the Import Project tab in the JSF Project screen allows you to determine the default servlet version and whether to register Web Context in server.xml.
The following preferences can be changed on the JBoss Tools > Packaging Archives page.
On Packaging Archives panel you determine settings for Project Packages view and core preferences.
By selecting Web > Struts > Automation > Plug-in Insets on tab Tiles you can define a default text for tiles plugin.
The same is done but for validator plugin on the tab Validators.
To see Resource Insets preference page select JBoss Tools > Web > Strats > Automation > Resource Insets.
On Resource Insets panel you determine default error messages for error resource files.
The following preferences can be changed on the JBoss Tools > Web > Seam page.
On Seam screen you can add and remove Seam runtimes.
Here is what Seam preference page looks like:
The following preferences can be changed on the JBoss Tools > Web > Seam > Validator page.
In Validator panel you configure seam problems that will be processed by validator.
By selecting JBoss Tools > Web > Struts you can configure Struts projects specific preferences.
On Automation panel you can modify default text for the Tilel Struts plug-in element, the Validator Struts plug-in element, and error message resource files.
The following preferences can be changed on the JBoss Tools > Web > Struts > Customization page.
In theCustomization screen you configure Link Recognizer for Struts tags.
Similarly to the JSF Flow Diagram screen, selecting JBoss Tools > Web > Editor > Struts Flow Diagram page allows you to specify aspects of the Diagram mode of the Struts configuration file editor. The Struts Flow Diagram screen adds an option to hide the Diagram tab and labeling settings for additional artifacts.
Selecting the Add Page tab in the Struts Flow Diagram screen allows you to determine the default template and file extension for views (pages) you add directly into the diagram using a context menu or the view-adding mode of the diagram cursor.
You can change the following preferences on the JBoss Tools > Web > Struts > Struts Pages preference page.
On Struts Pages panel you can add or remove Struts pages.
You can change the following preferences on the JBoss Tools > Web > Struts > Project preference page:
On Project panel you define a template for a new Struts created project: servlet version, page template and so on.
Selecting the Import Project tab in the Struts Project screen allows you to determine the default servlet version and whether to register Web Context in server.xml.
The following preferences can be changed on the JBoss Tools > Web > Struts > Project > Struts Support page.
Select Struts Support screen if you want to configure Struts versions support settings.
JBoss Tools > Web > Editors > Title Diagram screen allows you control some settings for the placement of Tiles definitions in the Diagram mode of the JBoss Tools Tiles editor.
The following preferences can be changed on the JBoss Tools > Web > Verification page.
On Rules Configuration tab of Verifcation panel you can determine JSF and Struts rules.
On Options tab you can define a limit for the reported errors number.
The following preferences can be changed on the JBoss Tools > JBoss Servers > View page.
The View shows you preferences for JBoss Servers view.
JBoss Tools > Web > Editors > Visual Page Editor screen allows you to control some aspects of the behavior of the Visual Page Editor (VPE) for JSP files. Also you can define a default editor tab.
On the Templates tab you can edit or remove VPE templates.
The following preferences can be changed on the JBoss Tools > XDoclet page.
On XDoclet screen you determine XDoclet module versions.
To see what XDoclet tags templates available for completion select JBoss Tools > XDoclet > Code Assist > Templates.
By right clicking on any tree element you can add a new template, remove or rename it and also add a new tree.
Select, for example, Add and you'll be prompted by a list of available elements to add.
By double-clicking some element a new list will be shown: now for available methods.
Choose any element from the list, then select an attribute.
It will be added to the available templates.
By selecting JBoss Tools > XDoclet > Variables you define variables used in templates.
To change the default environment and project template for either JSF or Struts new project creation:
Select Window > Preferences > JBoss Tools > Web > {JSF or Struts} > Project
For Version set the environment you want to be the default one
For Project Template set the template you want to be the default one
To change the default project template for either JSF or Struts new project creation:
Select Window > Preferences > JBoss Tools > Web > {JSF or Struts} > Project
For Project Template set the template you want to be the default one