public class EasyWindow extends Window implements Easy
window.addLine(0,0,100,100).setColor(Color.RED); window.addCircle(0, 0, 1).setColor(Color.RED); window.addShape(new Line(0, 0, 10, 10)).setColor(Color.RED);
Window.CloseWindow
JFrame.AccessibleJFrame
Frame.AccessibleAWTFrame
Window.AccessibleAWTWindow, Window.Type
Container.AccessibleAWTContainer
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, HIDE_ON_CLOSE
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
Constructor and Description |
---|
EasyWindow()
Luo uuden ikkunan
|
EasyWindow(int width,
int height)
Luo uuden ikkunan
|
Modifier and Type | Method and Description |
---|---|
Axis |
addAxis(double xLength,
double yLength,
double zLength)
Lisää olioon koordinaatistoakselit.
|
Axis |
addAxis(double xLength,
double yLength,
double zLength,
double x,
double y,
double z)
Lisää olioon koordinaatistoakselit.
|
Circle |
addCircle(double x,
double y,
double r)
Lisää olioon ympyrän.
|
Circle |
addCircle(double x,
double y,
double z,
double r)
Lisää olioon ympyrän.
|
FillPolygon |
addFillPolygon(double[][] points)
Lisää olioon täytetyn monikulmion.
|
FillPolygon |
addFillPolygon(double[] xpoints,
double[] ypoints)
Lisää olioon täytetyn monikulmion.
|
Line |
addLine(double x1,
double y1,
double x2,
double y2)
Lisää olioon uuden viivan.
|
Line |
addLine(double x1,
double y1,
double z1,
double x2,
double y2,
double z2)
Lisää olioon viivan.
|
Polygon |
addPolygon(double[][] points)
Lisää olioon monikulmion.
|
Polygon |
addPolygon(double[] xpoints,
double[] ypoints)
Lisää olioon monikulmion.
|
Drawable |
addShape(Drawable shape)
Lisää olioon kuvion joka on Drawable-olio.
|
add, changeTransform, clear, getFullTransform, getPanel, getRotator, getSavedPath, getTransform, move, redraw, remove, rotate, scale, scale, setControlButtons, setIsotrophic, setRotator, setSpace, setTouchPad, setTouchPad, setTransform, showWindow, transform
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setIconImage, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setBackground, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setOpacity, setResizable, setShape, setState, setTitle, setUndecorated
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBackground, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOpacity, getOwnedWindows, getOwner, getOwnerlessWindows, getShape, getToolkit, getType, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isAutoRequestFocus, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isOpaque, isShowing, isValidateRoot, pack, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setAutoRequestFocus, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImages, setLocation, setLocation, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setType, setVisible, show, toBack, toFront
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusDownCycle, validate, validateTree
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, revalidate, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getFont, postEvent
public EasyWindow()
public EasyWindow(int width, int height)
width
- ikkunan leveysheight
- ikkunan korkeuspublic Drawable addShape(Drawable shape)
Easy
space.addShape(new Line(0, 0, 10, 10)).setColor(Color.RED);
public Line addLine(double x1, double y1, double x2, double y2)
Easy
space.addLine(0,0,100,100).setColor(Color.RED);
public Line addLine(double x1, double y1, double z1, double x2, double y2, double z2)
Easy
space.addLine(0, 0, 0, 100, 100, 100).setColor(Color.RED);
public Circle addCircle(double x, double y, double r)
Easy
space.addCircle(0, 0, 1).setColor(Color.RED);
public Circle addCircle(double x, double y, double z, double r)
Easy
space.addCircle(0, 0, 0, 1).setColor(Color.RED);
public Polygon addPolygon(double[] xpoints, double[] ypoints)
Easy
double[] xpoints = {-1, 2, 4}; double[] ypoints = [5, 6, 7}; space.addPolygon(xpoints, ypoints).setColor(Color.RED);
addPolygon
in interface Easy
xpoints
- monikulmion kärkipisteiden x-koordinaatitypoints
- monikulmion käskipisteiden y-koordinaatitpublic Polygon addPolygon(double[][] points)
Easy
double[][] points = {{2, 6}, {5, 5}, {-1, 2.5}} space.addPoylgon(points).setColor(Color.RED);
addPolygon
in interface Easy
points
- monikulmion kärkipisteiden koordinaatitpublic FillPolygon addFillPolygon(double[] xpoints, double[] ypoints)
Easy
double[] xpoints = {-1, 2, 4}; double[] ypoints = [5, 6, 7}; space.addFillPolygon(xpoints, ypoints).setColor(Color.RED);
addFillPolygon
in interface Easy
xpoints
- monikulmion kärkipisteiden x-koordinaatitypoints
- monikulmion käskipisteiden y-koordinaatitpublic FillPolygon addFillPolygon(double[][] points)
Easy
double[][] points = {{2, 6}, {5, 5}, {-1, 2.5}} space.addFillPoylgon(points).setColor(Color.RED);
addFillPolygon
in interface Easy
points
- monikulmion kärkipisteiden koordinaatitpublic Axis addAxis(double xLength, double yLength, double zLength)
Easy
space.addAxis(5, 5, 5).setColor(Color.RED);
public Axis addAxis(double xLength, double yLength, double zLength, double x, double y, double z)
Easy
space.addAxis(5, 5, 5, 0, 0, 0).setColor(Color.RED);