Struct DocumentStyle

Source
pub struct DocumentStyle {
Show 19 fields pub background: Option<Background>, pub default_footer_id: Option<String>, pub default_header_id: Option<String>, pub even_page_footer_id: Option<String>, pub even_page_header_id: Option<String>, pub first_page_footer_id: Option<String>, pub first_page_header_id: Option<String>, pub flip_page_orientation: Option<bool>, pub margin_bottom: Option<Dimension>, pub margin_footer: Option<Dimension>, pub margin_header: Option<Dimension>, pub margin_left: Option<Dimension>, pub margin_right: Option<Dimension>, pub margin_top: Option<Dimension>, pub page_number_start: Option<i32>, pub page_size: Option<Size>, pub use_custom_header_footer_margins: Option<bool>, pub use_even_page_header_footer: Option<bool>, pub use_first_page_header_footer: Option<bool>,
}
Expand description

The style of the document.

This type is not used in any activity, and only used as part of another schema.

Fields§

§background: Option<Background>

The background of the document. Documents cannot have a transparent background color.

§default_footer_id: Option<String>

The ID of the default footer. If not set, there’s no default footer. This property is read-only.

§default_header_id: Option<String>

The ID of the default header. If not set, there’s no default header. This property is read-only.

§even_page_footer_id: Option<String>

The ID of the footer used only for even pages. The value of use_even_page_header_footer determines whether to use the default_footer_id or this value for the footer on even pages. If not set, there’s no even page footer. This property is read-only.

§even_page_header_id: Option<String>

The ID of the header used only for even pages. The value of use_even_page_header_footer determines whether to use the default_header_id or this value for the header on even pages. If not set, there’s no even page header. This property is read-only.

§first_page_footer_id: Option<String>

The ID of the footer used only for the first page. If not set then a unique footer for the first page does not exist. The value of use_first_page_header_footer determines whether to use the default_footer_id or this value for the footer on the first page. If not set, there’s no first page footer. This property is read-only.

§first_page_header_id: Option<String>

The ID of the header used only for the first page. If not set then a unique header for the first page does not exist. The value of use_first_page_header_footer determines whether to use the default_header_id or this value for the header on the first page. If not set, there’s no first page header. This property is read-only.

§flip_page_orientation: Option<bool>

Optional. Indicates whether to flip the dimensions of the page_size, which allows changing the page orientation between portrait and landscape.

§margin_bottom: Option<Dimension>

The bottom page margin. Updating the bottom page margin on the document style clears the bottom page margin on all section styles.

§margin_footer: Option<Dimension>

The amount of space between the bottom of the page and the contents of the footer.

§margin_header: Option<Dimension>

The amount of space between the top of the page and the contents of the header.

§margin_left: Option<Dimension>

The left page margin. Updating the left page margin on the document style clears the left page margin on all section styles. It may also cause columns to resize in all sections.

§margin_right: Option<Dimension>

The right page margin. Updating the right page margin on the document style clears the right page margin on all section styles. It may also cause columns to resize in all sections.

§margin_top: Option<Dimension>

The top page margin. Updating the top page margin on the document style clears the top page margin on all section styles.

§page_number_start: Option<i32>

The page number from which to start counting the number of pages.

§page_size: Option<Size>

The size of a page in the document.

§use_custom_header_footer_margins: Option<bool>

Indicates whether DocumentStyle margin_header, SectionStyle margin_header and DocumentStyle margin_footer, SectionStyle margin_footer are respected. When false, the default values in the Docs editor for header and footer margin are used. This property is read-only.

§use_even_page_header_footer: Option<bool>

Indicates whether to use the even page header / footer IDs for the even pages.

§use_first_page_header_footer: Option<bool>

Indicates whether to use the first page header / footer IDs for the first page.

Trait Implementations§

Source§

impl Clone for DocumentStyle

Source§

fn clone(&self) -> DocumentStyle

Returns a copy of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for DocumentStyle

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for DocumentStyle

Source§

fn default() -> DocumentStyle

Returns the “default value” for a type. Read more
Source§

impl<'de> Deserialize<'de> for DocumentStyle

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Serialize for DocumentStyle

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl Part for DocumentStyle

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts 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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts 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
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<T> ErasedDestructor for T
where T: 'static,