Listing 5: itemsRect.fx
package mariahcarey;
import javafx.ui.*;
import javafx.ui.canvas.*;
import javafx.ui.filter.*;
class itemsRect extends CompositeNode{
attribute subtext: Color;
attribute strokeValue_1: Number;
attribute strokeValue_2: Number;
attribute strokeValue_3: Number;
attribute strokeValue_4: Number;
}
attribute itemsRect.strokeValue_1 = 1.0;
attribute itemsRect.strokeValue_2 = 1.0;
attribute itemsRect.strokeValue_3 = 1.0;
attribute itemsRect.strokeValue_4 = 1.0;
attribute itemsRect.subtext = Color {
red:241
green:192
blue:239
};
function itemsRect.composeNode() =
Group {
transform: []
var color=Color{
red:205
green:208
blue:216
}
var textcolor=Color{
red:190
green:117
blue:199
}
var subtext=Color{
red:241
green:192
blue:239
}
content:[ImageView {
transform: translate(46,150)
image: Image
{ url:
"{__DOCBASE__}//images//up_flower.bmp" }
},
Rect {
x: 70
y: 205
height: 80
width: 470
arcHeight: 20
arcWidth: 20
fill: color
stroke: color
strokeWidth: 2
opacity: 0.9
},
Rect {
x: 70
y: 288
height: bind [0..530] dur 4000
width: 470
arcHeight: 20
arcWidth: 20
fill: color
stroke: color
strokeWidth: 2
opacity: 0.3
},
ImageView {
transform: translate(50,755)
image: Image
{ url:
"{__DOCBASE__}//images//down_flower.bmp" }
},
Text {
x: 120
y: 220
content: "2007-05-31 15:33:11"
font: Font {face: VERDANA, style: [BOLD], size: 15}
fill: LinearGradient {
x1: 0, y1: 0, x2: 0, y2: 1
stops:
[Stop {
offset: 0
color: textcolor
},
Stop {
offset: 0.5
color: textcolor
},
Stop {
offset: 1
color: textcolor
}]
}
},
Text {
x: 120
y: 240
content: "Mariah to Appear In New Bone -N- Harmony Video"
font: Font {face: VERDANA, style: [BOLD], size: 10}
fill: LinearGradient {
x1: 0, y1: 0, x2: 0, y2: 1
stops:
[Stop {
offset: 0
color: black
},
Stop {
offset: 0.5
color: black
},
Stop {
offset: 1
color: black
}]
}
},
Text {
x: 120
y: 255
content: "Mariah will make a special guest appearance
in the upcoming video for the \nlatest Bone
Thugs-N-Harmony track."
font: Font {face: VERDANA, style: [PLAIN], size: 10}
fill: LinearGradient {
x1: 0, y1: 0, x2: 0, y2: 1
stops:
[Stop {
offset: 0
color: gray
},
Stop {
offset: 0.5
color: gray
},
Stop {
offset: 1
color: black
}]
}
},
Text {
x: 120
y: 300
content: "2007-05-24 14:36:19"
font: Font {face: VERDANA, style: [BOLD], size: 15}
fill: LinearGradient {
x1: 0, y1: 0, x2: 0, y2: 1
stops:
[Stop {
offset: 0
color: textcolor
},
Stop {
offset: 0.5
color: textcolor
},
Stop {
offset: 1
color: textcolor
}]
}
},
Group{
transform: []
content:[Text {
x: 120
y: 319
content: "Check Out Brand New Honey B. Fly Merch!"
font: Font {face: VERDANA, style: [BOLD], size: 10}
cursor:HAND
onMouseEntered: operation(e:CanvasMouseEvent) {
strokeValue_1 = 2.0;
}
onMouseExited: operation(e:CanvasMouseEvent) {
strokeValue_1 = 1.0;
}
fill: LinearGradient {
x1: 0, y1: 0, x2: 0, y2: 1
stops:
[Stop {
offset: 0
color: subtext
},
Stop {
offset: 0.5
color: subtext
},
Stop {
offset: 1
color: subtext
}]
}
},
Line {
x1: 120
y1: 330
x2: 355
y2: 330
stroke: white
strokeWidth: bind strokeValue_1
}]
},
Text {
x: 120
y: 334
content: "Fan Club members will now receive a 10%
discount on all orders placed \nthrough the
Fan Club store!!"
font: Font {face: VERDANA, style: [PLAIN], size: 10}
fill: LinearGradient {
x1: 0, y1: 0, x2: 0, y2: 1
stops:
[Stop {
offset: 0
color: white
},
Stop {
offset: 0.5
color: white
},
Stop {
offset: 1
color: white
}]
}
},
Text {
x: 120
y: 385
content: "2007-05-24 10:21:17"
font: Font {face: VERDANA, style: [BOLD], size: 15}
fill: LinearGradient {
x1: 0, y1: 0, x2: 0, y2: 1
stops:
[Stop {
offset: 0
color: textcolor
},
Stop {
offset: 0.5
color: textcolor
},
Stop {
offset: 1
color: textcolor
}]
}
},
Group{
transform: []
content:[Text {
x: 120
y: 404
content: "MEMBERSHIP NEWS"
font: Font {face: VERDANA, style: [BOLD], size: 10}
cursor:HAND
onMouseEntered: operation(e:CanvasMouseEvent) {
strokeValue_2 = 2.0;
}
onMouseExited: operation(e:CanvasMouseEvent) {
strokeValue_2= 1.0;
}
fill: LinearGradient {
x1: 0, y1: 0, x2: 0, y2: 1
stops:
[Stop {
offset: 0
color: subtext
},
Stop {
offset: 0.5
color: subtext
},
Stop {
offset: 1
color: subtext
}]
}
},
Line {
x1: 120
y1: 415
x2: 232
y2: 415
stroke: white
strokeWidth: bind strokeValue_2
}]
},
Text {
x: 120
y: 417
content: "Honey B. Fly membership renewals will be starting
shortly."
font: Font {face: VERDANA, style: [PLAIN], size: 10}
fill: LinearGradient {
x1: 0, y1: 0, x2: 0, y2: 1
stops:
[Stop {
offset: 0
color: white
},
Stop {
offset: 0.5
color: white
},
Stop {
offset: 1
color: white
}]
}
},
Text {
x: 120
y: 457
content: "2007-05-18 11:08:47"
font: Font {face: VERDANA, style: [BOLD], size: 15}
fill: LinearGradient {
x1: 0, y1: 0, x2: 0, y2: 1
stops:
[Stop {
offset: 0
color: textcolor
},
Stop {
offset: 0.5
color: textcolor
},
Stop {
offset: 1
color: textcolor
}]
}
},
Group{
transform: []
content:[Text {
x: 120
y: 475
content: "Mariah Wins Two BMI Pop Awards"
font: Font {face: VERDANA, style: [BOLD], size: 10}
cursor:HAND
onMouseEntered: operation(e:CanvasMouseEvent) {
strokeValue_3 = 2.0;
}
onMouseExited: operation(e:CanvasMouseEvent) {
strokeValue_3= 1.0;
}
fill: LinearGradient {
x1: 0, y1: 0, x2: 0, y2: 1
stops:
[Stop {
offset: 0
color: subtext
},
Stop {
offset: 0.5
color: subtext
},
Stop {
offset: 1
color: subtext
}]
}
},
Line {
x1: 120
y1: 486
x2: 312
y2: 486
stroke: white
strokeWidth: bind strokeValue_3
}]
},
Text {
x: 120
y: 490
content: "Broadcast Music, Inc. staged its
55th Annual Pop Awards"
font: Font {face: VERDANA, style: [PLAIN], size: 10}
fill: LinearGradient {
x1: 0, y1: 0, x2: 0, y2: 1
stops:
[Stop {
offset: 0
color: white
},
Stop {
offset: 0.5
color: white
},
Stop {
offset: 1
color: white
}]
}
},
Text {
x: 120
y: 535
content: "2007-05-17 16:47:34"
font: Font {face: VERDANA, style: [BOLD], size: 15}
fill: LinearGradient {
x1: 0, y1: 0, x2: 0, y2: 1
stops:
[Stop {
offset: 0
color: textcolor
},
Stop {
offset: 0.5
color: textcolor
},
Stop {
offset: 1
color: textcolor
}]
}
},
Group{
transform: []
content:[Text {
x: 120
y: 552
content: "Mariah Tops OK! Magazine's Loveliest Legs List"
font: Font {face: VERDANA, style: [BOLD], size: 10}
cursor:HAND
onMouseEntered: operation(e:CanvasMouseEvent) {
strokeValue_4 = 2.0;
}
onMouseExited: operation(e:CanvasMouseEvent) {
strokeValue_4 = 1.0;
}
fill: LinearGradient {
x1: 0, y1: 0, x2: 0, y2: 1
stops:
[Stop {
offset: 0
color: subtext
},
Stop {
offset: 0.5
color: subtext
},
Stop {
offset: 1
color: subtext
}]
}
},
Line {
x1: 120
y1: 563
x2: 385
y2: 563
stroke: white
strokeWidth: bind strokeValue_4
}]
},
Text {
x: 120
y: 570
content: "Getting picked to front an advertising
campaign for a razor called Legs of a \nGoddess
is proof that Mariah deserves to top the list
of best celebrity gams."
font: Font {face: VERDANA, style: [PLAIN], size: 10}
fill: LinearGradient {
x1: 0, y1: 0, x2: 0, y2: 1
stops:
[Stop {
offset: 0
color: white
},
Stop {
offset: 0.5
color: white
},
Stop {
offset: 1
color: white
}]
}
}]
};
New on the Java Boutique:
New Review:
Time Management Made Easy with the Quartz Enterprise Job Scheduler
Why not just use the Java timer API? This open source scheduling
API boasts simplicity, ease-of-integration, a well-rounded feature
set, and it's free!
New Applet:
Reverse Complement
Reverse Complement is a simple applet that converts DNA or RNA
sequences into three useful formats.
Elsewhere on internet.com:
WebDeveloper Java
Lots of Java information on webdeveloper.com
WDVL Java
Thorough Java resource at the Web Developer's Virtual Library.
ScriptSearch Java
Hundreds of free Java code files to download.
jGuru: Your View of the Java Universe
Customizable portal with online training, FAQs, regular news updates, and tutorials.