syncfusion-aspnetmvc-pdf-viewer
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseSyncfusion ASP.NET MVC Pdfviewer – UI Sample Generator
Syncfusion ASP.NET MVC Pdfviewer – UI示例生成器
NuGet:
Syncfusion.EJ2.MVC5NuGet:
Syncfusion.EJ2.MVC5Generate Code for the User's Project (default)
为用户项目生成代码(默认)
Trigger keywords: "how to", "add pdfviewer", "code sample", "show me", "example", "snippet", "integrate", "component", "create sample", "ASP.NET MVC sample".
Purpose: Generate minimal, copy-pasteable Razor + HTML code (.cshtml) that the user can integrate directly into their ASP.NET MVC project.
Workflow:
⚠️ CRITICAL — Feature Support Policy (STRICT MODE):
FUNDAMENTAL RULE: Only generate code using APIs and properties that are EXPLICITLY listed in the reference files. ANY deviation is a VIOLATION.
-
MANDATORY CHECKS BEFORE GENERATING ANY CODE:
- Search the reference files for the exact API/property name
- Verify it appears in the Method Reference, Properties, or Events tables
- If NOT found in ANY reference file, STOP immediately
- Do NOT generate or suggest undocumented APIs under any circumstances
-
STRICT ENFORCEMENT - ZERO TOLERANCE:
- NO custom properties - Only use properties from reference file tables
- NO invented methods - Only use methods from reference file tables
- NO workarounds with undefined APIs - Forbidden
- NO assumptions about undocumented behavior - Forbidden
- NO alternative implementations using guess-work - Forbidden
- NO pretending support exists - Forbidden
-
MANDATORY RESPONSE FOR UNSUPPORTED FEATURES:
- If a requested scenario/feature/API is NOT listed in any reference file, you MUST respond with:
"This feature is not supported in the current Syncfusion ASP.NET MVC PDF Viewer implementation." - Then list what IS supported from the appropriate reference file
- Never suggest alternatives unless explicitly documented in reference files
- If a requested scenario/feature/API is NOT listed in any reference file, you MUST respond with:
-
REFERENCE FILE HIERARCHY:
- Each reference file contains complete, authoritative documentation for its domain
- The tables (Method Reference, Properties, Events) are the SOURCE OF TRUTH
- Content outside these tables in reference files is explanatory only
- Do NOT extend beyond what appears in the reference file tables
-
AUDIT YOUR GENERATION:
- Before providing any code, verify EVERY API used appears in a reference file table
- Document which reference file each API comes from
- If you cannot cite a reference file table entry, DELETE that code
-
This is a CRITICAL REQUIREMENT. Violations compromise the skill's integrity and reliability.
触发关键词: "how to", "add pdfviewer", "code sample", "show me", "example", "snippet", "integrate", "component", "create sample", "ASP.NET MVC sample".
用途: 生成可直接复制粘贴的Razor + HTML代码(.cshtml),用户可将其直接集成到ASP.NET MVC项目中。
工作流程:
⚠️ 关键提示 — 功能支持策略(严格模式):
基本原则: 仅使用参考文件中明确列出的API和属性生成代码。任何偏离均属违规。
-
生成代码前的强制检查:
- 在参考文件中搜索准确的API/属性名称
- 验证其是否出现在方法参考、属性或事件表中
- 如果未在任何参考文件中找到,立即停止
- 在任何情况下都不得生成或建议未记录的API
-
严格执行 - 零容忍:
- 禁止自定义属性 - 仅使用参考文件表中的属性
- 禁止自创方法 - 仅使用参考文件表中的方法
- 禁止使用未定义API的变通方案 - 禁止
- 禁止对未记录行为做假设 - 禁止
- 禁止基于猜测的替代实现 - 禁止
- 禁止谎称支持某项功能 - 禁止
-
不支持功能的强制响应:
- 如果请求的场景/功能/API未在任何参考文件中列出,必须回复:
"This feature is not supported in the current Syncfusion ASP.NET MVC PDF Viewer implementation." - 然后列出参考文件中支持的内容
- 除非参考文件中有明确记录,否则不得建议替代方案
- 如果请求的场景/功能/API未在任何参考文件中列出,必须回复:
-
参考文件层级:
- 每个参考文件包含其领域完整、权威的文档
- 表格(方法参考、属性、事件)是唯一可信来源
- 参考文件中表格以外的内容仅作解释用途
- 不得扩展参考文件表格中未列出的内容
-
生成内容审核:
- 在提供任何代码之前,验证所用的每个API都出现在参考文件表中
- 记录每个API来自哪个参考文件
- 如果无法引用参考文件表中的条目,删除该代码
-
这是一项关键要求。违规会损害技能的完整性和可靠性。
Step 1 — Generate Code from Reference Files Only (REQUIRED)
步骤1 — 仅从参考文件生成代码(必填)
- Read the relevant file(s) for the requested feature
references/*.md - Cross-reference EVERY API, property, and method against these tables
- MANDATORY: Before generating ANY code, verify that reference files exist and are accessible
- Read the appropriate reference file(s) for the requested feature:
- Use tool on relevant
read_filefilesreferences/*.md - Confirm file contains Methods/Properties/Events tables
- Verify tables are complete and readable
- Use
- If reference file is missing or cannot be read:
- STOP code generation
- Respond: "Reference file for this feature is not available. Please ensure all reference files are present in the directory."
references/ - List the missing reference file name
- This is a BLOCKER step: Cannot proceed without reference file validation
- If an API/property does NOT appear in the reference file table, DO NOT USE IT
- Do NOT invent, guess, or suggest any API, method, property, class, or namespace not explicitly present in the reference files
- 阅读与请求功能相关的文件
references/*.md - 对照这些表格交叉验证每个API、属性和方法
- 强制要求: 在生成任何代码之前,验证参考文件是否存在且可访问
- 阅读与请求功能相关的参考文件:
- 使用工具读取相关的
read_file文件references/*.md - 确认文件包含方法/属性/事件表
- 验证表格完整且可读
- 使用
- 如果参考文件缺失或无法读取:
- 停止代码生成
- 回复:"Reference file for this feature is not available. Please ensure all reference files are present in the directory."
references/ - 列出缺失的参考文件名
- 这是阻塞步骤: 未通过参考文件验证无法继续
- 如果API/属性未出现在参考文件表中,请勿使用
- 不得发明、猜测或建议任何未在参考文件中明确列出的API、方法、属性、类或命名空间
⚙️ SETTINGS CONFIGURATION BEST PRACTICES
⚙️ 设置配置最佳实践
When generating code with settings (toolbarSettings, annotationSettings, annotationSelectorSettings, arrowSettings, rectangleSettings, etc.), follow these guidelines to prevent unnecessary imports and over-engineering:
在生成包含设置(toolbarSettings、annotationSettings、annotationSelectorSettings、arrowSettings、rectangleSettings等)的代码时,请遵循以下准则以避免不必要的导入和过度设计:
Rule 1: Simple Settings → Define as Razor inline code
规则1:简单设置 → 定义为Razor内联代码
Use this approach when:
- Configuring only 1-3 properties
- Settings are straightforward without custom types
Example (DO THIS):
cshtml
@Html.EJS().PdfViewer("pdfviewer").AnnotationSelectorSettings(new Syncfusion.EJ2.PdfViewer.PdfViewerAnnotationSelectorSettings { ResizerBorderColor = "green", SelectionBorderColor = "blue", ResizerFillColor = "#4070ff", resizerSize = 8, SelectionBorderThickness = 1, SelectorLineDashArray = new int[] { 5, 6 }, ResizerLocation = "Corners|Edges", ResizerCursorType = "grab" }).Render()Benefits:
- ✅ Simple and readable
- ✅ Less code clutter
- ✅ Type checking still works
适用场景:
- 仅配置1-3个属性
- 设置简单,无需自定义类型
示例(推荐做法):
cshtml
@Html.EJS().PdfViewer("pdfviewer").AnnotationSelectorSettings(new Syncfusion.EJ2.PdfViewer.PdfViewerAnnotationSelectorSettings { ResizerBorderColor = "green", SelectionBorderColor = "blue", ResizerFillColor = "#4070ff", resizerSize = 8, SelectionBorderThickness = 1, SelectorLineDashArray = new int[] { 5, 6 }, ResizerLocation = "Corners|Edges", ResizerCursorType = "grab" }).Render()优势:
- ✅ 简洁易读
- ✅ 减少代码冗余
- ✅ 仍可进行类型检查
Rule 2: Complex Settings → Define as Razor code blocks outside HTML
规则2:复杂设置 → 在HTML外部定义为Razor代码块
Use this approach when:
- Configuring 4+ properties OR multiple related settings
- Using enums or complex configurations
- Need to reuse the same configuration across multiple components
- Settings are complex enough to warrant separate definition
Example (DO THIS ONLY FOR COMPLEX CASES):
cshtml
@{
var annotationSelectorSettings = new {
selectionBorderColor = "blue",
resizerBorderColor = "red",
resizerFillColor = "#4070ff",
resizerSize = 8,
selectionBorderThickness = 1,
resizerShape = "Circle",
selectorLineDashArray = new int[] { 5, 6 },
resizerLocation = "Corners|Edges",
resizerCursorType = "grab"
};
}
@Html.EJS().PdfViewer("pdfviewer").AnnotationSelectorSettings(annotationSelectorSettings).Render()适用场景:
- 配置4个及以上属性或多个相关设置
- 使用枚举或复杂配置
- 需要在多个组件间复用相同配置
- 设置复杂到需要单独定义
示例(仅适用于复杂场景):
cshtml
@{
var annotationSelectorSettings = new {
selectionBorderColor = "blue",
resizerBorderColor = "red",
resizerFillColor = "#4070ff",
resizerSize = 8,
selectionBorderThickness = 1,
resizerShape = "Circle",
selectorLineDashArray = new int[] { 5, 6 },
resizerLocation = "Corners|Edges",
resizerCursorType = "grab"
};
}
@Html.EJS().PdfViewer("pdfviewer").AnnotationSelectorSettings(annotationSelectorSettings).Render()Rule 3: NEVER Over-Engineer Simple Cases
规则3:切勿过度设计简单场景
❌ DO NOT DO THIS (Over-engineered):
cshtml
@{
var toolbarSettings = new Syncfusion.EJ2.PdfViewer.PdfViewerToolbarSettings { ShowTooltip = true };
}
@Html.EJS().PdfViewer("pdfviewer").ToolbarSettings(@toolbarSettings).Render()✅ DO THIS INSTEAD (Simple & Clean):
cshtml
@Html.EJS().PdfViewer("pdfviewer").ToolbarSettings(new Syncfusion.EJ2.PdfViewer.PdfViewerToolbarSettings { ShowTooltip = true }).Render()❌ 禁止(过度设计):
cshtml
@{
var toolbarSettings = new Syncfusion.EJ2.PdfViewer.PdfViewerToolbarSettings { ShowTooltip = true };
}
@Html.EJS().PdfViewer("pdfviewer").ToolbarSettings(@toolbarSettings).Render()✅ 推荐做法(简洁干净):
cshtml
@Html.EJS().PdfViewer("pdfviewer").ToolbarSettings(new Syncfusion.EJ2.PdfViewer.PdfViewerToolbarSettings { ShowTooltip = true }).Render()Reference File Routing Guide
参考文件路由指南
All templates and operation snippets live in . Each file is a focused snippet or template the agent will combine when generating samples.
references/*.mdFlow: Always start with getting-started.md, then merge matched features into its anchors (PROPS, EVENTS, UI_BUTTONS, HANDLERS). If no keyword matches, return only the basic sample.
所有模板和操作代码片段都存储在中。代理生成示例时会组合这些聚焦的代码片段或模板。
references/*.md流程: 始终从getting-started.md开始,然后将匹配的功能合并到其锚点(PROPS、EVENTS、UI_BUTTONS、HANDLERS)中。如果没有匹配的关键词,仅返回基础示例。
Checklist Before Generating Code
生成代码前的检查清单
- Count the settings properties: 1-3? → Use inline | 4+? → Use separate razor code block
- Is the component prop simple enough? Yes → Keep inline | No → Extract to separate razor code block
- Are Default values set for properties explicitly? Yes → Remove | No → Keep it
- 统计设置属性数量: 1-3个?→ 使用内联 | 4个及以上?→ 使用单独的Razor代码块
- 组件属性是否足够简单? 是 → 保持内联 | 否 → 提取到单独的Razor代码块
- 是否为属性显式设置了默认值? 是 → 删除 | 否 → 保留
🎯 MVC Setup & Configuration
🎯 MVC设置与配置
| File | Purpose |
|---|---|
| getting-started.md | Minimal PDF Viewer with documentPath, height, and width. Base template for all samples. |
| enable-properties.md | Enable/disable specific features (toolbar, annotations, forms, navigation, text selection, download, print). |
| general-properties.md | Configure core viewer properties and behavior (documentPath, width/height, locale, zoom/initialRenderPages), server/integration settings (serviceUrl, ajaxRequestSettings, serverActionSettings), resource loading (resourceUrl, customFonts), and performance/retry options. |
| 文件 | 用途 |
|---|---|
| getting-started.md | 带有documentPath、高度和宽度的最小化PDF查看器。所有示例的基础模板。 |
| enable-properties.md | 启用/禁用特定功能(工具栏、注释、表单、导航、文本选择、下载、打印)。 |
| general-properties.md | 配置核心查看器属性和行为(documentPath、宽/高、区域设置、缩放/初始渲染页面)、服务器/集成设置(serviceUrl、ajaxRequestSettings、serverActionSettings)、资源加载(resourceUrl、自定义字体)以及性能/重试选项。 |
Context Menu
上下文菜单
| File | Purpose |
|---|---|
| contextmenu.md | Context-aware context menu for text, annotations, and form fields; add custom items via |
| 文件 | 用途 |
|---|---|
| contextmenu.md | 针对文本、注释和表单字段的上下文感知菜单;通过 |
Navigation Features
导航功能
| File | Purpose |
|---|---|
| navigation.md | Enable/disable page navigation (first/last/previous/next/go to page), thumbnail view and navigation, hyperlink support (internal and external links), table of contents navigation, programmatic navigation methods, and navigation-related events. |
| bookmark-navigation.md | Enable/disable and show/hide bookmark navigation. Programmatically retrieve bookmarks for a document |
| 文件 | 用途 |
|---|---|
| navigation.md | 启用/禁用页面导航(首页/末页/上一页/下一页/跳转到指定页)、缩略图视图和导航、超链接支持(内部和外部链接)、目录导航、程序化导航方法以及导航相关事件。 |
| bookmark-navigation.md | 启用/禁用和显示/隐藏书签导航。以程序化方式检索文档的书签 |
MVC Viewing and Interaction
MVC查看与交互
| File | Purpose |
|---|---|
| viewing-and-interaction.md | Understand interaction modes (Text Selection/Pan), page scrolling & viewing behavior, panning operations, feature modules for modular architecture, enabling/disabling specific viewing features, and MVC viewing capabilities. |
| magnification.md | Configure zoom levels & zoom percentages, zoom modes (fit to page/fit to width/fit to visible area/automatic), custom zoom control, programmatic zoom operations, zoom toolbar configuration, and mouse wheel zoom behavior. |
| 文件 | 用途 |
|---|---|
| viewing-and-interaction.md | 了解交互模式(文本选择/平移)、页面滚动与查看行为、平移操作、模块化架构的功能模块、启用/禁用特定查看功能以及MVC查看功能。 |
| magnification.md | 配置缩放级别和缩放百分比、缩放模式(适合页面/适合宽度/适合可见区域/自动)、自定义缩放控件、程序化缩放操作、缩放工具栏配置以及鼠标滚轮缩放行为。 |
Toolbar Configuration
工具栏配置
| File | Purpose |
|---|---|
| toolbar-customization.md | Customize the PDF viewer primary, form designer, annotation toolbars. Programmatically enable/disable toolbar, enable/disable and show/hide toolbar items. Lists the toolbar items available for toolbars. Enable/disable form designer, annotation or primary toolbars during initialization. Create a custom toolbar item |
| toolbar-reference.md | Use the toolbar API methods/properties to show/hide the primary/annotation/navigation/redaction toolbars. |
| toolbar-customization-scenarios.md | Common toolbar customization scenarios |
| 文件 | 用途 |
|---|---|
| toolbar-customization.md | 自定义PDF查看器的主工具栏、表单设计器工具栏、注释工具栏。以程序化方式启用/禁用工具栏、启用/禁用和显示/隐藏工具栏项。列出各工具栏可用的工具栏项。初始化时启用/禁用表单设计器、注释或主工具栏。创建自定义工具栏项 |
| toolbar-reference.md | 使用工具栏API方法/属性显示/隐藏主工具栏/注释工具栏/导航工具栏/红action工具栏。 |
| toolbar-customization-scenarios.md | 常见的工具栏定制场景 |
Annotations and Markup
注释与标记
| File | Purpose |
|---|---|
| annotation-overview.md | Information about ink/freehand, sticky notes/comments, handwritten/digital signatures annotations and programmatically adding them. Overall annotation types and common default annotation settings example |
| text-markup-annotations.md | Programmatically add text markup annotations (Highlight, underline, strikethrough, squiggly). Manipulate default settings for each textmarkup annotations |
| shape-annotations.md | Information on shape annotations (Line, Arrow, Rectangle, Circle, Polygon). Programmatically adding shape annotations and manipulating default shape settings for each shape annotations |
| measurement-annotations.md | Information on measurement annotations (Distance, Perimeter, Area, Radius, Volume). Programmatically adding measurement annotations and manipulating default settings for each measurement annotations |
| stamp-annotation.md | Information on stamp annotations and different types of stamps available. Programmatically adding stamp annotations |
| free-text-annotations.md | Information on free text annotation. Programmatically adding free text annotations |
| annotation-settings.md | Configure appearance (colors, opacity, borders, styles) and behavior (restrictions, locking, printing) for all annotation types. Apply settings globally or per annotation type. Customize annotation selector (resizer, selection border). Set author, subject, and custom data. Control annotation-related component properties (toolbar visibility, signature settings, export options, drawing constraints). |
| annotation-events.md | Handle annotation lifecycle events (add, delete, move, resize, select, property change). |
| annotation-operations.md | Programmatically manipulate annotations like selection, moving and resizing, deleting, locking and importing and exporting annotations |
| annotation-use-cases.md | Common scenarios on how annotations can be programmatically manipulated |
| shape-label-settings.md | Configure shape and measure annotation label appearance (fill color, font, font size, opacity) and default content (label text, notes). |
| redaction-annotation.md | Hide and permanently remove sensitive information in PDFs. Mark content by area or full page, configure overlay text and styling, apply redactions irreversibly, search text and auto-redact, and manage redaction annotations programmatically. |
| 文件 | 用途 |
|---|---|
| annotation-overview.md | 关于墨迹/手绘、便签/评论、手写/数字签名注释的信息,以及如何以程序化方式添加这些注释。所有注释类型的概述和常见默认注释设置示例 |
| text-markup-annotations.md | 以程序化方式添加文本标记注释(高亮、下划线、删除线、波浪线)。为每种文本标记注释操作默认设置 |
| shape-annotations.md | 关于形状注释(线条、箭头、矩形、圆形、多边形)的信息。以程序化方式添加形状注释并为每种形状注释操作默认形状设置 |
| measurement-annotations.md | 关于测量注释(距离、周长、面积、半径、体积)的信息。以程序化方式添加测量注释并为每种测量注释操作默认设置 |
| stamp-annotation.md | 关于图章注释和可用的不同类型图章的信息。以程序化方式添加图章注释 |
| free-text-annotations.md | 关于自由文本注释的信息。以程序化方式添加自由文本注释 |
| annotation-settings.md | 配置所有注释类型的外观(颜色、透明度、边框、样式)和行为(限制、锁定、打印)。全局或按注释类型应用设置。自定义注释选择器(调整器、选择边框)。设置作者、主题和自定义数据。控制与注释相关的组件属性(工具栏可见性、签名设置、导出选项、绘图约束)。 |
| annotation-events.md | 处理注释生命周期事件(添加、删除、移动、调整大小、选择、属性更改)。 |
| annotation-operations.md | 以程序化方式操作注释,如选择、移动和调整大小、删除、锁定以及导入和导出注释 |
| annotation-use-cases.md | 关于如何以程序化方式操作注释的常见场景 |
| shape-label-settings.md | 配置形状和测量注释标签的外观(填充颜色、字体、字体大小、透明度)和默认内容(标签文本、注释)。 |
| redaction-annotation.md | 隐藏并永久删除PDF中的敏感信息。按区域或整页标记内容,配置覆盖文本和样式,不可逆地应用红action,搜索文本并自动红action,以及以程序化方式管理红action注释。 |
Forms Management
表单管理
| File | Purpose |
|---|---|
| form-fields-overview.md | Fill and design PDF forms, manage form fields (field types like textbox/password/checkbox/radio/dropdown/listbox/signature), create fields programmatically, use the form designer toolbar/UI interactions, configure field properties/customization, apply validation rules and constraints/settings, use form field API methods, and handle import/export form data including custom field data. |
| supported-form-fields.md | Supported form field types and programmatically add each |
| form-fields-props.md | Lists properties of form fields. Lists common properties and specific properties to each field. Manipulate form field settings |
| import-export-form-data.md | Programmatically import and export form field data |
| form-operations.md | Programmatically manipulate form fields including updating properties and values, moving and resizing, deleting, grouping, adding custom data & retrieving form field data |
| form-field-validation.md | Enable/disable form field validation. Programmatic flow of form field validation and examples |
| form-field-settings.md | Configure default properties for form fields (text, checkbox, radio, dropdown, signature). |
| form-field-events.md | Handle form field interaction events (focus, blur, value change, validation). |
| 文件 | 用途 |
|---|---|
| form-fields-overview.md | 填写和设计PDF表单,管理表单字段(文本框/密码框/复选框/单选按钮/下拉框/列表框/签名等字段类型),以程序化方式创建字段,使用表单设计器工具栏/UI交互,配置字段属性/定制,应用验证规则和约束/设置,使用表单字段API方法,以及处理表单数据的导入/导出(包括自定义字段数据)。 |
| supported-form-fields.md | 支持的表单字段类型以及如何以程序化方式添加每种类型 |
| form-fields-props.md | 列出表单字段的属性。列出公共属性和每种字段的特定属性。操作表单字段设置 |
| import-export-form-data.md | 以程序化方式导入和导出表单字段数据 |
| form-operations.md | 以程序化方式操作表单字段,包括更新属性和值、移动和调整大小、删除、分组、添加自定义数据以及检索表单字段数据 |
| form-field-validation.md | 启用/禁用表单字段验证。表单字段验证的程序化流程和示例 |
| form-field-settings.md | 配置表单字段(文本、复选框、单选按钮、下拉框、签名)的默认属性。 |
| form-field-events.md | 处理表单字段交互事件(聚焦、失焦、值更改、验证)。 |
Text Operations
文本操作
| File | Purpose |
|---|---|
| text-search.md | Implement text search in PDFs: search functionality, search options (case-sensitive/whole word), highlight search results, find next/previous occurrences, programmatic text search methods, search completion events, and custom highlight colors. Configure text extraction options/settings and programmatically extract text from pages. |
| text-selection.md | Enable text selection and text extraction: selection modes/behavior, copy selected text, text selection events, programmatic selection and text collections/bounds. |
| 文件 | 用途 |
|---|---|
| text-search.md | 在PDF中实现文本搜索:搜索功能、搜索选项(区分大小写/全字匹配)、高亮搜索结果、查找下一个/上一个匹配项、程序化文本搜索方法、搜索完成事件以及自定义高亮颜色。配置文本提取选项/设置并以程序化方式从页面提取文本。 |
| text-selection.md | 启用文本选择和文本提取:选择模式/行为、复制选定文本、文本选择事件、程序化选择和文本集合/边界。 |
Document Operations
文档操作
| File | Purpose |
|---|---|
| opening-pdfs.md | Load PDFs from URL/local paths/base64, open encrypted/password-protected PDFs, support programmatic document loading, handle document load events/lifecycle, and manage load failures/errors. |
| saving-and-downloading.md | Download PDFs, save PDFs with annotations/modifications, download with form data included, retrieve PDFs as base64, customize download events, and set custom download filenames. |
| printing-and-organizing.md | Print PDFs (including print options like page range/quality and silent printing), handle print events, organize pages (overview/rearrange/reorder/rotate/delete), copy/duplicate/extract pages to a new document, and use the page organizer toolbar with programmatic + mobile page organization. |
| 文件 | 用途 |
|---|---|
| opening-pdfs.md | 从URL/本地路径/base64加载PDF,打开加密/受密码保护的PDF,支持程序化文档加载,处理文档加载事件/生命周期,以及管理加载失败/错误。 |
| saving-and-downloading.md | 下载PDF,保存带有注释/修改的PDF,下载包含表单数据的PDF,以base64格式检索PDF,自定义下载事件,以及设置自定义下载文件名。 |
| printing-and-organizing.md | 打印PDF(包括页面范围/质量和静默打印等打印选项),处理打印事件,整理页面(概览/重新排列/重新排序/旋转/删除),复制/复制/提取页面到新文档,以及使用页面整理工具栏进行程序化+移动端页面整理。 |
⚙️ Advanced Features
⚙️ 高级功能
| File | Purpose | Route When User Asks About |
|---|---|---|
| api-methods.md | Programmatic control: load documents, manage forms, annotations, extract text, undo/redo, navigation APIs. | "load PDF programmatically", "API methods", "export form data", "extract text", "undo/redo", "programmatic control" |
| events.md | Complete list of all PDFViewer events (document load, download, annotations, forms, search, navigation). | "event list", "all events", "available events", "event reference", "event handlers" |
| 文件 | 用途 | 用户询问以下内容时路由至此 |
|---|---|---|
| api-methods.md | 程序化控制:加载文档、管理表单、注释、提取文本、撤销/重做、导航API。 | "load PDF programmatically", "API methods", "export form data", "extract text", "undo/redo", "programmatic control" |
| events.md | PDFViewer所有事件的完整列表(文档加载、下载、注释、表单、搜索、导航)。 | "event list", "all events", "available events", "event reference", "event handlers" |