Class JCalendarDateDialog
java.lang.Object
java.awt.Component
java.awt.Container
java.awt.Window
java.awt.Dialog
javax.swing.JDialog
org.gvsig.gui.beans.swing.textBoxWithCalendar.JCalendarDateDialog
- All Implemented Interfaces:
ImageObserver,MenuContainer,Serializable,Accessible,RootPaneContainer,WindowConstants,IMethodsForGraphicalCalendarComponents
public class JCalendarDateDialog
extends JDialog
implements IMethodsForGraphicalCalendarComponents, Serializable
Creates a Dialog that allows users to select the date they want
This class is a version of JCalendarDatePanel
- Author:
- Pablo Piqueras Bartolomé (p_queras@hotmail.com)
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JDialog
JDialog.AccessibleJDialogNested classes/interfaces inherited from class java.awt.Dialog
Dialog.AccessibleAWTDialog, Dialog.ModalExclusionType, Dialog.ModalityTypeNested classes/interfaces inherited from class java.awt.Window
Window.AccessibleAWTWindow, Window.TypeNested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainerNested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy -
Field Summary
Fields inherited from class javax.swing.JDialog
accessibleContext, rootPane, rootPaneCheckingEnabledFields inherited from class java.awt.Dialog
DEFAULT_MODALITY_TYPEFields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENTFields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTHFields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, EXIT_ON_CLOSE, HIDE_ON_CLOSE -
Constructor Summary
ConstructorsConstructorDescriptionDefault ConstructorJCalendarDateDialog(int width, int height) This is the default constructor with 2 parameters for set the size -
Method Summary
Modifier and TypeMethodDescriptiongetDate()Gets the date of the calendarReturns the date selected, formattedintGet the height of this panelgetTitle()Gets the title of the JDialog with the calendar component.intgetWidth()Get the width of this panelvoidSets the initial size of this panelvoidSets the date to the calendarvoidSets the default title of the JDialog with the calendar component.voidsetMaximumHeight(int max_height) Sets the maximum height for this component (If the parameter isn't > 0 neither -1, this method doesn't apply the changes)voidsetMaximumHeightScreenResolutionPercentage(double max_height_screen_percentage) Sets the maximum height for this component, according a percentage of the height resolution of the screen (If the parameter isn't > 0.0 neither -1.0 neither invalid input: '<'= 1.0, this method doesn't apply the changes)voidsetMaximumWidth(int max_width) Sets the maximum width for this component (If the parameter isn't > 0 neither -1, this method doesn't apply the changes)voidsetMaximumWidthScreenResolutionPercentage(double max_width_screen_percentage) Sets the maximum width for this component, according a percentage of the width resolution of the screen (If the parameter isn't > 0.0 neither -1.0 neither invalid input: '<'= 1.0, this method doesn't apply the changes)voidsetMinimumHeight(int min_height) Sets the minimum height for this component (If the parameter isn't > 0 neither -1, this method doesn't apply the changes)voidsetMinimumHeightScreenResolutionPercentage(double min_height_screen_percentage) Sets the minimum height for this component, according a percentage of the height resolution of the screen (If the parameter isn't > 0.0 neither -1.0 neither invalid input: '<'= 1.0, this method doesn't apply the changes)voidsetMinimumWidth(int min_width) Sets the minimum width for this component (If the parameter isn't > 0 neither -1, this method doesn't apply the changes)voidsetMinimumWidthScreenResolutionPercentage(double min_width_screen_percentage) Sets the minimum width for this component, according a percentage of the width resolution of the screen (If the parameter isn't > 0.0 neither -1.0 neither invalid input: '<'= 1.0, this method doesn't apply the changes)voidsetModal(boolean b) voidsetSizeResize(int width, int height) Sets the size of this panelvoidSets the title of the JDialog with the calendar component.Methods inherited from class javax.swing.JDialog
addImpl, createRootPane, dialogInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, updateMethods inherited from class java.awt.Dialog
addNotify, getModalityType, hide, isModal, isResizable, isUndecorated, setBackground, setModalityType, setOpacity, setResizable, setShape, setUndecorated, setVisible, show, toBackMethods inherited from class java.awt.Window
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, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isAutoRequestFocus, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isOpaque, isShowing, isValidateRoot, pack, paint, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeNotify, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setAutoRequestFocus, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImage, setIconImages, setLocation, setLocation, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setType, toFrontMethods inherited from class java.awt.Container
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, validateTreeMethods inherited from class java.awt.Component
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, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, 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, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, requestFocusInWindow, resize, resize, revalidate, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setMaximumSize, setMixingCutoutShape, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
-
Constructor Details
-
JCalendarDateDialog
public JCalendarDateDialog()Default Constructor -
JCalendarDateDialog
public JCalendarDateDialog(int width, int height) This is the default constructor with 2 parameters for set the size
-
-
Method Details
-
resizeToInitialSize
public void resizeToInitialSize()Sets the initial size of this panel- Parameters:
width- (the new Width for the panel)height- (the new Height for the panel)
-
setMaximumWidthScreenResolutionPercentage
public void setMaximumWidthScreenResolutionPercentage(double max_width_screen_percentage) Sets the maximum width for this component, according a percentage of the width resolution of the screen (If the parameter isn't > 0.0 neither -1.0 neither invalid input: '<'= 1.0, this method doesn't apply the changes)- Parameters:
max_width_screen_percentage- A float number > 0, or -1 if there is no limit
-
setMinimumWidthScreenResolutionPercentage
public void setMinimumWidthScreenResolutionPercentage(double min_width_screen_percentage) Sets the minimum width for this component, according a percentage of the width resolution of the screen (If the parameter isn't > 0.0 neither -1.0 neither invalid input: '<'= 1.0, this method doesn't apply the changes)- Parameters:
min_width_screen_percentage- A float number > 0.0 neither -1.0 neither invalid input: '<'= 1.0, or -1 if there is no limit
-
setMaximumHeightScreenResolutionPercentage
public void setMaximumHeightScreenResolutionPercentage(double max_height_screen_percentage) Sets the maximum height for this component, according a percentage of the height resolution of the screen (If the parameter isn't > 0.0 neither -1.0 neither invalid input: '<'= 1.0, this method doesn't apply the changes)- Parameters:
max_width_screen_percentage- A float number > 0.0 neither -1.0 neither invalid input: '<'= 1.0, or -1 if there is no limit
-
setMinimumHeightScreenResolutionPercentage
public void setMinimumHeightScreenResolutionPercentage(double min_height_screen_percentage) Sets the minimum height for this component, according a percentage of the height resolution of the screen (If the parameter isn't > 0.0 neither -1.0 neither invalid input: '<'= 1.0, this method doesn't apply the changes)- Parameters:
min_width_screen_percentage- A float number > 0.0 neither -1.0 neither invalid input: '<'= 1.0, or -1 if there is no limit
-
setMaximumWidth
public void setMaximumWidth(int max_width) Sets the maximum width for this component (If the parameter isn't > 0 neither -1, this method doesn't apply the changes)- Parameters:
max_width- A natural number > 0, or -1 if there is no limit
-
setMinimumWidth
public void setMinimumWidth(int min_width) Sets the minimum width for this component (If the parameter isn't > 0 neither -1, this method doesn't apply the changes)- Parameters:
min_width- A natural number > 0, or -1 if there is no limit
-
setMaximumHeight
public void setMaximumHeight(int max_height) Sets the maximum height for this component (If the parameter isn't > 0 neither -1, this method doesn't apply the changes)- Parameters:
max_width- A natural number > 0, or -1 if there is no limit
-
setMinimumHeight
public void setMinimumHeight(int min_height) Sets the minimum height for this component (If the parameter isn't > 0 neither -1, this method doesn't apply the changes)- Parameters:
min_width- A natural number > 0, or -1 if there is no limit
-
setSizeResize
public void setSizeResize(int width, int height) Sets the size of this panel- Parameters:
width- (the new Width for the panel)height- (the new Height for the panel)
-
getHeight
public int getHeight()Get the height of this panel -
getWidth
public int getWidth()Get the width of this panel -
getDate
Description copied from interface:IMethodsForGraphicalCalendarComponentsGets the date of the calendar- Specified by:
getDatein interfaceIMethodsForGraphicalCalendarComponents- Returns:
- Date
-
setDate
Description copied from interface:IMethodsForGraphicalCalendarComponentsSets the date to the calendar- Specified by:
setDatein interfaceIMethodsForGraphicalCalendarComponents- Parameters:
date-
-
getFormattedDate
Description copied from interface:IMethodsForGraphicalCalendarComponentsReturns the date selected, formatted- Specified by:
getFormattedDatein interfaceIMethodsForGraphicalCalendarComponents- Returns:
- String The formatted date
-
getTitle
Gets the title of the JDialog with the calendar component. The title is displayed in the JDialog's border. -
setTitle
Sets the title of the JDialog with the calendar component. -
setDefaultTitle
public void setDefaultTitle()Sets the default title of the JDialog with the calendar component. -
setModal
public void setModal(boolean b)
-