diff options
| author | Laurenz <laurmaedje@gmail.com> | 2025-02-05 14:24:10 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-02-05 13:24:10 +0000 |
| commit | 029ae4a5ea7ad1e52112ce26b6d38ce1750dae3f (patch) | |
| tree | 0c56e8c9898efff5e6735750e4291605e25a0d3f /crates/typst-library/src/pdf | |
| parent | 25f6a7ab161b2106c22a9997a68afee60ddb7412 (diff) | |
Export target docs (#5812)
Co-authored-by: Martin Haug <3874949+reknih@users.noreply.github.com>
Diffstat (limited to 'crates/typst-library/src/pdf')
| -rw-r--r-- | crates/typst-library/src/pdf/mod.rs | 19 |
1 files changed, 5 insertions, 14 deletions
diff --git a/crates/typst-library/src/pdf/mod.rs b/crates/typst-library/src/pdf/mod.rs index 3bd3b0c5..786a3637 100644 --- a/crates/typst-library/src/pdf/mod.rs +++ b/crates/typst-library/src/pdf/mod.rs @@ -4,21 +4,12 @@ mod embed; pub use self::embed::*; -use crate::foundations::{category, Category, Module, Scope}; - -/// PDF-specific functionality. -#[category] -pub static PDF: Category; - -/// Hook up the `pdf` module. -pub(super) fn define(global: &mut Scope) { - global.start_category(PDF); - global.define("pdf", module()); -} +use crate::foundations::{Module, Scope}; /// Hook up all `pdf` definitions. pub fn module() -> Module { - let mut scope = Scope::deduplicating(); - scope.define_elem::<EmbedElem>(); - Module::new("pdf", scope) + let mut pdf = Scope::deduplicating(); + pdf.start_category(crate::Category::Pdf); + pdf.define_elem::<EmbedElem>(); + Module::new("pdf", pdf) } |
