pdf_viewer
PDFファイルを処理するためのFlutterプラグイン。AndroidおよびiOSで動作します
- スター
- 2
- フォーク
- 20
- 最終プッシュ(UTC)
- 2024/04/13
- プロジェクト状態
- 公開中
元の README
以下は英語原文のスナップショットです。最新版は GitHub をご覧ください。
advance_pdf_viewer_fork
A flutter plugin for handling PDF files. Works on both Android & iOS. Originally forked from https://github.com/lohanidamodar/pdf_viewer that originally forked from https://github.com/CrossPT/flutter_plugin_pdf_viewer.
Installation
Add advance_pdf_viewer_fork as a dependency in your pubspec.yaml file.
advance_pdf_viewer_fork: any
Android
No permissions required. Uses application cache directory.
iOS
No permissions required.
How-to:
Load PDF
// Load from assets
PDFDocument doc = await PDFDocument.fromAsset('assets/test.pdf');
// Load from URL
PDFDocument doc = await PDFDocument.fromURL('http://www.africau.edu/images/default/sample.pdf');
// Load from file
File file = File('...');
PDFDocument doc = await PDFDocument.fromFile(file);
Load pages
// Load specific page
PDFPage pageOne = await doc.get(page: _number);
Pre-built viewer
Use the pre-built PDF Viewer
@override
Widget build(BuildContext context) {
Scaffold(
appBar: AppBar(
title: Text('Example'),
),
body: Center(
child: _isLoading
? Center(child: CircularProgressIndicator())
: PDFViewer(document: document)),
);
}
This code produces the following view:
TODO
- Allow password-protected files
Third-party packages used
| Name | Description |
|---|---|
| path_provider | A Flutter plugin for finding commonly used locations on the filesystem. Supports iOS and Android. |
| flutter_cache_manager | A CacheManager to download and cache files in the cache directory of the app. Various settings on how long to keep a file can be changed. |
| numberpicker | NumberPicker is a custom widget designed for choosing an integer or decimal number by scrolling spinners. |
言語DartJavaObjective-CRuby
使用している依存関係
依存関係一覧 4 件
- flutter
{"sdk":"flutter"} - flutter_cache_manager
^3.1.1 - numberpicker
^2.1.1 - path_provider
^2.0.2
プロジェクトに合うリポジトリを選ぶには?
用途で絞り込み、開発状況を比較し、採用前に元のリポジトリで要件を確認しましょう。
- 名前・作者・説明で検索し、技術トピックで絞り込みます。
- スター、フォーク、最近のプッシュを比較します。スターは関心の目安であり、品質の保証ではありません。
- 利用前に GitHub で README、ライセンス、Issues を確認します。
情報源と管理
“A repository is the most basic element of GitHub.”
GitHub Docs — About repositories ↗