├── .gitignore
├── LICENSE.txt
├── README.md
├── android-awt.iml
├── awtcompat
├── .gitignore
├── awtcompat.iml
├── build.gradle
├── proguard-rules.pro
└── src
│ └── main
│ ├── AndroidManifest.xml
│ ├── cpp
│ ├── CMakeLists.txt
│ ├── awtcompat_native_components.c
│ ├── common
│ │ ├── exceptions.c
│ │ └── exceptions.h
│ ├── headers
│ │ └── awtcompat_native_components.h
│ ├── lcmm
│ │ ├── NativeCMM.c
│ │ ├── NativeCMM.h
│ │ ├── NativeImageFormat.c
│ │ ├── NativeImageFormat.h
│ │ ├── cmmapi.h
│ │ ├── cmmerror.c
│ │ ├── cmmerror.h
│ │ ├── cmmio.c
│ │ └── cmmxforms.c
│ └── lcms
│ │ ├── cmscam02.c
│ │ ├── cmscam97.c
│ │ ├── cmscam97.c.rej
│ │ ├── cmscgats.c
│ │ ├── cmscnvrt.c
│ │ ├── cmserr.c
│ │ ├── cmsgamma.c
│ │ ├── cmsgmt.c
│ │ ├── cmsintrp.c
│ │ ├── cmsio0.c
│ │ ├── cmsio1.c
│ │ ├── cmslut.c
│ │ ├── cmsmatsh.c
│ │ ├── cmsmtrx.c
│ │ ├── cmsnamed.c
│ │ ├── cmspack.c
│ │ ├── cmspcs.c
│ │ ├── cmsps2.c
│ │ ├── cmssamp.c
│ │ ├── cmsvirt.c
│ │ ├── cmswtpnt.c
│ │ ├── cmsxform.c
│ │ ├── icc34.h
│ │ └── lcms.h
│ └── java
│ ├── java
│ └── awt
│ │ ├── AWTError.java
│ │ ├── AWTException.java
│ │ ├── ActiveEvent.java
│ │ ├── AlphaComposite.java
│ │ ├── BasicStroke.java
│ │ ├── BufferCapabilities.java
│ │ ├── Canvas.java
│ │ ├── Color.java
│ │ ├── Component.java
│ │ ├── ComponentOrientation.java
│ │ ├── Composite.java
│ │ ├── CompositeContext.java
│ │ ├── Dimension.java
│ │ ├── DisplayMode.java
│ │ ├── Event.java
│ │ ├── Font.java
│ │ ├── FontFormatException.java
│ │ ├── FontMetrics.java
│ │ ├── GradientPaint.java
│ │ ├── GradientPaintContext.java
│ │ ├── Graphics.java
│ │ ├── Graphics2D.java
│ │ ├── Graphics2DUtil.java
│ │ ├── GraphicsConfigTemplate.java
│ │ ├── GraphicsConfiguration.java
│ │ ├── GraphicsDevice.java
│ │ ├── GraphicsEnvironment.java
│ │ ├── HeadlessException.java
│ │ ├── HeadlessGraphicsEnvironment.java
│ │ ├── IllegalComponentStateException.java
│ │ ├── Image.java
│ │ ├── ImageCapabilities.java
│ │ ├── Insets.java
│ │ ├── JobAttributes.java
│ │ ├── MediaTracker.java
│ │ ├── PageAttributes.java
│ │ ├── Paint.java
│ │ ├── PaintContext.java
│ │ ├── Point.java
│ │ ├── PointerInfo.java
│ │ ├── Polygon.java
│ │ ├── Rectangle.java
│ │ ├── RenderingHints.java
│ │ ├── Shape.java
│ │ ├── Stroke.java
│ │ ├── TexturePaint.java
│ │ ├── TexturePaintContext.java
│ │ ├── Toolkit.java
│ │ ├── ToolkitImpl.java
│ │ ├── Transparency.java
│ │ ├── color
│ │ ├── CMMException.java
│ │ ├── ColorSpace.java
│ │ ├── ICC_ColorSpace.java
│ │ ├── ICC_Profile.java
│ │ ├── ICC_ProfileGray.java
│ │ ├── ICC_ProfileRGB.java
│ │ ├── ICC_ProfileStub.java
│ │ └── ProfileDataException.java
│ │ ├── font
│ │ ├── FontRenderContext.java
│ │ ├── GlyphJustificationInfo.java
│ │ ├── GlyphMetrics.java
│ │ ├── GlyphVector.java
│ │ ├── GraphicAttribute.java
│ │ ├── ImageGraphicAttribute.java
│ │ ├── LineBreakMeasurer.java
│ │ ├── LineMetrics.java
│ │ ├── MultipleMaster.java
│ │ ├── NumericShaper.java
│ │ ├── OpenType.java
│ │ ├── ShapeGraphicAttribute.java
│ │ ├── TextAttribute.java
│ │ ├── TextHitInfo.java
│ │ ├── TextLayout.java
│ │ ├── TextMeasurer.java
│ │ ├── TransformAttribute.java
│ │ └── sfntly
│ │ │ ├── SfntlyFontPeer.java
│ │ │ ├── SfntlyGlyph.java
│ │ │ └── SfntlyLineMetrics.java
│ │ ├── geom
│ │ ├── AffineTransform.java
│ │ ├── Arc2D.java
│ │ ├── Area.java
│ │ ├── Area.java.0
│ │ ├── CubicCurve2D.java
│ │ ├── Dimension2D.java
│ │ ├── Ellipse2D.java
│ │ ├── FlatteningPathIterator.java
│ │ ├── GeneralPath.java
│ │ ├── IllegalPathStateException.java
│ │ ├── Line2D.java
│ │ ├── NoninvertibleTransformException.java
│ │ ├── PathIterator.java
│ │ ├── Point2D.java
│ │ ├── QuadCurve2D.java
│ │ ├── Rectangle2D.java
│ │ ├── RectangularShape.java
│ │ ├── RoundRectangle2D.java
│ │ └── impl
│ │ │ ├── AreaOp.java
│ │ │ ├── ChainEnd.java
│ │ │ ├── Crossings.java
│ │ │ ├── Curve.java
│ │ │ ├── CurveLink.java
│ │ │ ├── Edge.java
│ │ │ ├── Order0.java
│ │ │ ├── Order1.java
│ │ │ ├── Order2.java
│ │ │ └── Order3.java
│ │ ├── image
│ │ ├── AffineTransformOp.java
│ │ ├── AreaAveragingScaleFilter.java
│ │ ├── AwtImageBackdoorAccessorImpl.java
│ │ ├── BandCombineOp.java
│ │ ├── BandedSampleModel.java
│ │ ├── BufferStrategy.java
│ │ ├── BufferedImage.java
│ │ ├── BufferedImageFilter.java
│ │ ├── BufferedImageOp.java
│ │ ├── ByteLookupTable.java
│ │ ├── ColorConvertOp.java
│ │ ├── ColorModel.java
│ │ ├── ComponentColorModel.java
│ │ ├── ComponentSampleModel.java
│ │ ├── ConvolveOp.java
│ │ ├── CropImageFilter.java
│ │ ├── DataBuffer.java
│ │ ├── DataBufferByte.java
│ │ ├── DataBufferDouble.java
│ │ ├── DataBufferFloat.java
│ │ ├── DataBufferInt.java
│ │ ├── DataBufferShort.java
│ │ ├── DataBufferUShort.java
│ │ ├── DirectColorModel.java
│ │ ├── FilteredImageSource.java
│ │ ├── ImageConsumer.java
│ │ ├── ImageFilter.java
│ │ ├── ImageObserver.java
│ │ ├── ImageProducer.java
│ │ ├── ImagingOpException.java
│ │ ├── IndexColorModel.java
│ │ ├── Kernel.java
│ │ ├── LookupOp.java
│ │ ├── LookupTable.java
│ │ ├── MemoryImageSource.java
│ │ ├── MultiPixelPackedSampleModel.java
│ │ ├── PackedColorModel.java
│ │ ├── PixelGrabber.java
│ │ ├── PixelInterleavedSampleModel.java
│ │ ├── RGBImageFilter.java
│ │ ├── Raster.java
│ │ ├── RasterFormatException.java
│ │ ├── RasterOp.java
│ │ ├── RenderedImage.java
│ │ ├── ReplicateScaleFilter.java
│ │ ├── RescaleOp.java
│ │ ├── SampleModel.java
│ │ ├── ShortLookupTable.java
│ │ ├── SinglePixelPackedSampleModel.java
│ │ ├── TileObserver.java
│ │ ├── VolatileImage.java
│ │ ├── WritableRaster.java
│ │ ├── WritableRenderedImage.java
│ │ └── renderable
│ │ │ ├── ContextualRenderedImageFactory.java
│ │ │ ├── ParameterBlock.java
│ │ │ ├── RenderContext.java
│ │ │ ├── RenderableImage.java
│ │ │ ├── RenderableImageOp.java
│ │ │ ├── RenderableImageProducer.java
│ │ │ └── RenderedImageFactory.java
│ │ ├── peer
│ │ ├── ButtonPeer.java
│ │ ├── CanvasPeer.java
│ │ ├── CheckboxMenuItemPeer.java
│ │ ├── CheckboxPeer.java
│ │ ├── ChoicePeer.java
│ │ ├── ComponentPeer.java
│ │ ├── DialogPeer.java
│ │ ├── FileDialogPeer.java
│ │ ├── FontPeer.java
│ │ ├── FramePeer.java
│ │ ├── LabelPeer.java
│ │ ├── LightweightPeer.java
│ │ ├── ListPeer.java
│ │ ├── MenuBarPeer.java
│ │ ├── MenuComponentPeer.java
│ │ ├── MenuItemPeer.java
│ │ ├── MenuPeer.java
│ │ ├── MouseInfoPeer.java
│ │ ├── PanelPeer.java
│ │ ├── PopupMenuPeer.java
│ │ ├── ScrollPanePeer.java
│ │ ├── ScrollbarPeer.java
│ │ ├── TextAreaPeer.java
│ │ ├── TextFieldPeer.java
│ │ └── WindowPeer.java
│ │ └── print
│ │ ├── PageFormat.java
│ │ ├── Pageable.java
│ │ ├── Paper.java
│ │ ├── Printable.java
│ │ ├── PrinterException.java
│ │ ├── PrinterGraphics.java
│ │ └── PrinterJob.java
│ ├── javax
│ └── imageio
│ │ ├── IIOException.java
│ │ ├── IIOImage.java
│ │ ├── IIOParam.java
│ │ ├── IIOParamController.java
│ │ ├── ImageIO.java
│ │ ├── ImageReadParam.java
│ │ ├── ImageReader.java
│ │ ├── ImageTranscoder.java
│ │ ├── ImageTypeSpecifier.java
│ │ ├── ImageWriteParam.java
│ │ ├── ImageWriter.java
│ │ ├── event
│ │ ├── IIOReadProgressListener.java
│ │ ├── IIOReadUpdateListener.java
│ │ ├── IIOReadWarningListener.java
│ │ ├── IIOWriteProgressListener.java
│ │ └── IIOWriteWarningListener.java
│ │ ├── metadata
│ │ ├── IIOInvalidTreeException.java
│ │ ├── IIOMetadata.java
│ │ ├── IIOMetadataController.java
│ │ ├── IIOMetadataFormat.java
│ │ ├── IIOMetadataFormatImpl.java
│ │ ├── IIOMetadataNode.java
│ │ ├── IIOStandardMetadataFormat.java
│ │ └── IIOStandardMetadataFormatResources.properties
│ │ ├── plugins
│ │ ├── bmp
│ │ │ └── BMPImageWriteParam.java
│ │ └── jpeg
│ │ │ ├── JPEGHuffmanTable.java
│ │ │ ├── JPEGImageReadParam.java
│ │ │ ├── JPEGImageWriteParam.java
│ │ │ └── JPEGQTable.java
│ │ ├── spi
│ │ ├── IIORegistry.java
│ │ ├── IIOServiceProvider.java
│ │ ├── ImageInputStreamSpi.java
│ │ ├── ImageOutputStreamSpi.java
│ │ ├── ImageReaderSpi.java
│ │ ├── ImageReaderWriterSpi.java
│ │ ├── ImageTranscoderSpi.java
│ │ ├── ImageWriterSpi.java
│ │ ├── RegisterableService.java
│ │ └── ServiceRegistry.java
│ │ └── stream
│ │ ├── FileCacheImageInputStream.java
│ │ ├── FileCacheImageOutputStream.java
│ │ ├── FileImageInputStream.java
│ │ ├── FileImageOutputStream.java
│ │ ├── IIOByteBuffer.java
│ │ ├── ImageInputStream.java
│ │ ├── ImageInputStreamImpl.java
│ │ ├── ImageOutputStream.java
│ │ ├── ImageOutputStreamImpl.java
│ │ ├── MemoryCacheImageInputStream.java
│ │ └── MemoryCacheImageOutputStream.java
│ ├── org
│ └── apache
│ │ ├── commons
│ │ └── imaging
│ │ │ ├── ColorTools.java
│ │ │ ├── FormatCompliance.java
│ │ │ ├── ImageDump.java
│ │ │ ├── ImageFormat.java
│ │ │ ├── ImageFormats.java
│ │ │ ├── ImageInfo.java
│ │ │ ├── ImageParser.java
│ │ │ ├── ImageReadException.java
│ │ │ ├── ImageWriteException.java
│ │ │ ├── Imaging.java
│ │ │ ├── ImagingConstants.java
│ │ │ ├── ImagingException.java
│ │ │ ├── PixelDensity.java
│ │ │ ├── color
│ │ │ ├── ColorCieLab.java
│ │ │ ├── ColorCieLch.java
│ │ │ ├── ColorCieLuv.java
│ │ │ ├── ColorCmy.java
│ │ │ ├── ColorCmyk.java
│ │ │ ├── ColorConversions.java
│ │ │ ├── ColorHsl.java
│ │ │ ├── ColorHsv.java
│ │ │ ├── ColorHunterLab.java
│ │ │ ├── ColorXyz.java
│ │ │ └── package-info.java
│ │ │ ├── common
│ │ │ ├── BasicCParser.java
│ │ │ ├── BinaryConstant.java
│ │ │ ├── BinaryFileParser.java
│ │ │ ├── BinaryFunctions.java
│ │ │ ├── BinaryOutputStream.java
│ │ │ ├── ByteConversions.java
│ │ │ ├── FastByteArrayOutputStream.java
│ │ │ ├── IBufferedImageFactory.java
│ │ │ ├── IImageMetadata.java
│ │ │ ├── ImageBuilder.java
│ │ │ ├── ImageMetadata.java
│ │ │ ├── PackBits.java
│ │ │ ├── RationalNumber.java
│ │ │ ├── RgbBufferedImageFactory.java
│ │ │ ├── SimpleBufferedImageFactory.java
│ │ │ ├── bytesource
│ │ │ │ ├── ByteSource.java
│ │ │ │ ├── ByteSourceArray.java
│ │ │ │ ├── ByteSourceFile.java
│ │ │ │ ├── ByteSourceInputStream.java
│ │ │ │ └── package-info.java
│ │ │ ├── itu_t4
│ │ │ │ ├── BitArrayOutputStream.java
│ │ │ │ ├── BitInputStreamFlexible.java
│ │ │ │ ├── HuffmanTree.java
│ │ │ │ ├── HuffmanTreeException.java
│ │ │ │ ├── T4AndT6Compression.java
│ │ │ │ ├── T4_T6_Tables.java
│ │ │ │ └── package-info.java
│ │ │ ├── mylzw
│ │ │ │ ├── BitsToByteInputStream.java
│ │ │ │ ├── MyBitInputStream.java
│ │ │ │ ├── MyBitOutputStream.java
│ │ │ │ ├── MyLzwCompressor.java
│ │ │ │ ├── MyLzwDecompressor.java
│ │ │ │ └── package-info.java
│ │ │ └── package-info.java
│ │ │ ├── formats
│ │ │ ├── bmp
│ │ │ │ ├── BmpHeaderInfo.java
│ │ │ │ ├── BmpImageParser.java
│ │ │ │ ├── BmpWriter.java
│ │ │ │ ├── BmpWriterPalette.java
│ │ │ │ ├── BmpWriterRgb.java
│ │ │ │ ├── ImageContents.java
│ │ │ │ ├── PixelParser.java
│ │ │ │ ├── PixelParserBitFields.java
│ │ │ │ ├── PixelParserRgb.java
│ │ │ │ ├── PixelParserRle.java
│ │ │ │ ├── PixelParserSimple.java
│ │ │ │ └── package-info.java
│ │ │ ├── dcx
│ │ │ │ ├── DcxImageParser.java
│ │ │ │ └── package-info.java
│ │ │ ├── gif
│ │ │ │ ├── GenericGifBlock.java
│ │ │ │ ├── GifBlock.java
│ │ │ │ ├── GifHeaderInfo.java
│ │ │ │ ├── GifImageParser.java
│ │ │ │ ├── GraphicControlExtension.java
│ │ │ │ ├── ImageContents.java
│ │ │ │ ├── ImageDescriptor.java
│ │ │ │ └── package-info.java
│ │ │ ├── icns
│ │ │ │ ├── IcnsDecoder.java
│ │ │ │ ├── IcnsImageParser.java
│ │ │ │ ├── IcnsType.java
│ │ │ │ ├── Rle24Compression.java
│ │ │ │ └── package-info.java
│ │ │ ├── ico
│ │ │ │ ├── IcoImageParser.java
│ │ │ │ └── package-info.java
│ │ │ ├── jpeg
│ │ │ │ ├── JpegConstants.java
│ │ │ │ ├── JpegImageMetadata.java
│ │ │ │ ├── JpegImageParser.java
│ │ │ │ ├── JpegPhotoshopMetadata.java
│ │ │ │ ├── JpegUtils.java
│ │ │ │ ├── decoder
│ │ │ │ │ ├── Block.java
│ │ │ │ │ ├── Dct.java
│ │ │ │ │ ├── JpegDecoder.java
│ │ │ │ │ ├── JpegInputStream.java
│ │ │ │ │ ├── YCbCrConverter.java
│ │ │ │ │ └── ZigZag.java
│ │ │ │ ├── exif
│ │ │ │ │ └── ExifRewriter.java
│ │ │ │ ├── iptc
│ │ │ │ │ ├── IptcBlock.java
│ │ │ │ │ ├── IptcConstants.java
│ │ │ │ │ ├── IptcParser.java
│ │ │ │ │ ├── IptcRecord.java
│ │ │ │ │ ├── IptcType.java
│ │ │ │ │ ├── IptcTypeLookup.java
│ │ │ │ │ ├── IptcTypes.java
│ │ │ │ │ ├── JpegIptcRewriter.java
│ │ │ │ │ └── PhotoshopApp13Data.java
│ │ │ │ ├── package-info.java
│ │ │ │ ├── segments
│ │ │ │ │ ├── App13Segment.java
│ │ │ │ │ ├── App14Segment.java
│ │ │ │ │ ├── App2Segment.java
│ │ │ │ │ ├── AppnSegment.java
│ │ │ │ │ ├── ComSegment.java
│ │ │ │ │ ├── DhtSegment.java
│ │ │ │ │ ├── DqtSegment.java
│ │ │ │ │ ├── GenericSegment.java
│ │ │ │ │ ├── JfifSegment.java
│ │ │ │ │ ├── Segment.java
│ │ │ │ │ ├── SofnSegment.java
│ │ │ │ │ ├── SosSegment.java
│ │ │ │ │ └── UnknownSegment.java
│ │ │ │ └── xmp
│ │ │ │ │ ├── JpegRewriter.java
│ │ │ │ │ ├── JpegXmpParser.java
│ │ │ │ │ └── JpegXmpRewriter.java
│ │ │ ├── package-info.java
│ │ │ ├── pcx
│ │ │ │ ├── PcxConstants.java
│ │ │ │ ├── PcxImageParser.java
│ │ │ │ ├── PcxWriter.java
│ │ │ │ └── package-info.java
│ │ │ ├── png
│ │ │ │ ├── BitParser.java
│ │ │ │ ├── ChunkType.java
│ │ │ │ ├── ColorType.java
│ │ │ │ ├── FilterType.java
│ │ │ │ ├── GammaCorrection.java
│ │ │ │ ├── InterlaceMethod.java
│ │ │ │ ├── PngConstants.java
│ │ │ │ ├── PngCrc.java
│ │ │ │ ├── PngImageInfo.java
│ │ │ │ ├── PngImageParser.java
│ │ │ │ ├── PngText.java
│ │ │ │ ├── PngWriter.java
│ │ │ │ ├── ScanExpediter.java
│ │ │ │ ├── ScanExpediterInterlaced.java
│ │ │ │ ├── ScanExpediterSimple.java
│ │ │ │ ├── chunks
│ │ │ │ │ ├── PngChunk.java
│ │ │ │ │ ├── PngChunkGama.java
│ │ │ │ │ ├── PngChunkIccp.java
│ │ │ │ │ ├── PngChunkIdat.java
│ │ │ │ │ ├── PngChunkIhdr.java
│ │ │ │ │ ├── PngChunkItxt.java
│ │ │ │ │ ├── PngChunkPhys.java
│ │ │ │ │ ├── PngChunkPlte.java
│ │ │ │ │ ├── PngChunkText.java
│ │ │ │ │ ├── PngChunkZtxt.java
│ │ │ │ │ └── PngTextChunk.java
│ │ │ │ ├── package-info.java
│ │ │ │ ├── scanlinefilters
│ │ │ │ │ ├── ScanlineFilter.java
│ │ │ │ │ ├── ScanlineFilterAverage.java
│ │ │ │ │ ├── ScanlineFilterNone.java
│ │ │ │ │ ├── ScanlineFilterPaeth.java
│ │ │ │ │ ├── ScanlineFilterSub.java
│ │ │ │ │ └── ScanlineFilterUp.java
│ │ │ │ └── transparencyfilters
│ │ │ │ │ ├── TransparencyFilter.java
│ │ │ │ │ ├── TransparencyFilterGrayscale.java
│ │ │ │ │ ├── TransparencyFilterIndexedColor.java
│ │ │ │ │ └── TransparencyFilterTrueColor.java
│ │ │ ├── pnm
│ │ │ │ ├── FileInfo.java
│ │ │ │ ├── PamFileInfo.java
│ │ │ │ ├── PamWriter.java
│ │ │ │ ├── PbmFileInfo.java
│ │ │ │ ├── PbmWriter.java
│ │ │ │ ├── PgmFileInfo.java
│ │ │ │ ├── PgmWriter.java
│ │ │ │ ├── PnmConstants.java
│ │ │ │ ├── PnmImageParser.java
│ │ │ │ ├── PnmWriter.java
│ │ │ │ ├── PpmFileInfo.java
│ │ │ │ ├── PpmWriter.java
│ │ │ │ ├── WhiteSpaceReader.java
│ │ │ │ └── package-info.java
│ │ │ ├── psd
│ │ │ │ ├── ImageContents.java
│ │ │ │ ├── ImageResourceBlock.java
│ │ │ │ ├── ImageResourceType.java
│ │ │ │ ├── PsdHeaderInfo.java
│ │ │ │ ├── PsdImageParser.java
│ │ │ │ ├── dataparsers
│ │ │ │ │ ├── DataParser.java
│ │ │ │ │ ├── DataParserBitmap.java
│ │ │ │ │ ├── DataParserCmyk.java
│ │ │ │ │ ├── DataParserGrayscale.java
│ │ │ │ │ ├── DataParserIndexed.java
│ │ │ │ │ ├── DataParserLab.java
│ │ │ │ │ ├── DataParserRgb.java
│ │ │ │ │ └── DataParserStub.java
│ │ │ │ ├── datareaders
│ │ │ │ │ ├── CompressedDataReader.java
│ │ │ │ │ ├── DataReader.java
│ │ │ │ │ └── UncompressedDataReader.java
│ │ │ │ └── package-info.java
│ │ │ ├── rgbe
│ │ │ │ ├── InfoHeaderReader.java
│ │ │ │ ├── RgbeImageParser.java
│ │ │ │ ├── RgbeInfo.java
│ │ │ │ └── package-info.java
│ │ │ ├── tga
│ │ │ │ ├── TgaConstants.java
│ │ │ │ └── TgaImageParser.java
│ │ │ ├── tiff
│ │ │ │ ├── JpegImageData.java
│ │ │ │ ├── TiffContents.java
│ │ │ │ ├── TiffDirectory.java
│ │ │ │ ├── TiffElement.java
│ │ │ │ ├── TiffField.java
│ │ │ │ ├── TiffHeader.java
│ │ │ │ ├── TiffImageData.java
│ │ │ │ ├── TiffImageMetadata.java
│ │ │ │ ├── TiffImageParser.java
│ │ │ │ ├── TiffReader.java
│ │ │ │ ├── constants
│ │ │ │ │ ├── AdobePageMaker6TagConstants.java
│ │ │ │ │ ├── AdobePhotoshopTagConstants.java
│ │ │ │ │ ├── AliasSketchbookProTagConstants.java
│ │ │ │ │ ├── AllTagConstants.java
│ │ │ │ │ ├── DcfTagConstants.java
│ │ │ │ │ ├── DngTagConstants.java
│ │ │ │ │ ├── ExifTagConstants.java
│ │ │ │ │ ├── GdalLibraryTagConstants.java
│ │ │ │ │ ├── GeoTiffTagConstants.java
│ │ │ │ │ ├── GpsTagConstants.java
│ │ │ │ │ ├── HylaFaxTagConstants.java
│ │ │ │ │ ├── MicrosoftHdPhotoTagConstants.java
│ │ │ │ │ ├── MicrosoftTagConstants.java
│ │ │ │ │ ├── MolecularDynamicsGelTagConstants.java
│ │ │ │ │ ├── OceScanjobTagConstants.java
│ │ │ │ │ ├── Rfc2301TagConstants.java
│ │ │ │ │ ├── TagConstantsUtils.java
│ │ │ │ │ ├── Tiff4TagConstants.java
│ │ │ │ │ ├── TiffConstants.java
│ │ │ │ │ ├── TiffDirectoryConstants.java
│ │ │ │ │ ├── TiffDirectoryType.java
│ │ │ │ │ ├── TiffEpTagConstants.java
│ │ │ │ │ ├── TiffTagConstants.java
│ │ │ │ │ └── WangTagConstants.java
│ │ │ │ ├── datareaders
│ │ │ │ │ ├── BitInputStream.java
│ │ │ │ │ ├── DataReader.java
│ │ │ │ │ ├── DataReaderStrips.java
│ │ │ │ │ └── DataReaderTiled.java
│ │ │ │ ├── fieldtypes
│ │ │ │ │ ├── FieldType.java
│ │ │ │ │ ├── FieldTypeAscii.java
│ │ │ │ │ ├── FieldTypeByte.java
│ │ │ │ │ ├── FieldTypeDouble.java
│ │ │ │ │ ├── FieldTypeFloat.java
│ │ │ │ │ ├── FieldTypeLong.java
│ │ │ │ │ ├── FieldTypeRational.java
│ │ │ │ │ └── FieldTypeShort.java
│ │ │ │ ├── package-info.java
│ │ │ │ ├── photometricinterpreters
│ │ │ │ │ ├── PhotometricInterpreter.java
│ │ │ │ │ ├── PhotometricInterpreterBiLevel.java
│ │ │ │ │ ├── PhotometricInterpreterCieLab.java
│ │ │ │ │ ├── PhotometricInterpreterCmyk.java
│ │ │ │ │ ├── PhotometricInterpreterLogLuv.java
│ │ │ │ │ ├── PhotometricInterpreterPalette.java
│ │ │ │ │ ├── PhotometricInterpreterRgb.java
│ │ │ │ │ └── PhotometricInterpreterYCbCr.java
│ │ │ │ ├── taginfos
│ │ │ │ │ ├── TagInfo.java
│ │ │ │ │ ├── TagInfoAny.java
│ │ │ │ │ ├── TagInfoAscii.java
│ │ │ │ │ ├── TagInfoAsciiOrByte.java
│ │ │ │ │ ├── TagInfoAsciiOrRational.java
│ │ │ │ │ ├── TagInfoByte.java
│ │ │ │ │ ├── TagInfoByteOrShort.java
│ │ │ │ │ ├── TagInfoDirectory.java
│ │ │ │ │ ├── TagInfoDouble.java
│ │ │ │ │ ├── TagInfoFloat.java
│ │ │ │ │ ├── TagInfoGpsText.java
│ │ │ │ │ ├── TagInfoLong.java
│ │ │ │ │ ├── TagInfoLongOrIFD.java
│ │ │ │ │ ├── TagInfoRational.java
│ │ │ │ │ ├── TagInfoSByte.java
│ │ │ │ │ ├── TagInfoSLong.java
│ │ │ │ │ ├── TagInfoSRational.java
│ │ │ │ │ ├── TagInfoSShort.java
│ │ │ │ │ ├── TagInfoShort.java
│ │ │ │ │ ├── TagInfoShortOrLong.java
│ │ │ │ │ ├── TagInfoShortOrLongOrRational.java
│ │ │ │ │ ├── TagInfoShortOrRational.java
│ │ │ │ │ ├── TagInfoUndefined.java
│ │ │ │ │ ├── TagInfoUnknown.java
│ │ │ │ │ └── TagInfoXpString.java
│ │ │ │ └── write
│ │ │ │ │ ├── ImageDataOffsets.java
│ │ │ │ │ ├── TiffImageWriterBase.java
│ │ │ │ │ ├── TiffImageWriterLossless.java
│ │ │ │ │ ├── TiffImageWriterLossy.java
│ │ │ │ │ ├── TiffOutputDirectory.java
│ │ │ │ │ ├── TiffOutputField.java
│ │ │ │ │ ├── TiffOutputItem.java
│ │ │ │ │ ├── TiffOutputSet.java
│ │ │ │ │ └── TiffOutputSummary.java
│ │ │ ├── wbmp
│ │ │ │ ├── WbmpImageParser.java
│ │ │ │ └── package-info.java
│ │ │ ├── xbm
│ │ │ │ ├── XbmImageParser.java
│ │ │ │ └── package-info.java
│ │ │ └── xpm
│ │ │ │ ├── XpmImageParser.java
│ │ │ │ └── package-info.java
│ │ │ ├── icc
│ │ │ ├── CachingInputStream.java
│ │ │ ├── IccConstants.java
│ │ │ ├── IccProfileInfo.java
│ │ │ ├── IccProfileParser.java
│ │ │ ├── IccTag.java
│ │ │ ├── IccTagDataType.java
│ │ │ ├── IccTagDataTypes.java
│ │ │ ├── IccTagType.java
│ │ │ ├── IccTagTypes.java
│ │ │ └── package-info.java
│ │ │ ├── package-info.java
│ │ │ ├── palette
│ │ │ ├── ColorComponent.java
│ │ │ ├── ColorCount.java
│ │ │ ├── ColorGroup.java
│ │ │ ├── ColorGroupCut.java
│ │ │ ├── ColorSpaceSubset.java
│ │ │ ├── Dithering.java
│ │ │ ├── MedianCutImplementation.java
│ │ │ ├── MedianCutLongestAxisImplementation.java
│ │ │ ├── MedianCutMostPopulatedBoxesImplementation.java
│ │ │ ├── MedianCutPalette.java
│ │ │ ├── MedianCutQuantizer.java
│ │ │ ├── Palette.java
│ │ │ ├── PaletteFactory.java
│ │ │ ├── QuantizedPalette.java
│ │ │ ├── SimplePalette.java
│ │ │ └── package-info.java
│ │ │ └── util
│ │ │ ├── Debug.java
│ │ │ ├── IoUtils.java
│ │ │ └── package-info.java
│ │ └── harmony
│ │ ├── awt
│ │ ├── Utils.java
│ │ ├── geom
│ │ │ ├── CrossingHelper.java
│ │ │ ├── CurveCrossingHelper.java
│ │ │ ├── GeometryUtil.java
│ │ │ └── IntersectPoint.java
│ │ ├── gl
│ │ │ ├── AwtImageBackdoorAccessor.java
│ │ │ ├── CommonGraphics2D.java
│ │ │ ├── CommonGraphics2DFactory.java
│ │ │ ├── CommonGraphicsEnvironment.java
│ │ │ ├── Crossing.java
│ │ │ ├── GLGraphicsDevice.java
│ │ │ ├── GLVolatileImage.java
│ │ │ ├── ICompositeContext.java
│ │ │ ├── ImageSurface.java
│ │ │ ├── LUTTables.java
│ │ │ ├── MultiRectArea.java
│ │ │ ├── MultiRectAreaOp.java
│ │ │ ├── NullTextRenderer.java
│ │ │ ├── SURFACE_STRUCTURE.java
│ │ │ ├── Surface.java
│ │ │ ├── TextRenderer.java
│ │ │ ├── XORComposite.java
│ │ │ ├── color
│ │ │ │ ├── ColorConverter.java
│ │ │ │ ├── ColorScaler.java
│ │ │ │ ├── ICC_ProfileHelper.java
│ │ │ │ ├── ICC_Transform.java
│ │ │ │ ├── LUTColorConverter.java
│ │ │ │ ├── NativeCMM.java
│ │ │ │ └── NativeImageFormat.java
│ │ │ ├── font
│ │ │ │ ├── BasicMetrics.java
│ │ │ │ ├── CaretManager.java
│ │ │ │ ├── CommonGlyphVector.java
│ │ │ │ ├── CompositeFont.java
│ │ │ │ ├── FontExtraMetrics.java
│ │ │ │ ├── FontFinder.java
│ │ │ │ ├── FontManager.java
│ │ │ │ ├── FontMetricsImpl.java
│ │ │ │ ├── FontPeerImpl.java
│ │ │ │ ├── FontProperty.java
│ │ │ │ ├── Glyph.java
│ │ │ │ ├── LineMetricsImpl.java
│ │ │ │ ├── TextDecorator.java
│ │ │ │ ├── TextMetricsCalculator.java
│ │ │ │ ├── TextRunBreaker.java
│ │ │ │ ├── TextRunSegment.java
│ │ │ │ └── TextRunSegmentImpl.java
│ │ │ ├── image
│ │ │ │ ├── BufferedImageGraphics2D.java
│ │ │ │ ├── BufferedImageSource.java
│ │ │ │ ├── ByteArrayDecodingImageSource.java
│ │ │ │ ├── DataBufferListener.java
│ │ │ │ ├── DecodingImageSource.java
│ │ │ │ ├── FileDecodingImageSource.java
│ │ │ │ ├── GifDecoder.java
│ │ │ │ ├── ImageDecoder.java
│ │ │ │ ├── ImageLoader.java
│ │ │ │ ├── JpegDecoder.java
│ │ │ │ ├── OffscreenImage.java
│ │ │ │ ├── OrdinaryWritableRaster.java
│ │ │ │ ├── PngDecoder.java
│ │ │ │ └── URLDecodingImageSource.java
│ │ │ └── render
│ │ │ │ ├── Blitter.java
│ │ │ │ ├── JavaArcRasterizer.java
│ │ │ │ ├── JavaBlitter.java
│ │ │ │ ├── JavaLineRasterizer.java
│ │ │ │ ├── JavaShapeRasterizer.java
│ │ │ │ ├── JavaTextRenderer.java
│ │ │ │ └── NullBlitter.java
│ │ ├── internal
│ │ │ └── nls
│ │ │ │ ├── Messages.java
│ │ │ │ └── messages.properties
│ │ └── wtk
│ │ │ └── GraphicsFactory.java
│ │ ├── luni
│ │ ├── internal
│ │ │ └── nls
│ │ │ │ ├── Messages.java
│ │ │ │ └── messages.properties
│ │ └── util
│ │ │ ├── NotImplementedException.java
│ │ │ └── Util.java
│ │ ├── misc
│ │ └── HashCode.java
│ │ └── x
│ │ └── imageio
│ │ ├── internal
│ │ ├── OutputStreamWrapper.java
│ │ └── nls
│ │ │ ├── Messages.java
│ │ │ └── messages.properties
│ │ ├── metadata
│ │ └── IIOMetadataUtils.java
│ │ ├── plugins
│ │ ├── AwtImageReader.java
│ │ ├── ImageSignature.java
│ │ ├── ImageType.java
│ │ ├── PluginUtils.java
│ │ ├── gif
│ │ │ ├── GIFImageReader.java
│ │ │ └── GIFImageReaderSpi.java
│ │ ├── jpeg
│ │ │ ├── JPEGConsts.java
│ │ │ ├── JPEGImageReader.java
│ │ │ ├── JPEGImageReaderSpi.java
│ │ │ ├── JPEGImageWriter.java
│ │ │ ├── JPEGImageWriterSpi.java
│ │ │ └── JPEGSpiConsts.java
│ │ └── png
│ │ │ ├── PNGImageReader.java
│ │ │ ├── PNGImageReaderSpi.java
│ │ │ ├── PNGImageWriter.java
│ │ │ ├── PNGImageWriterParam.java
│ │ │ ├── PNGImageWriterSpi.java
│ │ │ ├── PNGMetadataFormat.java
│ │ │ └── PNGSpiConsts.java
│ │ ├── spi
│ │ ├── FileIISSpi.java
│ │ ├── FileIOSSpi.java
│ │ ├── InputStreamIISSpi.java
│ │ ├── OutputStreamIOSSpi.java
│ │ ├── RAFIISSpi.java
│ │ └── RAFIOSSpi.java
│ │ └── stream
│ │ └── RandomAccessMemoryCache.java
│ └── ro
│ └── andob
│ └── awtcompat
│ └── nativec
│ └── AwtCompatNativeComponents.java
├── build.gradle
├── devenv
├── .gitignore
├── build.gradle
├── consumer-rules.pro
├── proguard-rules.pro
└── src
│ └── main
│ ├── AndroidManifest.xml
│ ├── java
│ └── ro
│ │ └── andob
│ │ └── awtcompat
│ │ └── devenv
│ │ ├── App.java
│ │ └── MainActivity.kt
│ └── res
│ ├── layout
│ └── activity_main.xml
│ ├── values
│ ├── strings.xml
│ └── styles.xml
│ └── xml
│ └── provider_paths.xml
├── gradle.properties
├── gradlew
├── gradlew.bat
├── publish.sh
└── settings.gradle
/.gitignore:
--------------------------------------------------------------------------------
1 | *.class
2 |
3 | # Package Files #
4 | *.war
5 | *.ear
6 |
7 | .idea/
8 | .gradle/
9 | build/
10 | out/
11 | gradle/
12 | local.properties
13 |
--------------------------------------------------------------------------------
/android-awt.iml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
--------------------------------------------------------------------------------
/awtcompat/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 | /.cxx
--------------------------------------------------------------------------------
/awtcompat/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.library'
2 | apply plugin: 'maven-publish'
3 |
4 | android {
5 | compileSdkVersion 30
6 | defaultConfig {
7 | minSdkVersion 14
8 | targetSdkVersion 30
9 | versionCode 1
10 | versionName "1.0.0"
11 | }
12 | buildTypes {
13 | release {
14 | minifyEnabled false
15 | proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
16 | }
17 | }
18 | publishing {
19 | singleVariant("release") {}
20 | }
21 | ndkVersion "22.0.7026061"
22 | externalNativeBuild {
23 | cmake {
24 | path "src/main/cpp/CMakeLists.txt"
25 | }
26 | }
27 | }
28 |
29 | dependencies {
30 | api 'com.jaredrummler:sfntly:1.0.1'
31 |
32 | implementation 'com.google.code.findbugs:jsr305:3.0.2'
33 | }
34 |
35 | project.afterEvaluate {
36 | publishing {
37 | publications {
38 | repositories.maven {
39 | url 'https://andob.io/repository/open_source/'
40 | credentials {
41 | username "$System.env.MAVEN_PUBLISH_USERNAME"
42 | password "$System.env.MAVEN_PUBLISH_PASSWORD"
43 | }
44 | }
45 |
46 | release(MavenPublication) {
47 | from components.release
48 | groupId 'ro.andob.androidawt'
49 | artifactId 'androidawt'
50 | version '1.0.4'
51 | }
52 | }
53 | }
54 | }
55 |
--------------------------------------------------------------------------------
/awtcompat/proguard-rules.pro:
--------------------------------------------------------------------------------
1 | # Add project specific ProGuard rules here.
2 | # You can control the set of applied configuration files using the
3 | # proguardFiles setting in build.gradle.
4 | #
5 | # For more details, see
6 | # http://developer.android.com/guide/developing/tools/proguard.html
7 |
8 | # If your project uses WebView with JS, uncomment the following
9 | # and specify the fully qualified class name to the JavaScript interface
10 | # class:
11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
12 | # public *;
13 | #}
14 |
15 | # Uncomment this to preserve the line number information for
16 | # debugging stack traces.
17 | #-keepattributes SourceFile,LineNumberTable
18 |
19 | # If you keep the line number information, uncomment this to
20 | # hide the original source file name.
21 | #-renamesourcefileattribute SourceFile
22 |
--------------------------------------------------------------------------------
/awtcompat/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
3 |
--------------------------------------------------------------------------------
/awtcompat/src/main/cpp/CMakeLists.txt:
--------------------------------------------------------------------------------
1 | cmake_minimum_required(VERSION 3.4.1)
2 |
3 | set(SOURCES
4 | awtcompat_native_components.c
5 | headers/awtcompat_native_components.h
6 |
7 | common/exceptions.c
8 | common/exceptions.h
9 |
10 | lcmm/cmmapi.h
11 | lcmm/cmmerror.h
12 | lcmm/cmmerror.c
13 | lcmm/cmmio.c
14 | lcmm/cmmxforms.c
15 | lcmm/NativeCMM.c
16 | lcmm/NativeCMM.h
17 | lcmm/NativeImageFormat.c
18 | lcmm/NativeImageFormat.h
19 |
20 | lcms/cmscam02.c
21 | lcms/cmscam97.c
22 | lcms/cmscam97.c.rej
23 | lcms/cmscgats.c
24 | lcms/cmscnvrt.c
25 | lcms/cmserr.c
26 | lcms/cmsgamma.c
27 | lcms/cmsgmt.c
28 | lcms/cmsintrp.c
29 | lcms/cmsio0.c
30 | lcms/cmsio1.c
31 | lcms/cmslut.c
32 | lcms/cmsmatsh.c
33 | lcms/cmsmtrx.c
34 | lcms/cmsnamed.c
35 | lcms/cmspack.c
36 | lcms/cmspcs.c
37 | lcms/cmsps2.c
38 | lcms/cmssamp.c
39 | lcms/cmsvirt.c
40 | lcms/cmswtpnt.c
41 | lcms/cmsxform.c
42 | lcms/icc34.h
43 | lcms/lcms.h
44 | )
45 |
46 | add_library( # Specifies the name of the library.
47 | awtcompat-native-components
48 |
49 | # Sets the library as a shared library.
50 | SHARED
51 |
52 | # Provides a relative path to your source file(s).
53 | ${SOURCES} )
54 |
55 | include_directories(
56 | headers/
57 | common/
58 | lcms/
59 | lcmm/
60 | )
--------------------------------------------------------------------------------
/awtcompat/src/main/cpp/common/exceptions.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | #ifndef EXCEPTIONS_H
19 | #define EXCEPTIONS_H
20 |
21 | #include
22 | #include
23 |
24 | #ifdef __cplusplus
25 | extern "C" {
26 | #endif
27 |
28 | void throwNewExceptionByName(JNIEnv* env,
29 | const char* name, const char* message);
30 | void throwNewOutOfMemoryError(JNIEnv* env, const char* message);
31 | void throwJavaIoIOException(JNIEnv* env, const char* message);
32 | void throwJavaIoIOExceptionClosed(JNIEnv* env);
33 | void throwNPException(JNIEnv* env, const char* message);
34 | void throwIndexOutOfBoundsException(JNIEnv* env);
35 |
36 | #ifdef __cplusplus
37 | }
38 | #endif
39 |
40 | #endif
41 |
--------------------------------------------------------------------------------
/awtcompat/src/main/cpp/lcmm/cmmerror.c:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Oleg V. Khaschansky
19 | *
20 | */
21 |
22 | #include "cmmerror.h"
23 |
24 | /*
25 | * Creates and throws CMMException
26 | */
27 | void newCMMException(JNIEnv *env, const char *message) {
28 | throwNewExceptionByName(env, "java/awt/color/CMMException", message);
29 | }
30 |
--------------------------------------------------------------------------------
/awtcompat/src/main/cpp/lcmm/cmmerror.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Oleg V. Khaschansky
19 | *
20 | */
21 |
22 | #ifndef _included_cmmerror
23 | #define _included_cmmerror
24 |
25 | #include "NativeCMM.h"
26 | #include "exceptions.h"
27 |
28 | // Java exception
29 | void newCMMException(JNIEnv *env, const char *message);
30 |
31 | #endif // _included_cmmerror
32 |
--------------------------------------------------------------------------------
/awtcompat/src/main/cpp/lcms/cmscam97.c:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/andob/android-awt/0d579f0d00da037ddd6abdfe5b1988bd48559714/awtcompat/src/main/cpp/lcms/cmscam97.c
--------------------------------------------------------------------------------
/awtcompat/src/main/cpp/lcms/cmscam97.c.rej:
--------------------------------------------------------------------------------
1 | ***************
2 | *** 420,428 ****
3 |
4 | // RGB_subw = [MlamRigg][WP/YWp]
5 | #ifdef USE_CIECAM97s2
6 | - MAT3eval(&lpMod -> RGB_subw, &lpMod -> MlamRigg, (LPVEC3) &lpMod -> WP);
7 | #else
8 | - VEC3divK(&tmp, (LPVEC3) &lpMod -> WP, lpMod->WP.Y);
9 | MAT3eval(&lpMod -> RGB_subw, &lpMod -> MlamRigg, &tmp);
10 | #endif
11 |
12 | --- 420,428 ----
13 |
14 | // RGB_subw = [MlamRigg][WP/YWp]
15 | #ifdef USE_CIECAM97s2
16 | + MAT3eval(&lpMod -> RGB_subw, &lpMod -> MlamRigg, &lpMod -> WP);
17 | #else
18 | + VEC3divK(&tmp, &lpMod -> WP, lpMod->WP.Y);
19 | MAT3eval(&lpMod -> RGB_subw, &lpMod -> MlamRigg, &tmp);
20 | #endif
21 |
22 |
--------------------------------------------------------------------------------
/awtcompat/src/main/cpp/lcms/cmscgats.c:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/andob/android-awt/0d579f0d00da037ddd6abdfe5b1988bd48559714/awtcompat/src/main/cpp/lcms/cmscgats.c
--------------------------------------------------------------------------------
/awtcompat/src/main/cpp/lcms/cmsvirt.c:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/andob/android-awt/0d579f0d00da037ddd6abdfe5b1988bd48559714/awtcompat/src/main/cpp/lcms/cmsvirt.c
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/AWTError.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Michael Danilov
19 | */
20 | package java.awt;
21 |
22 | public class AWTError extends Error {
23 | private static final long serialVersionUID = -1819846354050686206L;
24 |
25 | public AWTError(String msg) {
26 | super(msg);
27 | }
28 |
29 | }
30 |
31 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/AWTException.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Michael Danilov
19 | */
20 | package java.awt;
21 |
22 |
23 | public class AWTException extends Exception {
24 | private static final long serialVersionUID = -1900414231151323879L;
25 |
26 | public AWTException(String msg) {
27 | super(msg);
28 | }
29 |
30 | }
31 |
32 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/ActiveEvent.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Michael Danilov
19 | */
20 | package java.awt;
21 |
22 | public interface ActiveEvent {
23 |
24 | public void dispatch();
25 |
26 | }
27 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/Component.java:
--------------------------------------------------------------------------------
1 | package java.awt;
2 |
3 | public class Component
4 | {
5 | // final transient Toolkit toolkit = Toolkit.getDefaultToolkit();
6 |
7 | public boolean prepareImage(Image img, int w, int h, MediaTracker.TrackingImage trackingImage) {
8 | // toolkit.lockAWT();
9 | // try {
10 | // return toolkit.prepareImage(image, -1, -1, observer);
11 | // } finally {
12 | // toolkit.unlockAWT();
13 | // }
14 | return true;
15 | }
16 |
17 | public int checkImage(Image img, int w, int h, MediaTracker.TrackingImage trackingImage) {
18 | // toolkit.lockAWT();
19 | // try {
20 | // return toolkit.checkImage(image, width, height, observer);
21 | // } finally {
22 | // toolkit.unlockAWT();
23 | // }
24 | return 0;
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/Composite.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Igor V. Stolyarov
19 | */
20 | package java.awt;
21 |
22 | import java.awt.image.ColorModel;
23 |
24 | public interface Composite {
25 |
26 | public CompositeContext createContext(ColorModel srcColorModel,
27 | ColorModel dstColorModel, RenderingHints hints);
28 |
29 | }
30 |
31 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/CompositeContext.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Igor V. Stolyarov
19 | */
20 | package java.awt;
21 |
22 | import java.awt.image.Raster;
23 | import java.awt.image.WritableRaster;
24 |
25 | public interface CompositeContext {
26 |
27 | public void compose(Raster src, Raster dstIn, WritableRaster dstOut);
28 |
29 | public void dispose();
30 |
31 | }
32 |
33 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/FontFormatException.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Ilya S. Okomin
19 | */
20 | package java.awt;
21 |
22 | public class FontFormatException extends Exception {
23 | private static final long serialVersionUID = -4481290147811361272L;
24 |
25 | public FontFormatException(String reason) {
26 | super(reason);
27 | }
28 |
29 | }
30 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/Graphics2DUtil.java:
--------------------------------------------------------------------------------
1 | package java.awt;
2 |
3 | import java.awt.font.GlyphVector;
4 | import java.awt.geom.AffineTransform;
5 | import org.apache.harmony.awt.gl.font.CommonGlyphVector;
6 |
7 | public class Graphics2DUtil {
8 |
9 | public static void drawGlyphVector(Graphics2D g2d, GlyphVector g, float x, float y) {
10 | if(isIdentity(g) && g instanceof CommonGlyphVector) {
11 | g2d.drawString(string((CommonGlyphVector)g), x, y);
12 | } else {
13 | Shape s = g.getOutline(x, y);
14 | g2d.fill(s);
15 | }
16 | }
17 |
18 | private static String string(CommonGlyphVector gv) {
19 | StringBuilder text = new StringBuilder();
20 | for(int i=0;i!=gv.getNumGlyphs();++i) {
21 | int charIndex = gv.getGlyphCharIndex(i);
22 | char ch = gv.getGlyphChar(charIndex);
23 | text.append(ch);
24 | }
25 | return text.toString();
26 | }
27 |
28 | private static boolean isIdentity(GlyphVector gv) {
29 | for(int i=0;i!=gv.getNumGlyphs();++i) {
30 | AffineTransform tr = gv.getGlyphTransform(i);
31 | if(tr != null && !tr.isIdentity()) {
32 | return false;
33 | }
34 | }
35 | return true;
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/HeadlessException.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Alexey A. Petrenko
19 | */
20 | package java.awt;
21 |
22 | /**
23 | * HeadlessException
24 | *
25 | */
26 | public class HeadlessException extends UnsupportedOperationException {
27 | private static final long serialVersionUID = 167183644944358563L;
28 |
29 | public HeadlessException() {
30 | super();
31 | }
32 |
33 | public HeadlessException(String msg) {
34 | super(msg);
35 | }
36 | }
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/HeadlessGraphicsEnvironment.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package java.awt;
18 |
19 |
20 | import org.apache.harmony.awt.gl.CommonGraphicsEnvironment;
21 |
22 |
23 | class HeadlessGraphicsEnvironment extends CommonGraphicsEnvironment {
24 |
25 | @Override
26 | public boolean isHeadlessInstance() {
27 | return true;
28 | }
29 |
30 | @Override
31 | public GraphicsDevice getDefaultScreenDevice() throws HeadlessException {
32 | throw new HeadlessException();
33 | }
34 |
35 | @Override
36 | public GraphicsDevice[] getScreenDevices() throws HeadlessException {
37 | throw new HeadlessException();
38 | }
39 |
40 | }
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/IllegalComponentStateException.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Michael Danilov
19 | */
20 | package java.awt;
21 |
22 | public class IllegalComponentStateException extends IllegalStateException {
23 |
24 | private static final long serialVersionUID = -1889339587208144238L;
25 |
26 | public IllegalComponentStateException(String s) {
27 | super(s);
28 | }
29 |
30 | public IllegalComponentStateException() {
31 | }
32 |
33 | }
34 |
35 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/ImageCapabilities.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Alexey A. Petrenko
19 | */
20 | package java.awt;
21 |
22 | /**
23 | * ImageCapabilities
24 | *
25 | */
26 | public class ImageCapabilities implements Cloneable {
27 | private final boolean accelerated;
28 |
29 | public ImageCapabilities(boolean accelerated) {
30 | this.accelerated = accelerated;
31 | }
32 |
33 | @Override
34 | public Object clone() {
35 | return new ImageCapabilities(accelerated);
36 | }
37 |
38 | public boolean isAccelerated() {
39 | return accelerated;
40 | }
41 |
42 | public boolean isTrueVolatile() {
43 | return true;
44 | }
45 | }
46 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/Paint.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Alexey A. Petrenko
19 | */
20 | package java.awt;
21 |
22 | import java.awt.geom.AffineTransform;
23 | import java.awt.geom.Rectangle2D;
24 | import java.awt.image.ColorModel;
25 |
26 | /**
27 | * Paint
28 | */
29 | public interface Paint extends Transparency {
30 | PaintContext createContext(ColorModel cm, Rectangle deviceBounds,
31 | Rectangle2D userBounds, AffineTransform xform,
32 | RenderingHints hints);
33 | }
34 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/PaintContext.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Alexey A. Petrenko
19 | */
20 | package java.awt;
21 |
22 | import java.awt.image.ColorModel;
23 | import java.awt.image.Raster;
24 |
25 | /**
26 | * PaintContext
27 | */
28 | public interface PaintContext {
29 | void dispose();
30 |
31 | ColorModel getColorModel();
32 |
33 | Raster getRaster(int x, int y, int w, int h);
34 | }
35 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/PointerInfo.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Dmitry A. Durnev
19 | */
20 | package java.awt;
21 |
22 | public class PointerInfo {
23 | private GraphicsDevice device;
24 | private Point location;
25 |
26 | /**
27 | * @param device
28 | * @param location
29 | */
30 | PointerInfo(GraphicsDevice device, Point location) {
31 | this.device = device;
32 | this.location = location;
33 | }
34 |
35 | public GraphicsDevice getDevice() {
36 | return device;
37 | }
38 |
39 | public Point getLocation() {
40 | return location;
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/Stroke.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Alexey A. Petrenko
19 | */
20 | package java.awt;
21 |
22 | /**
23 | * Stroke
24 | *
25 | */
26 | public interface Stroke {
27 | public Shape createStrokedShape(Shape p);
28 | }
29 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/Transparency.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt;
21 |
22 |
23 | public interface Transparency {
24 |
25 | public static final int OPAQUE = 1;
26 |
27 | public static final int BITMASK = 2;
28 |
29 | public static final int TRANSLUCENT = 3;
30 |
31 | public int getTransparency();
32 |
33 | }
34 |
35 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/color/CMMException.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Oleg V. Khaschansky
19 | */
20 | package java.awt.color;
21 |
22 | public class CMMException extends java.lang.RuntimeException {
23 | private static final long serialVersionUID = 5775558044142994965L;
24 |
25 | public CMMException (String s) {
26 | super (s);
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/color/ICC_ProfileGray.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Oleg V. Khaschansky
19 | */
20 | package java.awt.color;
21 |
22 | public class ICC_ProfileGray extends ICC_Profile {
23 | private static final long serialVersionUID = -1124721290732002649L;
24 |
25 | ICC_ProfileGray(long profileHandle) {
26 | super(profileHandle);
27 | }
28 |
29 | public short[] getTRC() {
30 | return super.getTRC(icSigGrayTRCTag);
31 | }
32 |
33 | @Override
34 | public float[] getMediaWhitePoint() {
35 | return super.getMediaWhitePoint();
36 | }
37 |
38 | public float getGamma() {
39 | return super.getGamma(icSigGrayTRCTag);
40 | }
41 | }
42 |
43 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/color/ProfileDataException.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Oleg V. Khaschansky
19 | */
20 | package java.awt.color;
21 |
22 | public class ProfileDataException extends RuntimeException {
23 | private static final long serialVersionUID = 7286140888240322498L;
24 |
25 | public ProfileDataException(String s) {
26 | super(s);
27 | }
28 |
29 | }
30 |
31 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/font/MultipleMaster.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Ilya S. Okomin
19 | */
20 | package java.awt.font;
21 |
22 | import java.awt.Font;
23 |
24 | public interface MultipleMaster {
25 |
26 | public Font deriveMMFont(float[] glyphWidths, float avgStemWidth,
27 | float typicalCapHeight, float typicalXHeight, float italicAngle);
28 |
29 | public Font deriveMMFont(float[] axes);
30 |
31 | public float[] getDesignAxisDefaults();
32 |
33 | public String[] getDesignAxisNames();
34 |
35 | public float[] getDesignAxisRanges();
36 |
37 | public int getNumDesignAxes();
38 |
39 | }
40 |
41 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/geom/IllegalPathStateException.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Denis M. Kishenko
19 | */
20 | package java.awt.geom;
21 |
22 | public class IllegalPathStateException extends RuntimeException {
23 |
24 | private static final long serialVersionUID = -5158084205220481094L;
25 |
26 | public IllegalPathStateException() {
27 | }
28 |
29 | public IllegalPathStateException(String s) {
30 | super(s);
31 | }
32 |
33 | }
34 |
35 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/geom/NoninvertibleTransformException.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Denis M. Kishenko
19 | */
20 | package java.awt.geom;
21 |
22 | public class NoninvertibleTransformException extends java.lang.Exception {
23 |
24 | private static final long serialVersionUID = 6137225240503990466L;
25 |
26 | public NoninvertibleTransformException(String s) {
27 | super(s);
28 | }
29 |
30 | }
31 |
32 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/image/BufferStrategy.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Igor V. Stolyarov
19 | */
20 | package java.awt.image;
21 |
22 | import java.awt.BufferCapabilities;
23 | import java.awt.Graphics;
24 |
25 | public abstract class BufferStrategy {
26 |
27 | public abstract boolean contentsLost();
28 |
29 | public abstract boolean contentsRestored();
30 |
31 | public abstract BufferCapabilities getCapabilities();
32 |
33 | public abstract Graphics getDrawGraphics();
34 |
35 | public abstract void show();
36 |
37 | }
38 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/image/BufferedImageOp.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Alexey A. Petrenko
19 | */
20 | package java.awt.image;
21 |
22 | import java.awt.RenderingHints;
23 | import java.awt.geom.Point2D;
24 | import java.awt.geom.Rectangle2D;
25 |
26 | /**
27 | * BufferedImageOp
28 | *
29 | */
30 | public interface BufferedImageOp {
31 | public BufferedImage createCompatibleDestImage(BufferedImage src, ColorModel destCM);
32 |
33 | public BufferedImage filter(BufferedImage src, BufferedImage dest);
34 |
35 | public Rectangle2D getBounds2D(BufferedImage src);
36 |
37 | public Point2D getPoint2D(Point2D srcPt, Point2D dstPt);
38 |
39 | public RenderingHints getRenderingHints();
40 | }
41 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/image/ImageProducer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Igor V. Stolyarov
19 | */
20 | package java.awt.image;
21 |
22 | public interface ImageProducer {
23 |
24 | public boolean isConsumer(ImageConsumer ic);
25 |
26 | public void startProduction(ImageConsumer ic);
27 |
28 | public void requestTopDownLeftRightResend(ImageConsumer ic);
29 |
30 | public void removeConsumer(ImageConsumer ic);
31 |
32 | public void addConsumer(ImageConsumer ic);
33 |
34 | }
35 |
36 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/image/ImagingOpException.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Oleg V. Khaschansky
19 | *
20 | * @date: Oct 5, 2005
21 | */
22 |
23 | package java.awt.image;
24 |
25 | public class ImagingOpException extends RuntimeException {
26 | private static final long serialVersionUID = 8026288481846276658L;
27 |
28 | public ImagingOpException(String s) {
29 | super(s);
30 | }
31 | }
32 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/image/RasterFormatException.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Igor V. Stolyarov
19 | */
20 | package java.awt.image;
21 |
22 |
23 | public class RasterFormatException extends RuntimeException {
24 |
25 | private static final long serialVersionUID = 96598996116164315L;
26 |
27 | public RasterFormatException(String s) {
28 | super(s);
29 | }
30 |
31 | }
32 |
33 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/image/RasterOp.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Alexey A. Petrenko
19 | */
20 | package java.awt.image;
21 |
22 | import java.awt.RenderingHints;
23 | import java.awt.geom.Point2D;
24 | import java.awt.geom.Rectangle2D;
25 |
26 | /**
27 | * RasterOp
28 | *
29 | */
30 | public interface RasterOp {
31 | public WritableRaster createCompatibleDestRaster(Raster src);
32 |
33 | public WritableRaster filter(Raster src, WritableRaster dst);
34 |
35 | public Rectangle2D getBounds2D(Raster src);
36 |
37 | public Point2D getPoint2D(Point2D srcPpoint, Point2D dstPoint);
38 |
39 | public RenderingHints getRenderingHints();
40 | }
41 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/image/TileObserver.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Igor V. Stolyarov
19 | */
20 | package java.awt.image;
21 |
22 | public interface TileObserver {
23 |
24 | public void tileUpdate(WritableRenderedImage source, int tileX, int tileY, boolean willBeWritable);
25 |
26 | }
27 |
28 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/image/WritableRenderedImage.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Igor V. Stolyarov
19 | */
20 | package java.awt.image;
21 |
22 | import java.awt.Point;
23 |
24 | public interface WritableRenderedImage extends RenderedImage {
25 |
26 | public WritableRaster getWritableTile(int tileX, int tileY);
27 |
28 | public void removeTileObserver(TileObserver to);
29 |
30 | public void addTileObserver(TileObserver to);
31 |
32 | public void setData(Raster r);
33 |
34 | public Point[] getWritableTileIndices();
35 |
36 | public boolean isTileWritable(int tileX, int tileY);
37 |
38 | public void releaseWritableTile(int tileX, int tileY);
39 |
40 | public boolean hasTileWriters();
41 |
42 | }
43 |
44 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/image/renderable/RenderedImageFactory.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Igor V. Stolyarov
19 | */
20 | package java.awt.image.renderable;
21 |
22 | import java.awt.RenderingHints;
23 | import java.awt.image.RenderedImage;
24 |
25 | public interface RenderedImageFactory {
26 |
27 | public RenderedImage create(ParameterBlock a0, RenderingHints a1);
28 |
29 | }
30 |
31 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/ButtonPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface ButtonPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/CanvasPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface CanvasPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/CheckboxMenuItemPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface CheckboxMenuItemPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/CheckboxPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface CheckboxPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/ChoicePeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface ChoicePeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/ComponentPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface ComponentPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/DialogPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface DialogPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/FileDialogPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface FileDialogPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/FontPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface FontPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/FramePeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface FramePeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/LabelPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface LabelPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/LightweightPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface LightweightPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/ListPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface ListPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/MenuBarPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface MenuBarPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/MenuComponentPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface MenuComponentPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/MenuItemPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface MenuItemPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/MenuPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface MenuPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/MouseInfoPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface MouseInfoPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/PanelPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface PanelPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/PopupMenuPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface PopupMenuPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/ScrollPanePeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface ScrollPanePeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/ScrollbarPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface ScrollbarPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/TextAreaPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface TextAreaPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/TextFieldPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface TextFieldPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/peer/WindowPeer.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Pavel Dolgov
19 | */
20 | package java.awt.peer;
21 |
22 | public interface WindowPeer {
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/print/Pageable.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Igor A. Pyankov
19 | */
20 | package java.awt.print;
21 |
22 | public interface Pageable {
23 |
24 | public static final int UNKNOWN_NUMBER_OF_PAGES = -1;
25 |
26 | public abstract int getNumberOfPages();
27 |
28 | public PageFormat getPageFormat(int pageIndex)
29 | throws IndexOutOfBoundsException;
30 |
31 | public Printable getPrintable(int pageIndex)
32 | throws IndexOutOfBoundsException;
33 |
34 | }
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/print/Printable.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Igor A. Pyankov
19 | */
20 | package java.awt.print;
21 |
22 | import java.awt.Graphics;
23 |
24 | public interface Printable {
25 |
26 | public static final int NO_SUCH_PAGE = 1;
27 | public static final int PAGE_EXISTS = 0;
28 |
29 | public abstract int print(Graphics g, PageFormat pageformat, int i)
30 | throws PrinterException;
31 | }
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/print/PrinterException.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Igor A. Pyankov
19 | */
20 | package java.awt.print;
21 |
22 | public class PrinterException extends Exception {
23 |
24 | private static final long serialVersionUID = -3757589981158265819L;
25 |
26 | public PrinterException() {
27 | super();
28 | }
29 |
30 | public PrinterException (String msg) {
31 | super(msg);
32 | }
33 |
34 | }
35 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/java/awt/print/PrinterGraphics.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package java.awt.print;
19 |
20 | public interface PrinterGraphics {
21 |
22 | public abstract PrinterJob getPrinterJob();
23 |
24 | }
--------------------------------------------------------------------------------
/awtcompat/src/main/java/javax/imageio/IIOException.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Rustem V. Rafikov
19 | */
20 | package javax.imageio;
21 |
22 | import java.io.IOException;
23 |
24 | public class IIOException extends IOException {
25 |
26 | private static final long serialVersionUID = -3216210718638985251L;
27 |
28 | public IIOException(String message) {
29 | super(message);
30 | }
31 |
32 | public IIOException(String message, Throwable cause) {
33 | super(message);
34 | initCause(cause);
35 | }
36 | }
37 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/javax/imageio/IIOParamController.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Sergey I. Salishev
19 | */
20 | package javax.imageio;
21 |
22 | /**
23 | * @author Sergey I. Salishev
24 | */
25 | public interface IIOParamController {
26 |
27 | boolean activate(IIOParam param);
28 | }
29 |
30 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/javax/imageio/ImageTranscoder.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Rustem V. Rafikov
19 | */
20 | package javax.imageio;
21 |
22 | import javax.imageio.metadata.IIOMetadata;
23 |
24 |
25 | public interface ImageTranscoder {
26 | IIOMetadata convertStreamMetadata(IIOMetadata inData, ImageWriteParam param);
27 |
28 | IIOMetadata convertImageMetadata(IIOMetadata inData, ImageTypeSpecifier imageType, ImageWriteParam param);
29 | }
30 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/javax/imageio/event/IIOReadWarningListener.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Sergey I. Salishev
19 | */
20 | package javax.imageio.event;
21 |
22 | import javax.imageio.ImageReader;
23 |
24 | import java.util.EventListener;
25 |
26 |
27 | /**
28 | * @author Sergey I. Salishev
29 | */
30 | public interface IIOReadWarningListener extends EventListener {
31 |
32 | public void warningOccurred(ImageReader source, String warning);
33 | }
34 |
35 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/javax/imageio/event/IIOWriteWarningListener.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Rustem V. Rafikov
19 | */
20 | package javax.imageio.event;
21 |
22 |
23 | import javax.imageio.ImageWriter;
24 |
25 | import java.util.EventListener;
26 |
27 | public interface IIOWriteWarningListener extends EventListener {
28 | void warningOccurred(ImageWriter source, int imageIndex, String warning);
29 | }
30 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/javax/imageio/metadata/IIOMetadataController.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Sergey I. Salishev
19 | */
20 | package javax.imageio.metadata;
21 |
22 | /**
23 | * @author Sergey I. Salishev
24 | */
25 | public interface IIOMetadataController {
26 |
27 | public boolean activate(IIOMetadata metadata);
28 | }
29 |
30 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/javax/imageio/spi/ImageTranscoderSpi.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Rustem V. Rafikov
19 | */
20 | package javax.imageio.spi;
21 |
22 | import javax.imageio.ImageTranscoder;
23 |
24 |
25 | public abstract class ImageTranscoderSpi extends IIOServiceProvider
26 | implements RegisterableService {
27 |
28 | protected ImageTranscoderSpi() {
29 | }
30 |
31 | public ImageTranscoderSpi(String vendorName, String version) {
32 | super(vendorName, version);
33 | }
34 |
35 | public abstract String getReaderServiceProviderName();
36 |
37 | public abstract String getWriterServiceProviderName();
38 |
39 | public abstract ImageTranscoder createTranscoderInstance();
40 | }
41 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/javax/imageio/spi/RegisterableService.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Rustem V. Rafikov
19 | */
20 | package javax.imageio.spi;
21 |
22 | public interface RegisterableService {
23 | void onRegistration(ServiceRegistry registry, Class> category);
24 | void onDeregistration(ServiceRegistry registry, Class> category);
25 | }
26 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/ImageFormat.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging;
18 |
19 | /**
20 | * Simple image format interface.
21 | */
22 | public interface ImageFormat {
23 |
24 | /**
25 | * Get the name of this {@link ImageFormat}.
26 | *
27 | * @return String name
28 | */
29 | String getName();
30 |
31 | /**
32 | * Get the file extension associated with this {@link ImageFormat}.
33 | *
34 | * @return String extension
35 | */
36 | String getExtension();
37 |
38 | }
39 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/ImageFormats.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging;
18 |
19 | /**
20 | * Enum of known image formats.
21 | */
22 | public enum ImageFormats implements ImageFormat {
23 | UNKNOWN,
24 | BMP,
25 | DCX,
26 | GIF,
27 | ICNS,
28 | ICO,
29 | JBIG2,
30 | JPEG,
31 | PAM,
32 | PSD,
33 | PBM,
34 | PGM,
35 | PNM,
36 | PPM,
37 | PCX,
38 | PNG,
39 | RGBE,
40 | TGA,
41 | TIFF,
42 | WBMP,
43 | XBM,
44 | XPM;
45 |
46 | public String getName() {
47 | return name();
48 | }
49 |
50 | public String getExtension() {
51 | return name();
52 | }
53 | }
54 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/ImageReadException.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging;
18 |
19 | /**
20 | * A custom exception thrown when an ImageParser or other utility
21 | * encounters a format-violation, non-supported element, or other
22 | * condition that renders image data unaccessible.
23 | */
24 | public class ImageReadException extends ImagingException {
25 | private static final long serialVersionUID = -1L;
26 |
27 | public ImageReadException(final String message) {
28 | super(message);
29 | }
30 |
31 | public ImageReadException(final String message, final Throwable cause) {
32 | super(message, cause);
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/ImagingException.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging;
18 |
19 | /**
20 | * The base class for implementing custom exceptions in the
21 | * Apache Commons Imaging package.
22 | */
23 | public class ImagingException extends Exception {
24 | private static final long serialVersionUID = -1L;
25 |
26 | public ImagingException(final String message) {
27 | super(message);
28 | }
29 |
30 | public ImagingException(final String message, final Throwable cause) {
31 | super(message, cause);
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/color/ColorCieLab.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.color;
18 |
19 | public final class ColorCieLab {
20 | public final double L;
21 | public final double a;
22 | public final double b;
23 |
24 | public ColorCieLab(final double l, final double a, final double b) {
25 | L = l;
26 | this.a = a;
27 | this.b = b;
28 | }
29 |
30 | @Override
31 | public String toString() {
32 | return "{L: " + L + ", a: " + a + ", b: " + b + "}";
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/color/ColorCieLch.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.color;
18 |
19 | public final class ColorCieLch {
20 | public final double L;
21 | public final double C;
22 | public final double H;
23 |
24 | public ColorCieLch(final double l, final double C, final double H) {
25 | L = l;
26 | this.C = C;
27 | this.H = H;
28 | }
29 |
30 | @Override
31 | public String toString() {
32 | return "{L: " + L + ", C: " + C + ", H: " + H + "}";
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/color/ColorCieLuv.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.color;
18 |
19 | public final class ColorCieLuv {
20 | public final double L;
21 | public final double u;
22 | public final double v;
23 |
24 | public ColorCieLuv(final double l, final double u, final double v) {
25 | L = l;
26 | this.u = u;
27 | this.v = v;
28 | }
29 |
30 | @Override
31 | public String toString() {
32 | return "{L: " + L + ", u: " + u + ", v: " + v + "}";
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/color/ColorCmy.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.color;
18 |
19 | public final class ColorCmy {
20 | public final double C;
21 | public final double M;
22 | public final double Y;
23 |
24 | public ColorCmy(final double C, final double M, final double Y) {
25 | this.C = C;
26 | this.M = M;
27 | this.Y = Y;
28 | }
29 |
30 | @Override
31 | public String toString() {
32 | return "{C: " + C + ", M: " + M + ", Y: " + Y + "}";
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/color/ColorCmyk.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.color;
18 |
19 | public final class ColorCmyk {
20 | public final double C;
21 | public final double M;
22 | public final double Y;
23 | public final double K;
24 |
25 | public ColorCmyk(final double C, final double M, final double Y, final double K) {
26 | this.C = C;
27 | this.M = M;
28 | this.Y = Y;
29 | this.K = K;
30 | }
31 |
32 | @Override
33 | public String toString() {
34 | return "{C: " + C + ", M: " + M + ", Y: " + Y + ", K: " + K + "}";
35 | }
36 | }
37 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/color/ColorHsl.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.color;
18 |
19 | public final class ColorHsl {
20 | public final double H;
21 | public final double S;
22 | public final double L;
23 |
24 | public ColorHsl(final double h, final double s, final double v) {
25 | H = h;
26 | S = s;
27 | L = v;
28 | }
29 |
30 | @Override
31 | public String toString() {
32 | return "{H: " + H + ", S: " + S + ", L: " + L + "}";
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/color/ColorHsv.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.color;
18 |
19 | public final class ColorHsv {
20 | public final double H;
21 | public final double S;
22 | public final double V;
23 |
24 | public ColorHsv(final double h, final double s, final double v) {
25 | H = h;
26 | S = s;
27 | V = v;
28 | }
29 |
30 | @Override
31 | public String toString() {
32 | return "{H: " + H + ", S: " + S + ", V: " + V + "}";
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/color/ColorHunterLab.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.color;
18 |
19 | public final class ColorHunterLab {
20 | public final double L;
21 | public final double a;
22 | public final double b;
23 |
24 | public ColorHunterLab(final double l, final double a, final double b) {
25 | L = l;
26 | this.a = a;
27 | this.b = b;
28 | }
29 |
30 | @Override
31 | public String toString() {
32 | return "{L: " + L + ", a: " + a + ", b: " + b + "}";
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/color/ColorXyz.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.color;
18 |
19 | public final class ColorXyz {
20 | public final double X;
21 | public final double Y;
22 | public final double Z;
23 |
24 | public ColorXyz(final double x, final double y, final double z) {
25 | X = x;
26 | Y = y;
27 | Z = z;
28 | }
29 |
30 | @Override
31 | public String toString() {
32 | return "{X: " + X + ", Y: " + Y + ", Z: " + Z + "}";
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/color/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * Color spaces and conversions between them.
20 | */
21 | package org.apache.commons.imaging.color;
22 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/common/IBufferedImageFactory.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package org.apache.commons.imaging.common;
19 |
20 | import java.awt.image.BufferedImage;
21 |
22 | public interface IBufferedImageFactory {
23 | BufferedImage getColorBufferedImage(int width, int height,
24 | boolean hasAlpha);
25 |
26 | BufferedImage getGrayscaleBufferedImage(int width, int height,
27 | boolean hasAlpha);
28 | }
29 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/common/IImageMetadata.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.common;
18 |
19 | import java.util.List;
20 |
21 | public interface IImageMetadata {
22 | String toString(String prefix);
23 |
24 | List extends IImageMetadataItem> getItems();
25 |
26 | interface IImageMetadataItem {
27 | String toString(String prefix);
28 |
29 | String toString();
30 | }
31 | }
32 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/common/bytesource/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * Encapsulates sources from which data may be read.
20 | */
21 | package org.apache.commons.imaging.common.bytesource;
22 |
23 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/common/itu_t4/HuffmanTreeException.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.common.itu_t4;
18 |
19 | class HuffmanTreeException extends Exception {
20 | private static final long serialVersionUID = 1L;
21 |
22 | public HuffmanTreeException(final String message) {
23 | super(message);
24 | }
25 |
26 | public HuffmanTreeException(final String message, final Throwable cause) {
27 | super(message, cause);
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/common/itu_t4/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * Provides ITU-T T.4 and T.6 compression classes.
20 | */
21 | package org.apache.commons.imaging.common.itu_t4;
22 |
23 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/common/mylzw/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * Provides LZW compression.
20 | */
21 | package org.apache.commons.imaging.common.mylzw;
22 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/common/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * Provides utility classes that are employed across multiple
20 | * image formats and sub-packages.
21 | */
22 | package org.apache.commons.imaging.common;
23 |
24 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/bmp/BmpWriter.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.bmp;
18 |
19 | import java.awt.image.BufferedImage;
20 | import org.apache.commons.imaging.common.BinaryOutputStream;
21 |
22 | import java.io.IOException;
23 |
24 | abstract class BmpWriter {
25 |
26 | public abstract int getPaletteSize();
27 |
28 | public abstract int getBitsPerPixel();
29 |
30 | public abstract void writePalette(BinaryOutputStream bos) throws IOException;
31 |
32 | public abstract byte[] getImageData(BufferedImage src);
33 | }
34 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/bmp/ImageContents.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.bmp;
18 |
19 | class ImageContents {
20 |
21 | public final BmpHeaderInfo bhi;
22 | public final byte[] colorTable;
23 | public final byte[] imageData;
24 | public final PixelParser pixelParser;
25 |
26 | public ImageContents(BmpHeaderInfo bhi, byte[] colorTable, byte[] imageData, PixelParser pixelParser) {
27 | this.bhi = bhi;
28 | this.colorTable = colorTable;
29 | this.imageData = imageData;
30 | this.pixelParser = pixelParser;
31 | }
32 |
33 | }
34 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/bmp/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * The BMP image format.
20 | */
21 | package org.apache.commons.imaging.formats.bmp;
22 |
23 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/dcx/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * The DCX image format.
20 | */
21 | package org.apache.commons.imaging.formats.dcx;
22 |
23 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/gif/GifBlock.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.gif;
18 |
19 | class GifBlock {
20 | public final int blockCode;
21 |
22 | public GifBlock(final int blockCode) {
23 | this.blockCode = blockCode;
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/gif/ImageContents.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.gif;
18 |
19 | import java.util.List;
20 |
21 | class ImageContents {
22 | public final GifHeaderInfo gifHeaderInfo;
23 |
24 | public final List blocks;
25 | public final byte[] globalColorTable;
26 |
27 | public ImageContents(final GifHeaderInfo gifHeaderInfo, final byte[] globalColorTable,
28 | final List blocks) {
29 | this.gifHeaderInfo = gifHeaderInfo;
30 | this.globalColorTable = globalColorTable;
31 | this.blocks = blocks;
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/gif/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * The GIF image format.
20 | */
21 | package org.apache.commons.imaging.formats.gif;
22 |
23 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/icns/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * The ICNS image format.
20 | */
21 | package org.apache.commons.imaging.formats.icns;
22 |
23 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/ico/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * The ICO/CUR image formats.
20 | */
21 | package org.apache.commons.imaging.formats.ico;
22 |
23 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/jpeg/decoder/Block.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed under the Apache License, Version 2.0 (the "License");
3 | * you may not use this file except in compliance with the License.
4 | * You may obtain a copy of the License at
5 | *
6 | * http://www.apache.org/licenses/LICENSE-2.0
7 | *
8 | * Unless required by applicable law or agreed to in writing, software
9 | * distributed under the License is distributed on an "AS IS" BASIS,
10 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11 | * See the License for the specific language governing permissions and
12 | * limitations under the License.
13 | * under the License.
14 | */
15 |
16 | package org.apache.commons.imaging.formats.jpeg.decoder;
17 |
18 | final class Block {
19 | final int[] samples;
20 | final int width;
21 | final int height;
22 |
23 | Block(final int width, final int height) {
24 | samples = new int[width * height];
25 | this.width = width;
26 | this.height = height;
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/jpeg/iptc/IptcType.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.jpeg.iptc;
18 |
19 | public interface IptcType {
20 | int getType();
21 |
22 | String getName();
23 |
24 | String toString();
25 | }
26 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/jpeg/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * The JPEG image format.
20 | */
21 | package org.apache.commons.imaging.formats.jpeg;
22 |
23 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/jpeg/segments/AppnSegment.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.jpeg.segments;
18 |
19 | import java.io.IOException;
20 | import java.io.InputStream;
21 |
22 | import org.apache.commons.imaging.formats.jpeg.JpegConstants;
23 |
24 | public class AppnSegment extends GenericSegment {
25 |
26 | public AppnSegment(int marker, int markerLength, InputStream is) throws IOException {
27 | super(marker, markerLength, is);
28 | }
29 |
30 | @Override
31 | public String getDescription() {
32 | return "APPN (APP" + (marker - JpegConstants.JPEG_APP0_MARKER) + ") (" + getSegmentType() + ")";
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/jpeg/segments/UnknownSegment.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.jpeg.segments;
18 |
19 | import java.io.IOException;
20 | import java.io.InputStream;
21 |
22 | public class UnknownSegment extends GenericSegment {
23 | public UnknownSegment(int marker, int markerLength, InputStream is) throws IOException {
24 | super(marker, markerLength, is);
25 | }
26 |
27 | public UnknownSegment(final int marker, final byte[] bytes) {
28 | super(marker, bytes);
29 | }
30 |
31 | @Override
32 | public String getDescription() {
33 | return "Unknown (" + getSegmentType() + ")";
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 |
19 | /**
20 | * Image file formats.
21 | */
22 | package org.apache.commons.imaging.formats;
23 |
24 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/pcx/PcxConstants.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed under the Apache License, Version 2.0 (the "License");
3 | * you may not use this file except in compliance with the License.
4 | * You may obtain a copy of the License at
5 | *
6 | * http://www.apache.org/licenses/LICENSE-2.0
7 | *
8 | * Unless required by applicable law or agreed to in writing, software
9 | * distributed under the License is distributed on an "AS IS" BASIS,
10 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11 | * See the License for the specific language governing permissions and
12 | * limitations under the License.
13 | * under the License.
14 | */
15 | package org.apache.commons.imaging.formats.pcx;
16 |
17 |
18 | public interface PcxConstants {
19 | public static final String PARAM_KEY_PCX_COMPRESSION = "PCX_COMPRESSION";
20 | public static final int PCX_COMPRESSION_UNCOMPRESSED = 0;
21 | public static final int PCX_COMPRESSION_RLE = 1;
22 |
23 | public static final String PARAM_KEY_PCX_BIT_DEPTH = "PCX_BIT_DEPTH";
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/pcx/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * The PCX image format.
20 | */
21 | package org.apache.commons.imaging.formats.pcx;
22 |
23 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/png/FilterType.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.png;
18 |
19 | /**
20 | * Filter types for filter method 0.
21 | *
22 | * @see Portable Network Graphics Specification - Filtering
23 | */
24 | enum FilterType {
25 | NONE,
26 | SUB,
27 | UP,
28 | AVERAGE,
29 | PAETH
30 | }
31 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/png/InterlaceMethod.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.png;
18 |
19 | /**
20 | * Interlace methods.
21 | *
22 | * @see Portable Network Graphics Specification - Interlacing and pass extraction
23 | */
24 | public enum InterlaceMethod {
25 |
26 | NONE(false),
27 | ADAM7(true);
28 |
29 | private final boolean progressive;
30 |
31 | private InterlaceMethod(boolean progressive) {
32 | this.progressive = progressive;
33 | }
34 |
35 | public boolean isProgressive() {
36 | return progressive;
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/png/chunks/PngChunkIdat.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.png.chunks;
18 |
19 | public class PngChunkIdat extends PngChunk {
20 |
21 | public PngChunkIdat(int length, int chunkType, int crc, byte[] bytes) {
22 | super(length, chunkType, crc, bytes);
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/png/chunks/PngTextChunk.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.png.chunks;
18 |
19 | import org.apache.commons.imaging.formats.png.PngText;
20 |
21 | public abstract class PngTextChunk extends PngChunk {
22 |
23 | public PngTextChunk(final int length, final int chunkType, final int crc, final byte[] bytes) {
24 | super(length, chunkType, crc, bytes);
25 | }
26 |
27 | public abstract String getKeyword();
28 |
29 | public abstract String getText();
30 |
31 | public abstract PngText getContents();
32 |
33 | }
34 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/png/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * The PNG image format.
20 | */
21 | package org.apache.commons.imaging.formats.png;
22 |
23 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilter.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.png.scanlinefilters;
18 |
19 | import java.io.IOException;
20 |
21 | import org.apache.commons.imaging.ImageReadException;
22 |
23 | public abstract class ScanlineFilter {
24 | public abstract void unfilter(byte[] src, byte[] dst, byte[] up)
25 | throws ImageReadException, IOException;
26 | }
27 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterNone.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.png.scanlinefilters;
18 |
19 | import java.io.IOException;
20 |
21 | import org.apache.commons.imaging.ImageReadException;
22 |
23 | public class ScanlineFilterNone extends ScanlineFilter {
24 | @Override
25 | public void unfilter(final byte[] src, final byte[] dst, final byte[] up)
26 | throws ImageReadException, IOException {
27 | System.arraycopy(src, 0, dst, 0, src.length);
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/png/transparencyfilters/TransparencyFilter.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.png.transparencyfilters;
18 |
19 | import java.io.IOException;
20 |
21 | import org.apache.commons.imaging.ImageReadException;
22 | import org.apache.commons.imaging.common.BinaryFileParser;
23 |
24 | public abstract class TransparencyFilter extends BinaryFileParser {
25 | protected final byte[] bytes;
26 |
27 | public TransparencyFilter(final byte[] bytes) {
28 | this.bytes = bytes;
29 |
30 | }
31 |
32 | public abstract int filter(int rgb, int index) throws ImageReadException,
33 | IOException;
34 | }
35 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/pnm/PnmWriter.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.pnm;
18 |
19 | import java.awt.image.BufferedImage;
20 | import org.apache.commons.imaging.ImageWriteException;
21 |
22 | import java.io.IOException;
23 | import java.io.OutputStream;
24 | import java.util.Map;
25 |
26 | abstract class PnmWriter {
27 | protected final boolean rawbits;
28 |
29 | public PnmWriter(final boolean rawbits) {
30 | this.rawbits = rawbits;
31 | }
32 |
33 | public abstract void writeImage(BufferedImage src, OutputStream os,
34 | Map params) throws ImageWriteException, IOException;
35 | }
36 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/pnm/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * The PNM image format family.
20 | */
21 | package org.apache.commons.imaging.formats.pnm;
22 |
23 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/psd/dataparsers/DataParserStub.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.psd.dataparsers;
18 |
19 | import org.apache.commons.imaging.formats.psd.ImageContents;
20 |
21 | public class DataParserStub extends DataParser {
22 | @Override
23 | protected int getRGB(final int[][][] data, final int x, final int y,
24 | final ImageContents imageContents) {
25 | return 0;
26 | }
27 |
28 | @Override
29 | public int getBasicChannelsCount() {
30 | return 1;
31 | }
32 |
33 | }
34 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/psd/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * The PSD image format.
20 | */
21 | package org.apache.commons.imaging.formats.psd;
22 |
23 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/rgbe/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * The Radiance HDR image format.
20 | */
21 | package org.apache.commons.imaging.formats.rgbe;
22 |
23 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/tga/TgaConstants.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.tga;
18 |
19 | //public class TgaConstants {
20 | //
21 | //}
22 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/tiff/JpegImageData.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package org.apache.commons.imaging.formats.tiff;
19 |
20 | public class JpegImageData extends TiffElement.DataElement {
21 | public JpegImageData(final long offset, final int length, final byte[] data) {
22 | super(offset, length, data);
23 | }
24 |
25 | @Override
26 | public String getElementDescription(final boolean verbose) {
27 | return "Jpeg image data: " + data.length + " bytes";
28 | }
29 |
30 | }
31 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/tiff/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * Provides classes and methods for reading and writing
20 | * Tagged Image File Format (TIFF) files. Tiff files are
21 | * widely used in applications for which supplemental
22 | * metadata is added to images in the form of "tags".
23 | */
24 | package org.apache.commons.imaging.formats.tiff;
25 |
26 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/tiff/taginfos/TagInfoAny.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.tiff.taginfos;
18 |
19 | import org.apache.commons.imaging.formats.tiff.constants.TiffDirectoryType;
20 | import org.apache.commons.imaging.formats.tiff.fieldtypes.FieldType;
21 |
22 | public class TagInfoAny extends TagInfo {
23 | public TagInfoAny(final String name, final int tag, final int length,
24 | final TiffDirectoryType directoryType) {
25 | super(name, tag, FieldType.ANY, length, directoryType);
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/tiff/taginfos/TagInfoAsciiOrByte.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.tiff.taginfos;
18 |
19 | import org.apache.commons.imaging.formats.tiff.constants.TiffDirectoryType;
20 | import org.apache.commons.imaging.formats.tiff.fieldtypes.FieldType;
21 |
22 | public class TagInfoAsciiOrByte extends TagInfo {
23 | public TagInfoAsciiOrByte(final String name, final int tag, final int length,
24 | final TiffDirectoryType directoryType) {
25 | super(name, tag, FieldType.ASCII_OR_BYTE, length,
26 | directoryType, false);
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/tiff/taginfos/TagInfoAsciiOrRational.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.tiff.taginfos;
18 |
19 | import org.apache.commons.imaging.formats.tiff.constants.TiffDirectoryType;
20 | import org.apache.commons.imaging.formats.tiff.fieldtypes.FieldType;
21 |
22 | public class TagInfoAsciiOrRational extends TagInfo {
23 | public TagInfoAsciiOrRational(final String name, final int tag, final int length,
24 | final TiffDirectoryType directoryType) {
25 | super(name, tag, FieldType.ASCII_OR_RATIONAL, length,
26 | directoryType, false);
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/tiff/taginfos/TagInfoDirectory.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.tiff.taginfos;
18 |
19 | import org.apache.commons.imaging.formats.tiff.constants.TiffDirectoryType;
20 |
21 | /**
22 | * A LONG representing an offset to a TIFF directory.
23 | */
24 | public class TagInfoDirectory extends TagInfoLong {
25 | public TagInfoDirectory(final String name, final int tag, final int length,
26 | final TiffDirectoryType directoryType) {
27 | super(name, tag, length, directoryType, true);
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/tiff/taginfos/TagInfoSByte.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.tiff.taginfos;
18 |
19 | import java.nio.ByteOrder;
20 |
21 | import org.apache.commons.imaging.formats.tiff.constants.TiffDirectoryType;
22 | import org.apache.commons.imaging.formats.tiff.fieldtypes.FieldType;
23 |
24 | public class TagInfoSByte extends TagInfo {
25 | public TagInfoSByte(final String name, final int tag, final int length, final TiffDirectoryType directoryType) {
26 | super(name, tag, FieldType.SBYTE, length, directoryType);
27 | }
28 |
29 | public byte[] encodeValue(final ByteOrder byteOrder, final byte... values) {
30 | return values;
31 | }
32 | }
33 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/tiff/taginfos/TagInfoUndefined.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.tiff.taginfos;
18 |
19 | import org.apache.commons.imaging.formats.tiff.constants.TiffDirectoryType;
20 | import org.apache.commons.imaging.formats.tiff.fieldtypes.FieldType;
21 |
22 | public class TagInfoUndefined extends TagInfoByte {
23 | public TagInfoUndefined(final String name, final int tag, final int length, final TiffDirectoryType directoryType) {
24 | super(name, tag, FieldType.UNDEFINED, length, directoryType);
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/tiff/taginfos/TagInfoUnknown.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.formats.tiff.taginfos;
18 |
19 | import org.apache.commons.imaging.formats.tiff.constants.TiffDirectoryType;
20 | import org.apache.commons.imaging.formats.tiff.fieldtypes.FieldType;
21 |
22 | /**
23 | * A TIFF tag whose definition isn't known.
24 | */
25 | public final class TagInfoUnknown extends TagInfoByte {
26 | public TagInfoUnknown(final String name, final int tag, final int length, final TiffDirectoryType exifDirectory) {
27 | super(name, tag, FieldType.ANY, length, exifDirectory);
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/wbmp/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * The Wireless Application Protocol Bitmap Format image format.
20 | */
21 | package org.apache.commons.imaging.formats.wbmp;
22 |
23 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/xbm/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * The X BitMap image format.
20 | */
21 | package org.apache.commons.imaging.formats.xbm;
22 |
23 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/formats/xpm/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * The X PixMap image format.
20 | */
21 | package org.apache.commons.imaging.formats.xpm;
22 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/icc/IccConstants.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.icc;
18 |
19 | public final class IccConstants {
20 | public static final int IEC = (((0xff & 'I') << 24) | ((0xff & 'E') << 16)
21 | | ((0xff & 'C') << 8) | ((0xff & ' ') << 0));
22 | public static final int sRGB = (((0xff & 's') << 24) | ((0xff & 'R') << 16)
23 | | ((0xff & 'G') << 8) | ((0xff & 'B') << 0));
24 |
25 | private IccConstants() {
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/icc/IccTagDataType.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.icc;
18 |
19 | import java.io.IOException;
20 |
21 | import org.apache.commons.imaging.ImageReadException;
22 |
23 | interface IccTagDataType {
24 |
25 | String getName();
26 |
27 | int getSignature();
28 |
29 | void dump(String prefix, byte[] bytes) throws ImageReadException, IOException;
30 | }
31 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/icc/IccTagType.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.icc;
18 |
19 | interface IccTagType {
20 |
21 | String getName();
22 |
23 | String getTypeDescription();
24 |
25 | int getSignature();
26 | }
27 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/icc/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * ICC color profile.
20 | */
21 | package org.apache.commons.imaging.icc;
22 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 |
19 | /**
20 | * The main package for Apache Commons Imaging.
21 | */
22 | package org.apache.commons.imaging;
23 |
24 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/palette/ColorComponent.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.palette;
18 |
19 | enum ColorComponent {
20 | ALPHA(24),
21 | RED(16),
22 | GREEN(8),
23 | BLUE(0);
24 |
25 | private final int shift;
26 |
27 | private ColorComponent(int shift) {
28 | this.shift = shift;
29 | }
30 |
31 | public int argbComponent(int argb) {
32 | return (argb >> shift) & 0xff;
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/palette/MedianCutImplementation.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.palette;
18 |
19 | import java.util.List;
20 |
21 | import org.apache.commons.imaging.ImageWriteException;
22 |
23 | public abstract class MedianCutImplementation {
24 | public abstract boolean performNextMedianCut(final List colorGroups, final boolean ignoreAlpha)
25 | throws ImageWriteException;
26 | }
27 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/palette/MedianCutPalette.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.commons.imaging.palette;
18 |
19 | class MedianCutPalette extends SimplePalette {
20 | private final ColorGroup root;
21 |
22 | public MedianCutPalette(final ColorGroup root, final int[] palette) {
23 | super(palette);
24 | this.root = root;
25 | }
26 |
27 | @Override
28 | public int getPaletteIndex(final int rgb) {
29 | ColorGroup cg = root;
30 |
31 | while (cg.cut != null) {
32 | cg = cg.cut.getColorGroup(rgb);
33 | }
34 |
35 | return cg.paletteIndex;
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/palette/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * Color quantization and palette manipulation tools.
20 | */
21 | package org.apache.commons.imaging.palette;
22 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/commons/imaging/util/package-info.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | /**
19 | * Utility classes.
20 | */
21 | package org.apache.commons.imaging.util;
22 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/harmony/awt/Utils.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package org.apache.harmony.awt;
19 |
20 | import java.security.AccessController;
21 | import java.security.PrivilegedAction;
22 |
23 | public final class Utils {
24 |
25 | public static String getSystemProperty(final String name) {
26 | return getSystemProperty(name, null);
27 | }
28 |
29 | public static String getSystemProperty(final String name, final String value) {
30 | return AccessController.doPrivileged(new PrivilegedAction() {
31 | public String run() {
32 | return System.getProperty(name, value);
33 | }
34 | });
35 | }
36 | }
37 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/harmony/awt/gl/GLGraphicsDevice.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Alexey A. Petrenko
19 | */
20 | package org.apache.harmony.awt.gl;
21 |
22 | import java.awt.Dimension;
23 | import java.awt.GraphicsDevice;
24 |
25 | /**
26 | * GLGraphicsDevice is a super class for all GraphicsDevice implementations
27 | *
28 | */
29 | public abstract class GLGraphicsDevice extends GraphicsDevice {
30 | public abstract Dimension getResolution();
31 | }
32 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/harmony/awt/gl/GLVolatileImage.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Igor V. Stolyarov
19 | */
20 | package org.apache.harmony.awt.gl;
21 |
22 |
23 | import java.awt.image.VolatileImage;
24 |
25 |
26 | public abstract class GLVolatileImage extends VolatileImage {
27 |
28 | public abstract Surface getImageSurface();
29 | }
30 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/harmony/awt/gl/LUTTables.java:
--------------------------------------------------------------------------------
1 | package org.apache.harmony.awt.gl;
2 |
3 | public class LUTTables
4 | {
5 | private static final byte[][] mulLUT = new byte[256][256]; /* Multiply Lookup table */
6 | private static final byte[][] divLUT = new byte[256][256]; /* Divide Lookup table */
7 |
8 | static {
9 | init_mulLUT();
10 | init_divLUT();
11 | }
12 |
13 | private static void init_mulLUT(){
14 | int i, j;
15 | for(i = 0; i < 256; i++){
16 | for(j = 0; j < 256; j++){
17 | mulLUT[i][j] = (byte)(((float)i * j) / 255 + 0.5);
18 | }
19 | }
20 | }
21 |
22 | private static void init_divLUT(){
23 | int i, j;
24 | // memset(divLUT[0], 0, 256);
25 | for(i = 1; i < 256; i++){
26 | for(j = 0; j <= i; j++){
27 | divLUT[i][j] = (byte)(((float)j) / i * 255 + 0.5);
28 | }
29 | for(; j < 256; j++){
30 | divLUT[i][j] = 0;
31 | }
32 | }
33 | }
34 |
35 | public static byte MUL(int a, int b)
36 | {
37 | return mulLUT[a][b];
38 | }
39 |
40 | public static byte DIV(int a, int b)
41 | {
42 | return divLUT[a][b];
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/harmony/awt/gl/NullTextRenderer.java:
--------------------------------------------------------------------------------
1 | package org.apache.harmony.awt.gl;
2 |
3 | import java.awt.Graphics2D;
4 | import java.awt.font.GlyphVector;
5 |
6 | public class NullTextRenderer extends TextRenderer {
7 |
8 | @Override
9 | public void drawString(Graphics2D g, String str, float x, float y) {
10 |
11 | }
12 |
13 | @Override
14 | public void drawGlyphVector(Graphics2D g, GlyphVector glyphVector, float x,
15 | float y) {
16 |
17 | }
18 |
19 | }
20 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/harmony/awt/gl/image/DataBufferListener.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Igor V. Stolyarov
19 | * Created on 13.03.2006
20 | *
21 | */
22 | package org.apache.harmony.awt.gl.image;
23 |
24 | public interface DataBufferListener {
25 |
26 | void dataChanged();
27 | void dataTaken();
28 | void dataReleased();
29 |
30 | }
31 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/harmony/x/imageio/internal/OutputStreamWrapper.java:
--------------------------------------------------------------------------------
1 | package org.apache.harmony.x.imageio.internal;
2 |
3 | import javax.imageio.stream.ImageOutputStream;
4 |
5 | import java.io.IOException;
6 | import java.io.OutputStream;
7 |
8 | public class OutputStreamWrapper extends OutputStream {
9 |
10 | private ImageOutputStream out;
11 |
12 | public OutputStreamWrapper(ImageOutputStream out) {
13 | super();
14 | this.out = out;
15 | }
16 |
17 | @Override
18 | public void write(int b) throws IOException {
19 | out.write(b);
20 | }
21 |
22 | @Override
23 | public void close() throws IOException {
24 | //out.close();
25 | }
26 |
27 | @Override
28 | public void flush() throws IOException {
29 | out.flush();
30 | }
31 |
32 | @Override
33 | public void write(byte[] b, int off, int len) throws IOException {
34 | out.write(b, off, len);
35 | }
36 |
37 | @Override
38 | public void write(byte[] b) throws IOException {
39 | out.write(b);
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/harmony/x/imageio/plugins/gif/GIFImageReader.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.harmony.x.imageio.plugins.gif;
18 |
19 |
20 | import javax.imageio.spi.ImageReaderSpi;
21 | import org.apache.harmony.x.imageio.plugins.AwtImageReader;
22 |
23 | public class GIFImageReader extends AwtImageReader {
24 |
25 | public GIFImageReader(final ImageReaderSpi imageReaderSpi) {
26 | super(imageReaderSpi);
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/harmony/x/imageio/plugins/jpeg/JPEGImageReader.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | package org.apache.harmony.x.imageio.plugins.jpeg;
18 |
19 |
20 | import javax.imageio.ImageReadParam;
21 | import javax.imageio.plugins.jpeg.JPEGImageReadParam;
22 | import javax.imageio.spi.ImageReaderSpi;
23 | import org.apache.harmony.x.imageio.plugins.AwtImageReader;
24 |
25 | public class JPEGImageReader extends AwtImageReader {
26 |
27 | public JPEGImageReader(final ImageReaderSpi imageReaderSpi) {
28 | super(imageReaderSpi);
29 | }
30 |
31 | @Override
32 | public ImageReadParam getDefaultReadParam() {
33 | return new JPEGImageReadParam();
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/harmony/x/imageio/plugins/png/PNGImageReader.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 |
18 | package org.apache.harmony.x.imageio.plugins.png;
19 |
20 |
21 | import javax.imageio.spi.ImageReaderSpi;
22 | import org.apache.harmony.x.imageio.plugins.AwtImageReader;
23 |
24 | public class PNGImageReader extends AwtImageReader {
25 |
26 | public PNGImageReader(ImageReaderSpi imageReaderSpi) {
27 | super(imageReaderSpi);
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/awtcompat/src/main/java/org/apache/harmony/x/imageio/plugins/png/PNGImageWriterParam.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Licensed to the Apache Software Foundation (ASF) under one or more
3 | * contributor license agreements. See the NOTICE file distributed with
4 | * this work for additional information regarding copyright ownership.
5 | * The ASF licenses this file to You under the Apache License, Version 2.0
6 | * (the "License"); you may not use this file except in compliance with
7 | * the License. You may obtain a copy of the License at
8 | *
9 | * http://www.apache.org/licenses/LICENSE-2.0
10 | *
11 | * Unless required by applicable law or agreed to in writing, software
12 | * distributed under the License is distributed on an "AS IS" BASIS,
13 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 | * See the License for the specific language governing permissions and
15 | * limitations under the License.
16 | */
17 | /**
18 | * @author Viskov Nikolay
19 | */
20 | package org.apache.harmony.x.imageio.plugins.png;
21 |
22 | import javax.imageio.ImageWriteParam;
23 |
24 | public class PNGImageWriterParam extends ImageWriteParam {
25 |
26 | private boolean isInterlace = true;
27 |
28 | public PNGImageWriterParam() {
29 | super();
30 | }
31 |
32 | public boolean getInterlace() {
33 | return isInterlace;
34 | }
35 |
36 | public void setInterlace(boolean b) {
37 | isInterlace = b;
38 | }
39 |
40 | }
41 |
--------------------------------------------------------------------------------
/build.gradle:
--------------------------------------------------------------------------------
1 | buildscript {
2 | ext.kotlin_version = '1.5.0'
3 | repositories {
4 | google()
5 | mavenCentral()
6 | }
7 | dependencies {
8 | classpath 'com.android.tools.build:gradle:7.2.0'
9 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
10 | }
11 | }
12 |
13 | allprojects {
14 | repositories {
15 | google()
16 | mavenCentral()
17 | }
18 | }
19 |
20 | task clean(type: Delete) {
21 | delete rootProject.buildDir
22 | }
23 |
--------------------------------------------------------------------------------
/devenv/.gitignore:
--------------------------------------------------------------------------------
1 | /build
--------------------------------------------------------------------------------
/devenv/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.application'
2 | apply plugin: 'kotlin-android'
3 |
4 | android {
5 | compileSdkVersion 30
6 | defaultConfig {
7 | applicationId "ro.dobrescuandrei.openpdfandroidsample"
8 | minSdkVersion 16
9 | targetSdkVersion 30
10 | versionCode 1
11 | versionName "1.0.0"
12 | }
13 | buildTypes {
14 | release {
15 | debuggable false
16 | minifyEnabled true
17 | shrinkResources true
18 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
19 | }
20 |
21 | debug {
22 | debuggable true
23 | minifyEnabled true
24 | shrinkResources true
25 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
26 | }
27 | }
28 | compileOptions {
29 | sourceCompatibility JavaVersion.VERSION_1_8
30 | targetCompatibility JavaVersion.VERSION_1_8
31 | }
32 | kotlinOptions {
33 | jvmTarget = "1.8"
34 | }
35 | }
36 |
37 | dependencies {
38 | implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
39 | implementation 'androidx.appcompat:appcompat:1.2.0'
40 |
41 | implementation 'com.squareup.okio:okio:2.6.0'
42 |
43 | implementation 'com.jaredrummler:sfntly:1.0.1'
44 |
45 | implementation 'com.google.code.findbugs:jsr305:3.0.2'
46 |
47 | implementation 'com.github.librepdf:openpdf:1.3.24'
48 | implementation project(":awtcompat")
49 | }
50 |
--------------------------------------------------------------------------------
/devenv/consumer-rules.pro:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/andob/android-awt/0d579f0d00da037ddd6abdfe5b1988bd48559714/devenv/consumer-rules.pro
--------------------------------------------------------------------------------
/devenv/proguard-rules.pro:
--------------------------------------------------------------------------------
1 | # Add project specific ProGuard rules here.
2 | # You can control the set of applied configuration files using the
3 | # proguardFiles setting in build.gradle.
4 | #
5 | # For more details, see
6 | # http://developer.android.com/guide/developing/tools/proguard.html
7 |
8 | # If your project uses WebView with JS, uncomment the following
9 | # and specify the fully qualified class name to the JavaScript interface
10 | # class:
11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
12 | # public *;
13 | #}
14 |
15 | # Uncomment this to preserve the line number information for
16 | # debugging stack traces.
17 | #-keepattributes SourceFile,LineNumberTable
18 |
19 | # If you keep the line number information, uncomment this to
20 | # hide the original source file name.
21 | #-renamesourcefileattribute SourceFile
--------------------------------------------------------------------------------
/devenv/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
7 |
8 |
9 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
30 |
33 |
34 |
35 |
36 |
37 |
--------------------------------------------------------------------------------
/devenv/src/main/java/ro/andob/awtcompat/devenv/App.java:
--------------------------------------------------------------------------------
1 | package ro.andob.awtcompat.devenv;
2 |
3 | import android.app.Application;
4 | import android.widget.Toast;
5 | import ro.andob.awtcompat.nativec.AwtCompatNativeComponents;
6 |
7 | public class App extends Application
8 | {
9 | @Override
10 | public void onCreate()
11 | {
12 | super.onCreate();
13 |
14 | Toast.makeText(this, AwtCompatNativeComponents.getHelloWorldMesssage(), Toast.LENGTH_LONG).show();
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/devenv/src/main/res/layout/activity_main.xml:
--------------------------------------------------------------------------------
1 |
2 |
--------------------------------------------------------------------------------
/devenv/src/main/res/values/strings.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | AwtCompat DevEnv
4 |
--------------------------------------------------------------------------------
/devenv/src/main/res/values/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
10 |
11 | #000000
12 | #000000
13 | #000000
14 |
15 |
16 |
--------------------------------------------------------------------------------
/devenv/src/main/res/xml/provider_paths.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/gradle.properties:
--------------------------------------------------------------------------------
1 | ## For more details on how to configure your build environment visit
2 | # http://www.gradle.org/docs/current/userguide/build_environment.html
3 | #
4 | # Specifies the JVM arguments used for the daemon process.
5 | # The setting is particularly useful for tweaking memory settings.
6 | # Default value: -Xmx1024m -XX:MaxPermSize=256m
7 | # org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
8 | #
9 | # When configured, Gradle will run in incubating parallel mode.
10 | # This option should only be used with decoupled projects. More details, visit
11 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
12 | # org.gradle.parallel=true
13 | #Sun Feb 07 10:17:49 EET 2021
14 | android.enableJetifier=true
15 | android.useAndroidX=true
16 | org.gradle.jvmargs=-Xmx1536m
17 |
--------------------------------------------------------------------------------
/publish.sh:
--------------------------------------------------------------------------------
1 | set -o allexport
2 |
3 | echo "Type Archiva username:"
4 | read -r MAVEN_PUBLISH_USERNAME
5 | echo "Type Archiva password:"
6 | read -s -r MAVEN_PUBLISH_PASSWORD
7 |
8 | echo "Publishing..."
9 |
10 | ./gradlew :awtcompat:publish
11 |
12 | read -s -r MAVEN_PUBLISH_PASSWORD
13 |
14 | set +o allexport
15 |
--------------------------------------------------------------------------------
/settings.gradle:
--------------------------------------------------------------------------------
1 | include ':devenv'
2 | include ':awtcompat'
3 |
--------------------------------------------------------------------------------