pub struct LinkStyle {
pub color: ColorRgb,
pub italic: bool,
pub bold: bool,
pub underline: bool,
pub underline_thickness: f32,
}Expand description
How [text](url) links are visually distinguished from body text.
The PDF link annotation is created regardless of these settings;
these only affect the glyphs underneath so readers spot the link
without hovering.
Fields§
§color: ColorRgbText colour applied to the link’s glyphs.
italic: boolRender link text in italic.
bold: boolRender link text in bold (font weight 700).
underline: boolDraw a stroked rule directly below each line of the link’s
text, in color and at underline_thickness. Useful when
colour alone isn’t enough to make the link stand out (e.g.
for accessibility or B&W printing).
underline_thickness: f32Stroke thickness for the underline rule, in PDF points.
Ignored when underline = false.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for LinkStyle
impl<'de> Deserialize<'de> for LinkStyle
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Forget for LinkStyle
impl Freeze for LinkStyle
impl Move for LinkStyle
impl RefUnwindSafe for LinkStyle
impl Send for LinkStyle
impl Sync for LinkStyle
impl Unpin for LinkStyle
impl UnsafeUnpin for LinkStyle
impl UnwindSafe for LinkStyle
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<U, T> ToOwnedObj<U> for Twhere
U: FromObjRef<T>,
impl<U, T> ToOwnedObj<U> for Twhere
U: FromObjRef<T>,
Source§fn to_owned_obj(&self, data: FontData<'_>) -> U
fn to_owned_obj(&self, data: FontData<'_>) -> U
Convert this type into
T, using the provided data to resolve any offsets.