Top Description Inners Fields Constructors Methods
org.apache.pdfbox.jbig2

public Class TestImage

extends JFrame
Class Inheritance
Imports
java.awt.Dimension, .Graphics, .Graphics2D, .Image, .Insets, .MediaTracker, .Point, java.awt.image.BufferedImage, .ColorModel, .DataBuffer, .DataBufferByte, .IndexColorModel, .MultiPixelPackedSampleModel, .Raster, .SampleModel, .WritableRaster, java.io.IOException, javax.swing.JComponent, .JFrame, .JScrollPane

This is a utility class. It can be used to show intermediary results.

Nested and Inner Type Summary

Modifier and TypeClass and Description
pack-priv static class

Field Summary

Modifier and TypeField and Description
private static final long
Inherited from javax.swing.JFrame:
accessibleContextrootPanerootPaneCheckingEnabled

Constructor Summary

AccessConstructor and Description
public
TestImage(byte[] data, int w, int h, int scanlineStride)

public
TestImage(BufferedImage bufferedImage)

Method Summary

Modifier and TypeMethod and Description
public static void
main(String[] args)

Inherited from javax.swing.JFrame:
addImplcreateRootPaneframeInitgetAccessibleContextgetContentPanegetDefaultCloseOperationgetGlassPanegetGraphicsgetJMenuBargetLayeredPanegetRootPanegetTransferHandlerisDefaultLookAndFeelDecoratedisRootPaneCheckingEnabledparamStringprocessWindowEventremoverepaintsetContentPanesetDefaultCloseOperationsetDefaultLookAndFeelDecoratedsetGlassPanesetIconImagesetJMenuBarsetLayeredPanesetLayoutsetRootPanesetRootPaneCheckingEnabledsetTransferHandlerupdate

Field Detail

serialVersionUIDback to summary
private static final long serialVersionUID

Hides java.awt.Frame.serialVersionUID.

Constructor Detail

TestImageback to summary
public TestImage(byte[] data, int w, int h, int scanlineStride)
TestImageback to summary
public TestImage(BufferedImage bufferedImage)

Method Detail

mainback to summary
public static void main(String[] args)
org.apache.pdfbox.jbig2 back to summary

pack-priv Class TestImage.ImageComponent

extends JComponent
Class Inheritance

Field Summary

Modifier and TypeField and Description
pack-priv int
pack-priv int
pack-priv Image
pack-priv Dimension
private int
private static final long
Inherited from javax.swing.JComponent:
listenerListTOOL_TIP_TEXT_KEYuiUNDEFINED_CONDITIONWHEN_ANCESTOR_OF_FOCUSED_COMPONENTWHEN_FOCUSEDWHEN_IN_FOCUSED_WINDOW

Constructor Summary

AccessConstructor and Description
protected
ImageComponent()

Constructor for ImageComponent.

public
ImageComponent(Image image)

Constructor for ImageComponent.

Method Summary

Modifier and TypeMethod and Description
public Insets

Returns:

Insets the Insets of the Component
getInsets
()

Overrides javax.swing.JComponent.getInsets.

Get the Insets fo the Component

public Dimension
getMinimumSize()

Overrides javax.swing.JComponent.getMinimumSize.

Gets the minimum Size of the Component

public Dimension
getPreferredSize()

Overrides javax.swing.JComponent.getPreferredSize.

Gets the preffered Size of the Component

public int
protected void
paintComponent(Graphics
java.awt.Graphics
g
)

Overrides javax.swing.JComponent.paintComponent.

Paints the component

public void
setImage(Image
java.awt.Image
image
)

Sets an image to be shown

public void
setScale(int scale)

Inherited from javax.swing.JComponent:
addAncestorListeneraddNotifyaddVetoableChangeListenercomputeVisibleRectcontainscreateToolTipdisableenablefirePropertyChangefirePropertyChangefirePropertyChangefireVetoableChangegetActionForKeyStrokegetActionMapgetAlignmentXgetAlignmentYgetAncestorListenersgetAutoscrollsgetBaselinegetBaselineResizeBehaviorgetBordergetBoundsgetClientPropertygetComponentGraphicsgetComponentPopupMenugetConditionForKeyStrokegetDebugGraphicsOptionsgetDefaultLocalegetFontMetricsgetGraphicsgetHeightgetInheritsPopupMenugetInputMapgetInputMapgetInputVerifiergetInsetsgetListenersgetLocationgetMaximumSizegetNextFocusableComponentgetPopupLocationgetRegisteredKeyStrokesgetRootPanegetSizegetToolTipLocationgetToolTipTextgetToolTipTextgetTopLevelAncestorgetTransferHandlergetUIgetUIClassIDgetVerifyInputWhenFocusTargetgetVetoableChangeListenersgetVisibleRectgetWidthgetXgetYgrabFocushideisDoubleBufferedisLightweightComponentisManagingFocusisOpaqueisOptimizedDrawingEnabledisPaintingForPrintisPaintingOriginisPaintingTileisRequestFocusEnabledisValidateRootpaintpaintBorderpaintChildrenpaintImmediatelypaintImmediatelyparamStringprintprintAllprintBorderprintChildrenprintComponentprocessComponentKeyEventprocessKeyBindingprocessKeyEventprocessMouseEventprocessMouseMotionEventputClientPropertyregisterKeyboardActionregisterKeyboardActionremoveAncestorListenerremoveNotifyremoveVetoableChangeListenerrepaintrepaintrequestDefaultFocusrequestFocusrequestFocusrequestFocusInWindowrequestFocusInWindowresetKeyboardActionsreshaperevalidatescrollRectToVisiblesetActionMapsetAlignmentXsetAlignmentYsetAutoscrollssetBackgroundsetBordersetComponentPopupMenusetDebugGraphicsOptionssetDefaultLocalesetDoubleBufferedsetEnabledsetFocusTraversalKeyssetFontsetForegroundsetInheritsPopupMenusetInputMapsetInputVerifiersetMaximumSizesetMinimumSizesetNextFocusableComponentsetOpaquesetPreferredSizesetRequestFocusEnabledsetToolTipTextsetTransferHandlersetUIsetVerifyInputWhenFocusTargetsetVisibleunregisterKeyboardActionupdateupdateUI

Field Detail

imgHeightback to summary
pack-priv int imgHeight
imgWidthback to summary
pack-priv int imgWidth
myImageback to summary
pack-priv Image myImage
prefSizeback to summary
pack-priv Dimension prefSize

Hides java.awt.Component.prefSize.

scaleback to summary
private int scale
serialVersionUIDback to summary
private static final long serialVersionUID

Hides java.awt.Container.serialVersionUID.

Constructor Detail

ImageComponentback to summary
protected ImageComponent()

Constructor for ImageComponent.

ImageComponentback to summary
public ImageComponent(Image image)

Constructor for ImageComponent.

Method Detail

getInsetsback to summary
public Insets getInsets()

Overrides javax.swing.JComponent.getInsets.

Get the Insets fo the Component

Returns:Insets

Insets the Insets of the Component

getMinimumSizeback to summary
public Dimension getMinimumSize()

Overrides javax.swing.JComponent.getMinimumSize.

Gets the minimum Size of the Component

Returns:Dimension

Doc from javax.swing.JComponent.getMinimumSize.

the value of the minimumSize property

getPreferredSizeback to summary
public Dimension getPreferredSize()

Overrides javax.swing.JComponent.getPreferredSize.

Gets the preffered Size of the Component

Returns:Dimension

Doc from javax.swing.JComponent.getPreferredSize.

the value of the preferredSize property

getScaleback to summary
public int getScale()
paintComponentback to summary
protected void paintComponent(Graphics g)

Overrides javax.swing.JComponent.paintComponent.

Paints the component

Parameters
g:Graphics

java.awt.Graphics

setImageback to summary
public void setImage(Image image)

Sets an image to be shown

Parameters
image:Image

java.awt.Image

setScaleback to summary
public void setScale(int scale)