Logo Search packages:      
Sourcecode: latexdraw version File versions  Download package

latexDraw::figures::Axe Class Reference

Inheritance diagram for latexDraw::figures::Axe:

latexDraw::figures::GridShape latexDraw::figures::properties::Arrowable latexDraw::figures::Figure latexDraw::figures::properties::Drawable

List of all members.

Detailed Description

This class defines axes.

TODO: it seems to have an redefinition of psaxes in the pstricks-add package, but this class define only the psaxes of the pst-plot package. It possible to add the possibility to choose which definition we want to use.

Ox and Oy parameters can be float, but it occurs problems; for this reason these parameters will be only integer in LaTeXDraw. cf. http://tug.org/mailman/htdig/pstricks/1998/000227.html

This file is part of LaTeXDraw.
Copyright (c) 2005-2008 Arnaud BLOUIN

LaTeXDraw is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or any later version.

LaTeXDraw is distributed without any warranty; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.


Definition at line 45 of file Axe.java.

Public Member Functions

 Axe (LaTeXDrawPoint2D pos, boolean increaseMeter)
boolean canBeFilled ()
boolean canBeHatched ()
synchronized boolean canHaveArrow ()
boolean canHaveShadow ()
synchronized void changeMeter ()
Object clone () throws CloneNotSupportedException
double computeRotationAngle (Point formerPt, Point newPt) throws IllegalArgumentException
Shape createNonRotatedShape2D ()
Shape createShadowShape ()
Shape createShape2D ()
void draw (Graphics2D g, Object antiAlias, Object rendering, Object alphaInter, Object colorRendering)
String getArrow1Style ()
String getArrow2Style ()
ArrowHead getArrowHead1 ()
ArrowHead getArrowHead2 ()
synchronized int getAxesStyle ()
synchronized String getAxesStyleToken ()
synchronized float getBlackDashLength ()
synchronized LaTeXDrawRectangle getBorders ()
synchronized LaTeXDrawPoint2D getBordersPoint (int id)
synchronized String getBordersPosition ()
LaTeXDrawRectangle getBoundBorders ()
String getCodePSTricks (DrawBorders drawBorders, float ppc)
synchronized double getDistLabelsX ()
synchronized double getDistLabelsY ()
synchronized float getDotSep ()
synchronized Color getDoubleColor ()
synchronized double getDoubleSep ()
synchronized Font getFont ()
synchronized FontMetrics getFontMetrics ()
synchronized double getGradientAngle ()
synchronized Color getGradientEndColor ()
synchronized double getGradientMidPoint ()
synchronized Color getGradientStartColor ()
synchronized LaTeXDrawPoint2D getGravityCenter ()
synchronized LaTeXDrawPoint2D getGridEnd ()
synchronized LaTeXDrawPoint2D getGridStart ()
synchronized double getHatchingAngle ()
synchronized Color getHatchingColor ()
synchronized double getHatchingSep ()
synchronized String getHatchingStyle ()
synchronized float getHatchingWidth ()
synchronized LaTeXDrawPoint2D getIncrement ()
synchronized Color getInteriorColor ()
int getLabelsDisplayed ()
String getLabelsDisplayedToken ()
LaTeXDrawPoint2D getLastPoint ()
synchronized Color getLinesColor ()
synchronized String getLineStyle ()
synchronized int getNumber ()
synchronized LaTeXDrawPoint2D getOrigin ()
synchronized LaTeXDrawPoint2D getPosition ()
String getPSTricksCodeFilling (float ppc)
String getPSTricksCodeLine (float ppc)
synchronized double getRotationAngle ()
int getSelectedDelimitorOrientation ()
synchronized double getShadowAngle ()
synchronized Color getShadowColor ()
synchronized double getShadowSize ()
synchronized Shape getShape ()
LaTeXDrawPoint2D getTheNWBoundPoint ()
LaTeXDrawPoint2D getTheNWNonRotatedBoundPoint ()
LaTeXDrawPoint2D getTheNWPoint ()
LaTeXDrawPoint2D getTheNWRotatedPoint ()
LaTeXDrawPoint2D getTheSEBoundPoint ()
LaTeXDrawPoint2D getTheSENonRotatedBoundPoint ()
synchronized LaTeXDrawPoint2D getTheSEPoint ()
synchronized LaTeXDrawPoint2D getTheSERotatedPoint ()
synchronized float getThickness ()
synchronized int getTicksDisplayed ()
synchronized String getTicksDisplayedToken ()
synchronized double getTicksSize ()
synchronized int getTicksStyle ()
synchronized String getTicksStyleToken ()
synchronized float getWhiteDashLength ()
synchronized boolean hasDoubleBoundary ()
synchronized boolean hasGradient ()
int hashCode ()
synchronized boolean hasShadow ()
boolean hasTwoLeftArrows ()
boolean intersected (Rectangle2D.Double r)
synchronized boolean isADelimitorSelected ()
synchronized boolean isBordersMovable ()
synchronized boolean isCustomizable ()
synchronized boolean isDashableOrDotable ()
boolean isDelimitorSelected ()
synchronized boolean isDoubleBoundaryable ()
synchronized boolean isFilled ()
synchronized boolean isHatched ()
boolean isIn (Point pt)
boolean isIn (LaTeXDrawPoint2D pt)
boolean isOnRotation ()
boolean isParametersEquals (Figure f, boolean considerShadow, boolean considerArrow)
synchronized boolean isResizable ()
synchronized boolean isSelected ()
synchronized boolean isShowOrigin ()
synchronized boolean isThicknessable ()
boolean isTooSmallToBeRescaled ()
synchronized boolean isXLabelSouth ()
synchronized boolean isYLabelWest ()
void mirrorHorizontal (LaTeXDrawPoint2D orig)
void mirrorVertical (LaTeXDrawPoint2D orig)
synchronized void onClick (Point pt)
synchronized void onDelimitorRelease ()
void onDragged (Point formerPt, Point newPt)
synchronized void onRelease ()
void rescaleX (double formerX, double newX, double percent, LaTeXDrawRectangle bound)
void rescaleY (double formerY, double newY, double percent, LaTeXDrawRectangle bound)
void rotate (LaTeXDrawPoint2D gravityC, double angle)
void rotate (Point formerPt, Point newPt) throws IllegalArgumentException
LaTeXDrawPoint2D rotateInvertPoint (Point p)
LaTeXDrawPoint2D rotateInvertPoint (LaTeXDrawPoint2D p)
LaTeXDrawPoint2D rotatePoint (Point p)
synchronized LaTeXDrawPoint2D rotatePoint (LaTeXDrawPoint2D p, double theta)
LaTeXDrawPoint2D rotatePoint (LaTeXDrawPoint2D p)
void setArrow1Style (String style)
void setArrow2Style (String style)
synchronized void setAxesStyle (short axesStyle)
synchronized void setAxesStyleToken (String axesStyle)
synchronized void setBlackDashLength (float blackDashLength)
synchronized void setBordersPosition (String doubleLinePosition)
synchronized void setCustomizable (boolean isCustomizable)
synchronized void setDistLabelsX (double distLabelsX)
void setDistLabelsY (double distLabelsY)
synchronized void setDotSep (float dotSep)
synchronized void setDoubleColor (Color doublecolor)
synchronized void setDoubleSep (double doubleSep)
synchronized void setFirstPoint (LaTeXDrawPoint2D pt)
void setFirstPoint (double x, double y)
synchronized void setGradientAngle (double gradientAngle)
synchronized void setGradientEndColor (Color gradientEndColor)
synchronized void setGradientMidPoint (double gradientMidPoint)
synchronized void setGradientStartColor (Color gradientStartColor)
synchronized void setGridEnd (LaTeXDrawPoint2D gridEnd)
synchronized void setGridEndX (int x)
synchronized void setGridEndY (int y)
synchronized void setGridStart (LaTeXDrawPoint2D gridStart)
synchronized void setGridStartX (int x)
synchronized void setGridStartY (int y)
synchronized void setHasDoubleBoundary (boolean hasDoubleBoundary)
synchronized void setHasShadow (boolean hasShadow)
synchronized void setHatchingAngle (double hatchingAngle)
synchronized void setHatchingColor (Color color)
synchronized void setHatchingSep (double hatchSep)
synchronized void setHatchingStyle (String style)
synchronized void setHatchingWidth (float width)
synchronized void setIncrementX (double increment)
synchronized void setIncrementY (double increment)
synchronized void setInteriorColor (Color c)
synchronized void setIsFilled (boolean state)
synchronized void setLabelsDisplayed (short labelsDisplayed)
synchronized void setLabelsDisplayedToken (String labelsDisplayed)
synchronized void setLastPoint (LaTeXDrawPoint2D pt)
void setLastPoint (double x, double y)
synchronized void setLinesColor (Color c)
synchronized void setLineStyle (String style)
void setNewNumber ()
synchronized void setNumber (int number)
synchronized void setOnRotation (boolean on)
synchronized void setOrigin (LaTeXDrawPoint2D origin)
synchronized void setOriginX (int x)
synchronized void setOriginY (int y)
synchronized void setPosition (LaTeXDrawPoint2D position)
synchronized void setResizable (boolean isResizable)
synchronized void setRotationAngle (double theta)
synchronized void setSelected (boolean state)
synchronized void setShadowAngle (double shadowAngle)
synchronized void setShadowColor (Color shadowColor)
synchronized void setShadowSize (double shadowSize)
synchronized void setShowOrigin (boolean showOrigin)
synchronized void setThickness (float value)
synchronized void setTicksDisplayed (short ticksDisplayed)
synchronized void setTicksDisplayedToken (String ticksDisplayed)
synchronized void setTicksSize (double ticksSize)
synchronized void setTicksStyle (short ticksStyle)
synchronized void setTicksStyleToken (String ticksStyle)
synchronized void setWhiteDashLength (float whiteDashLength)
synchronized void setXLabelSouth (boolean isXLabelSouth)
synchronized void setYLabelWest (boolean isYLabelWest)
boolean shadowFillsShape ()
void shift (Point formerPt, Point newPt)
void shift (LaTeXDrawPoint2D formerPt, LaTeXDrawPoint2D newPt)
void shift (double shiftX, double shiftY)
String toString ()
void updateBorders (FontMetrics fm)
void updateBorders ()
synchronized void updateFonts ()
synchronized void updateGravityCenter ()
void updateShape ()
void updateStyleOfDelimitors ()
void updateToGrid (MagneticGrid grid)

Static Public Member Functions

static double computeAngle (Point pt, LaTeXDrawPoint2D gravityC)
static JComboBox createAxeStyleChoice ()
static LaTeXDrawComboBox createBordersPositionChoice ()
static LaTeXDrawComboBox createFillChoice ()
static LaTeXDrawComboBox createStyleLineChoice ()
static JComboBox createTicksStyleChoice ()
static double getCornerGap (Point2D a, Point2D b, Point2D c, double gap)
static boolean isValidBordersPosition (String pos)
static boolean isValidStyle (String style)
static LaTeXDrawPoint2D rotatePoint (LaTeXDrawPoint2D p, LaTeXDrawPoint2D gravityC, double theta)

Public Attributes

double rotationAngle

Static Public Attributes

static final String ACTION_CMD_AXE_STYLE_CHOICE = "axeStyleCmd"
static final String ACTION_CMD_TICKS_STYLE_CHOICE = "ticksStyleCmd"
static final short AXES_STYLE_AXES_VALUE = 0
static final short AXES_STYLE_FRAME_VALUE = 1
static final short AXES_STYLE_NONE_VALUE = 2
static final String DECREPETED_FILL_CROSS = "Cross hatch"
static final String DECREPETED_FILL_HORIZ = "Horizontal hatch"
static final String DECREPETED_FILL_NO = "No hatch"
static final String DECREPETED_FILL_VERT = "Vertical hatch"
static final float DEFAULT_BLACK_DASH_LGTH = 8
static final Color DEFAULT_BORDERS_COL = Color.BLACK
static final float DEFAULT_DOT_SEP = 8
static final boolean DEFAULT_DOUBLELINE = false
static final double DEFAULT_DOUBLESEP = 6
static final double DEFAULT_GRADIENT_ANGLE = Math.toRadians(PSTricksConstants.DEFAULT_GRADIENT_ANGLE)
static final double DEFAULT_GRADIENT_MID_POINT = 1
static final LaTeXDrawPoint2D DEFAULT_GRIDMAX = new LaTeXDrawPoint2D(2,2)
static final LaTeXDrawPoint2D DEFAULT_GRIDMIN = (LaTeXDrawPoint2D)DEFAULT_ORIGIN.clone()
static final boolean DEFAULT_HAS_DOUBLE_BOUNDARY = false
static final double DEFAULT_HATCH_ANGLE = 0.
static final Color DEFAULT_HATCH_COL = Color.BLACK
static final double DEFAULT_HATCH_SEP = PSTricksConstants.DEFAULT_HATCH_SEP*PPC
static final String DEFAULT_HATCH_STYLE = PSTricksConstants.TOKEN_FILL_NONE
static final Color DEFAULT_INTERIOR_COL = Color.WHITE
static final boolean DEFAULT_IS_BORDERS_MOVABLE = true
static final boolean DEFAULT_IS_CUSTOMISABLE = true
static final boolean DEFAULT_IS_FILLED = false
static final boolean DEFAULT_IS_HATCHED = false
static final boolean DEFAULT_IS_THICKNESSABLE = true
static final boolean DEFAULT_ISRESIZABLE = true
static final boolean DEFAULT_ISXLABELSOUTH = true
static final boolean DEFAULT_ISYLABELWEST = true
static final int DEFAULT_LABELSSIZE = 20
static final String DEFAULT_LINE_STYLE = PSTricksConstants.LINE_NONE_STYLE
static final LaTeXDrawPoint2D DEFAULT_ORIGIN = new LaTeXDrawPoint2D(0,0)
static final double DEFAULT_ROTATION_ANGLE = 0.
static final double DEFAULT_SHADOW_ANGLE = Math.toRadians(PSTricksConstants.DEFAULT_SHADOW_ANGLE)
static final boolean DEFAULT_SHADOW_HAS = PSTricksConstants.DEFAULT_SHADOW
static final double DEFAULT_SHADOW_SIZE = PSTricksConstants.DEFAULT_SHADOW_SIZE*PPC
static final float DEFAULT_THICKNESS = 2
static final float DEFAULT_WHITE_DASH_LGTH = 8
static final short DELIMITOR_ORIENTATION_EAST = 2
static final short DELIMITOR_ORIENTATION_NE = 6
static final short DELIMITOR_ORIENTATION_NONE = -1
static final short DELIMITOR_ORIENTATION_NORTH = 3
static final short DELIMITOR_ORIENTATION_NW = 4
static final short DELIMITOR_ORIENTATION_SE = 7
static final short DELIMITOR_ORIENTATION_SOUTH = 8
static final short DELIMITOR_ORIENTATION_SW = 5
static final short DELIMITOR_ORIENTATION_WEST = 0
static final short DELIMITOR_ROTATION = 9
static final double GAP_LABEL = 5.
static final String LABEL_BORDERS_POSITION_CHOICE = LaTeXDrawLang.getOthersString("Figure.boundPos")
static final String LABEL_HATCH_CHOICE = "Hatch choice"
static final String LABEL_HATCH_WIDTH = "Hatch width"
static final String LABEL_STYLE_AXE = LaTeXDrawLang.getString1_8("Axe.1")
static final String LABEL_STYLE_FRAME = LaTeXDrawLang.getString1_8("Axe.2")
static final String LABEL_STYLE_NONE = LaTeXDrawLang.getString1_8("Axe.0")
static final String LABEL_STYLE_TICKS_BOTTOM = LaTeXDrawLang.getString1_8("Axe.5")
static final String LABEL_STYLE_TICKS_FULL = LaTeXDrawLang.getString1_8("Axe.3")
static final String LABEL_STYLE_TICKS_TOP = LaTeXDrawLang.getString1_8("Axe.4")
static final short LABELS_DISPLAYED_ALL_VALUE = 0
static final short LABELS_DISPLAYED_NON_VALUE = 3
static final short LABELS_DISPLAYED_X_VALUE = 1
static final short LABELS_DISPLAYED_Y_VALUE = 2
static final int PPC = 50
static final short TICKS_STYLE_BOTTOM_VALUE = 2
static final short TICKS_STYLE_FULL_VALUE = 0
static final short TICKS_STYLE_TOP_VALUE = 1

Protected Member Functions

void fillFigure (Graphics2D g, Object antiAlias, Object rendering, Object alphaInter, Object colorRendering, Shape s)
Shape getTooSmallShape (Shape s)
void setHasGradient ()

Protected Attributes

ArrowHead arrowHead1
ArrowHead arrowHead2
int axesStyle
float blackDashLength
LaTeXDrawRectangle borders
String bordersPosition
boolean canBeFilled
boolean canHaveArrow
boolean canHaveShadow
LaTeXDrawPoint2D distLabels
float dotSep
Color doubleColor
double doubleSep
Delimitor dSelected
Font font
FontMetrics fontMetrics
double gradientAngle
Color gradientEndColor
double gradientMidPoint
Color gradientStartColor
LaTeXDrawPoint2D gravityCenter
LaTeXDrawPoint2D gridEnd
LaTeXDrawPoint2D gridStart
boolean hasDoubleBoundary
boolean hasShadow
double hatchingAngle
Color hatchingColor
double hatchingSep
String hatchingStyle
float hatchingWidth
LaTeXDrawPoint2D increment
Color interiorColor
boolean isBordersMovable
boolean isCustomizable
boolean isDashableOrDotable
boolean isDoubleBoundaryable
boolean isFilled
boolean isOnRotation
boolean isResizable
boolean isSelected
boolean isThicknessable
boolean isXLabelSouth
boolean isYLabelWest
int labelsDisplayed
Color linesColor
String lineStyle
int number
LaTeXDrawPoint2D origin
LaTeXDrawPoint2D position
double shadowAngle
Color shadowColor
double shadowSize
transient Shape shape
boolean showOrigin
float thickness
int ticksDisplayed
double ticksSize
int ticksStyle
float whiteDashLength

Private Member Functions

void readObject (ObjectInputStream ois) throws IOException, ClassNotFoundException

Static Private Attributes

static final long serialVersionUID = 1L

The documentation for this class was generated from the following file:

Generated by  Doxygen 1.6.0   Back to index