#[non_exhaustive]pub enum Action {
Show 14 variants
GoTo(Destination),
GoToR {
filename: String,
dest: Destination,
new_window: Option<bool>,
},
GoToE {
target: String,
dest: Destination,
new_window: Option<bool>,
},
Launch {
filename: String,
new_window: Option<bool>,
},
Uri {
uri: String,
is_map: bool,
},
Named(String),
JavaScript(String),
SubmitForm {
url: String,
fields: Vec<String>,
flags: u32,
},
ResetForm {
fields: Vec<String>,
flags: u32,
},
Hide {
targets: Vec<String>,
hide: bool,
},
Sound,
Movie,
Thread {
target: Option<String>,
},
Other {
subtype: String,
},
}Expand description
PDF action — what to do when a link / outline / page event fires.
stet does not execute most of these (no JS engine, no network access for URIs); the action is exposed as data for consumers that want to render link panels, route handlers, or convert to other formats.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
GoTo(Destination)
/S /GoTo — jump to a destination in this document.
GoToR
/S /GoToR — jump to a destination in another PDF.
GoToE
/S /GoToE — jump into an embedded PDF file.
Launch
/S /Launch — launch an application or open a file.
Uri
/S /URI — open a URI / hyperlink.
Named(String)
/S /Named — viewer-defined named action (/NextPage,
/PrevPage, /FirstPage, /LastPage, /Print, …).
JavaScript(String)
/S /JavaScript — execute the given JS source. Exposed as raw
source; stet does not evaluate.
SubmitForm
/S /SubmitForm — submit form data to a URL.
ResetForm
/S /ResetForm — reset form fields to their default values.
Hide
/S /Hide — hide / show form fields by name.
Sound
/S /Sound — deprecated. Marker only; we don’t expose audio data.
Movie
/S /Movie — deprecated. Marker only.
Thread
/S /Thread — article thread navigation.
Other
Unknown /S value. The raw subtype name is preserved for
callers that want to recognise their own extensions.
Trait Implementations§
impl StructuralPartialEq for Action
Auto Trait Implementations§
impl Freeze for Action
impl RefUnwindSafe for Action
impl Send for Action
impl Sync for Action
impl Unpin for Action
impl UnsafeUnpin for Action
impl UnwindSafe for Action
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more