Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on Jul 21, 2021. It is now read-only.

groupdocs-viewer/GroupDocs.Viewer-for-Java-Dropwizard

Repository files navigation

Document viewer

GroupDocs.Viewer for Java Dropwizard Example

version 1.14.27

Build StatusMaintainabilityGitHub license

⚠️This repository has moved tohttps://github.com/groupdocs-viewer/GroupDocs.Viewer-for-Java/tree/master/Demos/Dropwizard

System Requirements

  • Java 8 (JDK 1.8)
  • Maven 3

Document Viewer API for Java Dropwizard

GroupDocs.Viewer for Java API allows you to view over 170 document formats includingDOCX,PDF,PPT,XLS, among many others without any additional dependencies. Thanks to its flexible configuration it can be configured toview documents as images or as HTML5.

In order to demonstrate GroupDocs.Viewer for Java reach and powerful features we prepared a moderndocument viewer front-end web UI example. Which can be used as a standalone application or easily integrated into your project.

Note: without a license application will run in trial mode, purchaseGroupDocs.Viewer for Java license or requestGroupDocs.Viewer for Java temporary license.

Supported document Formats

FamilyFormats
Archive formatsZIP,TAR,BZ2,RAR,GZIP
Apple formatsNumbers
PDF formatsPDF,XPS,OXPS,TEX
CAD formatsDXF,DWG ,DWT,STL,IFC,DWF ,DWFX,DGN,PLT,CF2,OBJ,HPG,IGS
Microsoft WordDOC,DOCM ,DOCX,DOT,DOTM,DOTX,RTF
Microsoft ExcelXLS,XLSB,XLSM,XLSX,XLT,XLTM,XLTX,Excel 2003 XML,XLAM
Microsoft PowerPointPPT,POT,POTM,POTX,PPS,PPSM,PPSX,PPTM,PPTX
Microsoft VisioVSD,VSDX,VSDM,VDW,VDX,VSDX,VSS,VSSX,VSSM,VST,VSTX,VSX,VTX,VSTM
Microsoft ProjectMPP,MPT,MPX
Help filesCHM
Email formatsEML,EMLX,MSG,NSF,MBOX,PST,OST,VCF
OpenDocument FormatsODT,ODP,FODP,ODS,FODS,OTT,OTS,ODG,FODG,OTG,OTP,SXC
Plain Text FileTXT,TSV
Comma-Separated ValuesCSV
HyperText Markup LanguageHTML,MHT,MHTML,SVG,SVGZ
Extensible Markup LanguageXML,XML,XPS
AutoCAD Drawing File FormatDGN,DWG,DXF
Image filesBMP,CAL,DCX,CGM,PCL,PSB,DIB,EMF,EMZ,WEBP,DNG,CDR,CMX,GIF,JP2,JPG,JPF,JPM,J2C,J2K,JPC,JPX,MIL,MIL,PCD,PCT,PCX,PNG,Animated PNG,PSD,PS,RAS,TGA,TIFF,WMF,WMZ,EPS,AI
Electronic publicationEPUB,MOBI,DJVU
Windows IconICO
Medical image filesDCM
Programming Language FormatsAS,AS3,ASM,BAT,C,CC,CMAKE,CPP,CS,VB,CSS,CXX,DIFF,ERB,GROOVY,H,HAML,HH,JAVA,JS,JSON,LESS,LOG,M,MAKE,MD,ML,MM,PHP,PL,PROPERTIES,PY,RB,RST,SASS,SCALA,SCM,SCRIPT,SH,SML,SQL,VIM,YAML

Demo Video

Features

  • Clean, modern and intuitive design
  • Easily switchable colour theme (create your own colour theme in 5 minutes)
  • Responsive design
  • Mobile support (open application on any mobile device)
  • Support over 90 documents and image formats including popular MS Office (Word, Excel, PowerPoint)
  • HTML and image document viewing modes
  • Fully customizable navigation panel
  • Open password protected documents
  • Text searching & highlighting
  • Download documents
  • Upload documents
  • Print document
  • Rotate pages
  • Zoom in/out documents without quality loss in HTML mode
  • Thumbnails
  • Smooth page navigation
  • Smooth document scrolling
  • Preload pages for faster document viewing
  • Multi-language support for displaying errors
  • Display two or more pages side by side (when zooming out)
  • Cross-browser support (Safari, Chrome, Opera, Firefox)
  • Cross-platform support (Windows, Linux, MacOS)

How to run

You can run this sample by one of following methods

Build from source

Downloadsource code from github or clone this repository.

git clone https://github.com/groupdocs-viewer/GroupDocs.Viewer-for-Java-Dropwizardcd GroupDocs.Viewer-for-Java-Dropwizardmvn clean compile exec:java## Open http://localhost:8080/viewer/ in your favorite browser.

Binary release (with all dependencies)

Downloadlatest release fromreleases page.

Note: This method isrecommended for running this sample behind firewall.

curl -J -L -o release.tar.gz https://github.com/groupdocs-viewer/GroupDocs.Viewer-for-Java-Dropwizard/releases/download/1.14.27/release.tar.gztar -xvzf release.tar.gzcd releasejava -jar viewer-1.14.27.jar configuration.yaml## Open http://localhost:8080/viewer/ in your favorite browser.

Docker image

Usedocker image.

mkdir DocumentSamplesmkdir Licensesdocker run -p 8080:8080 --env application.hostAddress=localhost -v`pwd`/DocumentSamples:/home/groupdocs/app/DocumentSamples -v`pwd`/Licenses:/home/groupdocs/app/Licenses groupdocs/viewer## Open http://localhost:8080/viewer/ in your favorite browser.

Configuration

For all methods above you can adjust settings inconfiguration.yml. By default in this sample will lookup for license file in./Licenses folder, so you can simply put your license file in that folder or specify relative/absolute path by settinglicensePath value inconfiguration.yml.

Viewer configuration options

OptionTypeDefault valueDescription
filesDirectoryStringDocumentSamplesFiles directory path. Indicates where uploaded and predefined files are stored. It can be absolute or relative path
fontsDirectoryStringPath to custom fonts directory.
defaultDocumentStringAbsolute path to default document that will be loaded automaticaly.
preloadPageCountInteger0Indicate how many pages from a document should be loaded, remaining pages will be loaded on page scrolling.Set0 to load all pages at once
htmlModeBooleantrueHTML rendering mode. Setfalse to view documents in image mode. Settrue to view documents in HTML mode
zoomBooleantrueEnable or disable Document zoom
searchBooleantrueEnable or disable document search
thumbnailsBooleantrueEnable thumbnails preview
rotateBooleantrueEnable individual page rotation functionality
cacheBooleantrueSet true to enable cache
saveRotateStateBooleantrueIf enabled it will save chages made by rotating individual pages to same file.
watermarkTextStringText which will be used as a watermark

License

The MIT License (MIT).

Please have a look at the LICENSE.md for more details

GroupDocs Document Viewer on other platforms/frameworks

Home |Product Page |Documentation |Demos |API Reference |Examples |Blog |Search |Free Support |Temporary License


[8]ページ先頭

©2009-2025 Movatter.jp