Java - Bean Implementation Classes
Java - Bean Implementation Classes
May 2012
Summary
• Java Beans
(an open window to everything possible)
http://www.oracle.com/technetwork/developer-tools/forms/
http://forms.pjc.bean.over-blog.com/
Over 100 free Plug-ins
How tos / Articles
Links to other Java Beans’ providers
May 2012
Introduction
What is it ?
How it works ?
Demo
Where to download the project ?
May 2012
Introduction
May 2012
Change easily the look of the Forms application
Draw gradient backgrounds,
images, shapes and strings on the
Change the look
canvas
of the GUIs’
elements
Give table-blocks
an « HTML » style
May 2012
Externalize the graphical information
The painting is made at runtime by reading the required tags, then applying the settings through the Java Bean.
canvasEbay {
type:canvas
gradient-colors:r255g255b204,r255g255b255
gradient-vcycle:/2
gradient-hcycle:0
image1:/ebay.jpg,10,1,.8
image2:/ebay_line.jpg,30,74,.6,560,5
}
tableHeaderEbay {
type:header
font-family: Arial;
font-size:12
font-weight:bold
frame-color:r250g83b12
inside-color:r255g204b0
font-color:r0g0b204
shade-color:r255g255b204
frame-width:2
frame-rounded-border: 10
transparency:.8
text-align:left
text-align-offset:5
}
May 2012
Have a more « WEB » look on table-blocks
May 2012
Add some new functions
• Handle menus at runtime (add, enable, disable, show, hide, remove options).
• Handle frames at runtime (add, move, modify, hide).
• Play pre-loaded sounds.
• Receive external asynchronous messages.
• Draw graphics anywhere on the screen.
• Display input dialog boxes.
• Color Chooser.
• Add Items at runtime (Text Items, check-boxes, buttons, images, sliders).
• Handle HTML Maps.
• Display Google Charts.
• Display Swing Jtable coloured LOVs.
• Display dynamic popup menus.
• Display popup messages.
• Display Images in a Spinner component.
• …
May 2012
What is it ?
a PL/SQL library
That includes the functions and the procedures to read the tags
from the CSS file and decorate the dialogs.
a JAR file
a CSS file
May 2012
The PL/SQL library (laf.pll)
It contains the functions and the procedures needed to open the CSS file,
read the tags from it, then perfom the drawing job through the
associated Java Bean’s methods.
PKG_LOOK_AND_FEEL.Open_Css()
PKG_LOOK_AND_FEEL.Paint_Canvas()
PKG_LOOK_AND_FEEL.Paint_Block()
PKG_LOOK_AND_FEEL.Set_GUI_Properties()
May 2012
The JAR file (laf.jar)
Drawing shapes on the current canvas (images, lines, rectangles and strings).
Loading and playing sounds.
Dynamically handling menus - add, remove, enable, disable, show and hide menu
options at runtime.
Dynamically handling frames – add, remove, modify, move, show and hide frames at
runtime.
Display single or multi-line input dialog box.
Transform the Forms into a Socket Server, able to receive external asynchronous
messages.
Display texts anywhere on the canvas during a given time.
Change fonts and colors for menu bar, window caption, status bar and tabs.
Pick a color from a JColorChooser.
Turn simple images into sensitive areas you can click on.
May 2012
The PJCs tend to give a more « Windows XP » look with the use of gradients.
They also extend the standard behavior of the common Forms items:
Buttons with mixed text and image, and mouse-on, mouse-over events.
Text items that permit sending events back to Forms (last key typed with key char, key code
and key modifier).
Text items able to render HTML contents or handle huge texts like CLOBs or external text
files.
May 2012
The CSS file
type:canvas
That contains tags to decorate a canvas
type:title
That contains tags to draw a table-block title area
type:header
That contains tags to draw a table-block header area
type:body
That contains tags to draw a table-block body area
type:gui
That contains tags to manage the common GUIs elements
May 2012
Title section’s tags Header section’s tags Body section’s tags
May 2012
How it works?
May 2012
• The Forms side
When-New-Form-Instance trigger
May 2012
• The Java side
• When-Timer-Expired trigger
Colorize
widgets
Draw shapes
Draw images
Re-draw
buttons Paint gradients
May 2012
Look and Feel Project Demo
May 2012
Some links
Oracle Forms Look and Feel project Web site (documentation and download)
http://fdtool.free.fr/LAF/doc/Oracle_Forms_Look_and_Feel_project.htm
The Forms Look and Feel Project is free. There is no license attached.
You can use, modify and distribute without any restriction at all.
May 2012
Questions
THANK YOU