Java Doc for JBarGraph.java in » Science » JSci » JSci » swing » Java Source Code / Java DocumentationJava Source Code and Java Documentation
Java Source Code / Java Documentation
1.
6.0 JDK Core
2.
6.0 JDK Modules
3.
6.0 JDK Modules com.sun
4.
6.0 JDK Modules com.sun.java
5.
6.0 JDK Modules sun
6.
6.0 JDK Platform
7.
Ajax
8.
Apache Harmony Java SE
9.
Aspect oriented
10.
Authentication Authorization
11.
Blogger System
12.
Build
13.
Byte Code
14.
Cache
15.
Chart
16.
Chat
17.
Code Analyzer
18.
Collaboration
19.
Content Management System
20.
Database Client
21.
Database DBMS
22.
Database JDBC Connection Pool
23.
Database ORM
24.
Development
25.
EJB Server geronimo
26.
EJB Server GlassFish
27.
EJB Server JBoss 4.2.1
28.
EJB Server resin 3.1.5
29.
ERP CRM Financial
30.
ESB
31.
Forum
32.
GIS
33.
Graphic Library
34.
Groupware
35.
HTML Parser
36.
IDE
37.
IDE Eclipse
38.
IDE Netbeans
39.
Installer
40.
Internationalization Localization
41.
Inversion of Control
42.
Issue Tracking
43.
J2EE
44.
JBoss
45.
JMS
46.
JMX
47.
Library
48.
Mail Clients
49.
Net
50.
Parser
51.
PDF
52.
Portal
53.
Profiler
54.
Project Management
55.
Report
56.
RSS RDF
57.
Rule Engine
58.
Science
59.
Scripting
60.
Search Engine
61.
Security
62.
Sevlet Container
63.
Source Control
64.
Swing Library
65.
Template Engine
66.
Test Coverage
67.
Testing
68.
UML
69.
Web Crawler
70.
Web Framework
71.
Web Mail
72.
Web Server
73.
Web Services
74.
Web Services apache cxf 2.0.1
75.
Web Services AXIS2
76.
Wiki Engine
77.
Workflow Engines
78.
XML
79.
XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation
»
Science
»
JSci
»
JSci.swing
Source Cross Reference
Class Diagram
Java Document (Java Doc)
JSci.swing
.JDoubleBufferedComponent
JSci.swing
.JCategoryGraph2D
JSci.swing
.JBarGraph
All known Subclasses:
JSci.swing
.JStackedBarGraph
,
JSci.swing
.JLayeredBarGraph
,
JBarGraph
public
class JBarGraph extends
JCategoryGraph2D
(Code)
A bar graph Swing component. Multiple series are side-by-side.
version:
1.2
author:
Ismael Orenstein
Field Summary
protected
Color
barColor
Bar colors.
final
protected
int
barPad
Padding.
protected
int
barWidth
protected
float
minYmaxY
Min and max data points.
protected
boolean
numbering
Axis numbering.
protected
NumberFormat
yNumberFormat
Constructor Summary
public
JBarGraph
(
CategoryGraph2DModel
cgm)
Constructs a bar graph.
Method Summary
public
void
addNotify
()
public
void
dataChanged
(
GraphDataEvent
e)
Implementation of GraphDataListener.
final
protected
Point
dataToScreen
(float x, float y)
Converts a data point to screen coordinates.
final
protected
void
drawAxes
(
Graphics
g)
Draws the graph axes.
protected
void
drawBars
(
Graphics
g)
Draws the graph bars.
protected
void
drawXLabel
(
Graphics
g, int x)
protected
void
drawYLabel
(
Graphics
g, float y)
final
public
Color
getColor
(int n)
Gets the bar color of the nth series.
final
public
float
getYIncrement
()
Returns the y-axis numbering increment.
final
public
float
getYMaximum
()
final
public
float
getYMinimum
()
protected
void
offscreenPaint
(
Graphics
g)
Paint the graph.
final
protected
void
rescale
()
Rescales the bar graph.
final
protected
Point2D.Float
screenToData
(
Point
p)
Converts a screen point to data coordinates.
final
public
void
setBounds
(int x, int y, int width, int height)
Reshapes the bar graph to the specified bounding box.
final
public
void
setColor
(int n,
Color
c)
Sets the bar color of the nth series.
final
public
void
setNumberFormat
(
NumberFormat
format)
Sets the display format used for axis numbering.
final
public
void
setNumbering
(boolean flag)
Turns axis numbering on/off.
final
public
void
setYIncrement
(float dy)
Sets the y-axis numbering increment.
final
public
void
setYNumberFormat
(
NumberFormat
format)
Sets the display format used for y-axis numbering.
Field Detail
barColor
protected
Color
barColor
(Code)
Bar colors.
barPad
final
protected
int barPad
(Code)
Padding.
barWidth
protected
int barWidth
(Code)
minYmaxY
protected
float minYmaxY
(Code)
Min and max data points.
numbering
protected
boolean numbering
(Code)
Axis numbering.
yNumberFormat
protected
NumberFormat
yNumberFormat
(Code)
Constructor Detail
JBarGraph
public
JBarGraph(
CategoryGraph2DModel
cgm)
(Code)
Constructs a bar graph.
Method Detail
addNotify
public
void addNotify()
(Code)
dataChanged
public
void dataChanged(
GraphDataEvent
e)
(Code)
Implementation of GraphDataListener. Application code will not use this method explicitly, it is used internally.
dataToScreen
final
protected
Point
dataToScreen(float x, float y)
(Code)
Converts a data point to screen coordinates.
drawAxes
final
protected
void drawAxes(
Graphics
g)
(Code)
Draws the graph axes.
drawBars
protected
void drawBars(
Graphics
g)
(Code)
Draws the graph bars.
drawXLabel
protected
void drawXLabel(
Graphics
g, int x)
(Code)
drawYLabel
protected
void drawYLabel(
Graphics
g, float y)
(Code)
getColor
final
public
Color
getColor(int n)
(Code)
Gets the bar color of the nth series.
Parameters:
n - the index of the series.
getYIncrement
final
public
float getYIncrement()
(Code)
Returns the y-axis numbering increment.
getYMaximum
final
public
float getYMaximum()
(Code)
getYMinimum
final
public
float getYMinimum()
(Code)
offscreenPaint
protected
void offscreenPaint(
Graphics
g)
(Code)
Paint the graph.
rescale
final
protected
void rescale()
(Code)
Rescales the bar graph.
screenToData
final
protected
Point2D.Float
screenToData(
Point
p)
(Code)
Converts a screen point to data coordinates.
setBounds
final
public
void setBounds(int x, int y, int width, int height)
(Code)
Reshapes the bar graph to the specified bounding box.
setColor
final
public
void setColor(int n,
Color
c)
(Code)
Sets the bar color of the nth series.
Parameters:
n - the index of the series.
Parameters:
c - the line color.
setNumberFormat
final
public
void setNumberFormat(
NumberFormat
format)
(Code)
Sets the display format used for axis numbering. Convenience method.
See Also:
JBarGraph.setYNumberFormat(NumberFormat)
setNumbering
final
public
void setNumbering(boolean flag)
(Code)
Turns axis numbering on/off.
setYIncrement
final
public
void setYIncrement(float dy)
(Code)
Sets the y-axis numbering increment.
Parameters:
dy - use 0.0f for auto-adjusting (default).
setYNumberFormat
final
public
void setYNumberFormat(
NumberFormat
format)
(Code)
Sets the display format used for y-axis numbering.
Fields inherited from
JSci.swing.JCategoryGraph2D
final
protected
int axisPad
(Code)
(Java Doc)
protected
int leftAxisPad
(Code)
(Java Doc)
protected
CategoryGraph2DModel
model
(Code)
(Java Doc)
protected
Point
origin
(Code)
(Java Doc)
final
protected
int scalePad
(Code)
(Java Doc)
Methods inherited from
JSci.swing.JCategoryGraph2D
abstract
public
void dataChanged(
GraphDataEvent
e)
(Code)
(Java Doc)
public
Dimension
getMinimumSize()
(Code)
(Java Doc)
final
public
CategoryGraph2DModel
getModel()
(Code)
(Java Doc)
public
Dimension
getPreferredSize()
(Code)
(Java Doc)
final
public
void setModel(
CategoryGraph2DModel
cgm)
(Code)
(Java Doc)
Methods inherited from
JSci.swing.JDoubleBufferedComponent
final
protected
Graphics
getOffscreenGraphics()
(Code)
(Java Doc)
final
public
boolean isDoubleBuffered()
(Code)
(Java Doc)
abstract
protected
void offscreenPaint(
Graphics
g)
(Code)
(Java Doc)
final
public
void paintComponent(
Graphics
g)
(Code)
(Java Doc)
final
public
void printComponent(
Graphics
g)
(Code)
(Java Doc)
final
public
void redraw()
(Code)
(Java Doc)
final
public
void setDoubleBuffered(boolean flag)
(Code)
(Java Doc)
final
public
void update(
Graphics
g)
(Code)
(Java Doc)
www.java2java.com
|
Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.